View unanswered posts | View active topics It is currently Tue Oct 21, 2014 1:51 pm






Reply to topic  [ 5 posts ] 
logetech joystick 
Author Message
Rookie

Joined: Sat Dec 12, 2009 1:10 pm
Posts: 14
Post logetech joystick
no matter what i do i cant seem to get the NXT to see a change in the joystick positions or button presses. the debug window shows a change in the joystick values but nothing changes. i know that it must be something simple and obvious but i cant find it.

the attached file is one that i wrote to try to fix the problem


Attachments:
testish.c [4.24 KiB]
Downloaded 192 times

_________________
2 Much Sense
Sun Dec 20, 2009 4:55 pm
Profile WWW
Rookie

Joined: Sat Dec 12, 2009 1:10 pm
Posts: 14
Post Re: logetech joystick
i have also tried the joystick sample program and it has the same problem. nothing seems to react to the joystick inputs almost like the NXT is not receiving the BT packet

_________________
2 Much Sense


Mon Dec 21, 2009 2:56 pm
Profile WWW
Creator
Creator

Joined: Fri Feb 09, 2007 9:21 am
Posts: 615
Post Re: logetech joystick
Amity447 wrote:
i have also tried the joystick sample program and it has the same problem. nothing seems to react to the joystick inputs almost like the NXT is not receiving the BT packet

Depending on which of the four phases of competition
  • autonomous-disabled/waiting for start,
  • autonomous-running/enabled,
  • teleop-disabled/waiting for start,
  • teleop-running/enabled,
that you're running the joystick settings are not sent to the NXT. For the first three "NULL" (zero) values are sent. Only in the last case are the joystick values sent. If you think about this, it all makes logical sense. The fourth case is the only time that your program should see joystick changes.


Tue Dec 22, 2009 12:11 pm
Profile
Rookie

Joined: Sat Dec 12, 2009 1:10 pm
Posts: 14
Post Re: logetech joystick
thank you for the help putting it in the fourth phase allowed me to get everything working :D

this does make sense but it does pose an annoyance for debugging and testing :programmer:

_________________
2 Much Sense


Wed Dec 23, 2009 2:54 pm
Profile WWW
Creator
Creator

Joined: Fri Feb 09, 2007 9:21 am
Posts: 615
Post Re: logetech joystick
Amity447 wrote:
this does make sense but it does pose an annoyance for debugging and testing :programmer:

There are two "modes" of operation for joystick remote control on the ROBOTC menu.
  • The one described so far provides "competition emulation". Which has the complexity of the multiple states. And which you want to make sure works before you get to a competition rather than experience failure at the competiton. And which you should also test thoroughly in advance with the FCS (Field Competition System) that all teams must use during a standard match
  • The other one is simply for tele-operation of a robot. The joystick values are always sent to a robot without the autonomous/teleop flag or the enabled/disabled flag. This is useful for simply remotely operating a robot but is not very good if you're wanting to run the source code in a competition.
There are separate menu commands within the ROBOTC IDE to invoke these two different modes


Wed Dec 23, 2009 4:17 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 5 posts ] 

Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  



Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.