RH8 /Perl/BVK202A [LK202-25]
Posted: Sat Jul 19, 2003 1:37 pm
Hi,
I am little bit confused. Just purchased the BVK202A, which is a LK202-25.
Anyhoo, using perl, there is a few things I need to set and do with the command set - like set the startup screen and have a cursor be at certain positions.
The perl example that came on the CD doesn't seem to work.
For example, for clearing the screen ...
syswrite DisplayIO, sprintf ("%cX", 0xfe);
It's reporting it out to the LCD, which tells me that the command did not take.
HOWEVER, this does work for clearing the screen ...
syswrite DisplayIO, sprintf ("%c",0x0c);
or
syswrite DisplayIO, sprintf ("%c", 12);
If the latter is the correct way, does anyone have the command sets converted?
Now, would someone be able to tell me what the difference is between 0xfe and '12', because %c is taking care of the convert.
Doing od dumps on the output, I see that \f is being passed to the LCD.
So, I am presuming that 12 is someform of \f ... which I guess works for clearing the screen, but I would really like to use the other parts of the command structure... Any ideas? Why doesn't the perl code in the example given on the CD work?
stty is reporting correct speed, 19200, and I am able to echo test >/dev/ttyS0 just fine.....
TIA!
-Graham.
I am little bit confused. Just purchased the BVK202A, which is a LK202-25.
Anyhoo, using perl, there is a few things I need to set and do with the command set - like set the startup screen and have a cursor be at certain positions.
The perl example that came on the CD doesn't seem to work.
For example, for clearing the screen ...
syswrite DisplayIO, sprintf ("%cX", 0xfe);
It's reporting it out to the LCD, which tells me that the command did not take.
HOWEVER, this does work for clearing the screen ...
syswrite DisplayIO, sprintf ("%c",0x0c);
or
syswrite DisplayIO, sprintf ("%c", 12);
If the latter is the correct way, does anyone have the command sets converted?
Now, would someone be able to tell me what the difference is between 0xfe and '12', because %c is taking care of the convert.
Doing od dumps on the output, I see that \f is being passed to the LCD.
So, I am presuming that 12 is someform of \f ... which I guess works for clearing the screen, but I would really like to use the other parts of the command structure... Any ideas? Why doesn't the perl code in the example given on the CD work?
stty is reporting correct speed, 19200, and I am able to echo test >/dev/ttyS0 just fine.....
TIA!
-Graham.