RetroBrew Computers Forum
Discussion forum for the RetroBrew Computers community.

Home » RBC Forums » General Discussion » Parallel Printer Port driver for Z80 (Looking for Z80 assembler code example)
Re: Parallel Printer Port driver for Z80 [message #9823 is a reply to message #9822] Thu, 17 March 2022 18:34 Go to previous message
cluso99 is currently offline  cluso99
Messages: 40
Registered: June 2017
Member
Andrew,
The centronics interface is just a plain 8 bit parallel interface with a couple of pins for handshaking. There is no protocol as such. You just send the characters in ASCII to be printed and terminate with <cr> or <Cr><lf> depending on the printers' settings.

There are two ways for handshaking. Once you set the valid 8bit data out you strobe the data available pin (sorry, cannot recall precise naming) and then you either look for Busy to complete, or look for the data ack strobe to indicate completion of the character transfer. Either method works. Search for a Centronics protocol description - this is a standard that all printers comply with - I interfaced many of these to the mini I worked with in the 80's.

<ff> will advance the paper to TOF (top of form) although this may require a VFU (vertical format loop - used to be done with a punched paper tape loop on older printers) loop to be soft loaded, and this mechanism is often specific to the printer.

Some printers have extra character sets which can use the 8th ASCII bit, and others can use <esc> sequences or <si>...<so> sequences. All these are specific to the printer.

Hope this helps,
Ray

[Updated on: Thu, 17 March 2022 18:40]

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Previous Topic: DOS/65 Updated Version to 3.04 ROM
Next Topic: ECB-DMA


Current Time: Sat Oct 25 15:21:32 PDT 2025

Total time taken to generate the page: 0.01232 seconds