backend: 20Hz report rate and pitch/roll match

This commit is contained in:
Mikkeli Matlock
2026-02-02 19:30:55 +09:00
parent 83cc6bed19
commit 18fbc63281
2 changed files with 8 additions and 6 deletions

View File

@@ -298,9 +298,11 @@ class ArduinoService:
result[name] = float('nan')
# IMU axis correction for mounting orientation
# Roll needs inverting for motorcycle frame alignment
if 'roll' in result and not math.isnan(result['roll']):
result['roll'] = -result['roll']
# Pitch/yaw inverted for motorcycle frame alignment (roll left as-is)
if 'pitch' in result and not math.isnan(result['pitch']):
result['pitch'] = -result['pitch']
if 'yaw' in result and not math.isnan(result['yaw']):
result['yaw'] = -result['yaw']
return result