0

16ch Servo Bonnet
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

16ch Servo Bonnet

by cmiller73 on Sat May 16, 2020 2:27 pm

I am using the 16ch servo bonnet. I have installed the Python libraries and partially working, however only able to go to "0°" position. I am using OSSEP LS-0009AF servo. When I try other positions such as 45° or 90°, the servo stops responding.
I also have a DF9GMS continuous rotation servo. Once I start it going one direction, I cannot stop it or reverse it.
Any ideas on what' going on.

cmiller73
 
Posts: 4
Joined: Sat May 16, 2020 2:15 pm

Re: 16ch Servo Bonnet

by adafruit_support_carter on Mon May 18, 2020 2:17 pm

Can you post the code you are using to try and control the servo.

adafruit_support_carter
 
Posts: 15621
Joined: Tue Nov 29, 2016 2:45 pm

Re: 16ch Servo Bonnet

by cmiller73 on Mon May 18, 2020 2:35 pm

import time
from adafruit_servokit import ServoKit
kit = ServoKit(channels=16)

kit.servo[0].angle = 45

cmiller73
 
Posts: 4
Joined: Sat May 16, 2020 2:15 pm

Re: 16ch Servo Bonnet

by adafruit_support_carter on Mon May 18, 2020 2:42 pm

Try running the code below.

The servo only goes to angle 0? Does it even try to move for the other angles?

Code: Select all | TOGGLE FULL SIZE
import time
from adafruit_servokit import ServoKit
kit = ServoKit(channels=16)

while True:
    print("angle = 0")
    kit.servo[0].angle = 0
    time.sleep(1)
    print("angle = 45")
    kit.servo[0].angle = 45
    time.sleep(1)
    print("angle = 90")
    kit.servo[0].angle = 90
    time.sleep(1)

adafruit_support_carter
 
Posts: 15621
Joined: Tue Nov 29, 2016 2:45 pm

Re: 16ch Servo Bonnet

by cmiller73 on Mon May 18, 2020 4:02 pm

So I may have identified a problem with my servo. Ordering a new one. Will update when I test the new one. Thanks for your help and quick reply's!!!

cmiller73
 
Posts: 4
Joined: Sat May 16, 2020 2:15 pm

Re: 16ch Servo Bonnet

by cmiller73 on Mon May 18, 2020 5:27 pm

Actually ended up being a conflict with the i2c address. I had other address same as the servo hat. Jumper-ed A0 on pca, changed address to 0x41 and it works!!! Thanks again.

cmiller73
 
Posts: 4
Joined: Sat May 16, 2020 2:15 pm

Please be positive and constructive with your questions and comments.