Go to Post Things that get said on the field should stay on the field. - Bongle [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Spotlight this post!  
Unread 15-01-2005, 23:34
Anthony Kesich's Avatar
Anthony Kesich Anthony Kesich is offline
Programmer Turned Engineer
AKA: SonKenshin
#1097 (Site 3 Engineernig)
Team Role: Leadership
 
Join Date: Jan 2003
Rookie Year: 2003
Location: Sacramento, CA
Posts: 186
Anthony Kesich has a spectacular aura aboutAnthony Kesich has a spectacular aura about
Send a message via AIM to Anthony Kesich
2005 Autonomous Scripting Manual

OK, sorry I took so long. Its been a couple of hectic days. Anywho, here are all of the default commands available in Kevin Watson's code. I plan on playing around with the disabled ones (i.e. the way points and the like) and hopefully posting code to run it.

--------------------------------------------------------------------------

CMD_SHOW_STATE; no parameters
Prints back the on-board clock time, x and y coordinates in mm, and the heading in milliradians

CMD_VELOCITY; parm_1: velocity in mm/sec
Uses the PID algorithm and encoders on the wheels to keep the motors driving at the commanded velocity

CMD_WAIT; parm_1: time to wait in milliseconds
Waits for the specified time until executing the next command on the list. Very useful after setting the velocity. (i.e. set velocity 1000mm/sec, drive for 5000 milliseconds = 5 meters).

CMD_WAIT_UNTIL; parm_1: time to wait until in milliseconds
Waits until the specified milliseconds into the match until executing the next line. Useful to delay your code so your alliance can get out of the way first.

CMD_DRIVE; parm_1: distance to drive in mm
Uses the PID code and encoders to drive the robot forward the specified distance.

CMD_TURN; parm_1: distance to turn in milliradians, parm_2: tolerance to be within goal heading in milliradians
Uses the gyro along with the PID algorithm to turn the robot the specified distance. The tolerance is the buffer as to how close it needs to be before deciding it has succeeded.

CMD_WAIT_FOR_BUMP; no parameters
Waits for a switch to be hit before continuing on to the next command.

CMD_STOP; no parameters
Stops the robot.

CMD_GYRO_BIAS; no parameters
Tells the gyro code to use the next 8 loops or so to set its bias. Usually the first line of code to be called since you want to be stationary when setting the bias.

CMD_KEEP_HEADING; parm_1: time to hold heading in milliseconds. parm_2: tolerance in milliradians
Tells to robot to keep its heading (direction) using the Gyro and the PID code to within the specified tolerance for the specified time.

CMD_JUMP; parm_1: command to jump to
Jumps to the specified command in the command list. Usefull for creating loops.

--------------------------------------------------------------------------

That's all that is complete in Kevin's code. I will try to get CMD_SET_HEADING and CMD_SET_POS done soon as they should be useful. I hope this helps anyone that needs it.

-Tony K
__________________
C is screwing up my English--I'm ending all my sentences in semi-colons;

Horray for most things! -George Carlin

"Sure, I'll play rugby. Besides, I have a lot of experience running from really big guys who want to cream me." -Me, Freshman year

Last edited by Anthony Kesich : 16-01-2005 at 01:24. Reason: Forgot CMD_JUMP
 


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
2005 Manual dez250 General Forum 51 17-01-2005 21:06
**FIRST EMAIL**/Important 2005 Competition Manual Information Sscamatt FIRST E-Mail Blast Archive 1 06-01-2005 18:50
Autonomous to Manual control? Lint_Ninja Programming 5 16-02-2004 21:48


All times are GMT -5. The time now is 14:13.

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


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