fix: correct hex format for CRC output (#25442)

- switch to PRIx32 for proper hex formatting
- keep zero-padding and casing consistent
- ensure status prints CRC correctly
This commit is contained in:
Atsunori Saito
2025-08-19 01:03:44 +09:00
committed by GitHub
parent b52a9e7e32
commit e15752099f
+2 -2
View File
@@ -1230,8 +1230,8 @@ int PX4IO::io_reg_modify(uint8_t page, uint8_t offset, uint16_t clearbits, uint1
int PX4IO::print_status()
{
/* basic configuration */
printf("protocol %" PRIu32 " hardware %" PRIu32 " bootloader %" PRIu32 " buffer %" PRIu32 "B crc 0x%04" PRIu32 "%04"
PRIu32 "\n",
printf("protocol %" PRIu32 " hardware %" PRIu32 " bootloader %" PRIu32 " buffer %" PRIu32 "B crc 0x%04" PRIx32 "%04"
PRIx32 "\n",
io_reg_get(PX4IO_PAGE_CONFIG, PX4IO_P_CONFIG_PROTOCOL_VERSION),
io_reg_get(PX4IO_PAGE_CONFIG, PX4IO_P_CONFIG_HARDWARE_VERSION),
io_reg_get(PX4IO_PAGE_CONFIG, PX4IO_P_CONFIG_BOOTLOADER_VERSION),