View Single Post
  #2   Spotlight this post!  
Unread 17-07-2006, 18:52
bear24rw's Avatar
bear24rw bear24rw is offline
Team 11 Programming Captain
AKA: Max T
FRC #0011 (MORT)
Team Role: Programmer
 
Join Date: Sep 2005
Rookie Year: 2005
Location: Flanders, NJ
Posts: 385
bear24rw is a splendid one to beholdbear24rw is a splendid one to beholdbear24rw is a splendid one to beholdbear24rw is a splendid one to beholdbear24rw is a splendid one to beholdbear24rw is a splendid one to beholdbear24rw is a splendid one to behold
Send a message via AIM to bear24rw
Re: Globe Motor Programming Questions

First you need to wire the globe motor to a speed controller, then connect a PWM wire from the speed controller to one of the PWM output on the robot controller... to controller the motor from your program you set the PWM output to a certain value..

Assuming you connected the speed controller to PWM output 1
pwm01 = 0; // Full backward
pwm01 = 127; // Neutral (motor doesnt move)
pwm01 = 255; // Full foward

If you connect it to another output just change the pwm number (pwm01, pwm02, pwm03, etc...)

You can choose any value between 0 and 255 to move the motor at different speeds and directions...

You can also map it to a joystick..
pwm01 = p1_y;
This is set the motor speed to the value of the y axis on port 1

Hope that enough to get you started...