From 6bc7601e8f6c83c8def86aa7ae7cf06f51593771 Mon Sep 17 00:00:00 2001 From: James McKenzie Date: Sat, 18 Feb 2023 18:48:42 +0000 Subject: remove all use of FP in printf as it's not thread safe --- app/display.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'app/display.c') diff --git a/app/display.c b/app/display.c index 5c745b7..bf811d8 100644 --- a/app/display.c +++ b/app/display.c @@ -115,7 +115,7 @@ void display_dispatch (void) case 1: if (!have_lock) break; - snprintf (buf, sizeof (buf), "%.8f", gps_lat); + snprintf (buf, sizeof (buf), "%s", fd1 (gps_lat, 0, 1, 8)); buf[sizeof (buf) - 1] = 0; max7219_write_string (buf, 0, 2); break; @@ -123,7 +123,7 @@ void display_dispatch (void) case 2: if (!have_lock) break; - snprintf (buf, sizeof (buf), "%.8f", gps_lon); + snprintf (buf, sizeof (buf), "%s", fd1 (gps_lon, 0, 1, 8)); buf[sizeof (buf) - 1] = 0; max7219_write_string (buf, 0, 2); break; -- cgit v1.2.3