If I want to move it from Neutral to 90 degree, then it's actually 600us according to the servo angle schematic, as shown below.
<https://lh3.googleusercontent.com/-u5mQXBJjNts/UvraU_gxzwI/AAAAAAAABFA/RbvKo-rZpGo/s1600/HITec_HS-422_Servo_Angle.jpg> I was just trying to figure out the best sleep value for the loop method since I added a PID controller to the code so the servos can move the Nexus S device placed on a pan/tilt. Your answered about the dead-band helped me though. It's been a challenge because I can only get 15fps using OpenCV at a minimum resolution of 176x144. At that refresh rate it was not possible to have the servos moving smooth so I decided to use the IOIO loop method to call the PID every 10ms. That means that the COG is calculated every 60 ms at the end of each frame so there will be 6 PID cycles for each frame to update the servos position/pulse in a smooth way. Also, moving smooth will improve the quality of the image captured (less blur on the image). I'm using HSV instead of RGB/GRB since makes my life easier and I get a faster color indexing besides I find HSV less affected by lighting condition. I haven't updated the IOIO to the latest IOIOLib to v5.02. However, I'm not sure if that will make any difference for me. I might try with better/faster servos later since the Hitec 422 servos don't have the best dead-band width, but at this point I'm happy with the results. Here is a video showing the Android device tracking BugDroid: http://youtu.be/IpGD7KBM4zA Thanks! -- You received this message because you are subscribed to the Google Groups "ioio-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/ioio-users. For more options, visit https://groups.google.com/groups/opt_out.
