Overlay IMU data even if no cal

picamera2
Mark Jessop 2023-01-26 13:04:11 +10:30
rodzic a1b284a74c
commit eecc49e131
1 zmienionych plików z 8 dodań i 8 usunięć

Wyświetl plik

@ -172,14 +172,14 @@ def post_process_image(filename):
if bno != None:
orientation = bno.read_state()
if (orientation['sys_cal'] == 3):
bno_string = " Heading: %.1f˚ Pitch: %.1f˚ Roll: %.1f˚" % (
orientation['euler_heading'],
orientation['euler_pitch'],
orientation['euler_roll']
)
else:
bno_string = ""
bno_string = " Heading: %.1f˚ Pitch: %.1f˚ Roll: %.1f˚" % (
orientation['euler_heading'],
orientation['euler_pitch'],
orientation['euler_roll']
)
if (orientation['sys_cal'] != 3):
bno_string += " (Uncal)"
else:
bno_string = ""