Special symbols on LCD with PIC16F877A in CCS C Compiler

Status
Not open for further replies.

john120

Banned
Joined
Aug 13, 2011
Messages
257
Helped
11
Reputation
22
Reaction score
10
Trophy points
1,298
Activity points
0
Hello guys I am writing a program in ccs c which will display a percantage of calculations made but I have a great problem to display for example 10% on the lcd.

for example how can I collect this for the lcd to print out 52%:

delay_ms(500);
printf(lcd_putc,"\f52");
delay_ms(500);


thx
 

A single '%' is usually reserves as a format specifier but if you use two together "%%" printf usually prints one of them untouched. So printf(lcd_putc,"\f52%%"); should work. I can't check with CCS but that's how it normally works.

Brian.
 

Try this:

Code:
printf(lcd_putc(0x25));
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…