From a4fc870692c393e5d7222d3abded691215690392 Mon Sep 17 00:00:00 2001 From: YAMAMOTO Takashi Date: Fri, 13 Nov 2020 18:40:22 +0900 Subject: [PATCH] boards/arm/stm32/nucleo-f334r8/src/stm32_highpri.c: Fix a printf format warning --- boards/arm/stm32/nucleo-f334r8/src/stm32_highpri.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/boards/arm/stm32/nucleo-f334r8/src/stm32_highpri.c b/boards/arm/stm32/nucleo-f334r8/src/stm32_highpri.c index 32acb0ac4e..161b5c0ea0 100644 --- a/boards/arm/stm32/nucleo-f334r8/src/stm32_highpri.c +++ b/boards/arm/stm32/nucleo-f334r8/src/stm32_highpri.c @@ -24,6 +24,7 @@ #include +#include #include #include #include @@ -543,10 +544,10 @@ int highpri_main(int argc, char *argv[]) g_highpri.lock = true; #ifndef CONFIG_STM32_ADC1_DMA - printf("%d [%d] %0.3fV\n", g_highpri.cntr1, g_highpri.current, + printf("%" PRId32 " [%d] %0.3fV\n", g_highpri.cntr1, g_highpri.current, g_highpri.r_volt[g_highpri.current]); #else - printf("%d ", g_highpri.cntr1); + printf("%" PRId32 " ", g_highpri.cntr1); for (i = 0; i < REG_NCHANNELS; i += 1) { @@ -559,7 +560,7 @@ int highpri_main(int argc, char *argv[]) #ifdef HIGHPRI_HAVE_INJECTED /* Print data from injected channels */ - printf("%d ", g_highpri.cntr2); + printf("%" PRId32 " ", g_highpri.cntr2); for (i = 0; i < INJ_NCHANNELS; i += 1) {