Skip to content

Commit

Permalink
uORB/sensor: Update macro of sensor_gnss format string
Browse files Browse the repository at this point in the history
Make it easier to extend the format of struct member

Signed-off-by: wangjianyu3 <[email protected]>
  • Loading branch information
JianyuWang0623 authored and xiaoxiang781216 committed Dec 20, 2024
1 parent ba0a8fb commit d02b053
Showing 1 changed file with 15 additions and 4 deletions.
19 changes: 15 additions & 4 deletions system/uorb/sensor/gnss.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,21 @@
****************************************************************************/

#ifdef CONFIG_DEBUG_UORB
#define UORB_DEBUG_FORMAT_SENSOR_GNSS \
"timestamp:%" PRIu64 ",time_utc:%" PRIu64 ",latitude:%hf,longitude:%hf," \
"altitude:%hf,altitude_ellipsoid:%hf,eph:%hf,epv:%hf,hdop:%hf,pdop:%hf," \
"vdop:%hf,ground_speed:%hf,course:%hf,satellites_used:%" PRIu32 ""
#define UORB_DEBUG_FORMAT_SENSOR_GNSS \
"timestamp:%" PRIu64 \
",time_utc:%" PRIu64 \
",latitude:%hf" \
",longitude:%hf" \
",altitude:%hf" \
",altitude_ellipsoid:%hf" \
",eph:%hf" \
",epv:%hf" \
",hdop:%hf" \
",pdop:%hf" \
",vdop:%hf" \
",ground_speed:%hf" \
",course:%hf" \
",satellites_used:%" PRIu32 ""

#define SENSOR_GNSS_SATELLITE_INFO_FORMAT(idx) \
",svid" #idx ":%" PRIu32 \
Expand Down

0 comments on commit d02b053

Please sign in to comment.