| Author |
Message |
btminzon
Joined: 12 Jun 2006 Posts: 145 Helped: 19 Location: Brazil
|
05 Sep 2006 13:29 How to use printf to display amessage in LCD? |
|
|
|
|
Hi people!!! i´m developing an aplication that uses LCD 40x4. I have written the code to show the message, writting byte-to-byte. But takes so much code, and somuch time to do this. I saw in a code sometime ago, using printf function, but i don´t know how to drive the text os the printf function and my LCD logic. I just wanna use printf, instead of wrtitting byte-to-byte. I don´t know if a was clear in my doubt....If anyone understand my problem, and know how to help me, please, i´d be very thankfull!!!
regards
|
|
| Back to top |
|
 |
Google AdSense

|
05 Sep 2006 13:29 Ads |
|
|
|
|
|
|
| Back to top |
|
 |
kannan.k
Joined: 17 Jan 2006 Posts: 25 Helped: 1 Location: chennai, India
|
05 Sep 2006 13:37 Re: How to use printf to display amessage in LCD? |
|
|
|
|
Hi
I believe you are using a microcontroller to send the text. and you are using IDEs like KE!L or MP1AB....
It function name need not be printf (its just a name). You can create your own function, and send the string to be displayed to the function. The function can have all the necessary delays and all that.
Just create the program once and you can use it for any program you want (sort of a library)
kannan.k
|
|
| Back to top |
|
 |
btminzon
Joined: 12 Jun 2006 Posts: 145 Helped: 19 Location: Brazil
|
05 Sep 2006 13:45 Re: How to use printf to display amessage in LCD? |
|
|
|
|
| kannan.k wrote: |
Hi
I believe you are using a microcontroller to send the text. and you are using IDEs like KE!L or MP1AB.... |
yes, i´m using raisonance (like Keil). You know, i thought in doing this, creating my own printf function, but i swear i saw tha code in the programmer used the <stdio.h> printf. I just thought that there is a way to "modify" the standard printf. But, tnkx for the help
regards
|
|
| Back to top |
|
 |
Roma_te
Joined: 09 Feb 2006 Posts: 52 Helped: 4
|
07 Sep 2006 18:53 Re: How to use printf to display amessage in LCD? |
|
|
|
|
| I think the best way is to write new putchar function (it is used by printf). Which makes lowlevel output of one character on LCD and increases position.
|
|
| Back to top |
|
 |