Solved

??Keyboard Question??

Posted on 1998-12-10
12
248 Views
Last Modified: 2010-04-27
Hello,
   I am designing a VB app to help handicapped people type and I have two questions related to keyboards and ports.  Anyway, here we go...
   First, I would like to connect a laptop, from it's serial, to the keyboard port of a host computer.  What type of cord, hardware would I need.  Second, what signals are used by a keyboard and are sent to the computer, i.e, hexidecimal values, ....  Is there a reference, on the web or a book, describing how to manipulate a keyboard with these signals.

Thanks in advance!
- Rob

P.S. - I know little about hardware. :-)
0
Comment
Question by:RobS
12 Comments
 

Author Comment

by:RobS
ID: 1130831
Edited text of question
0
 
LVL 9

Expert Comment

by:rmarotta
ID: 1130832
Rob,
What are you trying to do?
Why not go from serialport-to-serialport to allow the two computers to communicate?
There are standard cables and software available to enable this.
Regards,
Ralph
0
 

Author Comment

by:RobS
ID: 1130833
rmarotta,
  The program is complete and works perfectly from serial to serial.  The problem is the host PC needs a program, which I've also written in VB, to process the incoming data.  We would like the host computer to not require any addition software.  I can't think of a way to send data from serial to serial and control the keyboard that way.  If you can think of something, let me know.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 5

Expert Comment

by:Jason_S
ID: 1130834
As I understand, you want connect directly from the Serial port on the laptop to the keyboard connector on the PC.  (Neat concept)  This would let you "virtualy" type anything into the PC by using a program sending the data out the serial on the Laptop.

I don't know if this link is any help to you, but its worth a try.
http://www.usar.com/prodnser/keycod.htm
0
 

Author Comment

by:RobS
ID: 1130835
Jason_S,
   That's exactly what I want to do.  I'm thinking if keyboards use hexidecimal values for keys and it should be the same with all keyboards and platforms, then the laptop will be able to connect to any computer (Macs, SUN, PCs...)
   I looked at the site you gave me.  Thank you, but I don't think it will help.  At least not yet ... I'll have to browse some more.

Thanks
0
 

Author Comment

by:RobS
ID: 1130836
Jason_S,
   That's exactly what I want to do.  I'm thinking if keyboards use hexidecimal values for keys and it should be the same with all keyboards and platforms, then the laptop will be able to connect to any computer (Macs, SUN, PCs...)
   I looked at the site you gave me.  Thank you, but I don't think it will help.  At least not yet ... I'll have to browse some more.

Thanks
0
 

Author Comment

by:RobS
ID: 1130837
Jason_S,
   That's exactly what I want to do.  I'm thinking if keyboards use hexidecimal values for keys and it should be the same with all keyboards and platforms, then the laptop will be able to connect to any computer (Macs, SUN, PCs...)
   I looked at the site you gave me.  Thank you, but I don't think it will help.  At least not yet ... I'll have to browse some more.

Thanks
0
 
LVL 3

Expert Comment

by:rosefire
ID: 1130838
Is your objective to be able to type on the laptop and have it appear as though you are typing on the other computer?  There may be a way to do this through DOS COM settings, but I am fuzzy on it.  If this is what you want to do, let me know and I'll look into it.
0
 

Author Comment

by:RobS
ID: 1130839
rosefire,
   I designed a program in Visual Basic and the form resembles a keyboard.  The user can click the button via the mouse/trackball or speak text in a microphone and I'll handle voice recognition.  The data will then be sent to the host computer.  The purpose it to mimic the keyboard without actually typing.
0
 
LVL 3

Expert Comment

by:rosefire
ID: 1130840
Ah, so what you want to do is have the PC act as a virtual keyboard for the host computer for a couple different input modes.  This is not a trivial problem.  Basically what you need to do is get a driver to sit on the host computer and interpret what comes in as keystrokes.  You also would need a program on the PC that would make the PC take its input from various sources and send it to a driver on the PC that would send it out to the host.  This is a significant undertaking.

You may be able to find some tools available if you search the internet.  Maybe someone or some company has already solve this problem.  You might even go ask at a handicapped-related chat or newsgroup.  The people who use stuff like this might be able to tell you more.

Sorry I don't have a pat answer.
0
 

Author Comment

by:RobS
ID: 1130841
rosefire,
   Thanks for your ideas.
0
 
LVL 12

Accepted Solution

by:
mark2150 earned 100 total points
ID: 1130842
First off there are the electrical problems. A COM port runs on +-12VDC signals, a keyboard uses TTL (+5V) or lower (3.3V) levels so a striaght cable is *NOT* going to work without some support electronics.

Second is protocol. COM ports are driven by 8255 type UARTs (Universal Asynchronuous Receiver/Transmitters). These chips convert a byte of data from the computer into a serial data stream. Additionally they add/remove start/stop bits, generate and check parity bits and take care of the timing. The keyboard uses a direct serial data stream with a separate clocking signal. There is no parity, stop, start or inter character bits. Additionally the UART runs on a 16X clock at specific baud rates (300/600/1200/2400/4800/9600/18.2k etc) while the keyboard generates it's own timing signal. Thus the data protocols are wildly different.

The upshot of this is that there is no good way to tie a COM from one computer to the keyboard of another without a *LOT* of data. Additionally since the keyboard is unidirectional (IN only), there is no way for the two systems to know where they are in a transfer or to signal when to start, stop, resend, etc.

By not using a small TSR program, you're requiring a huge up front engineering effort to design a complex box that, in the end, will *still* not give you decent performance. If you bite the bullet and get a simple TSR program (or even simply use the MODE command to redirect STDIN and STDOUT to the COM port) then you get the ability to fully control the PC with a $5.00, fully passive, serial cable.

M

0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Does a test card exist for a randomly rebooting PC 14 83
Server can not boot up 10 76
VMware Fail Over 5 84
USA Brother MFC suitable for UK countries? 2 37
In the modern office, employees tend to move around the workplace a lot more freely. Conferences, collaborative groups, flexible seating and working from home require a new level of mobility. Technology has not only changed the behavior and the expe…
A clone is a duplicate copy. Sheep have been cloned and maybe someday even people will be cloned, but disk cloning (performed by the hard drive cloning software) is a vital tool used to manage and protect data. Let’s look at what hard drive cloning …
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

679 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question