Teledyne CANbus TD User Manual

CANbus Trigger, Decode, and
Measure
Software Option
Operator's Manual
Manufactured under an ISO
9000 Registered Quality
Management System.
Visit www.lecroy.com to view
the certificate.
This electronic product is subject to disposal and
recycling regulations that vary by country and region.
Many countries prohibit the disposal of waste
electronic equipment in standard waste receptacles.
For more information about proper disposal and
recycling of your LeCroy product, please visit
www.lecroy.com/recycle.
LeCroy Corporation
700 Chestnut Ridge Road Chestnut Ridge, NY, 10977-6499 Tel: (845) 578-6020, Fax: (845) 578 5985
Warranty
LeCroy warrants this oscilloscope accessory for normal use and operation within specification for a period of one year from the date of shipment. Spare parts, replacement parts and repairs are warranted for 90 days.
In exercising its warranty, LeCroy, at its option, will either repair or replace any assembly returned within its warranty period to the Customer Service Department or an authorized service center. However, this will be done only if the product is determined by LeCroy’s examination to be defective due to workmanship or materials, and the defect is not caused by misuse, neglect, accident, abnormal conditions of operation, or damage resulting from attempted repair or modifications by a non-authorized service facility.
The customer will be responsible for the transportation and insurance charges for the return of products to the service facility. LeCroy will return all products under warranty with transportation charges prepaid.
This warranty replaces all other warranties, expressed or implied, including but not limited to any implied warranty of merchantability, fitness or adequacy for any particular purposes or use. LeCroy shall not be liable for any special, incidental, or consequential damages, whether in contract or otherwise.
Internet: www.lecroy.com © 2008 by LeCroy Corporation. All rights reserved.
LeCroy, ActiveDSO, JitterTrack, WavePro, WaveMaster, WaveSurfer, WaveLink, WaveExpert, Waverunner, and WaveAce are registered trademarks of LeCroy Corporation. Other product or brand names are trademarks or requested trademarks of their respective holders. Information in this publication supersedes all earlier versions. Specifications are subject to change without notice.
CANbus-TD-TDM-OM-E RevB
916940-00 RevA
Operator's Manual
CANbus-TD-TDM-OM-E RevB
iii
TABLE OF CONTENTS
Introduction ............................................................................................................. 5
Overview ...................................................................................................................... 5
Compatibility................................................................................................................ 6
Assumptions ................................................................................................................ 6
The TD Series Software ............................................................................................. 6
The TDM Series Software .......................................................................................... 7
Using the CANbus Options ........................................................................................ 9
Accessing Serial Triggers .............................................................................................. 9
Creating a CANbus Trigger Condition ........................................................................ 10
CANbus Trigger Setup Detail...................................................................................... 10
CANbus Decode Setup Detail ..................................................................................... 14
Measuring CANbus Performance Using CANBUS TDM .............................................. 15
Overview of CANbus TDM (Trigger, Decode, Measure/Graph) ................................. 15
CANBUS TDM Parameters ......................................................................................... 16
CANbus TDM Graphing and Statistical Analysis ........................................................ 17
General Setup of CANbus TDM Parameters .............................................................. 18
CAN-to-Analog or Analog-to-CAN Measurement Parameter .................................... 22
CAN Message-to-CAN Message Measurement Parameter ....................................... 25
Extract CAN Message Data to a Decimal Value ......................................................... 27
CAN Bus Message Load Percent Measurement Parameter ...................................... 28
Time from Trigger Point to CAN Message Parameter ............................................... 30
Characterizing CANbus System Performance ............................................................ 30
System Performance Characterization Overview ...................................................... 30
Using Cursors ............................................................................................................. 32
Using Measurement Parameters ............................................................................... 34
Measurement Gating ................................................................................................. 35
Using Statistics and Graphing .................................................................................... 35
Pass/Fail Analysis with Measurement Parameters.................................................... 36
CANbus Trigger, Decode, and Measure
iv
CANbus-TD-TDM-OM-E RevB
Isolating and Analyzing CANbus Activity .................................................................. 37
Isolate and Analyze Serial Bus Activity ...................................................................... 37
Reference ............................................................................................................... 45
CANbus TD and TDM Specifications .......................................................................... 45
Safety Requirements ................................................................................................. 47
Appendix A: External Trigger Hardware ................................................................... 48
CANbus TD Standard Hardware ................................................................................. 48
Accessories ................................................................................................................ 51
Connecting to a CANbus Circuit ................................................................................. 51
Trigger Setup .............................................................................................................. 62
Operator's Manual
CANbus-TD-TDM-OM-E RevB
5
Introduction
Several communication protocol types are used in automotive applications. They are used to send data from sensors to electronic control units (ECUs) or from one ECU to another. These protocol types include Controller Area Network (CAN), Local Interconnect Network (LIN), and FlexRay. LIN is a low-cost master/slave system designed for low-cost implementation in vehicles, typically in what is commonly referred to as body electronics. FlexRay is a time-triggered automotive communications bus designed for higher speeds and fault tolerance.
This manual focuses on the CANbus TDM and TD products. LeCroy also has separate LIN and FlexRay products and manuals.
Overview
CANbus TDM and TD options contain powerful software algorithms which extract serial data information from physical layer waveforms measured on your oscilloscope. The extracted information is overlaid (annotated) on the actual physical layer waveforms, and color-coded to provide fast, intuitive understanding.
The CANbus TD option allows triggering on CAN Frames and Errors. Frame triggering can be set to trigger on any frame, one specific Frame ID, a range of Frame IDs, Remote Frames, and Errors. Frame triggering and data triggering can be done for a single ID or message or a range of IDs and data by using the conditional trigger capabilities. Other powerful and user-friendly features included in CANbus TD include:
The ability to trigger and decode CAN at bit rates from 10 kb/s to 1 Mb/s. The ability to create powerful, conditional Frame ID and Data triggers. Triggering on CAN protocol errors and remote frames.
If you are unfamiliar or are just learning about CAN, start by using the simplest trigger conditions (All Frames or Frame ID). Next, experiment with an ID and Data to trigger on a specific value. Then, try a conditional ID + Data trigger (ID Greater Than or In Range).
The CANbus TDM and TD Serial Data options are unique oscilloscope tools from LeCroy which greatly increase your ability to debug and analyze embedded controllers that use CAN. The TDM product include Serial Trigger, Decode and Measure/Graph capabilities, the TD product include Serial Trigger and Decode.
The CAN trigger is integrated into the oscilloscope - meaning no external hardware is used. It's selected through the normal oscilloscope trigger menus. CAN signals are sent to the oscilloscope using a differential probe like the ADP305 or AP033. Decoding is accessed from the Analysis menu. The decoding is overlaid on top of the appropriate channel, and is intuitively presented and color-coded for quick understanding. Measurement and graphing capabilities may be accessed through the Measure/Graph tab in the Decode Setup or from the Measure menu. All
CANbus Trigger, Decode, and Measure
6
CANbus-TD-TDM-OM-E RevB
packages contain Search capability for specific IDs, Data and Errors and a Table displays summarized protocol data underneath the oscilloscope grid.
Compatibility
The CANbus TDM option is compatible for WavePro Zi and WaveRunner Xi oscilloscopes. The CANbus TD option is compatible with the WavePro Zi, WaveRunner Xi and WaveSurfer Xs oscilloscopes. CAN triggering is completely integrated with the oscilloscope and no external hardware is required. Earlier versions of LeCroy’s CANbus TDM and TD options required the use of an external trigger module, for documentation ion how to use the external trigger module please see the appendix. The external trigger module is still available for use with WaveMaster 8000A, WavePro 7000A, and WaveRunner 6000A oscilloscopes.
Note: All references to Decode and Measure/Graph capabilities and functionality are identical whether the external or internal CAN trigger is being used.
Assumptions
This manual assumes a basic understanding of the FlexRay standard physical layer and protocol layer specifications, and knowledge of how FlexRay is used. Also, a basic understanding of oscilloscope operation - specifically the LeCroy oscilloscope which the FlexRay trigger, decode, and physical layer option is used with - is assumed. Wherever practical or necessary, details on specific oscilloscope features have been included in this manual.
Note: LeCroy has a policy of frequently updating software. While screen images in this manual may not exactly match what is seen on your oscilloscope display, be assured that the functionality is nearly identical.
The TD Series Software
The TD option adds the following capability to the LeCroy oscilloscope software user interface dialogs:
1. Serial Trigger Selection - If this is the first serial trigger option you have installed on your
oscilloscope, an additional icon is shown on your trigger dialog box. It allows a serial trigger condition to be set from within the oscilloscope using an easy-to-understand interface.
2. Serial Decode - If this is the first serial decode option you have installed on your scope, an
additional set of Serial Decode and Decode Setup dialog boxes are provided for setup of
Operator's Manual
CANbus-TD-TDM-OM-E RevB
7
protocol format (as necessary) and decoding. These can be accessed from the Analysis menu.
3. Decode Protocol Selections - As serial decode options are added to your oscilloscope,
additional protocol selections are available in a pop-up dialog box within the Serial Decode dialog boxes.
Note: SIOP and SSPI are part of the SPIbus TD package. RS232 is part of the UART­RS232bus TD package.
The TDM Series Software
The TDP option adds the following capability to the LeCroy oscilloscope software user interface dialogs:
1. Serial Trigger Selection - If this is the first serial trigger option you have installed on your
oscilloscope, an additional icon is shown on your trigger dialog box. It allows a serial
CANbus Trigger, Decode, and Measure
8
CANbus-TD-TDM-OM-E RevB
trigger condition to be set from within the oscilloscope using an easy-to-understand interface.
2. Serial Decode - If this is the first serial decode option you have installed on your scope, an
additional set of Serial Decode and Decode Setup dialog boxes are provided for setup of protocol format (as necessary) and decoding. These can be accessed from the Analysis menu.
3. Decode Protocol Selections - CAN is one of several signal types that can be decoded by
the oscilloscope. Other standards include I2C, SPI, UART, RS-232, LIN, and FlexRay.
4. Measure/Graph Setup - CAN measurement and graphing functions are accessed through
the Serial Decode setup by selecting the Measure/Graph Setup tab.
Operator's Manual
CANbus-TD-TDM-OM-E RevB
9
Using the CANbus Options
Overview of CANbus TD (Trigger and Decode)
The CANbus TD option contains powerful software algorithms to extract serial data information from physical layer waveforms measured on your oscilloscope. The extracted information is overlaid (annotated) on the actual physical layer waveforms, and color-coded to provide fast, intuitive understanding.
The CANbus TD option allows triggering on CAN Frames and Errors. Frame triggering can be set to trigger on any frame, one specific Frame ID, a range of Frame IDs, Remote Frames and Errors. Frame triggering and data triggering can be done for a single ID or message or a range of IDs and data by using the conditional trigger capabilities. Other powerful and user-friendly features included in CANbus TD include:
The ability to trigger and decode CAN at bit rates from 10 kb/s to 1 Mb/s. The ability to create powerful, conditional Frame ID and Data triggers. Triggering on CAN protocol errors and remote frames.
If you are unfamiliar or are just learning about CAN, start by using the simplest trigger conditions (All Frames or Frame ID). Next, experiment with an ID and Data to trigger on a specific value. Then, try a conditional ID + Data trigger (ID Greater Than or In Range).
Accessing Serial Triggers
The CANbus serial trigger is accessed from the oscilloscope trigger dialog. Use one of the following methods:
Touch the Trigger Descriptor Box in the lower right hand corner of the oscilloscope
display.
OR
Touch Trigger → Trigger Setup from the Menu Bar. On the Trigger dialog, touch Serial on
the Type section. Select the appropriate serial trigger. The menu automatically changes to a different tab in
the Trigger dialog reflecting the selected standard.
CANbus Trigger, Decode, and Measure
10
CANbus-TD-TDM-OM-E RevB
Creating a CANbus Trigger Condition
The CANbus Trigger dialog, with detail on some of the setup conditions, is shown in the following topics.
CANbus Trigger Setup Detail
The following topics show the dialog selections for a CANbus Trigger.
Operator's Manual
CANbus-TD-TDM-OM-E RevB
11
The previously numbered CANbus trigger sections correspond with the following explanations.
1. Source Setup
DATA - The DATA field's pop-up dialog is used to select the appropriate channel or EXT
input for each. Set this field up with caution or your trigger may not function correctly. Use the Threshold field to adjust the vertical level for the trigger. Much like an Edge trigger, a user must specify the level used in order to process the incoming signals and determine whether the desired serial data pattern is meeting the set trigger condition.
2. CAN Setup
Bitrate - Use the Bitrate field to adjust the value and match the bus to which you are
connected. This bitrate selection is dynamically linked to the decoding bitrate (they are always the same value). Use the arrows to move through standard bit rates (10, 25,
33.333, 50, 83.333, 100, 125, 250, 500, and 1000 kb/s) and make a selection. Or, touch the number twice (with a finger, or using a mouse) and open a pop-up keypad and enter the value directly.
3. Trigger Type
Trigger Type - Depending on your Trigger Type selection, certain Frame ID and Data Pattern Setup fields are enabled or disabled as follows:
All - Triggers on all signals. No Frame ID and Data Pattern ID Setup fields are enabled.
CANbus Trigger, Decode, and Measure
12
CANbus-TD-TDM-OM-E RevB
Remote - Only Frame ID Setup fields are enabled. Data - Both Frame ID and Data Pattern ID Setup fields are enabled. Error - Triggers only when an error signal occurs. No Frame ID and Data Pattern ID Setup
fields are enabled.
4. Setup Format
Select either Binary or Hexadecimal (Hex) setup mode. The mode selected propagates through the entire CANbus trigger setup.
Try selecting Binary mode, and set up the Frame ID in binary format, then re-select HEX mode and set up the data in hexadecimal format. Toggling back and forth between the modes does not result in loss of information.
5. Frame ID Setup
Frame ID Setup is used to trigger on a specific Frame ID value with either 11 or 29 Bits.
When CANbus trigger selections are either Remote or Data, use the Frame ID Setup fields as follows:
ID Condition - The ID condition can be set to many different values. If the ID condition is
set to “=”, then a data definition can also be set. Any other ID condition precludes setting up a Data condition.
The ID condition can be set to <=, <, =, >, >=, not =, in a range, out of a range, or don’t care.
ID Bits - The trigger can be set to trigger on CAN messages with either 11-bits (Standard
CAN) or 29-bits (Extended CAN). You can also set the trigger so that it triggers on a message that meets a condition for either the 11-bit or 29-bit ID. For instance, there might be an 11-bit ID value that is present in both an 11-bit and a 29-bit ID, and by choosing ALL, you could trigger when that ID is present on either of those messages.
Frame ID - Specify the desired frame ID for triggering here.
Operator's Manual
CANbus-TD-TDM-OM-E RevB
13
To Frame ID - When using an in range or out of range ID Condition (previous), specify a To
Frame ID value for triggering.
6. Data Pattern Setup
Fields on this section of the dialog are only enabled when using the Data trigger type.
Data Condition - The Data Condition can be set to many different values. The Data
condition can be set to <=, <, =, >, >=, not =, in a range, out of a range, or don’t care.
DLC - The DLC (data length code) can be set to any integer value from 0 to 8. It should
match the DLC of the CAN message you want to trigger on. If you set it to a value less than 0, it will default to 0. If you set it to a value greater than 8, it will default to 8.
Byte Order - Choose from either Motorola (default) or Intel byte orders. Start Bit and # Data Bits - The CANbus trigger allows you to trigger on up to 64
contiguous data bits (8 data bytes). This maximum 64-bit string can start at any location in the CAN message data field - it is not limited to the start of a full byte or a nibble.
The Start Bit can be any value from 0 to 63. If you enter a value less than 0, it will default to 0. If you enter a value more than 63, it will default to 63. The Start Bit value is always in LSB format (i.e., the bit number as shown on the decoded waveform, with bit 0 being at the far left and bit 63 being at the far right of the data string). Remember that the 1st data byte is bits 0-7, the 2nd data byte is bits 8-15, etc. Also, make sure that your Start Bit value makes sense in relation to the DLC Value. For instance, a Start Bit value of 32 with a DLC Value of 4 is not going to result in a successful trigger.
The # Bits can be any value from 1 to 64. If you enter a value less than 1, it will default to
1. If you enter a value more than 64, it will default to 64.
Sign Type - Choose between signed and unsigned integer format. Data Value and Data Value To - The Data Value is set in Binary or Hexadecimal format.
For Hexadecimal, if desired, you can precede the ID value with “0x”, but this is not
necessary. Be sure to enter a Data Value that matches the DLC Value.
CANbus Trigger, Decode, and Measure
14
CANbus-TD-TDM-OM-E RevB
When using an in range or out of range Data Condition (previous), specify a Data Value To value for triggering.
CANbus Decode Setup Detail
CANbus Decode Setup Right-Hand Dialogs are shown when CAN is selected as the decode protocol. It provides detailed fields and setup conditions as follows:
Viewing - The decode format is displayed here as Hexadecimal for CANbus. Bitrate - Adjust the bit rate value here to match the bit rate on the bus you are connected
to. This bit rate selection is dynamically linked to the decoding bit rate (they are always the same value). Use the arrows to move through standard bit rates (10, 25, 33.333, 50,
83.333, 100, 125, 250, 500, and 1000 kb/s) and make a selection. Or, touch the number twice (with a finger, or using a mouse) and open the pop-up keypad to enter the value directly. Any value from 10-1000 kb/s may be entered in this way.
Show Stuff Bits – Use this checkbox to indicate whether you want stuff bits highlighted
on each CAN message frame.
Level Type and Level - The message decoding algorithm setup is performed here. The
level is normally set up in %, and defaults to 50%. To adjust the level, touch inside the number area to highlight the box title in yellow, then use the oscilloscope front panel
Operator's Manual
CANbus-TD-TDM-OM-E RevB
15
Adjust knob to adjust. Or touch inside the number area twice and select a value using the pop-up numeric keypad.
The set Level appears as a dotted horizontal line across the oscilloscope grid. If your initial decoding indicates that there are a number of error frames, make sure that
the level is set to a reasonable value.
Measuring CANbus Performance Using CANBUS TDM
Overview of CANbus TDM (Trigger, Decode, Measure/Graph)
Basic oscilloscope tools can be extremely helpful to understand single-shot events. However, their utility in measuring performance of a CAN Bus system can be very limited. It is usually necessary to obtain large quantities of data before you can be sure that system performance is within specified limits. The following are typical examples of actions to assess CAN Bus system performance:
Measure Timing Δ Between CAN and Analog Signals & Accumulate Statistics - Measure
the time difference between an analog signal and CAN signal generated in response to it (or vice-a-versa). View the mean, minimum, and maximum timing values, the number of samples, and the standard deviation of the measurements.
Measure Timing Δ Between Two CAN Messages & Accumulate Statistics - Same as
previous, but with two CAN signals.
Measure Timing Δ From the Trigger Point to a CAN Message - Same as previous, but the
trigger point can be anything - a CAN message, an Analog signal, a Pattern of signals, a Dropout condition, etc.
Measure Timing, Accumulate Statistics, View Distribution - Instead of just looking at
numerical values, graph/plot the distribution as a histogram to better understand the shape of the distribution, the quantity of extreme events, and determine underlying cause.
Graph/Plot CAN Data Values from a Single Acquisition - Extract CAN Data values in
decimal format and compare them to an analog signal in a time-correlated fashion.
Graph/Plot CAN Data Values Over Multiple Acquisitions - Extract CAN Data values in
decimal format and graph/plot them over multiple acquisitions.
Measure CAN Bus Load, Graph/Plot - Understand how bus loading relates to other CAN
and Analog signal events.
CANbus Trigger, Decode, and Measure
16
CANbus-TD-TDM-OM-E RevB
CAN Message to Analog Signal timing (CANtoAnalog)
Analog Signal to CAN Message timing (CANtoAnalog)
CAN Message to CAN Message Signal Timing (CANtoCAN)
Time from trigger to a specific CAN message (Time@CAN)
CAN Bus Message Load Percentage (CANLoad)
Extract CAN Message Data to a Decimal Value (CANtoValue)
Some of this information could be gathered using standard oscilloscope tools, but the accumulation of the data would take hours or days. It is more likely that the engineer would instead gather a very small sample set and skip the statistical evaluation in order to save time. The result is reduced product quality and corresponding greater risk of shipping product that functions incorrectly in some situations.
CANbus TDM contains specific CAN measurement parameters that allow you to quickly and easily accumulate statistical information on a wide variety of events, and graphical display tools to visualize the data on your oscilloscope screen. These sophisticated measurement and
graphical display tools are the “missing link” between standard oscilloscope and protocol
analyzer capability. The CANbus TDM tools provide the capability to trigger on defined CAN Bus events, observe actions/reactions, measure timing among CAN and Analog signals, and view results in a graphical fashion directly on the oscilloscope display with no complicated export of data. Data on tens of thousands of events can be automatically and quickly gathered and analyzed in a fraction of the time it takes to manually perform the same testing.
CANbus TDM contains additional CAN specific measurement, graphing, and statistical analysis capability as the following topics explain.
CANBUS TDM Parameters
Operator's Manual
CANbus-TD-TDM-OM-E RevB
17
CANbus TDM Graphing and Statistical Analysis
Histogram - The Histogram displays a statistical distribution of a measurement
parameter. Histogram is helpful to understand the modality of a measurement parameter, and to debug the root cause of excessive variation.
Trend - The Trend statistical tool visualizes the evolution of a timing parameter over time
in the form of a line graph. The graph’s vertical axis is the value of the parameter; its
horizontal axis is the order in which values were acquired. Trend is typically used for a multi-shot acquisition. Trend is analogous to a chart recorder.
Track - The Track displays a time-correlated accumulation of values for a single
acquisition. Track can be used to plot the values of CAN data and compare them to a corresponding analog signal, or observe changes in timing. Track is typically used for a single-shot acquisition. A long acquisition with many parameter measurements analyzed with Track could provide information about the modulation of the parameter.
CANbus Trigger, Decode, and Measure
18
CANbus-TD-TDM-OM-E RevB
In addition to the Histogram graphing capability, there are also 19 different measurement parameters that apply specifically to Histograms. These are listed below (more information is contained in Appendix D):
fwhm - full width (of largest peak) at half the maximum bin fwxx - full width (of largest peak) at xx% the maximum bin hist ampl - histogram amplitude between two largest peaks hist base - histogram base or leftmost of two largest peaks hist max - value of the highest (right-most) populated bin in a histogram hist mean - average or mean value of data in the histogram hist median - value of the x-axis of a histogram that divides the population into two
equal halves
hist min - value of the lowest (left-most) populated bin in a histogram hist rms - rms value of data in histogram hist sdev - standard deviation of values in a histogram hist top - histogram top or rightmost of two largest peaks max populate - population of most populated bin in histogram mode - data value of most populated bin in histogram percentile - data value in histogram for which specified `x'% of population is smaller peaks - number of peaks in histogram pop @ x - population of bin for specified horizontal coordinate range - difference between highest and lowest data values total pop - total population in histogram x at peak - x-axis position of specified largest peak
These measurement parameters are available in the Statistics category in the measurement selection pop-up dialog.
General Setup of CANbus TDM Parameters
There are two different ways to set up CAN related measurements. The easiest way is to use the Measure tab in the CAN Analysis dialogs to access the CAN Measure dialog. This dialog is specifically tailored to meet the needs of an engineer who is debugging CAN-based systems. It contains different categories of CAN, pulse, statistical, etc. measurement parameters that are commonly used to measure CAN system performance.
Setting Up CANbus Parameters using the Serial Decode option
1. Touch the Measure/Graph Setup tab in the CAN Serial Decode dialogs. There are four
parameter measurements displayed (P1 through P4).
Operator's Manual
CANbus-TD-TDM-OM-E RevB
19
CANbus Trigger, Decode, and Measure
20
CANbus-TD-TDM-OM-E RevB
2. For a specific measurement parameter, touch the parameter icon or parameter name to
access the CAN Measurement Select pop-up dialog.
3. From the CAN Select Measurement window, choose a parameter. Touch an icon to select
the measurement.
4. Touch the source field to open the Select Source pop-up dialog. Select a category to
display the available sources, then select the appropriate source.
Note:The source for the CAN measurements should be Decode1, Decode2, Decode3 or Decode4 depending on which serial data decode is being used to decode the bus you are trying to measure.
5. The View and Load Table checkbox is checked automatically when you select your
parameters. Uncheck it to turn measurements OFF.
Note: Measurement parameter and source selections that are set up in the CAN Measure menu are copied to the oscilloscope standard Measure menu.
Operator's Manual
CANbus-TD-TDM-OM-E RevB
21
6. Many parameters (and all CAN-specific parameters) require some additional setup
information to be entered in order to work correctly. To access the setup dialog, touch the Setup button.
Loading...
+ 48 hidden pages