Hello, I need help with some code I just wrote. I’m a pretty terrible programmer overall, but I am also working alone this year so I need to be able to learn to program. I was initially trying to make a split arcade drive (like I have working in VexCode V5 Text) in PROS. Seeing as that failed, I simplified in hopes of making SOMETHING work, but no luck even with what is basically the example code. Here’s what I have for Split Arcade:
Thank you Weilin. I’ll test. Also worth noting it may be the Move command I used which seems to take values between -127 and 127. Not sure if those motor power variables I had are going way higher or not. I just tried to mimic the code I had in VexCode…
I did notice that yes. However, I’m trying to basically convert my working code from Vexcode over, so that’s why I have the powers for the motors calculated the way I do. What function would you suggest using for that purpose? In VexCode I was using the spin command with velocity as a percent.
Also, I tried just doing printf(“testing”); in my while loop, when I turn on the program all I get is a gray screen. Not sure if this is some stupid LVGL thing plaguing me (I do have a working auton menu, I don’t know how it interacts with Opcontrol).
I’m not sure what else I can do. The definitions at the top are still the same. All I’m doing is entering the program from the menu normally. No competition switch or anything. Assuming this enters the Opcontrol function, I’m not sure what else to try.
Thanks, that would explain it. I looked into the printf a bit but I didn’t realize it went to the terminal. I was basically using the clawbot tutorial by the end of my testing (as in it was that simple) so I’ll have to keep fiddling with it until I get something working I guess.
As much as going back to VexCode is an option, I potentially wanted to use Okapi for odometry (provided I get meaningful access to a field this season to do auton) and I already have that auton menu which I really want to be able to implement. So, that would be worst case scenario…
Okay, problem solved. Literally all that was happening is my code was not downloading. I had been hitting the upload button, which is apparently not valid. Turns out you have to go save and then potentially the only button that can be used is the PROS Quick Action one. I figured out the terminal stuff, so thanks for that @weilin. Anyway that clears up all my issues for now, I might pm you if I run into any more later on.