[GreenKeys] CR LF etc.
John Nagle
nagle at animats.com
Tue Apr 26 12:20:51 EDT 2011
Someone wrote:
>> I typed another paragraph of info (complete with more typos) but
>> hit LTRS after CR-LF.
I've written software for this. In my "baudotrss" program,
http://sourceforge.net/projects/baudotrss/
I do the following:
At the end of a line, the software sends CR, and optionally LF
(some machines do LF on CR), then some number of LTRS characters,
normally two. This can be changed in the configuration file.
If the carriage is known to be at the left margin, from a previous
CR without following text, an end of line generates LF only.
This allows a fast paper advance for tear-off.
The software does a word wrap if there's a space within 15 characters
of the end of the line. At the line width (by default 72 characters)
an end of line is forced, with proper end of line handling.
The state of shifting is maintained by the software as LTRS, FIGS,
or "unknown". When a character needs to be in a shift other than
the current state, a LTRS or FIGS is sent first. After a space
while in LTRS shift, the state is considered to be "unknown".
So the output will work for machines with or without unshift-on-space.
However, printing spaced FIGS symbols like "1 2 3" is inefficient.
The character sets supported are USTTY and FRACTIONS. In FRACTIONS
mode, none of the fractions characters are ever printed. Most stop
punctuation (".", ":", etc.) is translated to " # # # ", and
non-stop punctuatoin (",", etc.) is translated to " - ". This is
a compromise since the machine can't print those characters.
I have a Model 15 with the USTTY set and a Model 14 with the
FRACTIONS set.
John Nagle
More information about the GreenKeys
mailing list