1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
|
Network Working Group Jerry Burchfiel
Request for Comments: 642 BBN
NIC: 30872 July 5, 1974
Ready Line Philosophy and Implementation
I. Introduction
BBN Report #1822, Specifications for the Interconnection of a Host
and an IMP, gives a complete specification of the Host-IMP interface.
However, the authors of this document bent over backward to avoid
issuing arbitrary dictatorial directives to host interface
implementors. They succeeded admirably in this goal by describing
the IMP implementation, and suggesting similar behavior on the part
of the host.
ARPA has appointed a PDP-11 local host interface standardization
committee composed of myself, Dave Retz of SCRL, and Yuval Peduel of
MIT Lincoln Labs. During our review of various interfaces designed
by the ARPA community, we have found total chaos, confusion and
misunderstanding about the recommended host interface implementation.
This note is an attempt to make explicit the recommendations which
are implicit in Report #1822. It provides a cookbook for interface
implementors, including a set of recommended do's and don't's in the
common problem areas. This document has been reviewed and approved
by the BBN IMP group.
II. Ready-line Philosophy
The following is an attempt to spell out in detail a consistent plan
for operation of the IMP ready line and host ready line with the
following objectives:
1. Reliably resynchronize and resume transmission after a
temporary lapse of service and possible loss of state
information by either system.
2. Make the programming of the host interface as simple as
possible. This will minimize bugs, and make it possible to
create a small ROM network-bootstrap loader.
First, consider the IMP ready line. When it drops, the IMP has
suffered a possible loss of state, so the message in transit from the
IMP to the host (if any) is likely to be incomplete. Similarly, the
message in transit from the host to the IMP (if any) is likely to be
incomplete. Both the host and the IMP must recognize this explicitly
Burchfiel [Page 1]
^L
RFC 642 Ready Line Philosophy and Implementation July 1974
by sending a message intended to be thrown away* (which may he
appended to the current message) and throw away the message currently
being received. (Both the host - IMP message and the IMP - host
message).
The simplest arrangement for the host's interface driver is a pair of
processes, one sending messages and the other receiving messages.
This drop of the IMP's ready line must be provided as an error status
bit to each process. However, the two processes will need to clear
this condition independently: the simplest implementation is an Input
Error flop and an Output Error flop. Both flops are set by a drop of
the IMP's ready line, and they are cleared independently under
program control.
When the IMP raises its ready line, each contact bounce will again
set the Error flops in the host's interface. To insure that messages
are not flowing across the interface at this time, assertions of the
signals "there's your IMP bit" and "ready for next host bit" have
been delayed sufficiently in the IMP to guarantee that the IMP ready
line has stabilized.
III. Programming
The interface driver processes can be described simply:
INPUT: Wait until an input buffer is available
Wait until IMP ready
Start input
Wait until input is complete
IF Input Error
THEN clear Input Error // Flush smashed message. Input
// buffer will be reused.
ELSE queue message on input queue
GOTO INPUT
OUTPUT: Wait until a message is present on output queue
Wait until IMP ready
Start output
Wait until output is complete
IF Output Error
THEN clear Output Error // smashed message is flushed
ELSE deque message from output queue // Free up
// output buffer
GOTO 0UTPUT
----------
*The standard convention uses the host-IMP NOP message.
Burchfiel [Page 2]
^L
RFC 642 Ready Line Philosophy and Implementation July 1974
The only initialization required for system startup or restart is
clearing the host READY flop, waiting 1/2 second, and setting the
host READY flop. Simply starting (or restarting) the above processes
will properly resynchronize host-IMP communication. As explained in
RFC #636, the IMP ready line (and error flops) should only affect the
two processes above: this resynchronization should be invisible to
the NCP, and should have no effect on the connection data base. The
NCP will be resynchronized or reinitialized by the type 10 IMP-to-
host message "interface was reset."
Actually, it is possible to share a single Error flop between the
input and output processes by implementing Input Error and Output
Error as software flags. A process testing for error must test both
the Error flop and its own flag. An interlock is required (e.g. a
mutual exclusion semaphore) to guarantee that only one process at a
time is testing and modifying the flags. If the Error flop is set,
the process must copy it into the other process' flag before clearing
the flop and its own flag.
IV. Host Ready Line Implementation
When the host drops and raises its ready line, the IMP behaves in a
fashion symmetric to that outlined above. Of course, this drop
indicates that the state of the host's interface driver, as well as
the current incoming and outgoing messages, are likely to be lost.
The appropriate action is triggered by setting the Error flop or
flops in the host interface, and the processes specified above will
correctly resynchronize message flow in both directions. Of course,
to guarantee that messages are not flowing across the interface while
the host ready line is undergoing contact bounce, the host must delay
transmission until its ready line has stabilized. This may be done
in two ways:
Hardware: an integrating one-shot driven by the host ready line
flop is ANDed with "there's your host bit" and "ready for
next IMP bit" to guarantee that message transfer will not
start until the ready flop has been on for 1/2 second.
Software: the initialization program executes a 1/2 second wait
after setting the host ready flop before permitting input or
output to begin.
Burchfiel [Page 3]
^L
RFC 642 Ready Line Philosophy and Implementation July 1974
V. Summary
This determines the specification READY line controls for the host's
interface to the IMP:
1. It contains a program settable/clearable host READY flop which
drives a relay closure to the IMP.
2. It detects the IMP's ready signal as a program-readable status
condition. (But not an interrupt condition)
3. It contains one or two ERROR flops set when either the host
READY flop is off or the IMP ready signal is off. The flop
(flops) is a program-readable and program-clearable status
condition. (But not an interrupt condition). These status
flops must not be cleared by system initialization.
4. If hardware stabilization of the host's READY line is
provided, it is a 1/2 second integrating one-shot driven by
the host READY flop. This signal is ANDed with "there's your
host bit" and "ready for next IMP bit".
[ This RFC was put into machine readable form for entry ]
[ into the online RFC archives by Alex McKenzie with ]
[ support from GTE, formerly BBN Corp. 2/2000 ]
Burchfiel [Page 4]
^L
|