This version did not generate any errors, but once again, it did not cause anything to happen on the servos.
The other version generated this:
Traceback (most recent call last):
File “/home/steve/python/robot/pantilt1.py”, line 7, in
kit = ServoKit(channels=16, i2c=i2c_bus, address=0x40)
File “/usr/local/lib/python3.8/dist-packages/adafruit_servokit.py”, line 89, in init
self._pca = PCA9685(
File “/usr/local/lib/python3.8/dist-packages/adafruit_pca9685.py”, line 150, in init
self.i2c_device = i2c_device.I2CDevice(i2c_bus, address)
File “/home/steve/.local/lib/python3.8/site-packages/adafruit_bus_device/i2c_device.py”, line 62, in init
self.__probe_for_device()
File “/home/steve/.local/lib/python3.8/site-packages/adafruit_bus_device/i2c_device.py”, line 184, in __probe_for_device
raise ValueError(“No I2C device at address: 0x%x” % self.device_address)
ValueError: No I2C device at address: 0x40
I’m going to try a different i2c device like an oled display…