Go to Post I am a mentor now and I would be more proud of a National Chairmans Award which acknowledges my many years of service to the team and the community rather than a National Championship which acknowledges one great robot I helped build. - The Lucas [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
  #6   Spotlight this post!  
Unread 21-03-2005, 21:07
dm0ney's Avatar
dm0ney dm0ney is offline
Will Code For Food (Food Optional)
AKA: Deepak Mishra
None #0217 (The ThunderChickens)
Team Role: Alumni
 
Join Date: Jan 2005
Rookie Year: 2004
Location: Shelby Twp., MI
Posts: 48
dm0ney will become famous soon enough
Send a message via AIM to dm0ney
Re: Programming motors with joystick buttons

Quote:
Originally Posted by stephenthe1
hey,
I always wandered, when you press a button on a joystick (say the top button or trigger), does it "remember" it was pressed and hold a value of 1? I don't really understand this. otherwise, for the guy who posted this forum, he would have to be holding down the trigger, which seems like it would be problematic. do you know what I mean? how does that work.
When a button is pressed on a joystick, it is not remembered. If the motor was to be driven for some time and the user did not want to hold the button until the desired point, a flag would have to be used.

The flag would be set to one when the button is pressed which would enable code controlling relay ouputs or pwms. Once a desired outcome happens, the flag would have to be reset. The outcome could be a pot position being reached, an encoder count value, a set amount of time from either Kevin's clock or a clock variable incremented every program cycle, or even the ORIGINAL BUTTON pressed on the joystick.
__________________

Alumni
Team #217, The ThunderChickens



Student, Class of 2009
California Institute of Technology


 


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
Using the extra buttons on the joystick. Code\\Pilot Programming 7 04-12-2004 19:30
problem with joystick buttons (top left one) Richomundo Programming 5 15-02-2004 17:16
Programming the second joystick in PBASIC archiver 2001 2 24-06-2002 00:25
Looking for practice motors & extra tape drive parts? archiver 2000 1 23-06-2002 22:54
"Motors and Drive train edition" of Fresh From the Forum Ken Leung CD Forum Support 6 29-01-2002 12:32


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

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