Go to Post Good teams get picked, great teams want to do the picking... - Dave McLaughlin [more]
Home
Go Back   Chief Delphi > Technical > Programming > NI LabVIEW
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
  #5   Spotlight this post!  
Unread 09-02-2013, 12:54
Mark McLeod's Avatar
Mark McLeod Mark McLeod is online now
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,833
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Robot "twitching?"

All the stuff that feeds into FIRE including the joystick gets for axes and buttons, can all be copied and pasted into clear space in Periodic Tasks.vi.

Then put a While loop around it that never ends, and put a 10ms Wait in there so it doesn't suck all the life out of the cRIO.

There's nothing special about Teleop that gives it exclusive access to the Joystick controls. They can be read in Teleop and in Periodic Tasks, or other places, too.
The advantage of Teleop is that it only gets called whenever there are new joystick values to process, so it's more efficient.
Run the loop in Periodic Tasks a little faster than the 20ms communication packet rate and it won't matter that you're sometimes reading joystick info twice sometimes. The duplicate info won't be the the signal telling you to FIRE.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle

Last edited by Mark McLeod : 09-02-2013 at 12:58.
Reply With Quote
 


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


All times are GMT -5. The time now is 22:51.

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