Anarchy
02-01-2004, 08:14 PM
I just finished wiring up a new 4x20 lcd and stumbled across a article about using a keypad wired to the serial port to control stuff.
Putting two and two together, I thought of having a keypad that is kind of like a ipod/jukebox setup, where you have menu items and submenu items etc. These will be displayed on the lcd, and the keypad will be the selection method. I've written much of the code for the menu system, but still remain clueless as to programming the lcd and keypad side of things.
What I want to happen is the lcd will be displaying stuff under the control of lcdsmartie. Then I press one of the keypad buttons and my program steals control of the parallel port, writes the menu to the lcd and keeps control until no more buttons are press for 5 secs. Then it returns control to lcdsmartie and the process can repeat itself.
My first concern is whether it is possible to simply take control of the parallel port without crashing the other program, and then return control without the other program knowing what happened. Is this possible/easy?
Putting two and two together, I thought of having a keypad that is kind of like a ipod/jukebox setup, where you have menu items and submenu items etc. These will be displayed on the lcd, and the keypad will be the selection method. I've written much of the code for the menu system, but still remain clueless as to programming the lcd and keypad side of things.
What I want to happen is the lcd will be displaying stuff under the control of lcdsmartie. Then I press one of the keypad buttons and my program steals control of the parallel port, writes the menu to the lcd and keeps control until no more buttons are press for 5 secs. Then it returns control to lcdsmartie and the process can repeat itself.
My first concern is whether it is possible to simply take control of the parallel port without crashing the other program, and then return control without the other program knowing what happened. Is this possible/easy?