Arduino library that implements a parallel printer - print interface
Go to file
rob tillaart fbeb25eee0 0.2.0 version 2020-06-25 10:19:33 +02:00
examples 0.2.0 version 2020-06-25 10:19:33 +02:00
LICENSE 0.2.0 version 2020-06-25 10:19:33 +02:00
ParallelPrinter.cpp 0.2.0 version 2020-06-25 10:19:33 +02:00
ParallelPrinter.h 0.2.0 version 2020-06-25 10:19:33 +02:00
README.md 0.2.0 version 2020-06-25 10:19:33 +02:00
library.json 0.2.0 version 2020-06-25 10:19:33 +02:00
library.properties 0.2.0 version 2020-06-25 10:19:33 +02:00

README.md

ParallelPrinter

Arduino library that implements a parallel printer - uses print interface

Description

This experimental library defines a simple parallel printer object.

It implements the Print interface to be able to print all datatypes. It writes every byte over 8 parallel lines including a STROBE (clock) pulse, while waiting for the connected printer to not be BUSY or OUT OF PAPER.

This library is meant to be a starting point to make a "printer driver" for a specific parallel printer. These can often be bought in 2nd hand stores or so.

Have fun!

Note: This lib is a extended redo of the ParPrinter class.

Interface

  • ParallelPrinter(strobe, busy, oop, arr) define 3 control pins + 8 datapins (= arr)

  • begin(linelength, pagelength) set page parameters

  • write(c) send a single byte to printer, implements Print interface.

  • setTabSize(n) tabs are replaced by spaces. n = 2,4,6,8

  • setLineFeed(n) n = 1,2,3 1 = default

  • printLineNr(b) true, false

  • formfeed() to eject current page

  • isOutOfPaper() check paper tray before printing starts

  • setStrobeDelay(n) make the strobe pulse shorter == faster printing allows tuning of performance. Typical value = 2000. Time in micros. use with care.

See also

https://en.wikipedia.org/wiki/Parallel_port#Centronics

Operation

See examples