So I have a odd problem.
I have raspberry pi model 3 using gpiozero in python 3.
Just trying to turn on the motor at half speed when calling the function.
Issue is that nothing happens when function is called no power coming from pin 17 and no errors are generated and the "got this far" print command is successful, also code works perfectly when not inside the function.
I know the code is a bit redundant but it is because I have simplified it trying to get it to work without possible external interference.
Import gpiozero def forwardboth(): a = gpiozero.Motor(17, 18) a.forward(0.5) print('got this far') forwardboth()