Polling Mode Data Flow Examples
Setup 1
Address
|
0x01 (translates to) Poll Req @ `0x1C', Unit
Select @ `0x1D'
|
RES
|
0x04
|
REQ
|
0x05
|
STX
|
0x02
|
ETX
|
0x03
|
ACK
|
0x06
|
NAK
|
0x15
|
LRC
|
disabled
|
Transfer 1
HOST_TX
|
`RES' `0x1D' `REQ' (Select Unit 1 to receive
data)
|
imager_TX
|
`0x1D' `ACK' (Unit responds with its address)
|
HOST_TX
|
`STX' <T> `ETX'
|
imager_TX
|
`0x1D' `ACK' (Unit responds with its address)
|
HOST_TX
|
`RES' (Terminate Transfer 2)
|
Transfer 2
HOST_TX
|
`RES' `0x1C' `REQ' (Poll Unit 1 for data)
|
imager_TX
|
`0x1C' `STX' <T/00000> `ETX'
|
HOST_TX
|
`ACK'
|
imager_TX
|
`RES' (Terminate Transfer 1)
|
Starting with a `RES' ensures a clean transaction,
without "leftovers" from the previous transaction.
Error Condition 1
HOST_TX
|
`RES' `0x1C' `REQ' (Poll Unit 1 for data)
|
imager_TX
|
`0x1C' `STX' <T/00000> `ETX'
|
HOST_TX
|
`Nothing' (Host should `ACK' here)
|
timeout reached...
|
imager_TX
|
`REQ' (Unit requests an `ACK' again)
|
timeout reached...
|
imager_TX
|
`REQ' (Unit requests an `ACK' again)
|
timeout reached...
|
imager_TX
|
`REQ' (Unit requests an `ACK' again)
|
timeout reached...
|
imager_TX
|
`RES' (Terminate Transfer 1, data is flushed)
|
Error Condition 2
HOST_TX
|
`RES' `0x1C' `REQ' (Poll Unit 1 for data)
|
imager_TX
|
`0x1C' `STX' <T/00000> `ETX'
|
HOST_TX
|
`Nothing' (Host should `ACK' here)
|
timeout reached...
|
imager_TX
|
`REQ' (Unit requests an `ACK' again)
|
HOST_TX
|
`NAK' (Host rejects data frame)
|
(Retry Event)
|
imager_TX
|
`0x1C' `STX' <T/00000> `ETX' (Unit sends
again)
|
HOST_TX
|
`ACK' (Host receives data)
|
imager_TX
|
`RES' (Terminate Transfer 1)
|
The protocol makes 3 retry attempts before data is
flushed and transfer is aborted.
Setup 2
Address
|
0x01 (translates to) Poll Req @ `0x1C', Unit
Select @ `0x1D'
|
RES
|
0x04
|
REQ
|
0x05
|
STX
|
0x02
|
ETX
|
0x03
|
ACK
|
0x06
|
NAK
|
0x15
|
LRC
|
enabled
|
Transfer 1
HOST_TX
|
`RES' `0x1D' `REQ' (Select Unit 1 to receive
data)
|
imager_TX
|
`0x1D' `ACK' (Unit responds with its address)
|
HOST_TX
|
`STX' <T> `ETX' `LRC'
|
imager_TX
|
`0x1D' `ACK' (Unit responds with its address)
|
HOST_TX
|
`RES' (Terminate Transfer 2)
|
Transfer 2
HOST_TX
|
`RES' `0x1C' `REQ' (Poll Unit 1 for data)
|
imager_TX
|
`0x1C' `STX' <T/00000> `ETX' `LRC'
|
imager_TX
|
`ACK'
|
HOST_TX
|
`RES' (Terminate Transfer 1)
|
Starting with a `RES' ensures a clean transaction,
without "leftovers" from the previous transaction.
Error Condition 1
HOST_TX
|
`RES' `0x1C' `REQ' (Poll Unit 1 for data)
|
imager_TX
|
`0x1C' `STX' <T/00000> `ETX' `LRC'
|
HOST_TX
|
`Nothing' (Host should `ACK' here)
|
timeout reached...
|
imager_TX
|
`REQ' (Unit requests an `ACK' again)
|
timeout reached...
|
imager_TX
|
`REQ' (Unit requests an `ACK' again)
|
timeout reached...
|
imager_TX
|
`REQ' (Unit requests an `ACK' again)
|
timeout reached...
|
imager_TX
|
`RES' (Terminate Transfer 1, data is flushed)
|
Error Condition 2
HOST_TX
|
`RES' `0x1C' `REQ' (Poll Unit 1 for data)
|
imager_TX
|
`0x1C' `STX' <T/00000> `ETX' `LRC'
|
HOST_TX
|
`Nothing' (Host should `ACK' here)
|
timeout reached...
|
imager_TX
|
`REQ' (Unit requests an `ACK' again)
|
HOST_TX
|
`NAK' (Host rejects data frame)
|
(Retry Event)
|
imager_TX
|
`0x1C' `STX' <T/00000> `ETX' `LRC' (Unit
sends again)
|
HOST_TX
|
`ACK' (Host receives data)
|
imager_TX
|
`RES' (Terminate Transfer 1)
|
Error Condition 3
HOST_TX
|
`RES' `0x1C' `REQ' (Poll Unit 1 for data)
|
imager_TX
|
`0x1C' `STX' <T/00000> `ETX' `BAD LRC'
|
HOST_TX
|
`NAK' (Host rejects bad LRC data)
|
(Retry Event)
|
imager_TX
|
`0x1C' `STX' <T/00000> `ETX' `GOOD LRC'
(Unit sends again)
|
HOST_TX
|
`ACK' (Host receives data)
|
imager_TX
|
`RES' Terminate Transfer 1)
|
The protocol makes 3 retry attempts before data is
flushed and transfer is aborted.