-
Notifications
You must be signed in to change notification settings - Fork 101
Description
When I run the command Servo.py. I get the following error:
Now servos will rotate to 90°.
If they have already been at 90°, nothing will be observed.
Please keep the program running when installing the servos.
After that, you can press ctrl-C to end the program.
Traceback (most recent call last):
File "/home/pi/Freenove_Robot_Dog_Kit_for_Raspberry_Pi/Code/Server/Servo.py", line 28, in
S=Servo()
^^^^^^^
File "/home/pi/Freenove_Robot_Dog_Kit_for_Raspberry_Pi/Code/Server/Servo.py", line 8, in init
self.pwm = PCA9685(address=0x40, debug=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/pi/Freenove_Robot_Dog_Kit_for_Raspberry_Pi/Code/Server/PCA9685.py", line 32, in init
self.write(self.__MODE1, 0x00)
File "/home/pi/Freenove_Robot_Dog_Kit_for_Raspberry_Pi/Code/Server/PCA9685.py", line 36, in write
self.bus.write_byte_data(self.address, reg, value)
OSError: [Errno 5] Input/output error
I use the command "sudo i2cdetect -y 1" to get connected device information. It shows there is no valid device.
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 sure I already enabled i2c and reboot system multiple times.
If you need more information, please let me know.