Debug using UART - function print_hword not working ???

2 posts / 0 new
Last post
SilasValera
Offline
Last seen:4 years 4 months ago
加入:2016-06-12 21:55
Debug using UART - function print_hword not working ???

Hi
I am trying to debug using UART, the blinky project works perfectly fine which uses function printf_string(str).
I am trying to send an integer variable value using print_hword (this function is in common_uart.h), the program compiles fine, the program also runs - but I do not see any output in the tera_terminal screen for the print_hword line

h = h * 265;
printf_string("\n\r *printing variable value **************");
print_hword(h);

Is there any other method to print formatted values of the variables (like int, decimal, float etc) ?
Requesting your prompt help...

Thanks
Silas Valera

Device:
MT_dialog
Offline
Last seen:2 months 2 weeks ago
工作人员
加入:2015-06-0811:34
Hi SilasValera,

Hi SilasValera,

I can't replicate what you are mentioning, i ve managed to use the print_hword() in the blinky project, check what is the parameter that you are using when calling the function, there is no printing function implementation that will output a float variable, regarding the printing in decimal, you can have a look at the printf_byte_dec() function that will print a byte value in decimal format. When using the BLE examples you can use the arch_printf() function for debugging where you can choose the format between decimal, hexadecimal, character or string.

Thanks MT_dialog