Connecting the mouse \ keyboard to the PDA via COM port | rasspinovki \ drivers



Rep: (109)
I wrote a small factor here. I need a little more work to be done and it will be what I need ...

Connecting a PS / 2 keyboard to a PDA via the COM port.

1) Output port com ..

If you need an external keyboard for your PDA, and the purchase of BT and IR keypads you can not afford, you can connect to the PDA the usual PS / 2 keyboard via the COM port, the COM port has almost all PDA (unlike USB host) ... to start, you need to lead a normal connector com port (RS232) of the conventional connector CPC, for this you need to find the connector the RS232 (for that I just made out the old cable from the modem), and plug the PDA (for this I used an ordinary whistle from the charger, bundled with my ipaq) also need a soldering iron and solder, and other accessories for soldering .. pinout (which is where the contacts are) can be found on pinouts.ru in particular pinout com port as a rs232 connector located athttp://pinouts.ru/SerialPorts/Serial9.shtmlpinout of the PDA connector can be found there, in particular, pinout of the connector HP iPAQ h19xx, h22xx, h3800, h3900, h4100, h4300, hx4700, h5400, h5500, h6315, h6340, h6365 located athttp://pinouts.ru/PDA/ipaq_22p.shtmlthere are tables, we look there identical names of contacts and simply combine the contacts of the PDA connector with the rs232 connector ...
I did it all in this form, but it can work out differently for you, in general, it’s not important that everything works ...
Attached Image

It should be noted that such a cable is useful not only for connecting a keyboard but also for connecting a mouse, and even a modem.

2) Preparing to assemble the circuit ..

Here is the adapter circuit ..
Attached Image

This scheme is based on the AT89C2051 programmable microcontroller, but for it you need to assemble a rather complicated programmer circuit instead, I recommend using the AT89S8252 microcontroller for it has more memory and is very easy to program ..

To build this scheme, you need:
1) Connector for ps / 2 keyboard "socket"
2) 2 ceramic capacitors 33pf (picot farad)
3) Quartz resonator 24 MHz
4) 10k ohm resistor (kilo ohms)
5) ceramic or electrolytic capacitor 10mkf (micro farad) 16V (volt)
6) atmel AT89S8252 programmable microcontroller in DIP 40 package
7) 4 ceramic capacitor 0.1mkf (micro farad)
8) Integrated Circuit MAX 232 CPE (it is desirable to take CPE and not ACPE and TP, since CPE is cheaper and more suitable for this circuit) in the DIP16 package.
9) RS232 connector
10) Panels for these microcircuits, they can be called SLC and TSR panels, they should definitely be taken, I didn’t buy it because of my stupidity I spoiled the prototyping board and the microchips themselves, because during the soldering the microcircuit contacts get very hot and the microchips fail from overheating, and if you need to remove the microcircuit from the board, you cannot do it without damaging it ..
11) A prototype board for simulating microcircuits, if you assemble such a scheme for the first time, then it is better to take a board with a larger size I bought a 10x10cm board, since I sang the scheme of such complexity for the first time ...
12) about 5 meters of mgtp, it is desirable that the section was smaller, my section was 0.05mm.
13) 2-pin power connectors.
14) 5v power supply, I used 3 AA batteries as a power source, do not try to use power supplies from mobile phones, because there is a pulsed power supply, and the pulsed power supply will not work.

To build the programmer:
1) 2 resistors 200 ~ 500 Ohm
2) lpt port connector
3) 5 pin connector on the board

I bought it all in the store CHIP and DIP at Metro Kurskaya.
Attached Image

I spent about 500r for all this, but if you buy everything exactly according to the list, it will be about 300-400r.

3) circuit assembly

One of the most complex assembly parts. First, take the very development board, then put it on the radio, they need to get their contacts at exactly the hole on the breadboard it all so calculated. I started with the Connector ps / 2, I installed it on the board, then dripped solder where entered the connector contacts, then cut off from the wire MGTF piece desired us the size, then remove from its edges a little insulation, bare wire cover solder, and then on the side where the pins are located. And so here quietly collect the whole scheme, during the assembly, you will need tsoklevki chips and programmable microcontrollers can be found in the datasheet, and themselves datasheets can be found on the manufacturer's website, AT89S8252 datasheethttp://www.atmel.com/dyn/resources/prod_do...nts/doc0401.pdfmax232 datasheetAttached fileimg-18420-MAX.rar(578.91 KB)
.. To distinguish such details as capacitors and resistors, you will need information about the markings, since most of the elements will either be marked with colors, or with codes, information about the marking of capacitors can be found here:http://www.radioradar.net/spravka/conder.p...avka/conder.php, marking resistors here:http://www.alfa-elektronik.com/html/articl...t/mark-res.html.. if you are new to radio engineering, then I would advise you to build small paper envelopes in which to embed elements and on envelopes to write which element lies in them (I did) in order not to accidentally confuse when assembling the circuit .. It is worth noting quartz and condensers need to be soldered closer to the controller, also on the DTR port you can not output the line .. It is also advisable to immediately assemble the programmer, the programmer circuit:
Attached Image
I recommend resistors to hide in the lpt connector itself ... For example, like this:
Attached Image

This is a programmer of another microcontroller (microcontroller), in the scheme of our programmer there will be only 2 resistors ..

It is desirable to ensure that the programmer connects to the board and is not firmly soldered to the MK contacts, for this I indicated a 5-pin connector on the list, which will greatly simplify the life of the M programming ..
Attached Image

Attached Image

4) Microcontroller programming

When the process is complete and the circuit is ready, you can go to the programming of the microcontroller, for this we need the programmer programmer "chameleon" it can be taken from herehttp://atprog.boom.ru/Sindex.htmlwe also need the “firmware” itself, it is a binary file, you can download it from herehttp://mkmk.ras.ru/iprim/arc/palmtasta2.zipIn arhve be file keyboard.bin this is our firmware microns. unsolder first capacitor and a resistor from rst line of the controller, and solder rst programmer, we connect our scheme to lpt computer, connect the power, run the program chameleon choose boring unit for programming we choose it will be AT89S8252 binary file for programming and program code process .. programming will be highlighted over the tablet, which will tell about it .. then we disconnect from the computer programmer, solder back RST line and you're done .. If you are not sure that he will be able to program the controller, as far as I know, there are special firms that have a special programmer, you can then contact them if it is desirable to build a circuit on AT89C2051 as if there where this chip zaprogrommirovat its application will greatly simplify the assembly process and yet it is the cheapest ..
That's all, it remains only to bring the connectors and build the case, well, this is a matter of creativity .. when everything is ready, install the newtonkey program on the PDA, launch it and enjoy the work from the full-size keyboard in the PDA ..
img-18281-IMG_0943.JPG


Post has been editedbambei - 18.11.10, 03:14



Rep: (112)
>Anticommunist
Scheme of what?
If the ps / 2- converter circuit>rs232, then the link to it was: __http://starostin.palmclub.ru/kbd.gif

Post has been editedKlev_ - 19.07.06, 21:25



Rep: (11)
Klev_ ps / 2 ->IR



Rep: (109)
Anticommunist , this is the shemka there at the bottom of the infrared diode (element called infra-red) ...
Klev_ , and what file did you program MK ??? so that the binary suggested link to hpc ???



Rep: (112)
Well, in general, we do not have to write the driver. Everything works fine anyway.
Picture
I ask a particularly shy not to faint. The picture is taken so called. debug booth. LCD display with 4-button keyboard attached to it for debugging purposes only. Also, a connector for programming the MK, a power switch, a reset button, a power indicator (LED), and a 3-pin K142EN5a microcircuit - the reference voltage + 3 capacitances to it and a diode are soldered there for protection against power reversal (fool protection).
The firmware came from the archive palmtasta2.zip. __http://mkmk.ras.ru/iprim/arc/palmtasta2.zip.
The driver used NewtonKey. Russian is naturally not there, but we will still think about it.
Klava yuzal old, oak PC / AT, her connector is not ps / 2.

>plab To test the performance of UART, I programmed the firmware, which I wrote myself with the help of Keil C51, which is also called Keil Mikrovizhn. This is the C ++ compiler for i8051 processor family.



Rep: (112)
Installed AE Keyboard Mapper. Now you can print in Russian. One of these days I will prepare a recipe for assembling a device.



Rep: (112)
And here is the device in work:
Picture
Powered by an external power supply.
Perhaps in the future, instead of the number buttons, I will insert a board with a controller and batteries.



Rep: (109)
Super!!! and what ps / 2 keyboard in any way to use ???

Added @ 20.07.2006, 23:19

another question: in the second picture you just connected instead of ps / 2 ps \ am clava yes ???
One of these days I will prepare a recipe for assembling a device.

I look forward to



Rep: (112)
PC / 2 keyboard and PC / AT keyboard have the same connection interface to the computer. Perhaps only the logic levels are slightly different (the supply voltage is different, etc.), although this is most likely not the case.
RS / AT Klava yuzal only because the PC / 2 was very sorry to put such a risk. Nobody knew whether it will work or not.
I remember that before, even PC / 2-PC / AT adapters were sold somewhere.
So you can use PC / 2 instead of PC / AT clavs.
Yes, and also about the AE Keyboard Mapper: I could not find the key combination with the code 21h to switch the layout to Russian. I had to change the combination to ALT-Z.



Rep: (6)
And here is the device in work:
Two requests:
1) Maybe you can try plug-in the diode and check it to work
2) measure the current consumed by a bunch ...



Rep: (109)
Klev_ or maybe you’ll try to connect the ps / 2 clave ?? Just PC / AT clavs are very healthy and it’s hard to find a fully working pc / at keyboard right now ...



Rep: (112)
>plab
Please write with spaces!
Unfortunately, I do not have an unnecessary PC / 2 keyboard. How to find an unnecessary - be sure to try.

>Mikeware
Current consumed clave -60mA
The current consumed by the controller - 31mA.
The current consumed by the clave can be reduced by lowering the supply voltage slightly.
The current consumed by the controller can be reduced by dropping the power LED out of it, slightly lowering the supply voltage of the circuit as a whole.
IK-diode so simple, I think it will not be possible to connect. The firmware for the controller used, in which there is no implementation of this feature. To use IR you need to find quartz 18 MHz. I have no such quartz. Or you need to pick the firmware of Mr. Starostin.



Rep: (14)
Klev_ @ 07.20.06 13:42:48
PC / 2 keyboard and PC / AT keyboard have the same connection interface to the computer. Perhaps only the logic levels are slightly different (the supply voltage is different, etc.), although this is most likely not the case.

no levels there are different.
just another connector with a different pinout, that's all.



Rep: (109)
I looked in the Internet about adapters ps / 2>PC / AT these clavs differ only with connectors ...
Klev_ what scheme did you use to get the rs232 connector from ipak ???
Another question: please write a list of what you need to buy to build this scheme (given that I already have a soldering iron and solder :)) ...



Rep: (112)
And now about the connection of the mouse.
It turned out that all is not so hopeless.

1) Redid dll driver in a normal exe.
The driver correctly transmits messages from the mouse.

2) I studied the possibility of using the NY virtual display.
In this NY, I discovered the presence of some kind of API.
NVDvideo.dll has mouse cursor routines.
Functions are called NVSetCursorPos and NVGetCursorPos.
I could use the NVSetCursorPos function. But when I tried to call NVGetCursorPos, an exception occurred.
As soon as NVGetCursorPos is obtained, the problem can be considered as solved.
While the mouse can move only relative to the point 0: 0.
Research continues.

>Plab
I found pinout from the pda on pinouts.com.
But when connecting a circuit, the signal from the TxD controller must go to the RxD port of the PDA port.

What you need to build the scheme:
1) All that is drawn on the scheme Starostin.
To ports MK 3.4, 3.5, 3.7 do not need to solder anything.
2) Quartz must be put instead of 18 MHz - 24 MHz.
3) DTR line can not be soldered.
4) Also, instead of the chip-reference voltage source-78L05, you can use its analogue KR142EN5A.
The pinout of this chip can be found on __http://pblock.narod.ru/info/kren_k.html
5) Also need one connector for com-port,
6) one clave connector
7) and any connector for power supply.
8) But the most important thing is to find something that can be soldered on - a breadboard. She in Chip_i_Dip'e worth 250r. It will be the most expensive component in this scheme.
9) Need another connector for LPT port (for the manufacture of the programmer)
10) Cable or cable for the programmer
11) 2 meters of MGTF wires (thin, flexible, stranded, made of copper, the insulation does not melt from overheating, because it is made of fluoroplastic) for the installation of the circuit itself
12) It is also necessary to have a multimeter to check the correctness of the assembly and fault analysis.

Post has been editedKlev_ - 22.07.06, 13:44



Rep: (14)
Klev_ @ 07.22.06 03:13:58
2) I studied the possibility of using the NY virtual display.
In this NY, I discovered the presence of some kind of API.
NVDvideo.dll has mouse cursor routines.
Functions are called NVSetCursorPos and NVGetCursorPos.
I could use the NVSetCursorPos function. But when I tried to call NVGetCursorPos, an exception occurred.
As soon as NVGetCursorPos is obtained, the problem can be considered as solved.
While the mouse can move only relative to the point 0: 0.
Research continues.

mouse_event



Rep: (112)
>sshd
mouse_event for some reason does not work, although it should work.



Rep: (109)
1) All that is drawn on the scheme Starostin.

namely???



Rep: (112)
Now the mouse cursor moves across the screen.
But clicks do not occur where necessary.
As soon as I make the mouse click where I’m going to lay out the finished program for testing.



Rep: (112)
// For the scheme itself
1) AT89S8252 microcontroller
2) Resistance 10k
3) Capacity 10ВµF, 16V, 2pcs
4) Capacity 33pF, 2 pcs
5) Quartz resonator 24 MHz
6) Claudia connector
7) Capacity 0.1ВµF, 4 pieces
8) MAX232 microcircuit
9) connector for the comport
10) Chip 78L05 or KR142EN5A
11) Capacity 1 microfarad
12) Any 2-pin power supply connector
13) Breadboard

// To build the programmer
1) Connector for LPT port
2) Resistance 200..560 Ohm 2pcs
3) 1.5m cable (5 or more lived)
4) five-pin plug for programming

//For work
1) PDA
2) a constant voltage source of at least 7V.
3) Soldered or purchased com cable for PDAs
4) Prog NewtonKey
5) Prog AE Keyboard Map

// To build the circuit and programmer
1) Soldering iron - low-power (15 W)
2) Solder the PIC
3) 2m wire MGTF
4) Multimeter to check the correctness of the circuit assembly and its subsequent debugging
5) Brain.drv driver installed correctly. If there is none, then it is better not to undertake this work.



Rep: (109)
Resistance 10k

resistance is reached by resistors ??? Wash my resistance is measured in ohms, which means 10k ?? I am very poorly versed in all of these resistors and so on ...
3) Capacity 10ВµF, 16V, 2pcs
4) Capacity 33pF, 2 pcs
7) Capacity 0.1ВµF, 4 pieces
11) Capacity 1 microfarad

and what should be the capacitors ?? there are several types of mud ...
13) Breadboard

Is this the one on which a bunch of holes or a ready-made PCB for this particular circuit ?? maybe it will be easier to buy a stetolite plate and make a PCB out of it ???
5) Brain.drv driver installed correctly. If there is none, then it is better not to undertake this work.

The driver is there, but the device is not working properly ...


Full version    

Help     rules

Time is now: 07/08/20, 04:07