View previous topic :: View next topic |
Author |
Message |
aldinlapinig
Joined: 16 Dec 2005 Posts: 22
|
counter function of atoi()... |
Posted: Sun Feb 05, 2006 11:27 pm |
|
|
hi guyz,
is there any counter function of atoi()? I want to convert integer to string.
using LCD.C driver, how can one display hexadecimal or decimal number?
thanx...
-=alDin=- |
|
|
Eugeneo
Joined: 30 Aug 2005 Posts: 155 Location: Calgary, AB
|
Re: counter function of atoi()... |
Posted: Mon Feb 06, 2006 1:04 am |
|
|
aldinlapinig wrote: | hi guyz,
using LCD.C driver, how can one display hexadecimal or decimal
-=alDin=- |
You don't have to convert it since hex is just a representation for the value. Just use
printf(lcd_putc, "Upper case %X Lower case %x",hex_value,hex_value); |
|
|
aldinlapinig
Joined: 16 Dec 2005 Posts: 22
|
im using parallel LCD... |
Posted: Mon Feb 06, 2006 6:46 pm |
|
|
thank u sir but I'm using the UART for other purpose. I'm using parallel lcd not serial. any other idea? I highly appreciate ur immediate response.
thank u
-=alDin=- |
|
|
kender
Joined: 09 Aug 2004 Posts: 768 Location: Silicon Valley
|
|
Posted: Mon Feb 06, 2006 7:19 pm |
|
|
Look at sprintf(). Same as printf, but it prints to the string in the memory, and then you can send the string as parallel bytes to your LCD. |
|
|
rwyoung
Joined: 12 Nov 2003 Posts: 563 Location: Lawrence, KS USA
|
Re: im using parallel LCD... |
Posted: Tue Feb 07, 2006 1:36 pm |
|
|
aldinlapinig wrote: | thank u sir but I'm using the UART for other purpose. I'm using parallel lcd not serial. any other idea? I highly appreciate ur immediate response.
thank u
-=alDin=- |
Look again at what Eugeneo wrote and read the documentation for the printf function in the help file. He isn't sending it to the UART. _________________ Rob Young
The Screw-Up Fairy may just visit you but he has crashed on my couch for the last month! |
|
|
aldinlapinig
Joined: 16 Dec 2005 Posts: 22
|
hi rwyoung... |
Posted: Tue Feb 07, 2006 8:09 pm |
|
|
thank u very much...sorry i missed that printf function.
kind regards,
-=alDin=- |
|
|
|