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.

IAR for MSP430 function printf

Hi everyone,

Why

uint8_t c;
c = ~0x0A; printf("%u", (unsigned int)c);

outputs value greater than 8bit variable can hold? for example the output might be something like this: 65525.


Is there is an approach to print 8bit variable's values using printf function?

**Attention** This is a public forum