Post Reply 
How to use a parallel printer with the HP Portable Plus
03-12-2023, 10:32 AM (This post was last modified: 03-14-2023 06:03 AM by Klaus Overhage.)
Post: #1
How to use a parallel printer with the HP Portable Plus
Printers can be connected to the HP Portable Plus via a serial cable or via HP-IL and are then automatically assigned to the MS-DOS device PRN as the standard printer. For example, you can type DIR > PRN from the DOS prompt to print a list of all files.

Anyone who owns an HP 82165A or HP 82166A, a so-called GPIO interface, and has connected a Centronics printer to it, can use it with the HP-75C and HP-71B without any problems by entering PRINTER IS ":PR". The BIOS of the HP Portable Plus does not offer such a possibility, it automatically assigns all HPIL printers and HPIL video interfaces to the device PRN and ignores GPIO interfaces at all.

The "Find Device" function of the software interrupt 54h is described on page 5-70 of the PortablePlus_TechnicalReferenceManual. The following sentence made me curious: "The BIOS maintains a table of all devices that have been found on the loop and will return data from this table if it is available."

So there is a list of all device accessory IDs found in RAM, but unfortunately there is no where. A printer has the accessory ID 32 (= 20h) and a GPIO interface has the accessory ID 64 (=40h). What happens if you change the value 64 to 32 in this list? Does this mean that a GPIO interface is recognized as a printer and becomes a PRN device? I tried that.

The list starts at memory location 3823 decimal. I connected several HP-IL devices at the same time and searched the RAM for their accessory ID's. Unfortunately, it is not enough to change the 64 found in this way to a 32 once, because the value is automatically reset to 64 a short time later. The "Configure Loop" function of the Int 54h is probably executed quite often before an HP-IL action.

This gave me the idea of ​​redirecting the entry in the interrupt table of INT 54h to a small machine language routine that sets the 64 of the first connected device to 32 before each HP-IL action. The PRT@GPIO.COM program saves the 19 bytes of machine code to a free location in RAM and changes the entry in the interrupt table. This can be observed with the help of the program MEMVIEW.COM.

The MEMVIEW1.txt attached below shows the state before, for example after a soft reset with CTRL-Shift-Break. MEMVIEW2.TXT shows the state after running PRT@GPIO. You can still see the 64 there. It changes to 32 with the next HP-IL action. This DOS command can be used as a test: echo hello > prn

Even after switching the HP Portable Plus off and on again, the conversion to 32 remains active. Every application program should also be able to recognize and use the parallel printer. The original state can be restored using CTRL-Shift-Break or with the help of the program PRT@STD.COM.

I find Martin Hepperle's HPIL.COM program very helpful because it lists all the HP-IL devices found with their accessory IDs and I have included it in the zip archive. Please refer

The zip archive contains the files:

Attached File(s)
.txt  MEMVIEW1.TXT (Size: 1.51 KB / Downloads: 13)
.txt  MEMVIEW2.TXT (Size: 1.51 KB / Downloads: 7)
.zip (Size: 38.98 KB / Downloads: 10)
Find all posts by this user
Quote this message in a reply
Post Reply 

Messages In This Thread
How to use a parallel printer with the HP Portable Plus - Klaus Overhage - 03-12-2023 10:32 AM

User(s) browsing this thread: 1 Guest(s)