Bus Shunt Revision 1
Bus Shunt Revision 1
LIN
Bus Shunt
Slave Node Position Detection
Revision 1.0
DISCLAIMER
This specification as released by the LIN Consortium is intended for the purpose of informa-
tion only and is provided on an "AS IS" basis only and cannot be the basis for any claims.
The LIN Consortium will not be liable for any use of this Specification. The unauthorized use,
e.g. copying, displaying or other use of any content from this document is a violation of the
law and intellectual property rights.
The LIN Consortium and its members make no representation or assurance that the stan-
dard can be practiced without infringing the intellectual property rights of members of the LIN
consortium or of third parties. Each user of this standard (whether or not a member of the
LIN consortium) bears its own responsibility to determine if its implementation infringes intel-
lectual property rights of third parties, and each user is responsible for acquiring any patent
or other intellectual property rights it may require to produce its products.
In particular, but without limitation, the LIN Consortium has been advised that ELMOS claims
that patents EP 1490772 B1 and US 7,091,876 cover the implementation of this standard.
No right or license to these patents is granted herein, and users must determine for them-
selves how to address these claims by ELMOS.
The LIN Consortium disclaims any and all warranties with respect to the subject matter of
this standard, which is expressly delivered AS IS."
REVISION HISTORY
Issue Date Remark
st
Revision 1.0 2008-12-10 1 release
TABLE OF CONTENTS
Disclaimer................................................................................................................... 2
Revision history .......................................................................................................... 3
Table of Contents ....................................................................................................... 4
1 Scope ............................................................................................................... 5
1.1 REFERENCES .................................................................................................. 5
2 Requirements ................................................................................................... 6
3 Bus Shunt Method (BSM) ................................................................................. 7
3.1 CONTENTS OF THIS CHAPTER ............................................................................ 7
3.2 BUS ARCHITECTURE ......................................................................................... 7
3.3 PRINCIPLE ....................................................................................................... 8
3.3.1 Location of the slave node positioning detection..................................... 9
3.4 PHYSICAL LAYER ............................................................................................. 9
3.4.1 Description of the needed components................................................... 9
3.4.2 LIN transceiver for BSM-nodes (principle) .............................................. 9
3.4.3 Differential amplifier (principle).............................................................. 10
3.4.4 Signal acquisition chain (principle)........................................................ 11
3.4.5 Pull-up current sources 1 & 2................................................................ 11
3.4.6 Timing Parameter ................................................................................. 12
3.4.7 DC characteristics................................................................................. 12
3.4.8 Timing of the measurement sequence.................................................. 13
3.4.9 Timing in the SNPD node ..................................................................... 13
3.4.10 Timing including tolerances .................................................................. 14
3.5 SUB FUNCTIONS ............................................................................................ 14
3.6 CONFIGURATION FLOW ................................................................................... 15
3.6.1 Position detection flowchart .................................................................. 16
3.6.2 Measurement position detection flowchart............................................ 17
3.6.3 BSM Setup Flow in Detail ..................................................................... 18
3.7 EXAMPLE OF SETUPS OF A LIN BUS SYSTEM WITH BSM ................................... 21
3.7.1 Calculation of the pre selected slaves for step 5 + 6............................. 21
3.7.2 Reference calculation of a system with 15 Standard- slaves ................ 21
3.7.3 Calculation of a system with 15 BSM- slaves........................................ 22
3.7.4 Calculation of a system with 5 standard- and 10 BSM- slaves............. 23
3.8 LIMITATIONS IN USE ....................................................................................... 24
1 SCOPE
This document is intended to describe a method for the detection of the position of a particu-
lar slave node in a LIN network with equal built slaves. This does not limit the use of position
detection to the method described here.
The document covers the Bus Shunt Method
1.1 REFERENCES
[1] LIN Specification Package, Revision 2.1, 2006-11-24
[2] Electromagnetic compatibility (EMC)- Part 4-2: Testing and measurement techniques
- Electrostatic discharge immunity test, IEC 61000-4-2: 1995
2 REQUIREMENTS
The specified methods must provide a means to assign a slave node with a unique node ad-
dress within the particular LIN network, which can be used to configure the nodes according
to LIN 2.1.
Any Slave Node Position Detection method should not violate the LIN Specification. In case
an SNPD method violates the LIN Specification, these violations are described in the follow-
ing chapters with the respective method descriptions. The behavior is described in the chap-
ter “Limitations in Use” of the respective method description.
On the left side of the schematic the master node is terminating the LIN bus. Next to it is a
standard LIN node followed by a BSM slave node and so on. The BSM slave nodes and
standard LIN nodes may be arranged in any order. The start of the addressing sequence is
initialized by the master node, with a command sent to the slaves telling them that the ad-
dressing sequence starts with the next break. During the next break each slave starts its own
sequence. The sequence is divided up in switching the slave pull-up resistor and current
sources on and off, measuring the offset current, making a pre-selection, and then at the
end, selection of the last not addressed BSM slave node in the line. Each slave stores its
new NAD and is now addressable over this new NAD. If all slaves have received their new
NAD, the master can now program this information into the SNPD node with a separate pro-
gramming command if NVM is available.
3.3 PRINCIPLE
The Bus Shunt Method (BSM) works as follows:
During a break the current on the LIN Bus depends on the position on the bus. The BSM is
routing the LIN Bus through a shunt on the SNPD node in order to be able to measure the
current of the LIN Bus. In order to have reproducible currents – independent of the supply
voltage, the pull up resistors are switched off and current sources are switched on during this
process in the following matter:
The break is divided into 7 steps, in which the current conditions on the bus change and
the measurements take place:
1. During the first step all current sources and the pull up resistors of the involved SNPD
nodes are switched off. This way only the pull up resistors of nodes not using the
shunt method contributes to the current on the bus line.
2. During the second step each SNPD node measures the current flowing through the
shunt of the SNPD node. The measured current is called Ishunt_1 and is the offset cur-
rent on the bus line.
3. During the third step, a pre selection of the slaves is done, for this, current sources 1
in all SNPD nodes are switched on. All nodes that have been already identified in a
previous cycle keep all their current sources and pull up resistors switched off.
4. During the fourth step, each SNPD node measures again the current on the LIN Bus
flowing through the shunt of the SNPD node. The measured current is called Ishunt_2.
The value of the difference between this current (Ishunt_2) and the offset current (Ishunt_1)
indicates, whether it could be one of the most distant SNPD nodes from the master. If
the difference is below a specific value IDiff the SNPD node is being considered as
one of the last SNPD nodes in line. These SNPD nodes are called “pre-selected”
SNPD nodes.
5. The next step is divided into two actions. First action (A), all not pre-selected SNPD
nodes switch their current sources 1 off. Second action (B), all pre-selected SNPD
nodes switch their current sources 2 on (The current sources 1 of the preselected
SNPD nodes remain switched on. The pull up resistors of all SNPD nodes remain
switched off.)
6. In the sixth step, the current through the SNPD node is measured again. The meas-
ured current is called Ishunt_3. If the difference between this current (Ishunt_3) and the off-
set current (Ishunt_1) is below a specific threshold value IDiff the SNPD node is identified
as the last not addressed SNPD node in the bus line. This SNPD node then stores
the transmitted NAD in to its RAM and the master can now communicate with the
SNPD node using this NAD.
7. During the seventh step, all current sources are switched off and all pull up resistors
of the SNPD nodes are switched on, in order to resume to the normal bus mode.
Positioning detection
Synch break Synch field Ident Command n Synch break Synch field Ident Command n+1
V_Sub
Control 1
Source 2
Source 1
RPU,LIN
Control 2
Control 3
BUS_IN
Comparator RXD
-Opamp
RSHUNT
Level shifter
slew rate control
current limitation
TXD
GND
Clock
BUS_IN Select
Control
SOC
Mode
D
R
SHUNT
ADC[7:0]
Aux-Input EOC
A
V V
BUS_OUT MID REF,ADC
Figure 3-4: Components contributing to the signal path using an A/D converter
The voltage over the shunt resistor is measured via a differential amplifier. In addition to the
output signal of the differential amplifier the ADC maybe used for any additional auxiliary sig-
nals on the chip. The reference voltage of the ADC can be a band gap reference trimmed to
the desired precision. If an SC-Amplifier (Switched Capacitor Amplifier) is used, the conver-
sion process has to be synchronized to the clock signal. This synchronization can be done
automatically by a conversion control block as soon as the differential amplifier is selected as
input source.
3.4.7 DC characteristics
no. symbol parameter condition min. typ. max. unit
1 I_CS_1 Pull-up current source_1 2) 1 1,24 mA
2 I_CS_2 Pull-up current source_2 2) 3,15 3,85 mA
R_shunt Bus shunt resistor in the
3 1) 0,65 1,25 Ω
slave
IDiff Selection and
4 2,3 2,9 mA
Pre- selection
5 R_Slave pull-up resistor in a slave 20 60 KΩ
R_Master pull-up resistor in the
6 900 1100 Ω
master
I_Bus_dom Driving current in domi-
7 2) 40 mA
nant state
Table 3-2: DC Characteristics
1) This resistor could also be located externally
2) The transceiver in the master ECU must be capable to drive at least 40mA for 9 T-Bit after 4 T-Bit of the falling edge
of the break field.
Table 3-3: Timing of Bus Shunt Method Slave Node Position Detection
.t_mid
LIN-Bus
Pull-up & pull-up resistor current sources 1&2=off Source 1 = on Pre selected sources 1 & 2 = on only pull-up resistor = on
current sources 1 & 2
Steps
Step 1 Step 2 Step 3 Step 4 Step 5 Step 6 Step 7
Synch Break
T Bit
.
Table 3-4: SNPD Sub Function IDs of the Bus Shunt Method
Note
With the Bus Shunt Method, the implementation of SNPD sub functions 0x01, 0x02 and 0x04
is mandatory. There is no SNPD response to the BSM sub functions, only addressed slaves
response to a request.
Optional Optional
Optional BSM
other other
Store NAD Finished
LIN massages LIN massages
.
Figure 3-7: Configuration flow of the Bus Shunt Method
Start Yes
Measurement No
BSM-Mode
position Set
detection
Yes Yes
Sub 0x02 Keep NAD Sub 0x01
No
No
Yes
Sub 0x03 Store NAD Set
in NVM BSM- Mode
No
Yes
Sub 0x04 Reset
BSM- Mode
No
End
Start
pull-up = Off
current source 1 = Off Step 1
current source 2 = Off
YES
Slave is already addressed
NO
current source 1 = On
Step 3
Step 5
First action (A) Yes
pull-up = Off
current source 1 = Off I_Diff < I_Shunt_2 - I_Shunt_1
current source 2 = Off
No
Step 5 Step 5
Second action (B)
Waiting for the end of step 6 pull-up = Off
current source 1 = On
current source 2 = On
Yes
Step 7
I_Diff < I_Shunt_3 - I_Shunt_1
No
End
All SNPD slaves with BSM capability start their measurement sequence within the break
field; after the break field the selected SNPD slave takes the NAD for slave 1
All SNPD slaves with BSM capability start their measurement sequence within the break
field; after the break field the selected SNPD slave takes the NAD for slave n
All SNPD slaves with BSM capability start their measurement sequence within the break
field; after the break field the selected SNPD slave takes the NAD for slave n+1
Pre selected
slaves
Threshold value Condition Calculation min type max
IDiff2-1 Current source 1 of the number of pre selected slaves
Min = 2,3 mA Min = 1000 µA IDiff
Type = 2,6 mA Type = 1100 µA -------------------------------------- 1 3
Max = 2,9 mA Max = 1240 µA current of current source 1
Table 3-5: Calculation of pre selected slaves
Condition
No. Parameter R_Master = 900 Ω R_Master = 1100 Ω
Vbat = 18V
Standard Nodes = 0
0 mA 0 mA
Step 3 + 4 R_Slave = 20 kΩ
BSM- Nodes = 15
18,6 mA 18,6 mA
1 I_CS_1 = 1,24 mA
I_R_Master 20 mA 16,4 mA
Current in the mas-
I_Bus_DOM 38,6 mA 35,0 mA
ter transceiver
Standard Nodes = 0
0 mA 0 mA
R_Slave = 20 kΩ
I_CS_1 = 1,24 mA
Step 5 + 6 BSM- nodes = 3 3,72 mA 3,72 mA
1)
2 I_CS_2 = 3,85mA
11,55 mA 11,55 mA
BSM- nodes = 3
1)
I_R_Master 20 mA 16,4 mA
Current in the mas-
I_Bus_DOM 35,27 mA 31,67 mA
ter transceiver
Table 3-7: Calculation of a system with 15 BSM- slaves
1) Maximum Number of pre selected BSM-nodes (see calculation of pre-selected slaves)
Condition
No. Parameter R_Master = 900 Ω R_Master = 1100 Ω
Vbat = 18V
Standard Nodes = 5
4,5 mA 4,5 mA
Step 3 + 4 R_Slave = 20 kΩ
BSM- Nodes = 10
12,4 mA 12,4 mA
1 I_CS_1 = 1,24 mA
I_R_Master 20 mA 16,4 mA
Current in the mas-
I_Bus_DOM 36,9 mA 33,3 mA
ter transceiver
Standard Nodes = 5
4,5 mA 4,5 mA
R_Slave = 20 kΩ
I_CS_1 = 1,24 mA
Step 5 + 6 BSM- nodes = 3 3,72 mA 3,72 mA
1)
2 I_CS_2 = 3,85mA
11,55 mA 11,55 mA
BSM- nodes = 3
1)
I_R_Master 20 mA 16,4 mA
Current in the mas-
I_Bus_DOM 39,77 mA 35,77 mA
ter transceiver
Table 3-8: Calculation of a system with 5 standard and 10 BSM- slaves
1) Maximum Number of pre selected BSM-nodes (see calculation of pre-selected slaves)
Number of Shunts (1.25Ω max) GND Shift tolerance [%VBAT] VBAT Shift tolerance [%VBAT]
0 10 10
1 9.8 9.89
2 9.65 9.8
3 9.49 9.71
4 9.32 9.62
5 9.15 9.53
6 8.97 9.43
7 8.78 9.33
8 8.58 9.22
9 8.38 9.11
10 8.17 9.00
11 7.95 8.88
12 7.72 8.76
13 7.48 8.64
14 7.24 8.51
15 6.98 8.38
Table 3-9: Ground- and VBAT shift Tolerances depending on the number of nodes