View unanswered posts | View active topics It is currently Thu Jul 24, 2014 4:32 pm






Reply to topic  [ 2 posts ] 
Buttons do not seem to work on the remote 
Author Message
Rookie

Joined: Thu Oct 18, 2012 2:31 pm
Posts: 1
Post Buttons do not seem to work on the remote
We are having trouble with the buttons on the remote. The joysticks will run the motors and servos perfectly, but the buttons will do nothing. Please see a screen shot of the program attached. I think the buttons on the remote are not working. Both joysticks can be configured to run the servos or the motors. Any ideas?

Thanks
Brad


Attachments:
buttons.JPG
buttons.JPG [ 41.94 KiB | Viewed 969 times ]
Thu Oct 18, 2012 2:43 pm
Profile
Site Admin
Site Admin

Joined: Thu May 24, 2012 12:15 pm
Posts: 556
Post Re: Buttons do not seem to work on the remote
The problem you are seeing is that the button commands are outside of the infinite loop. The
Code:
 while (1 == 1)
condition will never be false, so therefore anything below the while loop will never be reached.

Something else you may want to consider; when do you want your robot arm to stop moving, and where in the code does the arm motor stop? Take a look at our Cortex Video Trainer (specifically the Remote Control -> Buttons -> Controlling the Arm section). It's something I recommend every ROBOTC programmer goes through at least once to learn everything from the basic to the intermediate programming practices:

http://www.education.rec.ri.cmu.edu/pro ... index.html

_________________
Check out our Blog! And our Facebook page!
Need help? Take a look at our Wiki and our Forums.

I just met you,
And this is crazy,
But here's my code now,
So fix it, maybe?
~ Carly Rae Jepsen parody


Thu Oct 18, 2012 2:54 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 2 posts ] 

Who is online

Users browsing this forum: No registered users and 2 guests


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.