_X7JAY7X_ wrote:I guess there is a few options. Mine can use either 2xXX or 4x20 without any firmware change. Check the addressing of the 2 line LCD vs the 4 Line LCD. If I remember right, the first 2 lines of both use the same addressing.
Are you saying it works by default? I was worried that the goto [col][row] function wouldn't line up, but if it just works anyway, that's cool. Just solder and play!
_X7JAY7X_ wrote:The 40x4 is alot different and requires a complete firmware change as far as how the PIC writes to the LCD. You would have 2 enables lines (2 controllers) and would have to toggle between each controller depending on the write position. You also have to kesayi write to after a position change.
I won't bother then.
_X7JAY7X_ wrote:Another option would be to make a program (in visual basic or whatever) that can change values in the EEPROM. Depending on this value, the PIC would know what LCD routines it is supposed to use.
Guess I won't need to if it works by default.
_X7JAY7X_ wrote:Did you write the LCD routines yourself?
I tried using the XLCD library provided by Microchip. I spent a fruitless week trying to get it to work. I then thought never mind I might as well write my own, and it only took an afternoon to get data, commands and BF reading all working from scratch in 4bit mode. So easy to waste time looking at other people's code, hey!?
I then had to make them all non-blocking as the USB firmware isn't interrupt based, and likes to get enough CPU time. Time sharing isn't really a problem at 48MHz though! I have TMR0 triggering a buttons check routine though, which queues a keypress to be sent from the main time-shared loop. I plan to add the backlight PWM updater to this ISR.
I wrote them myself for the AVR thing as well, from the datasheet on the milinst.com website. Re-writing for the PIC wasn't too tricky as I could copy the procedures I'd already used before. I also worked from the LK-204-25 datasheet.
I've posted in the General Forum asking about some FanSpeed function that seems to be dead... I'm hoping the LCDSmartie developers are going to make it implement some kind of PWM for the GPOs! As the PIC can sustain 128kbaud with the computer, PWM for fans should be no problem! If they don't I may have to request/write a plugin...
Thanks for the info!
ch424