Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def get_direction(speed):
- '''
- speed := speed of axis in rotation per second
- This function returns:
- 1 := Clockwise rotation
- 0 := No rotation
- -1 := Counter clockwise rotation
- '''
- if speed > 0:
- return 1
- elif speed < 0:
- return -1
- else:
- return 0
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement