1 |
27 |
wfjm |
$Id: README_Rlink_V4.txt 614 2014-12-20 15:00:45Z mueller $
|
2 |
|
|
|
3 |
|
|
Summary of changes for rlink v3 to v4
|
4 |
|
|
|
5 |
|
|
Background
|
6 |
|
|
The protocol was initially designed as debug interface used over serial
|
7 |
|
|
port connections. From the beginning the protocol had crc error checking
|
8 |
|
|
and a simple error recovery mechanism.
|
9 |
|
|
When the protocol was used in the IO emulation of the w11, features like
|
10 |
|
|
block transfers, attentions, and command groups were added. Over time the
|
11 |
|
|
original simple concept for error recovery became practically unusable.
|
12 |
|
|
When the protocol was used on boards with a Cypress FX2 USB interface
|
13 |
|
|
the number of round trips became the sole performance limiting factor.
|
14 |
|
|
|
15 |
|
|
Goals for rlink v4
|
16 |
|
|
- 16 bit addresses (instead of 8 bit)
|
17 |
|
|
- more robust encoding, support for error recovery at transport level
|
18 |
|
|
- add features to reduce round trips
|
19 |
|
|
- improved attention handling
|
20 |
|
|
- new 'list abort' command
|
21 |
|
|
|
22 |
|
|
Changes in detail
|
23 |
|
|
|
24 |
|
|
- encoding
|
25 |
|
|
- framing (comma) char representation changed
|
26 |
|
|
- now 2 byte sequence for comma char, with internal redundancy
|
27 |
|
|
- optimized for robustness. Also more compact for larger rblk/wblk.
|
28 |
|
|
|
29 |
|
|
- framing
|
30 |
|
|
- unexpected EOP in sl_idle now silently ignored
|
31 |
|
|
--> before: send NAK+EOP
|
32 |
|
|
--> now allows to send EOP+NAK to start a retransmit
|
33 |
|
|
- command aborts send now an error code, the abort sequence
|
34 |
|
|
NAK EOP
|
35 |
|
|
- the nakbyte has the redundant format
|
36 |
|
|
10
|
37 |
|
|
- the abort sequence sequence is not protected by a crc, but has enough
|
38 |
|
|
redundancy that transmission errors can be detected.
|
39 |
|
|
- all unexpected commas after SOP will cause an abort. This adds robustness
|
40 |
|
|
in case transmission error converts a data byte into a comma.
|
41 |
|
|
|
42 |
|
|
- commands
|
43 |
|
|
- 16 bit addresses
|
44 |
|
|
- 16 bit rblk/wblk transfer size counts. Now cnt rather cnt-1 used.
|
45 |
|
|
- rblk/wblk now return 'done count', number of successfully transfered words
|
46 |
|
|
Note: rblk always transfers cnt words, rest is padded.
|
47 |
|
|
- babo state flag added
|
48 |
|
|
- babo is cleared when rblk/wblk is started, and set when they are aborted
|
49 |
|
|
- babo is not changed by commands other then rblk and wblk
|
50 |
|
|
- stat command removed (functionality not needed anymore)
|
51 |
|
|
- labo command added
|
52 |
|
|
- returns the babo flag
|
53 |
|
|
- if babo set, all remaining commands in the list will be ignored
|
54 |
|
|
- stat byte layout changed
|
55 |
|
|
- cerr and derr flags removed (not needed anymore)
|
56 |
|
|
- now 4 (instead of 3) external RB_STAT bit
|
57 |
|
|
- 16 bit crc used (instead of 8 bit)
|
58 |
|
|
- attn handling
|
59 |
|
|
- a message with the current attn pattern is send, not only an attn comma.
|
60 |
|
|
This give the attn handler a priori knowledge of LAM sources.
|
61 |
|
|
An attn command must still be used to harvest the attn pattern.
|
62 |
|
|
- attn poll always returns attn notify, usage of idle comma removed
|
63 |
|
|
|
64 |
|
|
- general
|
65 |
|
|
- reserve 0xff00-0xffff range for rlink system usage
|
66 |
|
|
- implement 4 default registers (in rlink_core)
|
67 |
|
|
ffff cntl
|
68 |
|
|
fffe stat (holds rtbuf size)
|
69 |
|
|
fffc/d sysid (32 bit system identifier)
|
70 |
|
|
- rlink initialization now via wreg, not with init anymore
|
71 |
|
|
- has now retransmit buffer, size configurable (2,4,8,.. kB)
|
72 |
|
|
- used for wblk dcrc validation in addition
|
73 |
|
|
- a NAK outside a SOP/EOP frame will trigger a retransmit of last response
|
74 |
|
|
- retransmit buffer cleared when first cmd processed
|
75 |
|
|
-> an empty SOP-EOP does not reset the retransmit buffer
|
76 |
|
|
- no internal/external init distinction, 'we' always 0 when init=1
|