Programmer's Guide

PcOS Series 150

Communications

 

 

Parallel Port

Mode 0

Mode 0 provides a reverse channel for information from the printer.

Normal responses to inquire (ENQ) commands will be placed in the IEEE 1284 reverse channel buffer. The Mode 0 reverse channel request will begin returning this information to the host. The host may terminate the transmission at any time. If the link is terminated between nibbles, the last nibble is retransmitted on the next request. If a complete byte is transmitted, it is deleted from the IEEE 1284 reverse channel buffer.

There is an inquire command that will clear the reverse channel buffer before placing its response in the buffer.

The IEEE 1284 buffer is limited to 256 characters. If the buffer is not emptied by reverse channel requests and data transfers, the buffer will overflow. The buffer is a first-in first-out (FIFO) buffer, and the last data placed in the buffer is lost.

No attempt should be made to send normal data to the printer while the reverse channel is active. Any data sent to the printer in this mode will be lost and may terminate the reverse channel link.

Time-out

IEEE 1284 specifies a time-out for various phases of the protocol. The Series 150 Printer treats these time-outs as minimums. The printer will time out at the specified time only if it is idle during the complete phase.

Active State

The IEEE 1284 reverse channel may be activated at any time as long as the printer is not busy with data. This means that if the printer is off-line the reverse channel may be activated. If the printer is placed back on-line while the reverse channel is active, the printer will not exit the reverse channel mode.

Inquire Responses

In general, inquire commands place two-byte responses in the IEEE 1284 reverse channel buffer. The two bytes are the same as the serial mode responses. In IEEE 1284 mode, the printer will remain busy until the inquire command is processed. This assures responses in real time. To get the response, the host must ask for it. It is possible for the host to make a number of requests and then get all the responses; however, the status returned will be valid at the time the request was made.

It is possible for the dynamic response mode to be activated and the reverse channel opened. The reverse channel will then change from reverse idle to reverse data available as the status changes. The application must be careful in dynamic response mode that the dynamic responses are not left active when the reverse channel is closed. If this happens, the buffer will overflow. If there is data in the buffer when dynamic responses are activated, it will not be replaced by current status. If dynamic response is off and a clear buffer command is issued followed by activation of dynamic responses, the buffer will then contain fresh data. If the buffer clear command is issued after the dynamic response is activated, the buffer will be cleared and any unread responses will be lost.

12/14/99

Rev G

Page 113

Page 123
Image 123
Star Micronics 150 manual Time-out