This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

  • TI Thinks Resolved

RTOS: Printf of hexdecimal not works

Guru 18480 points

Replies: 11

Views: 217

Tool/software: TI-RTOS

Hi, I'm working with the serial and I'm having trouble printing a hexadecimal value in uppercase. In lower case it works very well, in fact, I have:

System_sprintf(value, "%02x %02x %02x %02x\n ", Myvar[0], Myvar[1], Myvar[2], Myvar[3]);
	    UART_write(uart, value, 29);

And I see: 5e 5e 5e 5e

If I use:

System_sprintf(value, "%02X %02X %02X %02X\n ", Myvar[0], Myvar[1], Myvar[2], Myvar[3]);
	    UART_write(uart, value, 29);

I see: X X X X 

Why?

This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.