Heyo, I’m having trouble with my Pneumatics. When I hit the toggle the first time, they will extend, but when I hit it the second time, they will briefly release, but they won’t stay released.
Here’s the gists of the code
Not completely sure why your code didn’t work but its probably because your code loops so many times that its detecting the button being pressed multiple times before you release it, so that’s probably why it didn’t work. Example: Presses “A” Button for .2 seconds, Code has looped 16 times (not sure how many times per second the code loops so this is just an estimate) in that time which breaks your loop, and the toggle doesnt work.
I’m not really sure, it might have something to do with registering the button pressed callbacks multiple times in a loop. Or it might be due to the typo in the function definition.