![]() |
Help with toggle-button
We would like to be able to press a button in the joystick, and that for example if the joystick was controlling motor 1, it would control motor 2.
Thanks in advance. |
Re: Help with toggle-button
My team does type of action for our dual acting solenoid.
Code:
Code:
if(Piston){ |
Re: Help with toggle-button
Could you give me more info about it? or a simpler version using two motors only?
Thanks in advance |
Re: Help with toggle-button
All you would have to change is this part of the code assuming you keep Booleons named the same:
Code:
if(Piston){Code:
if(Piston){ |
Re: Help with toggle-button
i have this code so far, i cant get it to work, any idea of what could be wrong?
Code:
#include "WPILib.h" |
Re: Help with toggle-button
Quote:
|
Re: Help with toggle-button
could you give me a hand with it? im still new in the field of c++ robotics.
Thanks in advance |
Re: Help with toggle-button
tomy's first reply to you gave the toggle code you are looking for.
|
Re: Help with toggle-button
thanks for the reply, but i dont quite get what im supposed to do
Thanks in advance |
Re: Help with toggle-button
I'm not skilled enough with C++ to help you in this kind of back-and-forth forum posting. It seems likely that your level of understanding is such that you would be best served by someone helping you in person. Do you know any other teams in the Long Beach area?
|
Re: Help with toggle-button
Unfortunately, I don't thanks for the help tho
Any thing you think i should read to get more informed in the subject or another place to get help from are appreciated |
Re: Help with toggle-button
Here is some commented code that does what you want to get you started. If you are the only programmer on the team though, I agree you should try to find a mentor or another student who can help you out if you don't have much experience. Also, don't be afraid to read the errors and warnings eclipse is giving, often they make sense. Good luck! :)
Code:
#include "WPILib.h" |
| All times are GMT -5. The time now is 12:07. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi