OCCRA
Go to Post I still believe that if we are legitimately trying to make FRC be recognized as a real sport, then the GDC must treat it like one. - Jim Zondag [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

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 04-15-2008, 09:52 AM
qpang qpang is offline
Registered User
no team
 
Join Date: Mar 2008
Location: mississippi
Posts: 19
qpang is an unknown quantity at this point
Drive wheel motors using OItoPWM() --- how to debug?

I'm using OI_to_PWM() function to drive wheel motors during the Operator part of the game, and set_PWM() during the Autonomous part, setting to full speed.
It is observed that during the operator mode, it is running slower than the Auto mode, even the driver pushed the joystick to the limit.
I assume when the joystick is pushed to the limit, the output to PWM port should be 255(or 0) using OI_to_PWM() function. Is that true?
Is there a way to read the output to the PWM while running the OI_to_PWM() function using EasyCPro? I mean without any hardware equipment?
Reply With Quote
  #2   Spotlight this post!  
Unread 04-15-2008, 09:58 AM
whytheheckme's Avatar
whytheheckme whytheheckme is offline
Registered User
AKA: Jacob Komar
no team
 
Join Date: Feb 2006
Rookie Year: 2005
Location: Providence, RI
Posts: 1,318
whytheheckme has a reputation beyond reputewhytheheckme has a reputation beyond reputewhytheheckme has a reputation beyond reputewhytheheckme has a reputation beyond reputewhytheheckme has a reputation beyond reputewhytheheckme has a reputation beyond reputewhytheheckme has a reputation beyond reputewhytheheckme has a reputation beyond reputewhytheheckme has a reputation beyond reputewhytheheckme has a reputation beyond reputewhytheheckme has a reputation beyond repute
Send a message via ICQ to whytheheckme Send a message via AIM to whytheheckme Send a message via MSN to whytheheckme Send a message via Yahoo to whytheheckme Send a message via Skype™ to whytheheckme
Re: Drive wheel motors using OItoPWM() --- how to debug?

Use the OI Analog Input block, and throw that to a variable (int should be fine.) Then you can print out that variable, and see what it is.

Jacob
Reply With Quote
  #3   Spotlight this post!  
Unread 04-15-2008, 10:29 AM
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 7,845
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Send a message via AIM to Alan Anderson
Re: Drive wheel motors using OItoPWM() --- how to debug?

Quote:
Originally Posted by qpang View Post
I assume when the joystick is pushed to the limit, the output to PWM port should be 255(or 0) using OI_to_PWM() function. Is that true?
Not necessarily. Most joysticks don't quite reach the entire range of possible values. You can compensate for this in teleoperated mode by calibrating the Victor speed controller to match what your joystick provides.

(Note that the maximum PWM value in the IFI control system is 254, not 255.)
Quote:
Is there a way to read the output to the PWM while running the OI_to_PWM() function using EasyCPro? I mean without any hardware equipment?
If you already have a laptop computer with a serial connection, you can use a dashboard reader program to see exactly what pwm outputs are being commanded, and exactly what joystick values are being read.
Reply With Quote
Reply


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 to get robot to drive straigth using shaft encoders eccmaster Programming 5 02-02-2008 10:50 PM
Four Wheel Drive Using Standard Transmissions daviamp Technical Discussion 4 01-18-2006 07:03 PM
Using 6 motors in a drive system? FIRST JerseyKid Motors 7 01-12-2005 10:49 PM
How many motors are you using to drive? Joseph F Motors 18 10-16-2002 08:24 PM


All times are GMT -5. The time now is 02:02 AM.

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