[comp.sys.handhelds] HP28 IR Link: using a pull-up up resistor and faster transfers

alonzo@microsoft.UUCP (Alonzo GARIEPY) (02/01/90)

I finally got the IR sensor to work.  I use a pull-up resistor to help
the sensor drive the input port on the PC.  You may be having similar
problems, so here is the circuit.

				_________
			GND ---|	|
           +5v -----+----------|   IR	|
		    | 	PC -+--| sensor	|
		    | 	    |  |	|
		    +\/\/\/\+  |________|
		     resistor

The value of the resistor may depend on your PC.  The easiest thing
to do is use a variable resistor.  I ripped open a defunct walkman.

Increased Printing Speed
------------------------
For those of you who do have it working, you can speed up your output
by converting everything to a string and putting an escape character
at the front.  Here is a program that will print whatever is on the
stack.

PROBJ
<< ->STR 27 CHR SWAP + PR1 DROP >>

This is the way to get really fast continuous output.  I don't think
that flag 52 makes any difference in this case.  You should edit out
the escape characters on the PC side.  You could even modify hpread
so that whenever it sees a special sequence (say, three escapes in a
row) it edits them out for you.

I have a logic probe attached to my sensor so I can hear every bit
that goes across :-).  My thanks again to Monsieur Adler.

Alonzo