Automotive electronics CAN and LIN buses. Copyright 2006 Matrix Multimedia Limited



Similar documents
CAN bus board. EB018

E-Blocks Easy Internet Bundle

Introduction to RACE FUELS Hans-Christian von der Wense Munich, Germany

In-Vehicle Networking

E-Blocks Easy RFID Bundle

How To Program A Microcontroller Board (Eb064) With A Psp Microcontroller (B064-74) With An Ios 2.5V (Power) And A Ppt (Power Control) (Power Supply) (

Adaptive Cruise Control System Overview

Welcome to the Introduction to Controller Area Network web seminar My name is William Stuart, and I am a Applications Engineer for the Automotive

FlowKit in-circuit debug system

Bluetooth in Automotive Applications Lars-Berno Fredriksson, KVASER AB

LOCAL INTERCONNECT NETWORK (LIN)

LED board datasheet EB

A DIY Hardware Packet Sniffer

Understanding SAE J1939. by Simma Software, Inc.

Introduction. In this Self-study Programme we will explain to you the design and function of the CAN data bus. SSP 186/01

Surveillance System Using Wireless Sensor Networks

Electronically Controlled Air Suspension (ECAS) for Trucks

LIN (Local Interconnect Network):

ECIO40P ECIO28P ECRM40. Page 1. USB programmable microcontrollers. 0.6 DIP footprint. Supplied with a free version of Flowcode. E-blocks compatible

Switch board datasheet EB

RS232 Board datasheet

Introduction to. LIN (Local Interconnect Network)

ILISC515-A Shift Interlock (Manual Lift Door) 2015 Ford Transit, 3.7L and 3.5L

Using the HT46R46 I/O Ports to Implement Half-Duplex SPI Communication

FFT Frequency Detection on the dspic

Local Interconnect Network Training. Local Interconnect Network Training. Overview

UPS PIco. to be used with. Raspberry Pi B+, A+, B, and A. HAT Compliant. Raspberry Pi is a trademark of the Raspberry Pi Foundation

PID Control. Proportional Integral Derivative (PID) Control. Matrix Multimedia 2011 MX009 - PID Control. by Ben Rowland, April 2011

AUTOMATIC NIGHT LAMP WITH MORNING ALARM USING MICROPROCESSOR

The I2C Bus. NXP Semiconductors: UM10204 I2C-bus specification and user manual HAW - Arduino 1

Computer Organization & Architecture Lecture #19

Transporter Fitting Locations No. 804 / 1

The Secrets of RS-485 Half-duplex Communication

EBERSPÄCHER ELECTRONICS automotive bus systems. solutions for network analysis

PEMS Conference. Acquiring Data from In-Vehicle Networks. Rick Walter, P.E. HEM Data Corporation

PG DRIVES TECHNOLOGY R-NET PROGRAMMER R-NET PROGRAMMING SOFTWARE - DEALER ELECTRONIC MANUAL SK78809/2 SK78809/2 1

INTRODUCTION TO SERIAL ARM

LOCAL INTERCONNECT NETWORK (LIN)

TD-03011E. Identifier Usage in CANopen Networks

Configuring PROFINET

Install the DeviceNet Module using the following procedure:

Data Sheet. Adaptive Design ltd. Arduino Dual L6470 Stepper Motor Shield V th November L6470 Stepper Motor Shield

Quick Reference Guide VT55 & OBDII. Customer Service TPMS Version: QSG /12

AN460 Using the P82B96 for bus interface

Microprocessor & Assembly Language

ENGINE CONTROLS AND FUEL SYSTEMS

DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING Question Bank Subject Name: EC Microprocessor & Microcontroller Year/Sem : II/IV

GAS LEAKAGE DETECTION & AUTO ON-OFF GAS SYSTEM

CAN AND NETWORK COMMUNICATIONS

Programming Flash Microcontrollers through the Controller Area Network (CAN) Interface

Customer Experience. Silicon. Support & Professional Eng. Services. Freescale Provided SW & Solutions

RS-485 Protocol Manual

CAN-Bus Troubleshooting Guide

Case Study Competition Be an engineer of the future! Innovating cars using the latest instrumentation!

Figure 1 FPGA Growth and Usage Trends

1 Application Description Objective Goals... 3

Quick Start Guide Ski Doo Snowmobiles

Measurement and Analysis Introduction of ISO7816 (Smart Card)

CENTRONICS interface and Parallel Printer Port LPT

In networking ECUs in heavy-duty vehicles, it is the J1939 protocol that. plays a key role. J1939 networks are based on the CAN bus (high-speed

Options for ABB drives, converters and inverters. User s manual FDPI-02 diagnostics and panel interface

CHECK CAN BUS LINE (CAN-H) FOR SHORT TO +B

Measuring Resistance Using Digital I/O

Guide to TCP/IP, Third Edition. Chapter 3: Data Link and Network Layer TCP/IP Protocols

Software Development for Multiple OEMs Using Tool Configured Middleware for CAN Communication

UCC 1 USB-CAN CONVERTER

Implementing MOD bus and CAN bus Protocol Conversion Interface

PRODUCTIVITY THROUGH INNOVATION 600 CONTROL DIRECT DRIVE TECHNICAL/OPERATION MANUAL

SupverVAG K+CAN User Manual

Elettronica dei Sistemi Digitali Costantino Giaconia SERIAL I/O COMMON PROTOCOLS

AVL DISCAN Handheld-Scantool for multifunctional fields of application Faultcode-reader with integrated Informationsystem and Oscilloscope

Wireless-N. User Guide. PCI Adapter WMP300N (EU) WIRELESS. Model No.

Operating Instructions Display, graphic. Numeric language

FLASHZILLA USER GUIDE rev1.6

Bus Data Acquisition and Remote Monitoring System Using Gsm & Can

Laboratory Course Industrial Automation. Experiment Nr. 6. Introduction to the FlexRay bus system. Brief User Guide IAS Demonstrator Go-Cart

User s Manual of Board Microcontroller ET-MEGA2560-ADK ET-MEGA2560-ADK

WIFI OBD GPS Tracker T356 User Manual

CANnes PC CAN Interface Manual

MODEL S SOFTWARE RELEASE NOTES v5.8

PUSH BUTTON START INSTALLATION MANUAL

G-100/200 Operation & Installation

Super Vag K+Can User Manual

Wireless LAN g USB Adapter

Introduction to Electronic Signals

AIR CONDITIONING SYSTEM 1. FFH SPECIFICATION AIR CONDITIONING SYSTEM RODIUS

Meritor WABCO Pneumatic Antilock Braking System (ABS) 42.22

CONTROL MICROSYSTEMS DNP3. User and Reference Manual

An Escape. our man John on a research binge. Electric Slide

Class 5 to 7 Truck and Bus Hydraulic Brake System

Guide to the... Nissan Leaf. Completely harmless fun with. City Car Club 100% electric

Service Manual Trucks

INTERACTIVE DISTANCE LEARNING ANTI-LOCK BRAKE SPECIALIST: KELSEY HAYES REAR WHEEL ANTI-LOCK BRAKING SYSTEMS (RWAL/RABS)

AUTOBOSS V30 hand-held diagnostic tool developed for the European market - the true all-in-one scan tool. OEM COVERAGE FOR EUROPEAN/ASIAN/US VEHICLES

Massachusetts Institute of Technology

TekBots TM Oregon State University. usb_cam User Guide. Version 1.0 By Adriaan Smit OSU EE Graduate Student

Positioning Controller

PCMCIA 1 Port RS EDITION OCTOBER 1999

OUTCOME 1 TUTORIAL 1 - MECHATRONIC SYSTEMS AND PRODUCTS

Ethernet. Ethernet Frame Structure. Ethernet Frame Structure (more) Ethernet: uses CSMA/CD

Transcription:

Automotive electronics CAN and LIN buses Copyright 2006 atrix ultimedia Limited

About this presentation This presentation was developed by John Dobson anaging Director of atrix ultimedia Limited. PowerPoint versions of this presentation are available on request. Notes on the presentation are included with each slide down here: Automotive electronics is one of the few growth areas in electronics education. A major problem in this areas is understanding the control buses that have replaced wiring looms in vehicles. CAN bus is the most important of these but many vehicles now use both CAN and LIN buses for cost reasons. We are developing solutions for both areas. 2

Part - What is CAN? 3

What is CAN? Controller Area Network b/s data rate High reliability bus Used for control in industrial and Automotive applications CAN is an open standard with many variants CAN is also increasingly used in home automation and other areas. I have even had customers who are considering CAN for controlling points in small outdoor model railway systems. 4

Replacing the wiring loom Electronics are distributed all over the car LIN Actuators and sensors become smart Lock irror Lock otor Control panel Light cluster Power train ITS x6 Instruments Central body control Climate Lights Steering wheel panel CAN Seat Lock LIN Seat CAN Heater Interior light Heater Heater Heater Seat Light Wiper Heater Boot Light backbone, 3 nodes, 8 subnets, -8 local nodes, 52 nodes total Lock Lock irror Use of CAN and LIN buses in a modern car This diagram shows the distribution of CAN and LIN bus in a car. This is theoretical only but based on current industry practice. LIN is slightly cheaper than CAN ($0.5 a node) and is lower data rate, lower reliability. Some automotive systems currently only use CAN e.g. assey Ferguson tractors. I am told that in some cars there are up to 300 microcontrollers. This seems unlikely at first, but if you consider that there is one in the tyre (for pressure) a pressure information receiver, an antilock brake microcontroller, then we are up to 2 already. Electrically operated seats probably have a few in etc. aybe we can easily get to 50 micros, and maybe the 300 figure is true. 5

Advantages of CAN in automotive applications Lower cost at vehicle construction Increased flexibility and reusability of design Reduces time to market Facilitates drive by wire which reduces cost further Facilitates advanced features in vehicles Enhances debug at point of service Cost and features are the big driving forces. (forgive the pun) 6

What the CAN protocol defines Defines the physical layer Bitwise arbitration on the bus essage structure ID and data Error handling Fault isolation technique The low layers of the CAN communication protocol are defined as an international standard. 7

Higher Level Protocols (HLP) Startup procedures (e.g.are all the nodes there?) Addresses of particular nodes and kind of messages Layout of messages in data System level error handling A problem every CAN bus implementation is different: and private However each manufacturer will have their own upper layer definitions. A command for turning an indicator light on will be very different in a Ford car and an Audi car. Automotive manufactures may find it difficult to share HLPs and may not want to share them for commercial reasons. Also automotive manufacturers may not want to release details of the HLP for safety reasons you don t want consumers messing with the technology that operates the antilock brakes, and the brake lights. 8

Routes for teaching CAN Option : Pick on a manufacturer, say Audi, and teach their CAN system with their diagnostic tools etc. Option 2: teach the generic CAN system, make up your own micro-hlp This is an areas of debate. Option is incredibly expensive and very limited students only experience one kind of CAN and may be sheltered by many of the details which help understand what CAN is and what it does. Option has the advantage that the students would gain experience of using real diagnostic equipment, however they may be sheltered from details about how CAN actually works. In theory this is not a problem as automotive technicians only need to fix faults, however an understanding of the fundamentals is certainly an advantage. Our solution follows option 2. 9

A CAN ECU A CAN ECU / node consists of a microcontroller, a CAN controller, a line driver and I/O This can be mimicked with E- blocks This can be controlled with Flowcode E-blocks CAN controller and line driver An Electronic Control Unit has the devices shown. In practice this can be implemented in a number of ways: for example you may find a microcontroller with an internal CAN controller and I/O circuitry and you may even find a single chip that has all these four blocks. The E-blocks solution is a bit blocky here, but they form a perfectly valid, fully working ECU. 0

Physical layer CAN is differential - for noise cancellation Signal polarity will depend on whether you monitor CAN_H or CAN _L Up to bit/s (25kHZ here) CAN bus requires terminating. Here you can see scope traces of the signals on the two wires with respect to ground.

CAN packet structure Four types of messages: Data frame, remote frame, error frame, overload frame We have implemented the Data frame, and remote frame: others are for bus management Data field length is adjustable A lot of this is taken care of by a CAN stack on the E-blocks board. Here you can see the data frame for CAN. Several types are specified and we only support two. 2

A simplified CAN bus Each device or device group has a CAN ECU For example the block thermistor, instrument panel, foot brake and light clusters each have an ECU These ECUs all send and receive messages on the CAN bus The level of CAN granularity will vary from manufacturer to manufacturer, and will also change with time as more devices become available. For example you may have one ECU in a light cluster, or you could have one ECU for each bulb within a cluster, or one ECU the light cluster and the rear wiper and wash unit. 3

CAN messages ID Data Each message has an ID and Data up to 8 bytes CAN ECUs are programmed to transmit messages with a given ID, and/or look for messages with a given ID This shows the simplicity of CAN. The bus just has messages with ID and data. anufacturers then add functionality to the system by deciding what message to transmit on a particular event, and by deciding what actions should take place on receipt of a particular message. This customisation of the CAN bus system is referred to as a higher level protocol. Each manufacturer has its own higher level protocol. 4

An example of a message transaction Instrument panel ECU says can anyone tell me what the block temperature is? ID 400 Data Block ECU sees this message and issues a message block temperature is 76 Celsius 40 076 Instrument panel ECU sees block temperature message and displays it on console In practice this could be more complicated This is an example of transactions on a CAN bus. The information is actually quite complex and specific but it is distilled into very simple CAN bus transactions. 5

Things about CAN The protocol is designed to increase integrity of the system There is no hierarchy It is designed for control not transmission of large blocks of data At an basic level the protocol is quite simple the details are quite complex From the previous transaction you can see that these are key features of CAN. 6

Part 2 the E-blocks CAN bus solution 7

IN RV X J6 J7 J Z J B5 B4 B3 RESET PB J99 eblocks ONLY INSERT CHIP AT A TIE EB00600 USB multiprogrammer ONLY INSERT CHIP AT A TIE U8 U28 U40 U8/4 2 0 2 3 4 5 6 7 B CANL CANH LED 5V 5V 0V J5 40 eblocks lcd eblocks LEDs 5V 0V www..co.uk 5V 5V 0V www..co.uk www..co.uk IN RV X J6 J7 J Z J B5 B4 B3 5V 5V 0V RESET PB J99 eblocks ONLY INSERT CHIP AT A TIE EB00600 USB multiprogrammer ONLY INSERT CHIP AT A TIE U8 U28 U40 U8/4 2 0 2 3 4 5 6 7 B CANL CANH LED 5V 5V 0V J5 40 Hardware nodes and 2 Port A Port B Port D Port C SW SW2 8 pin Port E Port A U eblocks switches 0V +5V +5V +4V OU T OU T J0 Port B Port D Port C SW SW2 8 pin Port E U 0V +5V +5V +4V OU T OU T J0 SDO SDI SCK /INT /CS D7 D6 D5 D4 D3 D2 D D0 eblocks switches SDO SDI SCK /INT /CS www..co.uk OUT OUT2 eblocks CAN board OUT OUT2 eblocks CAN board Node is mimics the dashboard. Node 2 is a general purpose switch panel for brakes, indicator control etc. 8

IN RV X J6 J7 J Z J B5 B4 B3 eblocks RESET PB EB00600 USB multiprogrammer J99 ONLY INSERT CHIP AT A TIE U8 U28 U40 U8/4 2 ONLY INSERT CHIP AT A TIE 0 2 3 4 5 6 7 B CANL CANH LED 5V 5V 0V J5 40 IN RV X J6 J7 J Z J B5 B4 B3 eblocks RESET PB EB00600 USB multiprogrammer J99 ONLY INSERT CHIP AT A TIE U8 U28 U40 U8/4 2 ONLY INSERT CHIP AT A TIE 0 2 3 4 5 6 7 B CANL CANH LED 5V 5V 0V J5 40 0 2 3 4 5 6 7 LDR RV ANA SEN D IN D OUT GND eblocks Se nsors CAN_H CAN_L Hardware nodes 3 and 4 Port A Port B Port D Port C SW SW2 8 pin Port E Port A 0V +5V +5V +4V OUT OUT J0 U Port B eblocks LEDs D7 SDO SDI SCK /INT /CS D6 D5 D4 D3 D2 D D0 www..co.uk OUT OUT2 eblocks CAN board CAN_GND eblocks terminal board Port D Port C SW SW2 8 pin Port E 0V +5V +5V +4V OUT OUT J0 U SDO SDI SCK /INT /CS OUT OUT2 eblocks CAN board Node 3 is a general purpose LED node to mimic rear light clusters etc. Node 4 is a sensor node where you can mimic an ECU that measures block temperature. The small circuit board allows the CAN analyzer to be plugged in. 9

CAN analyzer The CAN analyzer generates CAN messages and also shows the CAN messages on the bus. Here you can see a simple screen shat shows messages with ID, one data byte of value 56. 20

Teacher s notes 50 pages of teacher s notes help you to familiarise yourself with the system and how to use it in class. As part of the solution we also ship a manual that covers setting up the system and gives some sample exercises for students. 2

Flowcode CAN software High level software in Flowcode Caters for different levels of user akes CAN transactions easy Can be used by automotive technicians upwards General settings screen Flowcode CAN software is a key part of this. The software provides access to the CAN hardware at a high level so that students can concentrate on setting up the CAN system and not spend all their time on low level programming. 22

Flowcode CAN software Transmit settings screen Receive settings screen 23

Flowcode software essage transfer is based on a buffer system ore advanced users can alter level settings and get access to more features These additional screens show how the CAN system operates with buffers transmit and receive. When a message is received it goes into a buffer very quickly. The microcontroller has to poll the CAN controller device regularly to see if there are any relevant messages. It is possible to set the buffers to filter out messages with a given ID. The contents of the transmit buffer can be examined so that students can understand packet structure. 24

CAN for Automotive students Students can understand the nature of an ECU Students can understand that ECUs can be reprogrammed and have hardware and software faults Students can construct basic CAN systems with prewritten programmes Students can construct simple CAN systems Theses are some of the requirements of automotive technicians. The CAN solution is ideal for this. 25

Beyond automotive The basics of CAN can be understood The software and hardware can be used to construct a fully working CAN bus, at varying levels of complexity Basic packet structure can be seen and understood Programmed in Flowcode or C Advanced users can use C to control all aspects of the CAN bus. However the code behind this could be ambitious! IN practice we believe that even degree level students don t need to understand much more than the basics of CAN asking degree students to program CAN systems in C may be more of a final year project than a learning exercise. 26

Part 3 - CAN system demonstration Node ID00, data 85. At this point in the presentation I make a demonstration of how you can sue Flowcode to construct CAN systems and how we can use The packet analyser to see the traffic on the CAN network. 27

Part 4 LIN bus Node ID00, data 85. 28

LIN status report We are just starting out with LIN We know what we want and how to do it we are just not finished yet Here is what we currently have: 29

LIN bus 3 wire bus GND. +2V and LIN Low data rate, low reliability Saves $0.5 per node on CAN Additional panel on the CAN solution will cover LIN We are in the process of developing a LIN bus board for E-blocks. This will work in much the same way as the CAN board with high level macros for Flowcode. 30

Adds 3 programmable LIN nodes to the CAN solution High level macros in Flowcode not yet available LIN bus add-on The LIN bus connects to the CAN bus (node 4 on the CAN bus becomes a CAN/LIN bus node) to provide 3 LIN nodes. Flowcode macros are under development that allow students to gain experience of LIN. 3