User`s manual
3.6.4 BISYNC Implementation
BISYNC
implementation software is considered in
three functional groups: control tables,
interrupt
service routines,
and
the protocol module.
The
control tables contain the control bytes, which
control sequencing between modes
and
accumulation
of
the BCC. During transmission, the control bytes
also control
DLE
stuffing and
Bee
transmission.
Additionally, during reception, the control bytes
enable discard
of
unwanted characters
and
reception
of
this BCC.
The
interrupt
service routines respond to zero byte
count
and
error
interrupts, and, during reception,
respond
to
special character interrupts.
The
protocol module initializes the DV
11,
establishes
direction
of
transfer, sets up
and
manages
the
data
buffers, and handles
error
and
special
character
flags
set
by
interrupt
service routines. Handling
of
error
flags may take the form
of
try-again routines,
or
operator
notification. Handling
of
special characters
may require such operations as a switch from receive
to
transmit,
or
termmation
and
disconnect \Le.,
EOI'
received).
3.6.4.1 Transmission Control - Figure 3-5 shows
state flowcharts for the
BISYNC
transmission con-
trol process. There are five states
or
modes: three for
transparent
data
transmission,
and
two
for
non-
transparent
data
transmission.
For
transparent data, the
DV
11
mode
is
initialized
to
Mode
0, causing the
DVII
to
stuff
a
DLE
in front
of
any A
CK,
RVI,
or
WACK
control characters sent by
the
PDP-II.
The
DVII
also stuffs a
DLE
in front
of
the first STX sent by
the
PDP-II
and
switches
to
Mode
I,
the
transparent
data
transmission mode.
The
DV
11
stays
in
Mode
1 until a marked byte
count
reaches zero (see Section 3.3),
and
is then switched
to
Mode
2, the end-of-transparent block mode.
In
Mode
2,
transmission
of
the ITB sequence
(lTB
DLE
STX) causes a return
to
Mode
1 for transmis-
sion
of
the remainder
of
the
data
block. Transmission
of
an ETB
or
ETX
character
causes a return to
Mode
o to enable transmission
of
the next
dat~
block.
Table
3-14 shows the transmission sequence
and
the
control byte directives for a block
of
transparent
data
that
is
separated into two intermediate blocks.
The
DV I I principal and alternate registers would initially
3-43
be loaded with the base addresses
and
byte
counts
for
data
buffers
one
and two, respectively. On each zero
byte
count
interrupt,
the
next buffer address would
be loaded into
the
appropriate
registers.
For
non-transparent
data,
the
DVII
is
initialized
to
Mode
3 for transmission
of
any header
data
(see Fig-
ure D-3)
or
the
ENQ
control character. ITB, ETB,
ETX characters are included in the
Bee
and
fol-
luweu
by
the BCC in jviode 3.
The
DVi
i
is
switched
to
Mode
4,
the text transmission mode, on occur-
rence
of
the STX
or
ITB delimiters. Occurrence
of
a
zero byte
count
causes a return
to
Mode 3
to
send the
next
data
block.
Table
3-15 shows the transmission sequence
and
the
control byte directives for a block
of
non-transparent
data
that
is
separated
into
two intermediate blocks.
3.6.4.2 Reception Control - Figure 3-6
is
a state flow
chart
for the BISYNC reception control process.
Four
states
or
modes are required: Modes °
and
2 are
used
to
handle
non-transparent
data, Modes 3
and
4
are
lIsed
to
handle transparent data.
Mode 0 (Waiting for Message)
The
DV II
is
initialized
to
Mode
0,
and
the address
and
byte
count
registers in the
DVII
are set
to
receive
one byte. Response to the initial control
character
is
as follows:
ENQ
- the
character
is
stored
to
record the
request, an interrupt
is
generated to
turn
the
buffer contents over
to
the protocol module for
printout
or
other
handling, and a new buffer
is
requested to store the expected
data.
The
data
is
input in
Mode
°
(no
mode
change).
DLE
- discard
the
character
and
go to
Mode
I
(transition
to
transparent
reception).
STX
or
SOH
- store the
character
and
go
to
Mode
2
(non-transparent
data
reception).
EDT
- store
the
character; generate
an
interrupt
to turn buffer contents over to
protocol
module
for termination
of
reception; stay in
Mode
0.
NA
CK
- store the negative acknowledgement
character, generate
interrupt
to
turn
buffer con-
tents over to protocol module for resumption
of
transmission; stay in
Mode
0.