OCCRA
Go to Post Moreover, lets discuss robots, its more fun :p - Bharat Nain [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Events   CD-Media   CD-Spy   FRC-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 01-22-2008, 05:02 PM
[RSMT]sturm [RSMT]sturm is offline
Registered User
FRC #2606
 
Join Date: Dec 2007
Location: Minnesota
Posts: 1
[RSMT]sturm is an unknown quantity at this point
Make my motor turn!

We're using the default code and we are trying to make the motor turn using the pwm functions and the pwm outputs 13-16. We have our motor hooked up and all components working as intended up to that point as far as physical electrical connections.
__________________
  #2   Spotlight this post!  
Unread 01-22-2008, 07:11 PM
mluckham's Avatar
mluckham mluckham is offline
Registered User
FRC #0758 (Sky Robotics)
Team Role: Mentor
 
Join Date: Mar 2006
Rookie Year: 2006
Location: Ontario, Canada
Posts: 116
mluckham will become famous soon enoughmluckham will become famous soon enough
Re: Make my motor turn!

Do you have the motor connected to the M+/M- side of a Victor speed controller?

The same Victor that your PWM cable goes to?

Is the PWM cable plugged all the way into the Victor speed controller ... sometimes they are hard to get in due to the plastic of the PWM cable connector being a bit large.

Are you supplying 12 volts from the battery, through a circuit breaker, to the V+/V- side of the Victor speed controller?

Are the wires all in good contact?

Did you test the motor first (direct-connect to a 12 volt battery)?

Make sure you are not outputting a "neutral" value to the pwm13 variable in your code ... neutral (no voltage to motor) is in the range of 127 +/- 14 (114 through 141). If you are just testing and the motor isn't connected to any gears or the robot, just set pwm13 to something like 10, or 230.
  #3   Spotlight this post!  
Unread 01-22-2008, 07:37 PM
Tom Line's Avatar
Tom Line Tom Line is offline
Raptors can't turn doorknobs.
FRC #1718 (The Fighting Pi)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 1999
Location: Armada, Michigan
Posts: 2,145
Tom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond repute
Re: Make my motor turn!

I'm doing this from memory, because I don't have the default code at home and I'm too lazy to do it, but to use pwm13-16, don't you have to use the Generate_PWMS(); function call?
  #4   Spotlight this post!  
Unread 01-22-2008, 11:47 PM
TubaMorg TubaMorg is offline
Programmermechanicalelect ricalcoach
AKA: Dan
FRC #1480 (Robatos Locos)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2005
Location: Houston
Posts: 450
TubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond repute
Re: Make my motor turn!

Another tip: The LEDs on the Victors should change color as you move from full forward to full reverse to neutral (green, red, orange is neutral). Also teams have had trouble using the last four PWM connections. You can try changing your code so that you can use 1-4 instead.

Important point, though, is to watch the LEDs. If they are flashing then something isn't connected right.
  #5   Spotlight this post!  
Unread 01-23-2008, 08:10 PM
JonathanLKS JonathanLKS is offline
Code::Blocks
FRC #0610 (The Coyotes)
Team Role: Leadership
 
Join Date: Feb 2006
Rookie Year: 2005
Location: Toronto
Posts: 36
JonathanLKS will become famous soon enough
Send a message via MSN to JonathanLKS
Re: Make my motor turn!

Other than everything else already mentioned, do you have alot of interrupts and are not using some kind of replacement for Generate_PWMs?

My team found that running with alot of interrupts can either disable or make pwm 13-16 irratic using only Generate_PWMs
__________________

Team 610 [ Co-Leader | Head Programmer | Webmaster ]
We're attending: Greater Toronto Regional, San Diego Regional, Championship
  #6   Spotlight this post!  
Unread 01-24-2008, 12:01 AM
TubaMorg TubaMorg is offline
Programmermechanicalelect ricalcoach
AKA: Dan
FRC #1480 (Robatos Locos)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2005
Location: Houston
Posts: 450
TubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond repute
Re: Make my motor turn!

Quote:
Originally Posted by JonathanLKS View Post
Other than everything else already mentioned, do you have alot of interrupts and are not using some kind of replacement for Generate_PWMs?

My team found that running with alot of interrupts can either disable or make pwm 13-16 irratic using only Generate_PWMs
Yes this is the problem teams tend to have if they use PWMs 13-16. Interupts conflict with the psuedo PWM's. Better to avoid the issue if possible by using any of the other PWMs.
  #7   Spotlight this post!  
Unread 01-24-2008, 07:54 AM
Unsung FIRST Hero
Al Skierkiewicz Al Skierkiewicz is offline
Broadcast Eng/Chief Robot Inspector
AKA: Big Al WFFA 2005
FRC #0111 (WildStang)
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 1996
Location: Wheeling, IL
Posts: 10,079
Al Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond reputeAl Skierkiewicz has a reputation beyond repute
Re: Make my motor turn!

Quote:
Originally Posted by [RSMT]sturm View Post
We're using the default code and we are trying to make the motor turn using the pwm functions and the pwm outputs 13-16. We have our motor hooked up and all components working as intended up to that point as far as physical electrical connections.
When you use the default code you must connect your PWM cables to the specified PWM outputs on the RC. The joystick port is already mapped for you, to specific motor PWM outputs. The RC manual has a complete documentation of the default code. (See Page 6, PWM Output map, default code only)
From the manual...
"PWMs 13-16 are meant to
be used if one desires to
control the robot using only
one joystick. The left and
right drive motors are
controlled by mixing the X
and Y axes of joystick 1."
Let us know if this helps.
__________________
Good Luck All. Learn something new, everyday!
Al
WB9UVJ
www.wildstang.org
________________________
All is better now, NOS parts are working fine. Why does this year's game remind me of Violet in Willie Wonka? Hmmmm, I see blueberries!
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How do you make the robot turn a perfect 90 eccmaster Programming 2 01-16-2008 08:54 PM
make motor go slower coolguybigt Motors 1 02-19-2007 09:36 AM
3-turn pots archiver 2001 2 06-24-2002 01:24 AM
How fast could a torque motor turn if a torque motor could.. archiver 2001 0 06-23-2002 10:54 PM
Robot Turn-in Mike Martus Off-Season Events 0 11-08-2001 07:32 PM


All times are GMT -5. The time now is 10:35 PM.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi