Controller Area Network (CAN) Tutorial

This course will guide you through the basics of Controller Area Network (CAN), CAN channel setup, reading and storing data from a CAN network, sending data on to the network with Dewesoft X2.

Share on linkedin
Share on facebook
Share on email
Share on print

This course will guide you through the basics of Controller Area Network (CAN), CAN channel setup, reading and storing data from a CAN network, sending data on to the network with Dewesoft X2.

Vehicle subsystems from the internal combustion engine to powered windows are controlled by electronic control units (ECU). These units are usually dependent of each other and have to pass information between one another.

For example a control unit in the car’s automatic gearbox shifts gears based on engine revolutions per minute and throttle position. Control unit in automatic transmission runs an algorithm that determines if the gear change is required based on the data that it gets from the engine control unit (engine speed (RPM), throttle position, emission sensors…). To ensure smooth gear shifting engine speed has to be adjusted to the next gear. Therefore both control units have to constantly communicate with each other to ensure correct operation.

Another example are powered windows in a road vehicle. Their upward and downward motion is controlled by an electronic control unit. This control unit switches the electric motor in the correct direction and also stops the electric motor when the window is in the fully closed or fully opened position. The electronic control unit gets messages to move windows from other control units. For example it can get an order from a control unit that checks the position of dashboard buttons or from a unit that receives signals from a vehicle remote control. Each of the mentioned control units performs its task and signals other control units to perform a task that is required from them. The messages can go either way. For example the window control unit can send a message back to other control units that the window is fully closed or fully opened.

As we can see from the previous example a single unit works only if it is connected to other units. Message transfer between units could be made with direct connections based on the dependency of electronic control units.

Electronic control units connected based on information flow between them

Electronic subsystems on modern road vehicles are usually controlled by more then 150 ECUs. These control units are highly dependent of each other and are connected to a single or multiple serial networks.

On a serial network data is being transmitted bit by bit onto a network. Each device can read all of the messages on the network but responds only to those that are meant for it. To ensure that critical messages get to their recipients with the least possible delay message priority is based on message importance.

Electronic control units connected on to a serial bus

Communication networks in modern road vehicles connect all of the electronic subsystems together. With transfer speeds of up to 10 Mb/s large amounts of data can be generated. With Dewesoft, we can decode and store this data.

Dewesoft device connected on to a serial bus

Controller Area Network (CAN) is the most widely used communication protocol in automotive applications. It was developed to replace complex wiring harnesses with a two-wire bus. CAN network consists of nodes – electronic control units (ECU) that are connected on to a two wire bus. Any electronic device with a CAN interface can be connected on to a network. 

Messages on CAN aren’t passed directly from node to node but are transmitted on to the network. Messages each have their unique message identification number which is also used to determine message priority. CAN network can operate without a central control node, message hierarchy is not based on nodes but on the messages that they transmit. Therefore, one node can transmit both high and low priority messages.

Error in message transmission is checked by all of the nodes that are connected to the network. If one of the nodes detects an error in message reception it sends a special error message on to the network. A node that originally sent the message has to retransmit it.

Different versions CAN configurations are defined by ISO standards. Normally there are two configurations used in automotive applications. High speed CAN is used for communications between critical subsystems that require high update rates and data correctness (anti lock braking system, electronic stability control, airbags, engine control unit…). Data transfer speeds of high speed CAN ranges from 1 kbit to 1 Mbit per second. Low speed CAN is used for fault tolerant systems that do not require high update rates. Their maximum data transfer rate is limited to 125 kbit per second but their wiring architecture can be more economical. In automotive applications low speed CAN is normally used for diagnostics, dashboard controls and displays, power windows…

During CAN bus operation additional nodes can be connected on to it. Dewesoft devices with CAN interfaces act like additional nodes on the CAN network. Dewesoft devices can read and also write data on to the CAN network.

CAN message types

There are four different message types/frames that can be transmitted on to the CAN network

  1. Data frame
    A message that transmits data through the CAN network. It is the most common message type on the network. Message consists of:
    • arbitration field – field that contains the message identification number and remote transmission request bit. More important messages have lower ID numbers, when multiple nodes want to transmit at the same time they start a simultaneous arbitration. A node with the lowest message id number wins. The message identifier can be 11 bit (Standard CAN, 2048 different message identifiers) or 29 bit in length (Extended CAN, 537 million different message identifiers). The remote transmission request bit is dominant and signals that data is being transmitted,
    • data field – field in length from 0 to 8 bytes that holds data,
    • crc field – cyclic redundancy check field, shows if there were any mistakes during message transfer,
    • acknowledge field – every node changes this field if it received a message without any errors.
  2. Dewesoft X can read or transmit data frames. It only needs message identification numbers and lengths of data fields of each data message. All of the other frames are automatically taken care of by Dewesoft devices and software.
  3. Remote frame
    The purpose of the remote frame is to request a message from another node. By structure it is similar to the data frame. The difference is that it doesn’t contain any data and has a recessive remote transmission request (RTR) bit which signals a message request from another node.
  4. Error frame
    Error frame is a special frame that violates CAN formatting rules and signals an error in data transmission. A node that detects an error while reading the message on the network transmits an error message. Because an error frame violates CAN formatting rules all of the nodes that were reading from the network retransmit it. After that a node that originally transmitted a message with an error has to retransmit the original message.
  5. Overload frame
    It is similar to the error frame with regard to formatting. It is transmitted by a node that becomes too busy. It is primarily used as an extra delay between messages.
Brandi Fruge

Brandi Fruge

Inside Sales Engineer

Office Phone: 720-822-4119
Email: brandif@vicmyers.com

Brandi grew up in Katy, Texas.  She graduated from Colorado School of Mines with her Mechanical Engineering Degree in 2015. She previously worked for Schlumberger as a field engineer on frac locations across Texas, Oklahoma, Pennsylvania and more. In her free time, she enjoys traveling, snowboarding, binge watching Netflix and spending time with her dog, Duke.

VMA Staff

TRACY GROSSMAN

Field Engineer

Tracy was raised in Arizona and served in the USAF as an Electronic Warfare Technician, completing an Electrical Engineering Technology Journeyman degree from Community College of the Air Force. After the Air Force he worked as a technician before getting his Bachelors in Computer Information Systems at the University of Phoenix. Tracy worked as a Computer Systems Engineering consultant before joining Orbital Sciences (now Northrop Grumman) in 2002, where he worked as an Electrical Engineer for 15 years designing and deploying systems to test and launch rockets. Tracy specialized in Telemetry Ground Systems for several years before becoming the Lead Electrical Engineer on the Antares Ground system design team. After Orbital, he worked as an Embedded Systems Sales Engineer, helping customers find the best solutions to solve complicated design requirements. Starting July 2019, Tracy is on Team VMA as a Field Engineer to continue building relationships and helping engineers find innovative solutions for high-reliability applications. Outside of the office he enjoys spending time with his wife and adult children and his hobbies include Trucks, Hiking, Camping, Hunting, Scuba diving, Motorcycling and church.

KEENAN GRIFFIN

Field Engineer

Keenan was born and raised in Milwaukee, Wisconsin. Graduated from the University of Denver with his Electrical Engineering Degree with a Specification in Mechatronic Systems. With the need to problem solve and the love to work with people, Keenan has worked in technical sales for the manufacturing, construction, and security industries. From going outside to hike, snowboard, golf, run, or grill to staying inside to cook, read, or simply relax by sitting down to watch a good movie, Keenan loves to spend as much time as possible with his friends and family.

CHRISTIE WHITEHEAD

Field Engineer

Christie Whitehead Is married and has raised 3 beautiful children, one girl and 2 boys. Her passions are children, education, technology and volunteering. She helped open a Charter school from the ground up in 2000 that is now a top 100 school in the nation year after year. Christie has her bachelor’s degree in Electrical Engineering Technology. She has been in many technology engineering positions and thrives on solving problems. She strives to always add value, have patience and care for others. She loves technology and complexity of the things people are designing. She loves to get into the lab, sharing experiences and knowledge that may help her customers.

SIERRA BISHOP

Inside Sales

Sierra has been with VMA for 3 years.  She previously worked in law enforcement/emergency dispatching for over 9 years.  She is currently going back to school get a bachelors degree in Art and Graphic Design.  She loves travelling and enjoys doing anything ‘artsy’, but especially loves watercolor and oil painting.  When she can she likes to catch a good live theater show.

KRISTIN HALL

Sales Administration

Kristin has been a part of the Vic Myers Associates team for five years now. Prior to her position as Inside Sales and Administration, she worked in the Construction Industry as a Project Manager. Needless to say, she has learned a lot here at VMA, and enjoys being a part of this company. In her free time, she values singing at church, card-making, and spending time with her husband and family.

RON GARCIA

Inside Sales

Office Phone: 505-884-6878
Email: rong@vicmyers.com

Ron has worn several hats at VMA over the past twenty years, including inside sales, IT guru, webmaster and application engineer. As a recent empty-nester, Ron and his wife are spending more time on the road, exploring the Southwest. He is an avid sci-fi enthusiast, enjoys playing guitar and listening to jazz.

VMA Staff

JIM BARNETT

Inside Sales

Office Phone: 480-345-6449
Email: jimb@vicmyers.com

Jim was born in Michigan but has lived in Arizona longer than most natives. He graduated from Arizona State University with a B.S. in Computer Information Systems and holds certifications in Network Administration and Network Security. Jim originally joined Vic Myers Associates in 1991 and has held a variety of positions. Among his interests are hiking, travel, and most things vintage including cars, music, architecture, and artifacts.

MARK MYERS

Field Engineer, Legend

There a few experiences in my life which I consider invaluable. They include earning my Boy Scout Eagle rank with considerable help and inspiration from my father, serving in the United States Submarine Service during the Viet Nam war, earning a black belt in a mixed style martial arts (it took me 25 years), completing a masters degree (16  years),  becoming a lifelong learner, being engaged in my faith, and ending up with some really good friends.  Professionally, I love being a helper, an ally, a facilitator, a problem solver and someone who is passionate about wanting my friends, my customers and my colleagues to be successful.  Life can be hard, life can be unfair and life can be extraordinary, all at the same time.

VMA Staff

CARLTON DAVENPORT

VP of Administration

Office Phone: 505-884-6878
Email: abq@vicmyers.com

Carlton has traveled and lived all over the U.S. but chose Albuquerque as his home. Carlton and Nancy have raised 3 daughters, grown up and making their own lives now. He joined VMA in 1991 and is responsible for the day-to-day business side, supporting our sales efforts, doing whatever it takes.

BOB BISHOP

Field Engineer, Area Manager

Bob was raised in Minnesota. Graduated from Minneapolis Technical College with an A&P license. He worked at Rosemount Inc. for a few years and moved to California where he met his wife and gained valuable experience having sold to the test ranges, military bases, and contractors. Bob has been in Colorado selling to the same customers for over 25 years. He enjoys muscle cars, hockey, travel, golf and singing at his church.

RYAN CHRISTIAN

Field Engineer, VP

Ryan was raised in Mesa, Arizona, attended Gilbert schools and graduated from ASU in 2006 with a Bachelors in Interdisciplinary Studies. He went on to complete his MBA at the University of Phoenix Campus in Mesa. Prior to VMA, Ryan worked 5 years as a consumer sales consultant and then 5 years as Analyst at Orbital Sciences, now Northrop Grumman.   Outside of the office, Ryan loves to spend time with his wife, 10yr old daughter and twin 5 year old boys. Ryan loves to get outdoors to hunt & fish as often as possible, serves frequently with kids and adults at church and enjoys quality BBQ time with his friends and family.

Can’t find what you’re looking for?