<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
On 4/10/2012 10:57 PM, <a class="moz-txt-link-abbreviated" href="mailto:dabigboy@cox.net">dabigboy@cox.net</a> wrote:
<blockquote
cite="mid:20120410235742.H0JGA.388301.imail@eastrmwml301"
type="cite">
<pre wrap="">Thanks for the link, looks interesting. Actually the original CRT tube probably still works, I just have no idea how to power or drive it, so I went the "easy" (HAH!) route. I would love to run the original 3" CRT, but I'm afraid such a feat is far beyond my meager electronics skills.
Matt
_______________________________________________
Simpits-tech mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Simpits-tech@simpits.org">Simpits-tech@simpits.org</a>
<a class="moz-txt-link-freetext" href="http://www.simpits.org/mailman/listinfo/simpits-tech">http://www.simpits.org/mailman/listinfo/simpits-tech</a>
To unsubscribe, please see the instructions at the bottom of the above page. Thanks!
</pre>
</blockquote>
Matt<br>
I saw the working LCD nice.. for your keyboard dont re-invent the
wheel.. a ps2 keyboard (downer) with the cable then a ps2 extension
cable for your socket or rip one off a old dead motherboard, works
really well. Check out my blog: <a
href="http://phoenixcomm.wordpress.com/category/ps2-keybaord/">http://phoenixcomm.wordpress.com/category/ps2-keybaord/</a><br>
there is a nice step by step tutorial here: <a
href="http://www.instructables.com/id/Hacking-a-USB-Keyboard/">http://www.instructables.com/id/Hacking-a-USB-Keyboard/
</a><br>
one note ps2 keyboard is a snap if you use usb you will need a USB
shield, because you cant use the usb that goes to your host (wont
work)<br>
then write a little lookup table and assign the keys: you have the
full alpha A-Z (but there shifted).<br>
so use un-shifted first something like this:<br>
<br>
<i>keyboardscanner(){<br>
enum skeys { MSG, ALPHA, CLR, ENTER }<br>
//then the rest is a snap.. just use alpha keys but your going to
have to change them a little <br>
raw = getchar(); // get first char<br>
switch( raw ) {<br>
case MSG: //do something<br>
case ALPHA: {<br>
alpha_flag = 1; //shifts keybord for one char.<br>
raw = getchar();<br>
decodedchar = decoder( raw, alpha_flag )<br>
// send off the char<br>
alpha_flag = 0; // reset flag }<br>
case CLR: // press once: clear last char or press twice: clear
msg.<br>
case ENTER: // does what it says.. no code.<br>
default: {<br>
alpha_flag = 0; //make sure that the flag is reset<br>
decodedchar = decoder( raw, alpha_flag )<br>
// send off the char<br>
}}}<br>
<br>
char decoder( char raw, int alpha_flag ){<br>
// build a 2 dim lookup table (array) ie.. something in..
something else out.. LOL<br>
char keys[4][28]; //to make it simple do it in two passes..<br>
keys[0] = { unshifted keys}<br>
keys[1] = { shifted keys }<br>
keys[2] = {outputed un-shifted keys }<br>
keys[3] = {outputed shifted keys }<br>
<br>
for( int n = 0; n < 29; n++ ){<br>
if( raw == keys[ alpha_flag][n] ) {<br>
return keys[ alpha_flag + 2 ][n];<br>
}<br>
// error recovery ?<br>
return -1;<br>
}<br>
</i><br>
BTW there is a ps2 keyboard libary.. in the playground:<br>
<a href="http://www.arduino.cc/playground/Main/PS2Keyboard">http://www.arduino.cc/playground/Main/PS2Keyboard</a>
<br>
I have mine hooked up on a prototype shield (btw or maybe a gotcha?<br>
the cheep proto shields on ebay ARE NOT STACKABLE!! beware!!!!<br>
<br>
hopes this all helps just a little <br>
<br>
Cris H.<br>
phoenixcomm.wordpress.com<br>
<a href="http://www.instructables.com/id/Hacking-a-USB-Keyboard/"></a>
</body>
</html>