Download PolyLetter 1987 - PolyMorphic

Transcript
:.
PolyLetter 8706
Page
to agree with Edit.GO . To maintain consistency,
this forced me to change mine to CTRL-U also. A
B-EDIT user discribed its capabilities and
limitations to me over the telephone. It only does
one line, and doesn't understand TABS. CTry editing
a BASIC program line which has a TAB character in
it; he said it stopped before the tabJ Anyway, I
wanted to be able to edit other lines than the last
one typed. The fact of the matter is that I wrote
my own version, BEDIT, sometime after reading about
yours, but had used it only occasionally . I was
doing a lot of custom work in BASIC, and finally had
the need for it. In writing edit.GO, I started with
that code, so it is true to say that your product
served as the stimulus for mine. My first version
used UCHR and UVEC, and was modeled on a screen
dump to printer program . However, I was leery of
all this editing being done at the interrupt level,
and I wanted to invoke edit from a command file,
where UCHR has no effect. So, I changed it to a
gnome which eye's WHO. edit.GO can be invoked in
command files, and can input and convert CTRL
characters. With this capability, I can type in two
or three Exec commands on one line separated by "M's
and execute them all in one stroke. Furthermore,
edit knows how to find and copy a marked block from
anywhere on the screen to the cursor location.
With all this information, I am sure you could
upgrade B-EDIT to include the additional features I
have mentioned. After all, we're both competent
programmers with considerable experience in the Poly
environment. Competetion is, after all, competition.
In my opinion, it was monopolizing and secrecy which
killed Poly's chance for a good market share. Had
we healthy competition, low prices, and lots of
sharing... but that's off to never-never land again
with the rest of the nostalgia.
Incidentally, ISS advertized a spelling checker
with a mere 3,000 words CSISS.RL) for S350 well
before Frank's SPELL, advertised as having 20,000
words, appeared. lA!SJ Spell has about 12,000
words. -- Ralph.J
A
PARALLEL
8251
UART
by John J . Warkentin
The Editor of POLYLETTER has voiced a desire for
a 'black board' that could be plugged into an
integrated circuit socket that normally is occupied
by an 8251 Universal Asynchronous Receiver
Transmitter CUARTl, and provide support for a
parallel printer port.
Although such a project is only slightly less
complicated than a full-blown parallel printer port,
there are certain instances where such a hardware
device would be most useful. It certainly minimizes
the software modifications required to support a
change in printers.
Before I begin the discussion of this project let
me make one thing perfectly clear: I have NOT built
this device; to the best of my knowledge it SHOULD
work, but I cannot guarantee that it WILL work. If
anyone does build it and discover that it does work,
s
NOV/DEC 19 f
please let me know via a letter to POLYLETTER . ·
THEORY
Let's begin with a brief discussion of the 8251
UART . The 8251 is basically a serial-to-parallel
converter, and vice verse. We do not need to
concern ourselves with the serial side of this LC.
to understand what is going on with this project.
The parallel side of the 8251. however, is important
to understand, as this is what we have to emulate.
The parallel side of the UART is connected to the
computer's internal data, address, and control bus .
Cln the Poly these are contained on the CPU card;
buffers drive the S-100 bus . ) The 8251 has 8
bi-directional data lines, 4 interrupt lines, 4
control lines, and of course a +5 volt line and a
ground line.
CThere are additional lines,
particularly for voltages, that we need not concern
ourselves with hereJ
Internally, the 8251 has a data-output register,
a data-input register, a control register, a status
register, and an interrupt facility. Our parallel
printer port must emulate these registers and
functions if we are to fool the software into
thinking it is still working with a serial port.
Let's take a look at the control logic of our
'black board' at this point. Four control lines are
used to control the 8251 Cor our 'black board' J A
brief aside: Signal names preceded by a '-' are
low-true, and those preceded with a '+' are hightrue . The 4 signals are -WR, -RD, +C/-D, and -CS .
-WR goes true when the computer wishes to write, or
output to the 8251. -RD goes true when the computer
wishes to read, or input from the 8251. +C/-D goes
high when the computer wishes to output to the
command port, and low when the computer wishes to
input from the status port. +C/-D is driven by the
address bit 0 line. The remaining address lines are
decoded and used to select the 8251 via the -CS
C-Chip Select> line. A 74LS138 CU1l is used to
decode the 4 control lines and generate strobes used
to control the remainder of our project.
we· do not need to worry about data INPUT, but we
do need to support data output. the -DATA OUT
strobe is used to load data into the 74LS374 CU2),
which has 8 internal latches, one for each data bit.
At the same time the strobe is passed to the printer
to let it know that there is data being presented to
it.
The status byte from the 8251 has to be emulated
quite exactly . The +Printer Busy signal can be
inverted and presented as status bit 0, Transmit
Buffer Empty. Whenever this bit is HIGH the
software knows that the 8251 is ready to output
another byte . We can use the inverted +Printer
Error line to emulate Data Set Ready on status bit
7. This bit should be HIGH to permit output . Bit 0
should be tied to bit 2, and bits 1, 3, 4, 5, and 6
should be tied low. A 74LS244 CU3) is used to gate
the status byte to computer when the -STATUS strobe
goes low.
Now let's provide a means for executing a