Browse
(440) 299-7778
Menu
(440) 299-7778
One-year parts and labor warranty30-day money-back guaranteeContact

The text of a manual · part 21 of 23

Bulletin 1771 Communication Controller Module (Cat. Nos. 1771-KE, -KF) User's Manual, pages 201 to 210

Pages 201 to 210 of 228

The original document is the PDF (9.6 MB). This is its text as extracted, unedited; tables and drawings read best in the PDF, and each page heading opens it at that page.

For the Allen-Bradley 1771-KE

Page 201 read from a scan by OCR; it may hold reading errors

Page B-7

Detailed Flow Charts

< TIMEOUT )

WAKEUP

Wake Up the Process Sleeping at WTRESP (If Any)

RETURN e STARTTIME

Aborted By: ® STOPTIME

11660

Figure B.7, TIMEOUT Subroutine

Page 202 read from a scan by OCR; it may hold reading errors

Page B-8 Detailed Flow Charts

GETMSG

SLEEP

Go to Sleep At WTMSG

Indivisible Zone

Lew oh ee ee ee

UNLINK Common:

Remove a « WIMSG

Message From

Queue e Output Queue Output: « A Message

Y RETURN

Boxed area above must be executed indivisibly, i.e., with the scheduler or interrupts disabled, depending on implementation.

11661

Figure B.8, GETMSG Subroutine

Page 203 read from a scan by OCR; it may hold reading errors

Page B-9 Detailed Fiow Charts

SIGOK

Place Success Code in Message Control Block

SIGFAIL

Place Failed Code in Message Control BLock

' LINK

Place Message on RETURN Queue

J

WAKEUP-NET

Implementation-Dependent Procedure to Tell Network Layer that RETURN Queue Entry Has Been Made j

RETURN

11662

Figure B.9, SIGOK/SIGFAIL Subroutine

Page 204 read from a scan by OCR; it may hold reading errors

Page B-10 Detailed Flow Charts

XMIT RCVE tt TXALLOC “ / t Not-In-Use x << UART Usage Signal \ \ \ Ye TXFREE XMIT RCVE

Since the tramsit side of the UART is shared by the transmit and receive processes, a mutual exclusion mechanism is used to gain sole access during transmission of each indivisible code sequence. The UART is like a small bridge, and the mutual exclusion mechanism is like two flagmen, one at each end of the bridge. If two heavy trucks (one called XMIT and one called RCVE) come to the bridge at the same time, the flagman on that side lets one through and makes the other wait. When the first truck has crossed the bridge, the flagman on the far side signals the first flagman, who then allows the second truck to cross. Ina similar manner, TXALLOC and TXFREE work together to ensure that XMIT and RCVE do not try to use the UART at the same time.

11664

Figure B.10, Sharing the Transmit Side of the UART

Page 205 read from a scan by OCR; it may hold reading errors

Page B-11 Detailed Flow Charts

SENDCTL j

Input:

TXALLOC * Control Code

Allocate UART or Wait f

SEND

Transmit DLE j

SEND

Transmit Control Code y

TXFREE

Deallocate UART

'

RETURN

11663

Figure B.11, SENDCTL Subroutine

Page 206 read from a scan by OCR; it may hold reading errors

Page B-12 Detailed Flow Charts

( SENDTX )

|

TXALLOC

Allocate UART or Wait d

SEND

Transmit DLE i

SEND

Transmit ETX j

Zero Out Any Previous Response Code at RESP d

SEND

Transmit BCC

TXFREE

Deallocate UART

RETURN

Input: e BCC

Common:

e RESP: The Response Code Variable

11665

Figure B.12, SENDTX Subroutine

Page 207 read from a scan by OCR; it may hold reading errors

Page B-13 Detailed Flow Charts

( SEND )

Input: e Link Data Byte Common:

¢ TXWAIT: A Sleep Variable

Disable Processor Interrupts

| I l

Pe a aa mie HC d

Enable UART Transmit Interrupt

UART Transmitter

Empty 9

Yes

SLEEP

Suspend at TXWAIT d

Disable UART Transmit Interrupt y

Output Byte to UART d

Enable Processor Interrupts

[ | I

Indivisible Zone

J RETURN

NOTE: This figure assumes the use of a Z80 SIO

11669

Figure B.13, SEND Subroutine

Page 208 read from a scan by OCR; it may hold reading errors

Page B-14 Detailed Flow Charts

( SENDDATA

L

Input: * Link Data Byte

TXALLOC

Allocate UART or Wait

SEND

Transmit Link Data Byte

SEND Is Data Yes Byte DLE Transmit a : Second DLE _ No TXFREE De-allocate UART

Y

( RETURN )

11666

Figure B.l14, SENDDATA Subroutine

Page 209 read from a scan by OCR; it may hold reading errors

Page B-15 Detailed Flow Charts

TXALLOC

SLEEP

Wait at TXALWT Until UART is Free

Set IN-USE Flag

RETURN

Indivisible Zone

Common: e IN-USE Flag ® TXALWT: A Sleep Variable

11667

Figure B.15, TXALLOC Subroutine

Page 210 read from a scan by OCR; it may hold reading errors

Page B-16 Detailed Flow Charts

( TXFREE }

Reset IN-USE Flag

Common:

® {N-USE Fiag © TXALWT: A Sleep Variable

Y WAKEUP

Continue Any Process at TXALWT

\

RETURN

11668

Figure B.16, TXFREE Subroutine