Reading Keypad on GLK 1964

LK/ELK/VK/PK/OK/MX/GLK/EGLK/GVK/GLT Series

Moderators: Henry, Mods

Post Reply
Kayla
LCD?
Posts: 3
Joined: Tue Jan 31, 2012 4:10 pm

Reading Keypad on GLK 1964

Post by Kayla »

I was following the app note but and my lcd wont read key pressed from the LCD keypad. It would read only from my computer keyboard. Any help on how I would read from the keypad. I'm running Ubuntu and trying to create a menu system.

int PollKeyPress(char key[])//Send the poll command and read a 1 byte, report errors
{
unsigned char command[] = {254, 38};
if(write(lcd, &command, sizeof(command)))
return(read(lcd, key, sizeof(key)));
else
return(false);
}

Thanks,
-Kayla

Clark
Matrix Orbital
Matrix Orbital
Posts: 881
Joined: Fri Aug 17, 2007 10:58 am
Location: Matrix Orbital
Contact:

Post by Clark »

Hi Kayla,

I must admit, the demo is not running as smoothly on a GLK19264-7T-1U as I remember it did on the LK204-7T-1U on which it was written. I'll take a look at the code and let you know what I find.

Thanks,
Troy
Troy Clark
Design & Development
Matrix Orbital

Clark
Matrix Orbital
Matrix Orbital
Posts: 881
Joined: Fri Aug 17, 2007 10:58 am
Location: Matrix Orbital
Contact:

Post by Clark »

Hello again Kayla,

I've rewritten the portion of code that determines if additional keys are to be read, and remembered a rather obscure but important passage from Microsoft documentation regarding port naming.

Please make sure your virtual serial port is no higher than COM9 by changing the advanced port settings in the device manager, or see the notes on naming ports with higher numbers.

The code itself seems to be running smoothly now, if you do have any additional questions please don't hesitate to ask.

Thanks,
Troy
Troy Clark
Design & Development
Matrix Orbital

Post Reply