Go to Post And, if you don't know what something means, say so, we'll be happy to explain. - DonRotolo [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

 
Closed Thread
 
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 12-02-2006, 20:45
lightning_blast lightning_blast is offline
Registered User
FRC #1814
 
Join Date: Feb 2006
Location: Canada
Posts: 15
lightning_blast is an unknown quantity at this point
Help with joystick

hello! we're a rookie team for the FIRST robotics competition and we're using intelitek's easyC. we got the robot driving, but how do we use the other buttons such as the little joystick on the joystick, the trigger, thumb, and the other two buttons? i've tried relay, but i found it to work only on spikes. How do we get it to work on victors? any help would be greatly appreciated, thank you!
  #2   Spotlight this post!  
Unread 12-02-2006, 21:17
rushrtr3 rushrtr3 is offline
Registered User
FRC #0131
 
Join Date: Dec 2005
Location: Manchester NH
Posts: 2
rushrtr3 is an unknown quantity at this point
Re: Help with joystick

You will first have to assign each of the buttons as a digital input. In the browser, expand the RC Control browser. Then drag a Digital OI Input into your program were it can be accessed by the fuction you want it to accomplish. Choose the port that the joystick is plugged into and then choose the button number. 1=Trigger, 2=Thumb, 3=Aux1 (the left button) 4=Aux2 (the right button). As far as I know you can't use the easyC program to use the little joystick. You will need to make a variable for the digital input to retrieve to. Make the varriable an "unsigned char". I'm not sure what you want the buttons to do with the motors but the basic idea is to make so that if xxxxxx (your digital inputs variable) = 1 set pwm to yyyyy (the motors speed). NOTE: the buttons read as 1 if they are pressed, if you release them they go back to 0. Hope this helps.
  #3   Spotlight this post!  
Unread 12-02-2006, 22:25
lightning_blast lightning_blast is offline
Registered User
FRC #1814
 
Join Date: Feb 2006
Location: Canada
Posts: 15
lightning_blast is an unknown quantity at this point
Re: Help with joystick

alright!! thanks!! ill try it out tomorrow at school. and does anybody know how to debug on the same line? its the PrintToScreen command but when i try to output 2 variables, its on 2 lines and looks messed up. so does anybody know how to put both on the same line? thanks!
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
Change joystick to pwm mapping Joe Lewis Programming 3 30-03-2005 19:27
Changing 1 joystick code to 2 (rookie team) Brawler006 Programming 5 20-02-2004 17:00
robot goes haywire with the one joystick default code Miles Programming 7 24-01-2003 14:58
joystick problem archiver 2000 12 23-06-2002 23:08
switching joystick axis????? team222badbrad Technical Discussion 9 16-01-2002 23:07


All times are GMT -5. The time now is 01:34.

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