Controlling Motors with Stamp
Hi all.
I'll be starting on my MCU work for my robot. I have a question in terms of the MCU sending signals to the motor.
I went through the Boe-Bot book and still refer to it. But that Bot used servo motors. In order to get to a position or
make the servo move using the PULSOUT command.
Now, I have a homemade robot with NPC T64 motors which is not a servo.
I use a Sabertooth 2x25 controller, Vantec RDFR36E Speed Controller and RoboClaw 2x25. I swap them in and out using one at a time to test.
My questions are:
-Is there a standard number that I use with the MCU PULSOUT command to adjust speed (fast, slow), direction (right, left, forward, reverse)? Or is it trial and error with testing?
-Does the type of speed controller vary with the PULSOUT command from the MCU?
Please feel free to correct any incorrect statements that I've made. I'm a 47year old that is doing this stuff for fun and learning. I'm not enrolled in any school or class. I'm not enrolled in any school or class and this is not associated with any project or assignment.
Thanks, any help will be appreciated.
I'll be starting on my MCU work for my robot. I have a question in terms of the MCU sending signals to the motor.
I went through the Boe-Bot book and still refer to it. But that Bot used servo motors. In order to get to a position or
make the servo move using the PULSOUT command.
Now, I have a homemade robot with NPC T64 motors which is not a servo.
I use a Sabertooth 2x25 controller, Vantec RDFR36E Speed Controller and RoboClaw 2x25. I swap them in and out using one at a time to test.
My questions are:
-Is there a standard number that I use with the MCU PULSOUT command to adjust speed (fast, slow), direction (right, left, forward, reverse)? Or is it trial and error with testing?
-Does the type of speed controller vary with the PULSOUT command from the MCU?
Please feel free to correct any incorrect statements that I've made. I'm a 47year old that is doing this stuff for fun and learning. I'm not enrolled in any school or class. I'm not enrolled in any school or class and this is not associated with any project or assignment.
Thanks, any help will be appreciated.
Comments
If you would read the chapter in the Basic Stamp Syntax and Reference Manual (or the section of the on-line help in the Stamp Editor) on the PULSOUT statement, you'll see that pulse width values in the PULSOUT statement correspond to 0.2us units, so 750 causes a 1.5ms pulse to be produced.
Motor speed controllers either are designed to accept servo control pulses or something else like asynchronous serial commands (sent with the SEROUT statement). You'd have to look at the documentation for the controller.
Added: The Sabertooth controller looks like it will accept either servo control pulses (R / C) or serial commands ... your choice. The serial commands would probably give you finer control.
Thank you very much.