Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def update():
- #Apply deadband filter to avoid drift
- #And continousRotation filter to yaw axis to avoid jumps when passing tracker center
- x = filters.deadband(filters.delta(math.degrees(filters.continousRotation(android[0].googleYaw))), deadband)
- y = filters.deadband(filters.delta(math.degrees(android[0].googleRoll)), deadband)
- mouse.deltaX = x * x_multiply
- mouse.deltaY = -y * y_multiply
- if starting:
- deadband = 0.1
- x_multiply = 15
- y_multiply = 15
- android[0].update += update
Add Comment
Please, Sign In to add comment