ArduCAM / Arducam_tof_camera

51 stars 20 forks source link

rgb + d in raspberry #18

Open monschine opened 1 year ago

monschine commented 1 year ago

Hi, is it possible to connect to cameras to a raspberry pi 3 model b ? I have seen there are some multi cam adapters, but as far as I can read they need to be same resolution, and because of the low resolution of the tof camera would that be still possible ?

Thanks

dennis-ard commented 1 year ago

Hi, tof camera can run on raspberry pi 3 model b. Regarding multiple camera adapters, it may be possible. But we haven't tested it yet so we can't give you an accurate answer.

monschine commented 1 year ago

Thanks for the answer, I think it would be very valuable for the community if you could perform some tests and confirm that such configuration is working on raspberry pi with the multicamera adpaters. if there is some computation limitation on my case would be acceptable to have this setup working from raspberry pi 4 and above... Kind regards

dennis-ard commented 1 year ago

Thank you for your proposal, we will include it as a supported function. We may not be able to reply to you in the near future, but we will support this function in the future. Kind regards

vlsd commented 1 year ago

FWIW we've tried it with an Arducam RGB camera through USB and were not able to get them both working at the same time. We didn't spend a lot of time trying though, as the errors we were getting were all over the place (kept changing every reboot).

dennis-ard commented 1 year ago

If you still want to try, we will provide as much support as possible.

monschine commented 1 year ago

My initial idea was to use a multicamera adapter for connecting both cameras, seems like a better integration to the system, rather than using the usb, though it's a nice experiment to do it via usb, such a pitty it was not initially working... Please @dennis-ard let us know when there is a working solution. Actually I would be pleased to start testing using the multiadapter, but I would like some suggestion regarding which adapter and which rgb camera should be used .

Kind regards

dennis-ard commented 1 year ago

In view of the complexity of this issue, please contact support@arducam.com, and we will assign someone to contact you.

Kind regards

monschine commented 1 year ago

Thanks, I already contacted them. To be true I can not wait to start testing the system ! Just as extra bonus, I want to mention that the final goal for the system I thinking about, is to use 2 tof cameras + 2 rgb cameras. Let's see if the multicam adapter for 4 cameras could handle that

dennis-ard commented 1 year ago

that's awesome!

vlsd commented 1 year ago

Let's see if the multicam adapter for 4 cameras could handle that

Interested in your results here as well, as we'd like to try it as well in the near future.

dennis-ard commented 1 year ago

Oh, and I also asked the engineer about the use of the multicam adapter. If you use 4 cameras at the same time, you need the same model. If you use different models of cameras, they cannot be started at the same time to obtain frame data. If you want to connect two different models of cameras, you may need two camera ports to use the multicam adapter.

dennis-ard commented 1 year ago

FWIW we've tried it with an Arducam RGB camera through USB and were not able to get them both working at the same time. We didn't spend a lot of time trying though, as the errors we were getting were all over the place (kept changing every reboot).

hi, We found that usb camera and tof can be used at the same time, but this needs to specify the video path of tof in the code, for example :

int video_index = 1;
tof.init(ArduCam::CSI, ArduCam::DEPTH_TYPE, video_index );

The path here is just a random value, you need to use ' ls /dev/video' to see what videos are there, and use ' v4l2-ctl -d --list-formats-ext ' to verify whether it is the camera format of tof. Refer to the following format:

ioctl: VIDIOC_ENUM_FMT
   Type: Video Capture

   [0]: 'Y12P' (12-bit Greyscale (MIPI Packed))
     Size: Discrete 240x180
   [1]: 'Y12' (12-bit Greyscale)
     Size: Discrete 240x180
monschine commented 1 year ago

Thanks for the info ! That's a good usage case, but I think it would be great to be able to use the rgb camera without the usb.

So could a multiadpater be used to link 2 or 4 tof cameras as they are the same sensor ? Could that be processed independetly so getting simultanously the n number of depthmaps ? That could be used for increasing the field of view in a single position.

Thanks in advance

dennis-ard commented 1 year ago

Sorry for not getting back to you sooner.

At present, we have verified the use of multiple TOF cameras via USB. If you want us to verify the use of TOF cameras with multiadpater, you can contact support@arducam.com and give them feedback on your needs.