Please select To the mobile version | Continue to access the desktop computer version

OrangePi

 Login            
 Register            
Search
Hot search: orangepi
View: 3614|Reply: 6

oPi One Module gc2035 not found in directory /lib/modules/4.19.25-sunxi

[Copy link]

5

Threads

34

Posts

151

Credits

Registered member

Rank: 2

Credits
151
Post time 2019-4-18 07:51:40 | Show all posts |Read mode
  1. # cat /etc/armbian-release | grep BOARD
  2. BOARD=orangepione
  3. BOARD_NAME="Orange Pi One"
  4. BOARDFAMILY=sun8i
  5. BOARD_TYPE=conf
  6. # cat /etc/os-release
  7. PRETTY_NAME="Debian GNU/Linux 9 (stretch)"
  8. NAME="Debian GNU/Linux"
  9. VERSION_ID="9"
  10. VERSION="9 (stretch)"
  11. ID=debian
  12. HOME_URL="https://www.debian.org/"
  13. SUPPORT_URL="https://www.debian.org/support"
  14. BUG_REPORT_URL="https://bugs.debian.org/"
  15. # modprobe gc2035
  16. <font color="Red">modprobe: FATAL: Module gc2035 not found in directory /lib/modules/4.19.25-sunxi</font>
  17. # modprobe vfe_v4l2
  18. <font color="Red">modprobe: FATAL: Module vfe_v4l2 not found in directory /lib/modules/4.19.25-sunxi
  19. <font color="Black"># find /lib/modules/ | grep -i -e vfe -e 2035 | wc
  20.       0       0       0
  21. # ls /dev/vid*
  22. ls: cannot access '/dev/vid*': No such file or directory
  23. </font>
  24. </font>
Copy the Code



Same with Armbian_5.75_Orangepione_Ubuntu_bionic_next_4.19.20.img

These are basic steps I found in those tutos:
http://www.orangepi.org/orangepi ... thread&tid=3049
https://forum.armbian.com/topic/ ... ments#comment-38493
https://projetsdiy.fr/orange-pi- ... mp-csi-test-motion/

9

Threads

635

Posts

4288

Credits

Moderator

Rank: 7Rank: 7Rank: 7

Credits
4288
Post time 2019-4-18 13:31:21 | Show all posts
Perhaps because this driver was not ported to this Linux version yet?

5

Threads

34

Posts

151

Credits

Registered member

Rank: 2

Credits
151
 Author| Post time 2019-4-19 05:22:45 | Show all posts
After triple checking ... you are right, the seller tells to use Android

More in a few days. Will still try other distros ... (don't burn all of them, just download, extract image, and run find in /lib/modules)

5

Threads

34

Posts

151

Credits

Registered member

Rank: 2

Credits
151
 Author| Post time 2019-4-19 21:45:34 | Show all posts
Edited by DoubleHP at 2019-4-24 03:03

After digging a bit:

Driver not present. Kernel 4.19 . No way to ever get any CSI cam work on 4.19, cause it lacks the CSI support; wait for a further 4.X kernel.
Armbian_5.75_Orangepione_Debian_stretch_next_4.19.20.7z
Armbian_5.75_Orangepione_Ubuntu_bionic_next_4.19.20.7z

I am said 4.21 may bring CSI in ... but the source is uncertain.

Driver gc2035 present in /lib/modules; kernel 3.4.*
Lubuntu_1404_For_OrangePiPC_v0_8_0_.img.xz : modprobe gc2035 => "could not insert 'gc2035': Exec format error". Not going to dig this kind of issue.
Raspbian_For_OrangePi_PC_v0_8_0.img.xz : modprobe gc2035 => "could not insert 'gc2035': Exec format error". Not going to dig this kind of issue.
ZeroShell-3.7.1A-OPIPC.img.gz
: image contains gc2035.ko under 3.4 branch. => "[CSI_ERR][GC2035]chip found is not an target chip." ; in Armbian this is usually fixed with messing some pins but sunxi-pio is not available in ZeroShell; there is probably an other way to do it; not going to dig. If you want to dig, try to find how to rise PA7 PA7 and PG11 with ZeroShell tools.
Armbian_5.75_Orangepione_Ubuntu_xenial_default_3.4.113_desktop.7z : /lib/modules/3.4.113-sun8i/kernel/drivers/media/video/sunxi-vfe/device/gc2035.ko => produces sane pictures. (see below)
ubuntu_lxde_desktop_OrangePipc_v0_9_1.img.xz : /lib/modules/3.4.112/kernel/drivers/media/video/sunxi-vfe/device/gc2035.ko => produces sane pictures. (see below)

About Zeroshell, note that the serial baudrate is 115200 like for other oPis, and not 38400 as explained in their docs.

OrangePi_One_Android_4.4_zh_ov5640_v1.1.img.tar.gz : does not seem to boot. No image on HDMI, no activity on ethernet. No green or red LED. (try again)
OrangePi_Pc_One_Android_7.0_Beta.tar.gz : does not seem to boot. No image on HDMI, no activity on ethernet. No green or red LED. (try again)
Could not mount images; had to burn them. Android are the images recommended by the seller of my kit (it was a bundle kit OpiOne+cam).

5

Threads

34

Posts

151

Credits

Registered member

Rank: 2

Credits
151
 Author| Post time 2019-4-22 21:57:25 | Show all posts
Edited by DoubleHP at 2019-4-24 03:04

I have had a stupid idead: since all images having the driver I want are using 3.4 kernels, why not saerch for a deprecated Armbian in archives ?

I have great hopes for Armbian_5.75_Orangepione_Ubuntu_xenial_default_3.4.113_desktop.7z but ... I would prefer a non-Ubuntu Debian; where can I find a Debian 3.4 that would not be Ubuntu ? https://dl.armbian.com/orangepione/archive/ . Google did not help.

Now burning Armbian_5.75_Orangepione_Ubuntu_xenial_default_3.4.113_desktop.7z ... EDIT : and 2h later ... still not working.

I will also reburn all previous images, and double check HDMI, USB, and serial outputs. In particular, if no Android can work, I will ask for refund. https://fr.aliexpress.com/item/Orange-Pi-One-SET-9-Orange-Pi-One-and-Camera-Camera-with-wide-angle-lens-for/32660642513.html?spm=a2g0s.9042311.0.0.27426c37iv2yIP set 9.

Edit:
- at the moment, 4.19 kernels don't support CSI at all. Must use 3.4 kernels. I am said 4.21 may bring CSI in ... but the source is uncertain.
- many people need to mess with <<sunxi-pio -m "PG11<1><0><1><1>">> (must be run before any modprobe)
- I have read "Armbian_5.20_Orangepipc_Debian_jessie_3.4.112.7z" works fine out of the box, but I am not able to find any miror providing this image.
- I have seen some distros use gc_2035 instead of gc2035
- some people recommend "modprobe gc_2035 hres=1" instead of just "modprobe gc2035"
- some people mention that after some failures, a power cycle is required, and a simple software reboot may not suffice.

5

Threads

34

Posts

151

Credits

Registered member

Rank: 2

Credits
151
 Author| Post time 2019-4-23 03:34:44 | Show all posts
Edited by DoubleHP at 2019-4-23 03:52

I am getting somewhere with ubuntu_lxde_desktop_OrangePipc_v0_9_1.img.xz

I have tried to plug raw camera (without ribbon and adapter) 3 different ways: lens up, lens down, not connected at all. In all 3 cases, I get the same output:

  1. root@OrangePI:~# ls /dev/vid*
  2. ls: cannot access '/dev/vid*': No such file or directory
  3. root@OrangePI:~# modprobe gc2035 hres=0
  4. root@OrangePI:~# modprobe vfe_v4l2
  5. root@OrangePI:~# sleep 1
  6. root@OrangePI:~# ls /dev/vid*
  7. /dev/video0
  8. root@OrangePI:~# dmesg | grep -i -e csi -e 2035 -e isp
  9. [    0.547947] [DISP]disp_module_init
  10. [    0.548216] cmdline,init_disp=
  11. [    0.548252] cmdline,disp=
  12. [    0.554691] [DISP] Fb_map_kernel_logo,line:932:Fb_map_kernel_logo failed!
  13. [    0.581312] [DISP]disp_module_init finish
  14. [    4.554267] cmdline,disp=
  15. [    5.200042] [DISP] disp_device_attached_and_enable,line:159:attched ok, mgr0<-->device0, type=4, mode=5
  16. [   23.993592] [DISP] disp_ioctl,line:1584:para err in disp_ioctl, cmd = 0x0,screen id = 65536
  17. [   66.420288] [VFE]dev->isp_sel = 0
  18. [   66.433750] [ISP] isp platform_id = 5!
  19. [   66.440116] [VFE]Find sensor name is "gc2035", i2c address is 78, type is "YUV" !
  20. [   66.440126] [VFE]Sub device register "gc2035" i2c_addr = 0x78 start!
  21. [   66.508237] [CSI_ERR][GC2035]sensor_read err at sensor_detect!
  22. [   66.508245] [CSI_ERR][GC2035]chip found is not an target chip.
  23. [   66.576134] [VFE]Sub device register "gc2035" failed!
  24. root@OrangePI:~# ls /dev/vid*
  25. /dev/video0
  26. root@OrangePI:~#
Copy the Code


=> This distribution accepts to load the driver and create the node, but, behave exactly the same way whether device is plugged or not.

  1. root@OrangePI:~# uname -a
  2. Linux OrangePI 3.4.112 #4 SMP PREEMPT Wed Dec 7 09:46:40 CST 2016 armv7l armv7l armv7l GNU/Linux
  3. root@OrangePI:~# cat /etc/lsb-release
  4. DISTRIB_ID=Ubuntu
  5. DISTRIB_RELEASE=16.04
  6. DISTRIB_CODENAME=xenial
  7. DISTRIB_DESCRIPTION="Ubuntu 16.04.1 LTS"
Copy the Code


Now using adapter:

  1. root@OrangePI:~# i2cdetect -y 0
  2.      0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
  3. 00:          -- -- -- -- -- -- -- -- -- -- -- -- --
  4. 10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
  5. 20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
  6. 30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
  7. 40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
  8. 50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
  9. 60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
  10. 70: -- -- -- -- -- -- -- --
  11. root@OrangePI:~# i2cdetect -y 1
  12.      0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
  13. 00:          -- -- -- -- -- -- -- -- -- -- -- -- --
  14. 10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
  15. 20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
  16. 30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
  17. 40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
  18. 50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
  19. 60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
  20. 70: -- -- -- -- -- -- -- --

  21. root@OrangePI:~# ls /dev/vid*
  22. ls: cannot access '/dev/vid*': No such file or directory
  23. root@OrangePI:~# modprobe gc2035 hres=0
  24. root@OrangePI:~# modprobe vfe_v4l2
  25. root@OrangePI:~# sleep 1
  26. root@OrangePI:~# ls /dev/vid*
  27. /dev/video0
  28. root@OrangePI:~# dmesg | grep -i -e csi -e 2035 -e isp
  29. [   95.723834] [VFE]dev->isp_sel = 0
  30. [   95.737679] [ISP] isp platform_id = 5!
  31. [   95.740138] [VFE]Find sensor name is "gc2035", i2c address is 78, type is "YUV" !
  32. [   95.740148] [VFE]Sub device register "gc2035" i2c_addr = 0x78 start!
  33. [   95.807757] [CSI][GC2035]V4L2_IDENT_SENSOR=2035[CSI][GC2035]disalbe oe!
  34. [   96.255133] [VFE]Sub device register "gc2035" is OK!
  35. root@OrangePI:~# ls /dev/vid*
  36. /dev/video0
Copy the Code


=> at last, my hardware is fine.

  1. # v4l2-ctl -d /dev/video0 --list-formats | head -n 30
  2. ioctl: VIDIOC_ENUM_FMT
  3.         Index       : 0
  4.         Type        : Video Capture
  5.         Pixel Format: '422P'
  6.         Name        : planar YUV 422

  7.         Index       : 1
  8.         Type        : Video Capture
  9.         Pixel Format: 'YU12'
  10.         Name        : planar YUV 420

  11.         Index       : 2
  12.         Type        : Video Capture
  13.         Pixel Format: 'YV12'
  14.         Name        : planar YVU 420

  15.         Index       : 3
  16.         Type        : Video Capture
  17.         Pixel Format: 'NV16'
  18.         Name        : planar YUV 422 UV combined

  19.         Index       : 4
  20.         Type        : Video Capture
  21.         Pixel Format: 'NV12'
  22.         Name        : planar YUV 420 UV combined

  23.         Index       : 5
  24.         Type        : Video Capture
  25.         Pixel Format: 'NV61'
  26.         Name        : planar YUV 422 VU combined
  27. root@OrangePI:~# v4l2-ctl -d /dev/video0 --list-formats | wc
  28.     121     377    2512
  29. root@OrangePI:~# fswebcam -r 1600x1200 -p YUV420P - > /tmp/cam1600x1200.jpg
  30. --- Opening /dev/video0...
  31. Trying source module v4l2...
  32. /dev/video0 opened.
  33. No input was specified, using the first.
  34. --- Capturing frame...
  35. Captured frame in 0.00 seconds.
  36. --- Processing captured image...
  37. Writing JPEG image to '-'.
Copy the Code


The proper way to connect the ribbons depends on the exact hardware you buy. The idea is that the shiny face of ribbons usually go face down (not facing the lever)

Note that v4l2-ctl will produce this output as soon as modprobe is fine, even if the camera is not connected. So, this command is not reliable to check if hardware is working fine.

Here is a better check:
  1. root@OrangePI:~# fswebcam -r 1600x1200 -p YUV420P - > /tmp/cam1600x1200.jpg
  2. --- Opening /dev/video0...
  3. Trying source module v4l2...
  4. /dev/video0 opened.
  5. No input was specified, using the first.
  6. Unable to query input 0.
  7. VIDIOC_ENUMINPUT: Invalid argument
Copy the Code


It will fail two different ways if camera is not connected, and/or driver not loaded. And will produce a sane picture if it's all fine.

This bunch of commands can be run in one shot.  ubuntu_lxde_desktop_OrangePipc_v0_9_1.img produces a lot of garbage in dmesg, so buffer is running out in 10 or 20s. The last command must be run less than 5s after modprobe, because later than 10s, it won't be able to find relevant lines.

  1. modprobe gc2035
  2. modprobe vfe_v4l2
  3. sleep 1
  4. ls /dev/vid*
  5. dmesg | grep -i -e csi -e 2035 -e isp | grep -q -e 'Sub device register "gc2035" is OK!' && echo OK
  6. dmesg | grep -i -e csi -e 2035 -e isp | grep -q -e 'Sub device register "gc2035" failed!' && echo BAD
  7. fswebcam -r 1600x1200 -p YUV420P - > /tmp/cam1600x1200.jpg
Copy the Code

5

Threads

34

Posts

151

Credits

Registered member

Rank: 2

Credits
151
 Author| Post time 2019-4-23 04:20:43 | Show all posts
Edited by DoubleHP at 2019-4-23 04:21

Armbian_5.75_Orangepione_Ubuntu_xenial_default_3.4.113_desktop :

Here is how to launch driver and check things are working fine:

  1. sunxi-pio -m "PG11<1><0><1><1>"
  2. modprobe gc2035
  3. modprobe vfe_v4l2
  4. sleep 1
  5. ls /dev/vid*
  6. #dmesg | grep -i -e csi -e 2035 -e isp
  7. dmesg | grep -q -e 'isp platform_id = 5!' && { dmesg | grep -q -e 'V4L2_IDENT_SENSOR=2035' && echo Good ; dmesg | grep -q -e 'sensor_read err at sensor_detect!' && echo "Failed." ; true ; } || echo "You did not try to load the driver."
  8. fswebcam -r 1600x1200 -p YUV420P - > /tmp/cam1600x1200.jpg
Copy the Code
You have to log in before you can reply Login | Register

Points Rules

Archiver|Mobile edition|Darkroom|OrangePi En ( 粤ICP备14086627号-2

2020-7-13 03:59 GMT+8 , Processed in 0.030774 second(s), 22 queries .

Powered by Discuz! X3.2

© 2014-2015 orangepibbs en.

Quick Reply To Top Return to the list