rfmw
Advanced Member level 2

I'm using Hi-Tech's PICC versions 8.05pl2 and 9.50pl1 and experience the same problems using the conversion characters in the printf() function.
I can output onto the LCD whatever string I want (i.e. alphabet, numbers 0-9, ...) but conversion characters in the printf() function don't work properly. Example:
printf("aBcDeF: %d %x %X",0xca,0xCA,0xcA);
or
unsigned char i=0xCA;
printf("aBcDeF: %d %x %X",i,i,i);
outputs on the LCD the same wrong characters in both cases:
"aBcDeF: 202 CA CA",
where the right string would be: "aBcDeF: 202 ca CA".
I've tried this in MPLAB v7.22 (with 8.05pl2 and 9.50pl1) and HPDPIC (8.05pl2), WinXP SP2.
Any suggestions?
Thanks,
rfmw
I can output onto the LCD whatever string I want (i.e. alphabet, numbers 0-9, ...) but conversion characters in the printf() function don't work properly. Example:
printf("aBcDeF: %d %x %X",0xca,0xCA,0xcA);
or
unsigned char i=0xCA;
printf("aBcDeF: %d %x %X",i,i,i);
outputs on the LCD the same wrong characters in both cases:
"aBcDeF: 202 CA CA",
where the right string would be: "aBcDeF: 202 ca CA".
I've tried this in MPLAB v7.22 (with 8.05pl2 and 9.50pl1) and HPDPIC (8.05pl2), WinXP SP2.
Any suggestions?
Thanks,
rfmw