View previous topic :: View next topic |
Author |
Message |
SubhamayS
Joined: 07 Mar 2012 Posts: 34 Location: jalpaiguri, India
|
How can I print an Integer value using lcd_putc() function. |
Posted: Mon Feb 10, 2014 9:42 am |
|
|
Hi,
I am using "lcd.c" driver to print a Integer value on LCD (LHD162A)
Please tell how can I do that using lcd_putc() function.
please help !! ![Sad](images/smiles/icon_sad.gif) |
|
![](templates/subSilver/images/spacer.gif) |
bkamen
Joined: 07 Jan 2004 Posts: 1611 Location: Central Illinois, USA
|
Re: How can I print an Integer value using lcd_putc() functi |
Posted: Mon Feb 10, 2014 10:45 am |
|
|
SubhamayS wrote: | Hi,
I am using "lcd.c" driver to print a Integer value on LCD (LHD162A)
Please tell how can I do that using lcd_putc() function.
|
First, read the PIC manual. it specifically states that printf can call other functions. It's very frustrating to have posters crying for help when they simply haven't read the manual. This does nothing but raise the static level drowning out more significant issues/problems others are having.
Your question is outlined right on the help page covering printf.
In your case,
Code: |
printf(lcd_putc, "some string with numbers like %u\r\n", someInt8);
|
_________________ Dazed and confused? I don't think so. Just "plain lost" will do. :D |
|
![](templates/subSilver/images/spacer.gif) |
SubhamayS
Joined: 07 Mar 2012 Posts: 34 Location: jalpaiguri, India
|
Problem solved ! :) |
Posted: Tue Feb 11, 2014 8:14 am |
|
|
Thank a lot @bkamen .. ![Smile](images/smiles/icon_smile.gif) |
|
![](templates/subSilver/images/spacer.gif) |
EJAZMIRZAN
Joined: 02 Aug 2013 Posts: 3
|
|
Posted: Tue Feb 25, 2014 7:09 pm |
|
|
itoa function in string.h convert integer to equivalent character. then you can print it. |
|
![](templates/subSilver/images/spacer.gif) |
|