How to control your HP Jetdirect 170x
This step by step
instruction describes how to setup a HP Jetdirect 170x
print server so that the 8 bits output
can be controlled by a user made program
or from a PHP script.
To make a fresh start you can factory reset
the Jetdirect 170x.
1. Unplug the power to the Jetdirect.
2. Press and hold the 'Test' button while plugging the power back in for 5 seconds.
3. The Jetdirect should be reset now and is configured by default to obtain an IP address automatically.
Take a DB25 male connector and connect pins 1, 10, 13 and 15
Plug in the DB25 connector.
Start your web browser and go to the Jetdirect's web interface
by typing its IP address in the location bar. (e.g. http://192.168.1.xxx).
Give the Java engine some time to start.
The printer status should show 'On-Line'
- now you know your DB25 connector is soldered well.
and go to the Configuration tab
and tick the Snmp checkbox.
Enter 'private' (without the quotes) as New Set Community Name. This community name functions as a password
, we will need it later on.
Press Apply and wait for the device to reset.
Now we need to change a (hardware) register inside the Jetdirect.
It is the npPortCentronicsHandshaking register
which controls handshaking between printer and Jetdirect.
To accomplish this you need a tool that can send (and receive) SNMP commands
A simple tool will do. E.g. SNMPGetSet.exe, obtained here: http://www.fileguru.com/SNMPGetSet/download
Start the program and type the Jetdirect's IP address. Click SNMP Get All
. This should give a result of 3 out of 5.
DO NOT use this program when you're in a hurry - you might screw up your print server!!!!
Registers are read and written by using Object Identifiers
(OIDs) - it is the dotted numerical strings you see.
The npPortCentronicsHandshaking register is addressed by OID 126.96.36.199.188.8.131.52.184.108.40.206.0 .
Copy this OID to the lower panel of the program to do a Selective SNMP Get
Click SNMP Get
and note the returned value.
We need to set this register value to '2
Type '2' as value and click SNMP Set
. The value will be written using the Write community name (top right) as password.
Give the Jetdirect some time to store
the new value. It is retained
after a power cycle.
Now you are ready to control the eight bits
output of your print server by PHP or any other home made program.
Use TCP port 9100
to write your bytes to.