CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to support@ccsinfo.com

counter function of atoi()...

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
aldinlapinig



Joined: 16 Dec 2005
Posts: 22

View user's profile Send private message

counter function of atoi()...
PostPosted: Sun Feb 05, 2006 11:27 pm     Reply with quote

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

View user's profile Send private message

Re: counter function of atoi()...
PostPosted: Mon Feb 06, 2006 1:04 am     Reply with quote

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

View user's profile Send private message

im using parallel LCD...
PostPosted: Mon Feb 06, 2006 6:46 pm     Reply with quote

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

View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger

PostPosted: Mon Feb 06, 2006 7:19 pm     Reply with quote

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

View user's profile Send private message Send e-mail

Re: im using parallel LCD...
PostPosted: Tue Feb 07, 2006 1:36 pm     Reply with quote

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

View user's profile Send private message

hi rwyoung...
PostPosted: Tue Feb 07, 2006 8:09 pm     Reply with quote

thank u very much...sorry i missed that printf function.

kind regards,

-=alDin=-
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group