Remote I/O error with 13 MP PTZ Camera

Thanks for getting this to the public, this toy is very interesting.

My problem is that that I can not get the FocuserExample.py working, python FocuserExample.py yields the following error message:

`

Traceback (most recent call last):
File “FocuserExample.py”, line 217, in <module>
main()
File “FocuserExample.py”, line 209, in main
curses.wrapper(draw_menu,camera)
File “/usr/lib/python2.7/curses/wrapper.py”, line 43, in wrapper
return func(stdscr, *args, **kwds)
File “FocuserExample.py”, line 196, in draw_menu
RenderMiddleText(stdscr,k,focuser)
File “FocuserExample.py”, line 78, in RenderMiddleText
focus_value = “Focus : {}”.format(focuser.get(Focuser.OPT_FOCUS))[:width-1]
File “/home/pi/Arducam_OBISP_MIPI_Camera_Module/ptz_focus_example/Focuser.py”, line 149, in get
self.waitingForFree()
File “/home/pi/Arducam_OBISP_MIPI_Camera_Module/ptz_focus_example/Focuser.py”, line 92, in waitingForFree
while self.isBusy() and count < (5 / 0.01):
File “/home/pi/Arducam_OBISP_MIPI_Camera_Module/ptz_focus_example/Focuser.py”, line 88, in isBusy
return self.read(self.CHIP_I2C_ADDR,self.BUSY_REG_ADDR) != 0
File “/home/pi/Arducam_OBISP_MIPI_Camera_Module/ptz_focus_example/Focuser.py”, line 79, in read
value = self.bus.read_word_data(chip_addr,reg_addr)
IOError: [Errno 121] Remote I/O error

`

I purchase the Arducam 13mp-ptz-camera from amazon: https://www.amazon.com/Arducam-Camera-Raspberry-Switchable-Digital/dp/B08LGW1N9X/ref=sr_1_1?dchild=1&keywords=arducam+13MP+PTZ&qid=1605385323&s=electronics&sr=1-1

I am able to follow the tutorial and set it up and connect to the freshly made Raspberry Pi 4. The camera seems to be working, though i think i should adjust the focus of the camera and the image is blurred. I tried the following the commands and the returns are.

`

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: – – – – – – – –

`

I am not sure if the default addr 0x0C correct, but this is the same as the post from the user bin in another question. I did connect all 6 pins to the GPIO, and they should be the same as that in the youtube video and the other post. I have also enable the I2C and make the changes in the /boot/config.txt

`

dtparam=i2c_arm=on

dtparam=i2c_arm_baudrate=10000

`

Any suggestions to get it to be working?

Other minor feedbacks:

I have found that the PTZ camera would not be working if I do apt-get upgrade on the raspberry pi, looks like the kernel is not compatible, but I have not seen this after I remake a new raspberry pi OS from the official website.

 

I have also find that if I mistaken to put the GPIO pins, the raspberry pi would not be reboot. The color of the cables from what I bought is different from that on the website, but I have corrected this following the suggestions from the other post. I am able to reboot the raspberry pi even the GPIO pins are connected.

Hello,

Sorry for my late reply. It seems the i2c signal is abnormal. Please check the ribbon cable in detail if normal, you will see the 0x0C address. Or you can change another ribbon cable and retry.