Hi.
I recently purchased a 5mp stereo hat. I connect it to my rpi4 and run a raspistill command and it appears to work fine. Cool.
So I navigate to the stereo_depth_demo to emulate the coolness I saw on the web.
pi@raspberrypi:~/MIPI_Camera/RPI/stereo_depth_demo $ LD_PRELOAD=/usr/lib/arm-linux-gnueabihf/libatomic.so.1 python3 1_test.py
Open camera…
Error: Could not open file /dev/i2c-0’ or
/dev/i2c/0’: No such file or directory
I2C check functionality fail.
init_camera: Unexpected result.
Ok, that tells me the cameras aren’t on the i2c bus. So I check.
pi@raspberrypi:~/MIPI_Camera/RPI/stereo_depth_demo $ sudo i2cdetect -y 1
0 1 2 3 4 5 6 7 8 9 a b c d e f
00: – – – – – – – – – – – – –
10: – – – – – – – – – – – – – – – –
20: – – – – – – – – – – – – – – – –
30: – – – – – – – – – – – – – – – –
40: – – – – – – – – – – – – – – – –
50: – – – – – – – – – – – – – – – –
60: – – – – – – – – – – – – – – – –
70: – – – – – – – –
Sure enough, no devices.
So here is what I’ve done to ensure the issue isn’t on my end.
-
I read through the read me and installed the wiringpi-latest.deb since I’m on a pi-4. Same result as above.
-
I disconnect and reconnect both camera cables as well as the pi camera cable. Same result as above.
-
I made my own connector as I don’t want the stereo hat on top of the pi. I removed my connector and disassembled my case and put the stereo hat directly on top of the pi and used the stereo hat connector directly. Same result as above.
-
I connected some other i2c device to my pi in order to validate the i2c bus works. It shows up and functions just fine.
Not sure what a next step would be? Please help.
I did notice that the error printed says it is looking for i2c-0, which is what it would be looking for on an older pi model. I am running a pi-4, which is i2c-1. Is the error text just misleading? Can I set which bus I want? Where?
Thanks in advance for your time and assistance.