Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ov5647 with Ubuntu 22.04.4 64bit (Jammy Jellyfish) error #51

Closed
Jai-GAY opened this issue Jun 25, 2024 · 26 comments
Closed

ov5647 with Ubuntu 22.04.4 64bit (Jammy Jellyfish) error #51

Jai-GAY opened this issue Jun 25, 2024 · 26 comments

Comments

@Jai-GAY
Copy link

Jai-GAY commented Jun 25, 2024

I can run sudo rpicam-hello but not rpicam-hello, and also I get a Could not open any dmaHeap device error with the camera_ros. What am I missing?
ros-humble-camera-ros (0.1.0-2jammy.20240524.040616)

$ ros2 run camera_ros camera_node 
[1:07:48.481956213] [3588]  INFO Camera camera_manager.cpp:284 libcamera v0.1.0
[1:07:48.519219966] [3601] ERROR RPI dma_heaps.cpp:53 Could not open any dmaHeap device
[1:07:48.536688342] [3601] ERROR RPI vc4.cpp:209 Failed to register camera ov5647 10-0036: -12
terminate called after throwing an instance of 'std::runtime_error'
  what():  no cameras available
[ros2run]: Aborted

$sudo libcamera-hello --list-cameras

Available cameras
-----------------
0 : ov5647 [2592x1944 10-bit GBRG] (/base/soc/i2c0mux/i2c@1/ov5647@36)
    Modes: 'SGBRG10_CSI2P' : 640x480 [58.92 fps - (16, 0)/2560x1920 crop]
                             1296x972 [43.25 fps - (0, 0)/2592x1944 crop]
                             1920x1080 [30.62 fps - (348, 434)/1928x1080 crop]
                             2592x1944 [15.63 fps - (0, 0)/2592x1944 crop]

$ sudo v4l2-ctl --list-devices

bcm2835-codec-decode (platform:bcm2835-codec):
	/dev/video10
	/dev/video11
	/dev/video12
	/dev/video18
	/dev/video31
	/dev/media3

bcm2835-isp (platform:bcm2835-isp):
	/dev/video13
	/dev/video14
	/dev/video15
	/dev/video16
	/dev/video20
	/dev/video21
	/dev/video22
	/dev/video23
	/dev/media1
	/dev/media2

unicam (platform:fe801000.csi):
	/dev/video0
	/dev/media0
$ pip3 show opencv-python
Name: opencv-python
Version: 4.9.0.80
Summary: Wrapper package for OpenCV python bindings.
Home-page: https://github.com/opencv/opencv-python
Author: 
Author-email: 
License: Apache 2.0
Location: /home/pi/.local/lib/python3.10/site-packages
Requires: numpy, numpy, numpy, numpy, numpy
Required-by: cv-3
$cat /boot/firmware/config.txt 
camera_auto_detect=0
start_x=1
dtoverlay=ov5647
$ll /dev/video0
crw-rw-rw-+ 1 root video 81, 0 Jun 25 10:42 /dev/video0
$ll /dev/media0
crw-rw-rw-+ 1 root video 505, 0 Jun 25 10:42 /dev/media0
$cat /etc/udev/rules.d/xxx.rules
SUBSYSTEM=="dma_heap", GROUP="video", MODE="0660"
$sudo rpicam-hello --version
rpicam-apps build: 122b835fb927-intree 09-01-2024 (17:13:42)
libcamera build: v0.1.0+118-563cd78e

[0:38:57.836935566] [3136]  INFO Camera camera_manager.cpp:284 libcamera v0.1.0+118-563cd78e
[0:38:57.912760444] [3140]  WARN RPiSdn sdn.cpp:39 Using legacy SDN tuning - please consider moving SDN inside rpi.denoise
[0:38:57.921061837] [3140]  INFO RPI vc4.cpp:444 Registered camera /base/soc/i2c0mux/i2c@1/ov5647@36 to Unicam device /dev/media0 and ISP device /dev/media1
[0:38:57.921561890] [3140]  INFO RPI pipeline_base.cpp:1142 Using configuration file '/usr/local/share/libcamera/pipeline/rpi/vc4/rpi_apps.yaml'
Made X/EGL preview window
Mode selection for 1296:972:12:P
    SGBRG10_CSI2P,640x480/0 - Score: 3296
    SGBRG10_CSI2P,1296x972/0 - Score: 1000
    SGBRG10_CSI2P,1920x1080/0 - Score: 1349.67
    SGBRG10_CSI2P,2592x1944/0 - Score: 1567
Stream configuration adjusted
[0:38:58.602930195] [3136]  INFO Camera camera.cpp:1183 configuring streams: (0) 1296x972-YUV420 (1) 1296x972-SGBRG10_CSI2P
[0:38:58.605066550] [3140]  INFO RPI vc4.cpp:608 Sensor: /base/soc/i2c0mux/i2c@1/ov5647@36 - Selected sensor format: 1296x972-SGBRG10_1X10 - Selected unicam format: 1296x972-pGAA

Coex_cam_sudo_rpicam-hello_2

@christianrauch
Copy link
Owner

I don't fully follow what commands work and which do not. If the "rpicam-apps" do not work, you should open an issue at https://github.com/raspberrypi/rpicam-apps. If libcamera does not detect any cameras, then there is nothing the node can do. Maybe this is just a configuration issue?

I am also testing on an ov5647 on a Raspberry Pi Zero 2 W, previously with Ubuntu 22.04 and libcamera 0.1, now with Ubuntu 24.04 with libcamera 0.3, without issues. You could try to compile a newer libcamera version from source or simply switch to Ubuntu 24.04.

@Jai-GAY
Copy link
Author

Jai-GAY commented Jun 25, 2024

I don't fully follow what commands work and which do not. If the "rpicam-apps" do not work, you should open an issue at https://github.com/raspberrypi/rpicam-apps. If libcamera does not detect any cameras, then there is nothing the node can do. Maybe this is just a configuration issue?

I am also testing on an ov5647 on a Raspberry Pi Zero 2 W, previously with Ubuntu 22.04 and libcamera 0.1, now with Ubuntu 24.04 with libcamera 0.3, without issues. You could try to compile a newer libcamera version from source or simply switch to Ubuntu 24.04.

So the prerequisites if rpicam-apps (without sudo) work and libcamera detected OV5647, camera_ros should work?

@christianrauch
Copy link
Owner

So the prerequisites if rpicam-apps (without sudo) work and libcamera detected OV5647, camera_ros should work?

Of course, libcamera has to recognise the camera. The ROS node is just using the library to access cameras, read image data, etc. This all should work as normal user without sudo. If you can use libcamera only with sudo, then your user is probably missing the access rights or other settings are missing or wrong.

Can you please confirm if you can or cannot use the libcamera example applications (a.k.a. rpicam-apps) as a regular user without sudo?

You can list the video devices with v4l2-ctl --list-devices as you have shown, and then check the required permissions with ls. E.g.:

$ ls -alh /dev/video0
crw-rw----+ 1 root video 81, 0 Jun 22 19:32 /dev/video0

shows me that the root user and users of the video group have access to that device.

I am not in the video group but I can still access the cameras. But maybe you need to be in the video group?

@Jai-GAY
Copy link
Author

Jai-GAY commented Jun 26, 2024

Can you please confirm if you can or cannot use the libcamera example applications (a.k.a. rpicam-apps) as a regular user without sudo?

I cannot use it without sudo. it could be due to raspberrypi step recommend sudo ninja -C build install while GitHub site recommends without sudo.

check the required permissions with ls. E.g.:

$ll /dev/video0
crw-rw-rw-+ 1 root video 81, 0 Jun 25 10:42 /dev/video0
$ll /dev/media0
crw-rw-rw-+ 1 root video 505, 0 Jun 25 10:42 /dev/media0

$ ls -alh /dev/video0
crw-rw-rw-+ 1 root video 81, 13 Jun 26 15:59 /dev/video0

$ groups pi
pi : pi adm cdrom sudo dip video plugdev lpadmin lxd sambashare

@christianrauch
Copy link
Owner

I cannot use it without sudo. it could be due to raspberrypi step recommend sudo ninja -C build install while GitHub site recommends without sudo.

And this is the same for the ROS node, i.e. you can use it with sudo but not without sudo? If this is the case, then I guess you have to take the issue with libcamera or the rpicam-apps projects since there is nothing the node can do about this.

@Jai-GAY
Copy link
Author

Jai-GAY commented Jun 26, 2024

And this is the same for the ROS node, i.e. you can use it with sudo but not without sudo?

if I use sudo ros2 run,

[ros2run]: Aborted
sudo: ros2: command not found

separately, what is your opinion on the humble-libcamera?

@Jai-GAY
Copy link
Author

Jai-GAY commented Jun 27, 2024

after the following change. still on libcamera v0.1.0
Edit /boot/config.txt, remove the line "camera_auto_detect=1" and dtoverlay=ov5647, and add "start_x=1" and "gpu_mem=128". Rebooting at this stage will reload the old V4L2 driver.

$cheese works

$ ros2 run camera_ros camera_node 
[0:34:34.080810852] [3100]  INFO Camera camera_manager.cpp:284 libcamera v0.1.0
terminate called after throwing an instance of 'std::runtime_error'
  what():  no cameras available
[ros2run]: Aborted
$ sudo rpicam-hello 
[sudo] password for pi: 
ERROR: rpicam-apps currently only supports the Raspberry Pi platforms.
Contributions for other platforms are welcome at https://github.com/raspberrypi/rpicam-apps.
$cat /boot/firmware/config.txt 
#camera_auto_detect=0
start_x=1
dtoverlay=ov5647

$ sudo rpicam-hello
okay, works.

$ sudo cheese 

(cheese:3509): GLib-GObject-CRITICAL **: 09:17:45.154: g_value_dup_string: assertion 'G_VALUE_HOLDS_STRING (value)' failed
(cheese:3509): GLib-GObject-CRITICAL **: 09:17:45.154: g_value_dup_string: assertion 'G_VALUE_HOLDS_STRING (value)' failed
(cheese:3509): GLib-GObject-CRITICAL **: 09:17:45.155: g_value_dup_string: assertion 'G_VALUE_HOLDS_STRING (value)' failed
(cheese:3509): GLib-GObject-CRITICAL **: 09:17:45.155: g_value_dup_string: assertion 'G_VALUE_HOLDS_STRING (value)' failed
(cheese:3509): GLib-GObject-CRITICAL **: 09:17:45.155: g_value_dup_string: assertion 'G_VALUE_HOLDS_STRING (value)' failed
(cheese:3509): GLib-GObject-CRITICAL **: 09:17:45.390: g_value_dup_string: assertion 'G_VALUE_HOLDS_STRING (value)' failed
(cheese:3509): GLib-GObject-CRITICAL **: 09:17:45.400: g_value_dup_string: assertion 'G_VALUE_HOLDS_STRING (value)' failed
(cheese:3509): GLib-GObject-CRITICAL **: 09:17:45.408: g_value_dup_string: assertion 'G_VALUE_HOLDS_STRING (value)' failed
(cheese:3509): GLib-GObject-CRITICAL **: 09:17:45.472: g_value_dup_string: assertion 'G_VALUE_HOLDS_STRING (value)' failed
(cheese:3509): GLib-GObject-CRITICAL **: 09:17:45.491: g_value_dup_string: assertion 'G_VALUE_HOLDS_STRING (value)' failed
(cheese:3509): cheese-WARNING **: 09:17:45.524: Failed to allocate required memory.: ../sys/v4l2/gstv4l2src.c(759): gst_v4l2src_decide_allocation (): /GstCameraBin:camerabin/GstWrapperCameraBinSrc:camera_source/GstBin:bin18/GstV4l2Src:v4l2src1:
Buffer pool activation failed
image

@Jai-GAY
Copy link
Author

Jai-GAY commented Jun 28, 2024

A new finding, after disabling start_x=1
now, stop at [ERROR] [1719563746.700658255] [camera_calibration_parsers]: Unable to open camera calibration file [/home/pi/.ros/camera_info/ov5647__base_soc_i2c0mux_i2c_1_ov5647_36_2560x1600.yaml]

$ ros2 run camera_ros camera_node
[0:08:37.057173377] [2578] �[1;32m INFO �[1;37mCamera �[1;34mcamera_manager.cpp:284 �[0mlibcamera v0.1.0
[0:08:37.127649848] [2591] �[1;32m INFO �[1;37mRPI �[1;34mvc4.cpp:390 �[0mRegistered camera /base/soc/i2c0mux/i2c@1/ov5647@36 to Unicam device /dev/media0 and ISP device /dev/media1
[INFO] [1719563745.786570339] [camera]: 
>> cameras:
   0: ov5647 (/base/soc/i2c0mux/i2c@1/ov5647@36)
[WARN] [1719563745.786935432] [camera]: no camera selected, using default: "/base/soc/i2c0mux/i2c@1/ov5647@36"
[INFO] [1719563745.787877017] [camera]: 
>> stream formats:
   - Pixelformat: NV21 (64x64 - 2592x1944)
   - Pixelformat: YUV420 (64x64 - 2592x1944)
   - Pixelformat: NV12 (64x64 - 2592x1944)
   - Pixelformat: YVU420 (64x64 - 2592x1944)
   - Pixelformat: XBGR8888 (64x64 - 2592x1944)
   - Pixelformat: BGR888 (64x64 - 2592x1944)
   - Pixelformat: RGB888 (64x64 - 2592x1944)
   - Pixelformat: XRGB8888 (64x64 - 2592x1944)
   - Pixelformat: RGB565 (64x64 - 2592x1944)
   - Pixelformat: YVYU (64x64 - 2592x1944)
   - Pixelformat: YUYV (64x64 - 2592x1944)
   - Pixelformat: VYUY (64x64 - 2592x1944)
   - Pixelformat: UYVY (64x64 - 2592x1944)
[WARN] [1719563745.788069761] [camera]: no pixel format selected, using default: "XBGR8888"
[INFO] [1719563745.788195337] [camera]: 
>> XBGR8888 format sizes:
   - 160x120
   - 240x160
   - 320x240
   - 400x240
   - 480x320
   - 640x360
   - 640x480
   - 720x480
   - 768x480
   - 854x480
   - 720x576
   - 800x600
   - 960x540
   - 1024x576
   - 960x640
   - 1024x600
   - 1024x768
   - 1280x720
   - 1152x864
   - 1280x800
   - 1360x768
   - 1366x768
   - 1440x900
   - 1280x1024
   - 1536x864
   - 1280x1080
   - 1600x900
   - 1400x1050
   - 1680x1050
   - 1600x1200
   - 1920x1080
   - 2048x1080
   - 1920x1200
   - 2160x1080
   - 2048x1152
   - 2560x1080
   - 2048x1536
   - 2560x1440
   - 2560x1600
[WARN] [1719563745.788252947] [camera]: no dimensions selected, auto-selecting: "2560x1600"
[WARN] [1719563745.788642233] [camera]: stream configuration adjusted from "2560x1600-XBGR8888" to "2560x1600-XBGR8888"
[0:08:37.130476584] [2578] �[1;32m INFO �[1;37mCamera �[1;34mcamera.cpp:1033 �[0mconfiguring streams: (0) 2560x1600-XBGR8888
[0:08:37.133130507] [2591] �[1;32m INFO �[1;37mRPI �[1;34mvc4.cpp:512 �[0mSensor: /base/soc/i2c0mux/i2c@1/ov5647@36 - Selected sensor format: 2592x1944-SGBRG10_1X10 - Selected unicam format: 2592x1944-pGAA
[INFO] [1719563745.797166584] [camera]: camera "/base/soc/i2c0mux/i2c@1/ov5647@36" configured with 2560x1600-XBGR8888 stream
[WARN] [1719563745.798542579] [camera]: control NoiseReductionMode (39) not handled
[INFO] [1719563746.700198244] [camera]: using default calibration URL
[INFO] [1719563746.700371074] [camera]: camera calibration URL: file:///home/pi/.ros/camera_info/ov5647__base_soc_i2c0mux_i2c_1_ov5647_36_2560x1600.yaml
[ERROR] [1719563746.700658255] [camera_calibration_parsers]: Unable to open camera calibration file [/home/pi/.ros/camera_info/ov5647__base_soc_i2c0mux_i2c_1_ov5647_36_2560x1600.yaml]
[WARN] [1719563746.700725738] [camera]: Camera calibration file /home/pi/.ros/camera_info/ov5647__base_soc_i2c0mux_i2c_1_ov5647_36_2560x1600.yaml not found
$ cat /boot/firmware/config.txt
camera_auto_detect=0
#start_x=1
dtoverlay=ov5647

$ sudo rpicam-hello --version
rpicam-apps build: 122b835fb927-intree 09-01-2024 (17:13:42)
libcamera build: v0.1.0+118-563cd78e

$ sudo rpicam-hello --list-camera
Available cameras
-----------------
0 : ov5647 [2592x1944 10-bit GBRG] (/base/soc/i2c0mux/i2c@1/ov5647@36)
    Modes: 'SGBRG10_CSI2P' : 640x480 [58.92 fps - (16, 0)/2560x1920 crop]
                             1296x972 [43.25 fps - (0, 0)/2592x1944 crop]
                             1920x1080 [30.62 fps - (348, 434)/1928x1080 crop]
                             2592x1944 [15.63 fps - (0, 0)/2592x1944 crop]

@christianrauch
Copy link
Owner

if I use sudo ros2 run,

[ros2run]: Aborted
sudo: ros2: command not found

You can also start the node directly via its camera_node executable in the install folder.

@christianrauch
Copy link
Owner

You can also start the node directly via its camera_node executable in the install folder.

Concretely, I mean that instead of sudo ros2 run camera_ros camera_node you can also run the camera_node executable directly via sudo ./install/camera_ros/lib/camera_ros/camera_node.

@Jai-GAY Can you check if running the node with sudo this way allows you to access the camera? Also, can you be specific about what you expect to work and what concretely does not work? You are mixing a couple of things here and I am still not sure what issues are caused by the node and what is irrelevant to this repo.

@Jai-GAY
Copy link
Author

Jai-GAY commented Jul 1, 2024

sudo ./install/camera_ros/lib/camera_ros/camera_node

camera_ros was installed via

source /opt/ros/humble/setup.bash
sudo apt install ros-$ROS_DISTRO-camera-ros
$ ll ./install
ls: cannot access './install': No such file or directory

Also, can you be specific about what you expect to work and what concretely does not work?

hoping this works. ros2 run camera_ros camera_node. by the way, if it works what will user see?

I think camera_ros depends on libcamera, so I understand what you mean.
I may have overwhelmed the issue without knowing how camera_ros and libcamera working relationship.

current error.
[ERROR] [1719809358.804975838] [camera_calibration_parsers]: Unable to open camera calibration file [/home/pi/.ros/camera_info/ov5647__base_soc_i2c0mux_i2c_1_ov5647_36_2560x1600.yaml]
[WARN] [1719809358.805043906] [camera]: Camera calibration file /home/pi/.ros/camera_info/ov5647__base_soc_i2c0mux_i2c_1_ov5647_36_2560x1600.yaml not found

$ ros2 run camera_ros camera_node
[0:03:43.447698915] [2374]  INFO Camera camera_manager.cpp:284 libcamera v0.1.0
[0:03:43.523380998] [2387]  INFO RPI vc4.cpp:390 Registered camera /base/soc/i2c0mux/i2c@1/ov5647@36 to Unicam device /dev/media0 and ISP device /dev/media2
[INFO] [1719809357.905187514] [camera]: 
>> cameras:
   0: ov5647 (/base/soc/i2c0mux/i2c@1/ov5647@36)
[WARN] [1719809357.905536335] [camera]: no camera selected, using default: "/base/soc/i2c0mux/i2c@1/ov5647@36"
[INFO] [1719809357.906442977] [camera]: 
>> stream formats:
   - Pixelformat: NV21 (64x64 - 2592x1944)
   - Pixelformat: YUV420 (64x64 - 2592x1944)
   - Pixelformat: NV12 (64x64 - 2592x1944)
   - Pixelformat: YVU420 (64x64 - 2592x1944)
   - Pixelformat: XBGR8888 (64x64 - 2592x1944)
   - Pixelformat: BGR888 (64x64 - 2592x1944)
   - Pixelformat: RGB888 (64x64 - 2592x1944)
   - Pixelformat: XRGB8888 (64x64 - 2592x1944)
   - Pixelformat: RGB565 (64x64 - 2592x1944)
   - Pixelformat: YVYU (64x64 - 2592x1944)
   - Pixelformat: YUYV (64x64 - 2592x1944)
   - Pixelformat: VYUY (64x64 - 2592x1944)
   - Pixelformat: UYVY (64x64 - 2592x1944)
[WARN] [1719809357.906535561] [camera]: no pixel format selected, using default: "XBGR8888"
[INFO] [1719809357.906639182] [camera]: 
>> XBGR8888 format sizes:
   - 160x120
   - 240x160
   - 320x240
   - 400x240
   - 480x320
   - 640x360
   - 640x480
   - 720x480
   - 768x480
   - 854x480
   - 720x576
   - 800x600
   - 960x540
   - 1024x576
   - 960x640
   - 1024x600
   - 1024x768
   - 1280x720
   - 1152x864
   - 1280x800
   - 1360x768
   - 1366x768
   - 1440x900
   - 1280x1024
   - 1536x864
   - 1280x1080
   - 1600x900
   - 1400x1050
   - 1680x1050
   - 1600x1200
   - 1920x1080
   - 2048x1080
   - 1920x1200
   - 2160x1080
   - 2048x1152
   - 2560x1080
   - 2048x1536
   - 2560x1440
   - 2560x1600
[WARN] [1719809357.906695306] [camera]: no dimensions selected, auto-selecting: "2560x1600"
[WARN] [1719809357.907038202] [camera]: stream configuration adjusted from "2560x1600-XBGR8888" to "2560x1600-XBGR8888"
[0:03:43.525823651] [2374]  INFO Camera camera.cpp:1033 configuring streams: (0) 2560x1600-XBGR8888
[0:03:43.526560123] [2387]  INFO RPI vc4.cpp:512 Sensor: /base/soc/i2c0mux/i2c@1/ov5647@36 - Selected sensor format: 2592x1944-SGBRG10_1X10 - Selected unicam format: 2592x1944-pGAA
[INFO] [1719809357.909785402] [camera]: camera "/base/soc/i2c0mux/i2c@1/ov5647@36" configured with 2560x1600-XBGR8888 stream
[WARN] [1719809357.910690432] [camera]: control NoiseReductionMode (39) not handled
[INFO] [1719809358.804530191] [camera]: using default calibration URL
[INFO] [1719809358.804711713] [camera]: camera calibration URL: file:///home/pi/.ros/camera_info/ov5647__base_soc_i2c0mux_i2c_1_ov5647_36_2560x1600.yaml
[ERROR] [1719809358.804975838] [camera_calibration_parsers]: Unable to open camera calibration file [/home/pi/.ros/camera_info/ov5647__base_soc_i2c0mux_i2c_1_ov5647_36_2560x1600.yaml]
[WARN] [1719809358.805043906] [camera]: Camera calibration file /home/pi/.ros/camera_info/ov5647__base_soc_i2c0mux_i2c_1_ov5647_36_2560x1600.yaml not found

@christianrauch
Copy link
Owner

camera_ros was installed via

source /opt/ros/humble/setup.bash
sudo apt install ros-$ROS_DISTRO-camera-ros
$ ll ./install
ls: cannot access './install': No such file or directory

Of course, you have to pick the correct path. If you install the node via the Debian package, the executable will be somewhere under /opt/ros/.

current error.
[ERROR] [1719809358.804975838] [camera_calibration_parsers]: Unable to open camera calibration file [/home/pi/.ros/camera_info/ov5647__base_soc_i2c0mux_i2c_1_ov5647_36_2560x1600.yaml]
[WARN] [1719809358.805043906] [camera]: Camera calibration file /home/pi/.ros/camera_info/ov5647__base_soc_i2c0mux_i2c_1_ov5647_36_2560x1600.yaml not found

What issues do you have with this? You should still get images from the camera.

@Jai-GAY
Copy link
Author

Jai-GAY commented Jul 3, 2024

You should still get images from the camera.

No, that is the thing.

@christianrauch
Copy link
Owner

You should still get images from the camera.

No, that is the thing.

Can you please be more specific about what the observed and expected behaviour is? What did you try, what did you expect and what was the actual observed behaviour? Is this still related to your initial problem? It is not possible to help you with this sparse information. The missing calibration file does not affect the published images.

@Jai-GAY
Copy link
Author

Jai-GAY commented Jul 3, 2024

can you provide a screen capture of when the user runs this command and what success output is expected?

ros2 run camera_ros camera_node

@christianrauch
Copy link
Owner

can you provide a screen capture of when the user runs this command and what success output is expected?

If you are trying to use the node, there must be something that you expect it to do for you :-) Typically, you want to subscribe to an image topic to get the images from the camera.

If you say you are not receiving images, what did you try?

@Jai-GAY
Copy link
Author

Jai-GAY commented Jul 4, 2024

how does the user verify setup and that everything is working when executing the following command, ros2 run camera_ros camera_node? Do you have a screenshot example?

@christianrauch
Copy link
Owner

I won't be able to help you unless you tell me explicitly and in detail 1)what you have tried, 2) what you expect to happen and 3) what actually happened.

Your questions are generically about how to run a ROS node and use topics etc. For this, please consult the ROS tutorials and documentation at https://docs.ros.org/en/jazzy/Tutorials.html.

@Jai-GAY
Copy link
Author

Jai-GAY commented Jul 4, 2024

I have only tried installing and launching the node.

@christianrauch
Copy link
Owner

But what did you try with the node in order to access the images? Did you subscribe to the image topics?

You said that you are not getting images from the camera. What makes you say that?

@Jai-GAY
Copy link
Author

Jai-GAY commented Jul 5, 2024

You said that you are not getting images from the camera. What makes you say that?

First, I needed to verify that my hardware and settings were okay, so I used 3rd party software module or application to verify.

So, I like to know how users verify that their subscription for images is not working or Camera_ros is not working.
Is there any printout statement users can observe to know that Camera_ros is working well in the backend?

@christianrauch
Copy link
Owner

I created PR #52 to add more information about ROS topics, calibration and debugging to the documentation. Please have a look if this helps you to better understand what the node is supposed to do and let me know if anything is missing from your side there.

So, I like to know how users verify that their subscription for images is not working or Camera_ros is not working.
Is there any printout statement users can observe to know that Camera_ros is working well in the backend?

Not in the default info log level. You can enable the libcamera and ROS debug levels. With the libcamera debug information, you should see something like DEBUG Request request.cpp:122 Request(1:C:0/1:0) printed periodically on screen. To introspect the ROS topics, you can use the usual ros2 topic list and ros2 topic echo commands.

@Jai-GAY
Copy link
Author

Jai-GAY commented Sep 26, 2024

@christianrauch
Copy link
Owner

The "legacy" mode will be removed at some point since libcamera is now the official way to access the cameras: https://www.raspberrypi.com/documentation/computers/camera_software.html. If you need something future-proof, I would not invest in the legacy mode.

@Jai-GAY
Copy link
Author

Jai-GAY commented Sep 27, 2024

since libcamera is now the official way to access the cameras: https://www.raspberrypi.com/documentation/computers/camera_software.html.

I am unsure if anything has to do with the libcamera I recompiled and reinstalled last month.

Raspberry Pi’s implementation of libcamera supports the following cameras:
Official cameras:
OV5647 (V1)

@christianrauch
Copy link
Owner

I don't get what you want to say. libcamera supports all Raspberry Pi cameras. It's the officially supported camera software stack on the Raspberry Pi and the one this ROS node is made for.

If you still want to use the legacy stack for a while, then you cannot use this node.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants