Running multiple instances of the HB25 object
DiverBob
Posts: 1,110
I am using the HB25.spin object from the OBEX in single mode and need to run multiple instances, one for each motor (3). It appears that each instance requires a seperate cog if I'm reading the code correctly which means this object may not be the best one to use in this instance. Any suggestions on workarounds or other HB25 object that would work better?
Thanks for the info!
Thanks for the info!
Comments
Servo32_v9 is the latest I believe.
I'm thinking that Duane's suggestion might work out well.
The only problem with it, is that you will need to write a routine that will initialize your HB25s.
If you are running each HB25 separately, without them being daisy chained, After initialization, they should act like a CR servo.
I hope this helps in some manner.
Gary
Post #2 of my 32-servo demo has the code I used attached to it.
I used the same sort of control loop in my hexapod projects.
While this technique works well for my applications, I'm pretty sure there are other ways to do this. Paul K posted code he uses in his hexapod.
Edit: changed code to set up properly
Having problems with the motors overshooting the target ADC value. The code I'm using stops in plenty of time but it seems to take the motor longer than expected to actually stop. I think once there is a load on the motors the overshoot will drop down. I'm still tweaking the code after a full day of experimenting with it.