Simplifying CAN Automotive Applications with Highly Integrated 8-bit MCUs



Why 8-bit MCUs and CAN form an effective team

Designed for the automotive industry in the mid-1980’s, the controller area network (CAN) protocol addressed and continues to address the need to reduce the wiring complexity (weight, amount and cost) for data transmission in increasingly interconnected applications.

The advantages of CAN have also been embraced and adopted in other markets including factory automation and medical applications, so extensively that well over 1 billion CAN nodes are shipped worldwide each year. Similarly, over 1 billion 8-bit microcontroller units (MCUs) are shipped annually. While today there is some overlap in these statistics, that should increase considerably in the future.

…these 8-bit MCUs provide an alternative to 16-bit MCUs that are more expensive and more difficult to program.

CAN Continues to Meet Carmaker’s Needs
Traditional CAN communications are event-based, allowing microcontrollers and application specific integrated circuits (ASICS) to directly communicate with each other in applications without a host computer. The integration by semiconductor companies has greatly added to CAN’s cost-effectiveness and compatibility with many automotive systems. Since the early 2000’s, 8-bit MCUs have also included the CAN protocol. More recently an 8-bit MCU design approach, initially introduced in 2015, uses Core Independent Peripherals (CIPs) to allow a new family of 8-bit MCUs to address many system aspects in CAN applications.

In addition to its cost-effectiveness, CAN’s success can be attributed to its:

  • Robustness
  • Reliable data transmission
  • Rather simple implementation

Not surprisingly, 8-bit MCUs also have these same attributes in addition to their cost-effectiveness. So, 8-bit MCUs with CAN are a natural combination to address many automotive networking requirements.

Over the years, CAN has proven to be capable of meeting a variety of control system requirements. As automotive networks increased to require different attributes including time-triggered, fault-tolerant and single-wire implementations, as well as CAN with flexible data rate (CAN FD), CAN specifications expanded. Table 1 shows many of the CAN variations that have occurred since its initial introduction over 30 years ago.

Table 1: CAN adaptations can meet a variety of automotive needs.

For networking sensors and actuators to comfort systems, automotive engineers have used the local area network (LIN) protocol to reduce costs. However, LIN, a single-wire, master-slave network, requires both hardware and software changes from CAN. Some of the newest automotive applications for CAN include access control, battery charging/battery management, and diagnostic equipment. These and other vehicle requirements, especially those that require access to data from another CAN control system, are driving the use of 8-bit MCUs/CAN. Figure 1 shows the easy addition of an 8-bit MCU/CAN node to an existing CAN bus.

Figure 1: Different CAN implementations can coexist and add to the flexibility of the CAN bus.

Solving Low-Cost Networking Requirements Using an 8-Bit MCU with CAN
While connecting to the CAN bus is the minimum capability that system designers need, added peripherals that specifically address other system requirements simplify the designer’s task. Those system tasks could include sensing a parameter or two for control purposes, moving a motor, activating a solenoid, or providing some other functions.

The CIP approach can reduce software complexity and deliver faster response times at lower clock speeds while using less power. Broad system categories for CIPs in Microchip’s PIC18 K83 family include:

  • Intelligent analog (including sensor interface)
  • Waveform control
  • Timing and measurements
  • Logic and math
  • Safety and monitoring
  • Communications
  • Low power and system flexibility

Within these categories, specific peripherals include:

  • Cyclic Redundancy Check (CRC) with memory scan to ensure the integrity of non-volatile memory
  • Direct Memory Access (DMA) to enable data transfers between memory and peripherals without CPU involvement
  • Windowed Watchdog Timer (WWDT) for triggering system resets
  • A 12-bit Analog-to-Digital Converter with Computation (ADC2) for automating analog signal analysis for real-time system response
  • Complementary Waveform Generator (CWG) for enabling high-efficiency synchronous switching for motor control

In addition to working with CAN 2.0B, the integrated CAN controller is fully backwards compatible with previous CAN modules (CAN 1.2 and CAN 2.0A). The products’ capabilities include the Memory Access Partition (MAP) to support designers in data protection and bootloader applications. Device Information Area (DIA) provides a dedicated memory space for factory-programmed device ID and peripheral calibration values.

Since communications are a primary goal for CAN nodes, the 8-bit MCUs have improved serial communications, including UART with support for Asynchronous and LIN protocols as well as higher-speed, standalone I2C and SPI serial communication interfaces. Table 2 shows the 15 CIPs and how they address specific system requirements.

Table 2: Core Independent Peripherals in PIC18 K83 family address several system requirements.

Thanks to these on-chip structures that were not thought of or implemented in 8-bit MCUs in the past, today’s 8-bit MCUs can perform quite differently than many designers have come to expect and deliver much more than MCUs designed over a decade ago.

Programming an 8-bit MCU is simple and easy and with the CAN plus CIPs, it is even easier. When they provide sufficient processing power, especially for remote nodes, these 8-bit MCUs provide an alternative to 16-bit MCUs that are more expensive and more difficult to program. With CIPs, even more processing power is available, enabling more 8-bit MCU options.

The highly configurable on-chip hardware modules handle repetitive embedded tasksmore efficiently and deterministically. Thanks to the deterministic nature of CAN, if an MCU gets caught in a loop, one with CIPs can still continue operations outside of the core.

With the newest 8-bit MCUs/CAN+CIPs, as well as LIN, network designers now have more flexibility and options for implementing CAN and LIN communications. In fact, some typical 8-bit MCU LIN applications are now potential CAN applications. For example, if the module needs to be aware of other data on the network, such as vehicle speed, CAN may be a better choice or at least an option to LIN. This can be useful for windshield wipers that can change their speed based on the vehicle’s speed to avoid a CAN to LIN gateway. In addition, the system-level CIPs may avoid the need for an additional ASIC or two, as shown in Figure 2.

The same PWM and complementary waveform generator CIPs have been used for years to do fairly complex, multi-color LED mood lighting in vehicles. Those drivers were connected to a LIN bus because the MCUs did not have CAN. The combination of that functionality in a cost-effective 8-bit MCU with CAN could provide flexibility and a simplified alternate approach to the design.

While most 8-bit MCUs on the market rely heavily on the core for processing its peripheral’s functions, other system design possibilities that can be performed by CIPs without significantly taxing the CPU include: precision interface to various sensors, high-power LED driver and/or a reasonably complex level of motor control.

To determine which of these and other possibilities are appropriate for a specific network, a variety of development tools are available. For example, the MPLAB® Code Configurator (MCC) is a free software plug-in that provides a graphical interface to configure peripherals and functions specific to the application. With this tool, system design engineers can easily configure the hardware-based peripherals—rather than writing and validating an entire software routine—to accomplish a specific task.

Developing a CAN-Do Attitude
For automotive and industrial applications, system designers certainly have several choices for bus architectures. As a widely accepted bus, and certainly when additional sensing and/or control are required for an existing network, an MCU with additional functions to address different system requirements makes CAN an excellent option. With its Core Independent Peripherals, the 8-bit MCU/CAN family allows CAN expansion into more cost-sensitive nodes on the network.

The new 8-bit MCU/CAN+CIPs address emerging automotive network applications that require flexible, cost-effective, simple, and reliable robust data transmission. Present too are the increased performance and system support that access control, battery charging/battery management, and diagnostic equipment demand.

References

  1. PIC18 K83 Product Family: http://www.microchip.com/promo/pic18f-k83
  2. MPLAB Code Configurator (MCC): http://www.microchip.com/mplab/mplab-code-configurator

Edwin Romero began working in the semiconductor industry in 2006. Prior to joining Microchip Technology in 2012, he worked in various roles at ON Semiconductor, including application engineer, and in technical sales and marketing. As a product marketing manager within Microchip’s MCU8 Division, Romero is currently responsible for product definition and promotion of Microchip’s 8-bit PIC® microcontrollers. He has a Bachelor of Science degree in Electrical Engineering (BSEE) degree from Arizona State University.

 

Share and Enjoy:
  • Facebook
  • Google
  • TwitThis

Tags:

Extension Media websites place cookies on your device to give you the best user experience. By using our websites, you agree to placement of these cookies and to our Privacy Policy. Please click here to accept.