AnsweredAssumed Answered

sprintf question

Question asked by Li Zhengping on Jan 4, 2010
Latest reply on Jan 13, 2010 by CrasyCat

hi all!

 

I am use codewarrior for microcontroller special edition V6.2 and for coldire v7.1.AND find one question about sprintf function. It seem not support "%C" format arguments. I write the code:

uint8 c; 

sprintf(buf,"char you send is:%c\N",c); 

uart_putstr( buf);

I got "char you send is:   "

but if I change"%c"to"%d",I got correct ascii code of the c.

Outcomes