You are on page 1of 48

Automotive Low Speed Serial Bus Analysis

with Tektronix Oscilloscopes


2
Automotive Serial Bus Overview
I
2
C
SPI
CAN
FlexRay
USB (Infotainment: UserDevice Access)
MOST 50 / 150 (Infotainment: Network)
Ethernet (BroadR-Reach PHY , Broadcom)
MIPI (D-Phy, DSI / CSI)
HDMI / MHL

SPI
3
Trace Data Flow Through an Automotive Network
Trace serial data flow between nodes through a network
Simultaneously display messages at transmitter and receiver to verify continuity and
propagation delays
Trace serial data flow between network segments separated by a gateway
Simultaneously display messages from multiple buses, at different speeds, or even
different bus standards
Gateway
Mobile Phone
Car
Radio
Multi Media
Module
CAN
Air Bag ABS
ABS
CAN
Climate
Control
Left Door Right Door
Seat
Control
CAN
Sensor
Motor
LIN
Engine
Control
ESP
Gear
Box
CAN
Diagnostic
LIN
Data Backbone for ADAS
(Active Driver Assistance Systems)
Data Interchange with other
specific automotive bus systems
(CAN/Flexray)

Automotive Bus Technology - Application Areas
Source: www.mostcooperation.com
4
Tektronix Confidential

Midrange Scope Portfolio




MSO/DPO2000




MSO/DPO3000




MSO/DPO4000B




MSO/DPO5000




DPO7000C
200 - 100 MHz
1 GS/s
500 - 100 MHz
2.5 GS/s
1 GHz 350 MHz
5 2.5 GS/s
2 GHz 350 MHz
10 - 5 GS/s
3.5 GHz 500 MHz
40 - 5 GS/s
1M Samples Max 5 M Samples Max 20 M Samples Max 250 M Samples Max 500 M Samples Max
MS WIN 7 Embd. OS
Debugging Serial Buses with the MSO/DPO Series
4000B Series 3000 Series 2000 Series
Bandwidth 1 GHz, 500 MHz, 350 MHz 500 MHz, 300 MHz, 100 MHz 200 MHz, 100 MHz
Channels 4 analog
16 digital (MSO Series)
2 or 4 analog
16 digital (MSO Series)
2 or 4 analog
16 digital (MSO Series)
Record Length 20 M points 5 M points 1 M points
Serial Bus
Analysis
I
2
C, SPI
USB
Ethernet
CAN, LIN, FlexRay
RS-232/422/485/UART
I
2
S/LJ/RJ/TDM
MIL-STD-1553
I
2
C, SPI
CAN, LIN
RS-232/422/485/UART
I
2
S/LJ/RJ/TDM
I
2
C, SPI
CAN, LIN
RS-232/422/485/UART
# of
Simultaneous
Decoded Buses
4 2 2
Automated Trigger, Decode and Search for Serial Buses
7
Speed debug of serial buses with the MSO/DPO5000 Series
Automated Decode, Trigger, Search and Eye Diagram Analysis
MSO/DPO5000 Series
350 MHz to 2 GHz
Up to 250 M record length
Comprehensive verification
including compliance with jitter
and eye validation
Physical layer testing for USB 2.0
and Ethernet 10/100/1000BASE-T
Serial bus decode, trigger and
search support for:
I
2
C
SPI
UART/RS-232
USB 2.0
MOST 50 / 150


In-Depth Analysis of Serial Buses with the DPO7000 Series
DPO7000 Series
500 MHz to 3.5 GHz
Up to 500 M record length
Physical layer testing for USB 2.0,
Ethernet and MIPI
Serial data characterization with
jitter and eye analysis
Supported serial buses:
I
2
C
SPI
CAN
LIN
FlexRay
UART/RS-232
MOST 50 / 150


Automated Decode, Trigger, Search and Eye Diagram Analysis
V6.4.0 Firmware for 5k, 7kC, 70kC/D WIN7 Scopes
Great new features
New bus standards support
Improvements to Visual Trigger
New mark all trigger events Search capability
Improved Zoom and Cursor button operation
Measurements on digital channels
MATLAB and MS Visual Studio math plug-in functionality
Performance improvements
Faster MSO/DPO5k operation
FastFrame and long record length speed increased
Defect fixes for many customer-reported bugs
Larger HDD and SSD
New PS2 power bundle
Available end of June 2012
Available for all demo units now - update yours today!
New one-step complete update with deployment package
New Standards Support
CAN/LIN/FlexRay (trigger/decode/search)
MIL-STD-1553B (trigger/decode/search)
PCI Express gen 1/2/3 (trigger (70k)/decode/search)
SPI 2-wire (trigger/decode/search)
8b/10b added to MSO/DPO5k and DPO7kC (decode/search)
MIPI D-PHY added to MSO/DPO5k (decode/search)
Electrical Compliance Measurements
MOST 50 and 150 electrical compliance
Thunderbolt

LSS Trigger/Decode/Search
CAN/LIN/FlexRay: SR-AUTO
MIL-STD-1553: SR-AERO
2-Wire SPI added to SR-EMBD


CAN Bus: SR-AUTO
MIL-STD-1553: SR-AERO
2-Wire SPI: SR-EMBD
12
How do I probe serial digital buses?
Digital buses are not digital
Digital signals do not
necessarily have only
two discrete levels
Digital probes are not digital
Everything you know about
analog probing still applies
Minimize DC and AC loading
Voltage measurements are
always differential
Minimize lead inductance

The real signal must be delivered to the oscilloscopes hardware or
software comparator, where it can be compared to the digital
threshold value(s)
Bus and Waveforms display of I
2
C signal
13
What do the probing and acquisition architectures look like
3pF
100k
0.2pF
-
+
front-panel
connector
P6616 passive probe Digital input circuit
(logic analyzer ASIC)
coax
Acquisition
System
acquisition circuit
14
Digital Acquisition System
MSO/DPO4000B / 5000 Series and P6616 Digital Probe
high end digital specification

P6616 16-channel digital probe matched to
the digital acquisition system
Specification MSO4000 MSO4000B
Maximum Sample Rate
500MS/s
16.5GS/s with MagniVu
500MS/s
16.5GS/s with MagniVu
Maximum Input Toggle Rate 350 MHz 500 MHz
DC Input Voltage Range 15 V 42 Vpeak
Maximum Input Voltage
Swing
6 Vp-p
centered on threshold
30 Vp-p 200MHz
10 Vp-p >200 MHz
Input Impedance 20 kOhm 100 kOhm
Input Capacitance 3 pF 3 pF
Threshold Range -2 V to +5 V 40 V
Minimum Input Swing 500 mVp-p 400 mVp-p
Minimum Detectable Pulse 1.5 ns 1 ns
MSO5000
500MS/s
16.5GS/s with MagniVu
500 MHz
42 Vpeak
30 Vp-p 200MHz
10 Vp-p >200 MHz
100 kOhm
3 pF
40 V
400 mVp-p
1 ns
15
I
2
C (Inter-Integrated Circuit)
Used for chip-to-chip communication between microcontrollers and A/Ds,
D/As, FPGAs, sensors, etc.
Uses two single-ended, bi-directional signals: clock and data (Half Duplex)
Any I
2
C device can be attached to the bus
Data rates:
Standard Mode (100 kbps)
Fast Mode (400 kbps)
High Speed Mode (3.4 Mbps)

16
I
2
C (Physical Part)
Master
Device
3
Device
4
SDA
SCL
+V
Pull-up resistors
17
Input Source Selection (example: I
2
C)

CH1 CH4

D0 D15 (MSO)

View different
busses
simultaneously

Channel Labeling
18
I
2
C Message Structure
Start: Indicates the device is taking control of the bus and a message will follow
Address: 7-bit or 10-bit number representing the device address to read or write
Data: Integer number of bytes read from or written to the device
Acknowledge: 1-bit from the slave device acknowledging the masters actions
Stop: Indicating the message is complete and the master has released the bus
19
1 0 1 0 0 0 0
Serial Debug
Manually Decoding Serial Bits
1 0 1 0 0 0 0
Engineers must manually count each bit and determine if it is a 1 or a 0
0 0 0 1 0 1 0 0 0 0 1 0 0 1 1 0 1
20
Serial Debug
Manually Decoding Serial Bits
Engineers must then convert the data to an understandable format

First three bits are most significant digit of a 7-bit address
Read or Write
Most significant digit of 8-bit byte
4 1
Least significant digit of 8-bit byte
0 5 6 1
0 0 0 1 0 1 1 0 0 0 0 1 0 1 0 0 1 0 1 0 0 0 0 1
R
Next four bits are least significant digit of a 7-bit address
= Read data 14 and 16 from Address 50
21
There must be a better way
Serial Debug
Serial Triggering and Decode
I2C Decoding is done by oscilloscope for the engineer
22
I
2
C Message Flow Control
Acknowledge/No Acknowledge

Indicates success or failure of a data transmission or the continuation of a transfer

Generated by holding the SDA low on the 9th clock pulse









SDA
SCL
. . .
1 2 3 8 9
SDA
SCL
. . .
1 2 3 8 9
ACK
NACK
23 23
I
2
C Solution on Tektronix Oscilloscope
24
SPI (System Peripheral Interface)
Used primarily to communicate between microcontrollers and their
immediate peripheral devices
Typical configuration has four signals: SCLK, MOSI, MISO, SS
Data is simultaneously transmitted and received
SS line used to specify slave device
Each unique device on bus has its own SS signal from master
Multiple bus configurations are allowed
Network can use 2-, 3-, or 4-wire bus topology
Data rates up to 50 Mbps
SS enables slave device to accept data

MOSI data from the master to a slave

MISO data from a slave to the master

SCLK serial clock driven by Master
SS
MOSI (n bits)
MISO (n bits)
SCLK
MSB LSB
MSB LSB
25
SPI (System Peripheral Interface)
SPI Bus Hardware Configurations
Single Master Multiple Slaves
Single Master hardwired to Single Slave
26
Serial Debug
Serial Triggering and Decode
There is more than just decoding

Trigger on packet content
Search and mark packet content
View data in an Event Table format
View two buses simultaneously
I
2
C
CAN
SPI
LIN
RS-232
FlexRay
27
CAN (Controller Area Network)
Used for system-to-system communication in Automotive, Industrial
Automation, and Medical Equipment
Serial asynchronous, multi-master, layered communication network
Sophisticated error detection and error handling mechanisms
Flexible signaling support for low-cost implementation
Messages are broadcast to all nodes on the network
Physical bus is single-wire or dual-wire, and fault tolerant
Data rates from 5 kbps to 1 Mbps
CAN Physical Layer

Electronic
Control
Unit

CAN
Controller
Tx


Rx
Rx


Tx
CAN_H

CAN_L
CAN Bit Rate
Min. CAN
Pulse Width
1 Mbps 1 s
800 Kbps 1.25 s
500 Kbps 2 s
250 Kbps 4 s
125 Kbps 8 s
83.3 Kbps 12 s
62.5 Kbps 16 s
50 Kbps 20 s
33.3 Kbps 30 s
20 Kbps 50 s
10 Kbps 100 s
3.5V
2.5V
1.5V
recessive
dominant
recessive
CAN-H
CAN-L
1 0 1
CAN High Speed Differential Bus
Signal
CAN Bus Bit Rate Table
CAN is a differential BUS
Tx
+
-
+
-
Rcv
path +
-
+
-
CAN Physical Layer

Electronic
Control
Unit

CAN
Controller
Tx


Rx
Rx


Tx
CAN_H

CAN_L
3.5V
2.5V
1.5V
recessive
dominant
recessive
CAN-H
CAN-L
1 0 1
CAN High Speed Differential Bus
Signal
29
In-Depth Analysis of Network Performance
Locate and analyze signal integrity problems with eye diagrams
Characterize different oscillator tolerances and propagation delays
between nodes for synchronizing the network
Monitor bus utilization to ensure efficient use of the network
1
2
0


1
2
0


Node 1 Node 2 Node 10
40 meters
Near End
Far End
CAN
Network
Eye diagram measurements
Fast Data Rates, More HF Loss
Reference Maxim Note HFDN-27.0 (Rev. 0, 09/03)
Tx
+
-
+
-
Rcv
path +
-
+
-
Clean, open, logical 1 & 0 at
launch from transmitter
Smeared edges at end of long
interconnect.
Logical 1 & 0 can be hard to
distinguish at end of long
interconnects; (this is often
called a closed eye)
Fast, sharp, edges at
transmitter launch
31
CAN Data and Remote Frame Overview
SOF: begins with a start of frame (SOF) bit
Arbitration: Identifier (address) and Remote Transmission Request (RTR) bit
Control: 6 bits including Identifier Extension (IDE) bit and Data Length Code (DLC)
Data: zero to eight bytes of data
CRC: 15-bit cyclic redundancy check code and a recessive delimiter bit
ACK: acknowledge field is two bits long
EOF: 7 recessive bits indicate the end of frame (EOF)
INT: intermission field of three recessive bits indicates the bus is free
32
Characterize System Timing
Characterize timing between bus messages and system operation
Requires waveform displays time-correlated with decoded messages
Characterize timing differences which occur when adding a new
network node to an existing network
Automotive application example:
Measure worst-case time from crash sensor output to airbag activation
Measure variations in timing of airbag activation with varying levels of CAN bus traffic
33
CAN Bus
DPO7000 CAN Trigger
34
CAN Bus
DPO7000 CAN Analysis Application
Select Function :
Decoding
Timing Analysis
35
CAN Bus
DPO7000 CAN Analysis Application
Configure :
Trig.-Source
Bus-Source
36
CAN Bus
DPO7000 CAN Analysis Application
Trig.-Configure :
Field Type
Field Value

37
CAN Bus
DPO7000 CAN Analysis Application
Decoding Results :
Field Value
Timing Result


38
CAN Bus
DPO7000 CAN Analysis Application
Decoding Results :
Correlation to
Acq.-Mem


39
Characterizing Oscillator Tolerance and Propagation Delay
Oscillator tolerance of a
CAN node
Specify the specific ID for
trigger condition
Result will include ACK and
without ACK bit
With ACK bit, shows the
impact of receiving CAN node
oscillator tolerance on
transmitting node
Propagation Delay
Connect two channels to any
two CAN nodes
Result is directly available

40
Monitoring CAN Traffic for Bus Utilization
Measure at specific
ID, error frame or
overload frame

Specifies percentage
of time traffic present
in the CAN bus

Type of traffic can be
analyzed
Frame count
Tektronix DPO7000 Series with TDSVNM option
41
CAN Trigger Overview
42
FlexRay 2.1 (3.0)
FlexRay is a automotive bus still being developed by a group of
leading automotive companies and suppliers known as the FlexRay
Consortium
The physical bus can be unshielded twisted pair, or shielded twisted
pair to improve EMC performance
FlexRay is a differential serial bus configured in three recurring
segments: Header, Payload, and Trailer
Each frame contains a static and dynamic segment, and bus idle time
concludes each frame
Transmitted data rates up to 10 Mbps
Automotive
Manufacturers are finding that existing automotive serial standards
such as CAN and LIN do not have the speed, reliability, or redundancy
required to address X-by-wire applications such as brake-by-wire or
steer-by-wire.
43 43
FlexRay Frame Structure
Header Segment
Contains Indicator Bits, Frame ID, Payload Length (in words), Header CRC, and Cycle Count
Payload Segment
Contains data transferred by the frame. Maximum payload length is 127 words (254 bytes)
Trailer Segment
Contains a single 24 bit field [three 8 bit CRC registers] for header and payload protection
44 44
FlexRay Terms and Abbreviations
TSS (Transmission Start Sequence): initiate network connection setup.
FSS (Frame Start Sequence): immediately follows TSS
Indicator Bits: provides Header Segment preamble information.
Frame Id (Frame Identifier): defines to which slot frame is transmitted.
Payload Length: indicates data size being transferred in the frame.
Header CRC: contains CRC computed from portion of Header Segment.
Cycle Count: holds value that increments for each comm. cycle start.
Data (Payload): contains data transferred by frame (254 bytes max.).
Trailer CRC: protects against improper header and payload modification.
FES (End of Frame): immediately follows the Trailer CRC
DTS (Dynamic Trailing Sequence): indicates a dynamic frame.
CID (Channel Idle Detection): indicates end of comm. (Idle: BP=BM)
Data_0: negative differential voltage between BP and BM.
Data_1: positive differential voltage between BP and BM.
Idle_LP (LowPower): biased to ground. No current to BP or BM.
Idle: biased to a voltage. No current to BP or BM.
BP (Bus Plus) and BM (Bus Minus) lines used to balance the differential
communications network.
FlexRay Bus Decode Terms
45
FlexRay Bus
FlexRay Analysis Application
Configure :
Data Source
Probing
Trigger

46
Results :
Decoding
CRC Analysis
Correlation to
Acq.-Mem


FlexRay Bus
FlexRay Analysis Application
47
Results :
Timing Meas.
Sync. Meas.
Eye/Mask Test
TIE
Zoom

FlexRay Bus
FlexRay Analysis Application
48
FlexRay Bus
FlexRay Analysis Application
Real Signals

MASK violation

could be ID related