Advertisement
Guest User

Untitled

a guest
Jan 24th, 2020
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import MotorBridgeI
  2. from time import sleep
  3.  
  4. ServoName   =  1
  5. Frequency   =  50
  6.  
  7. motor = MotorBridgeI.MotorBridgeCape()
  8. motor.ServoInit(ServoName, Frequency)
  9.  
  10. for angle in ( 0, 45, 90, 135, 180, 135, 90, 45, 0 ):
  11.     sleep( 0.5 )
  12.     motor.ServoMoveAngle(ServoName, angle)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement