Hello, I was looking a demo application for MC9S12DT256B which prints characters & strings onto the LCD display using LCDPutString() and LCDPutChar() function.
(a) My requirement is to print integers in a loop (say i = 0 to i = 10) onto the LCD display. Can you kindly help me out with this? I tried a number of ways to implement it, but unfornately none of them worked.
(b) As I can print characters using LCDPutChar function, is it possible to print the characters on the LCD display in sequence by incrementing the ascii values? Please help me out with this.
Thanks,
Aditya.
If you already have a function that is able to print the chars (LCDPutChar) then all you have to do is
for ( i = 0; i < 10; i++ ){ LCDPutChar( 0x30 + i ); Delay ( 2ms ); /* Delay of 2 ms if you are not watching the busy flag */}
It be an idea to post the things that you have tried so that we dont suggest what you have already tried or see if there is a bug in what you have done. The above will print 0 to 9 like
0123456789, depending on if this the first thing that your are printing after clearing the LCD and commanding it to home position.