How do you set a custom controller code in python
I really recommend using the tutorials that are already in VEX code to learn about this. They are really helpful. Sadly I’m not on a computer right now so I can’t properly help you otherwise.
you could have a look at code I posed here.
or the simplified version using graphical setup here.
That’s probably a lot more than you need, it simulates the built in drive code for V5