Design of Automotive Cluster Meter Using Nuvoton Microcontrollers
In the article “Automotive Cluster Meter Development Using Nuvoton’s Microcontrollers – Introduction“, we’ve discussed the component selection criteria for designing instrument clusters and how Nuvoton’s microcontrollers can be used in the development of instrument clusters. This article describes the guidelines for designing a digital instrument cluster with Nuvoton’s M0A23 and N9H30 series of controllers. It also provides an overview of power supply design, external components and safety requirements to use in instrument cluster applications.
Instrument clusters need to provide driver with all the critical information required for a safe and comfortable drive like vehicle status and direction, indicate gear status, provide feedbacks such as turn left, right, oil temperature etc., and sound alarms.
This article is segregated into two sections: one based on the Nuvoton’s M0A23 with all the inputs processing sections, and the other on how the data is communicated in the LCD using Nuvoton’s N9H30. Below is the basic block diagram of instrument cluster with all the input and output peripherals.
Following are the modules of the instrument cluster that will be discussed in this article
- M0A23 Section
o M0A23 circuit design guide
o Protection circuits
o Power supply design
o Interface modules
- N9H30 Section
Note: The schematics shown in this document are provided for reference purposes only.
If you use any part of these schematics as a basis for hardware design, do so at their own risk; TECHDesign does not assume any liability for such a hardware design.
2. M0A23 Section
This section talks about the protection circuits, DC-DC converter section, and the design guidelines of M0A23 and also the interface modules to M0A23.
2.1 M0A23 circuit design guide
As a designer, the first step in designing the electronics product is to list down the inputs and outputs of the system along with the current requirements of each section. M0A23 series controllers provide the below options to interface with the external devices.
|Part Number||Flash (KB)||SRAM (KB)||ISP ROM (KB)||I/O||Timer||PWM||PDMA||Connectivity||DAC||LXT||ACMP||ADC (12-Bit)||Package|
As per the block diagram shown in Figure 1, below are our requirements to design an instrument cluster.
|Pin No.||Pin Configured as||Function|
|17||PD.4||Switch Input 01|
|18||PD.5||Switch Input 02|
Nuvoton offers NuTool – Pin Configure tool which contains all Nuvoton NuMicro® Family chip series with all part numbers, and helps configure GPIO multi-function pins correctly for the users.
Guidelines for M0A23 circuit design
The circuit below in Figure 2 shows the power supply connections to the M0A23 microcontroller and the serial wired debugger for programming the microcontroller. As per recommendation the VDD pin should be connected to +5V and decoupling capacitance of 0.1uF needs to be placed as close as possible to the pin.
The high-speed external (HXT) clock can be supplied with a 4 to 24 MHz crystal oscillator. For instrument cluster application, the external components have to be placed as close as possible to the XT1_IN and XT1_Out pins. Refer to the selected crystal resonator manufacturer for details on the resonator characteristics (frequency, package, accuracy) and in order to minimize output distortion and startup stabilization time.
For C3 and C4, it is recommended to use high-quality external ceramic capacitors in 10 pF ~ 20 pF range, designed for high-frequency applications. The crystal manufacturer typically specifies a load capacitance which is the series combination of C3 and C4.
For instrument cluster application the M0A23 can be operated in normal mode and idle mode. The table below shows the difference between two modes and how the CPU operates during each mode.
|Power Mode||Normal Mode||Idle Mode|
|Definition||CPU is in active state||CPU is in sleep state|
|Entry Condition||Chip is in normal mode after system reset released||CPU executes WFI instruction.|
|Wake-up Sources||N/A||All interrupts|
|Available Clocks||All||All except CPU clock|
|After Wake-up||N/A||CPU back to normal mode|
2.2 Protection circuits
Protection circuits for automotive applications must safeguard the electronic control unit (ECU) without failure during harsh condition. The circuit designer must ensure reliable circuit operation in this severe transient environment. The transients on the automobile power supply range from the severe, high energy, transients generated by the alternator/regulator system to the low-level noise generated by the ignition system and various accessories. The figure below shows an automotive environment on how the power is delivered to the instrument cluster.
Below are the protections required for any automotive ECU’s:
When battery terminals are disconnected, the car battery connection can be reversed by mistake, which will create a negative voltage across the input of the instrument cluster. Most of the ICs are not rated for withstanding the negative voltage.
A reverse protection diode or MOSFET is typically used to protect circuits against this condition.
During cold weather conditions the starter draws a high current to turn on the engine which results in reduced battery voltage. During this condition, expectations of the system is to provide continuous, stable output regulation for a short duration. To achieve this DC-DC converter with a wide VIN range can be used to address low input voltage condition.
Load dump is the surge in voltage generated when the battery is disconnected while the alternator is still connected to other electronic loads. This can occur when the battery is accidentally disconnected while the vehicle is running.
Guidelines for protection circuit design:
Protection circuit can be designed using any automotive AEC Q100 qualified components. For example, an ideal diode controller which can operate in conjunction with an external N-channel MOSFET as an ideal diode rectifier can be used reverse polarity protection. And for the Transient protect, TVS diodes can be used. The input range of 3.2 V to 65V is well suited for severe cold crank requirements in automotive systems. The device should withstand and protect the loads from negative supply voltages down to –65 V.
2.3 Power supply design
For this instrument cluster application based on our architecture, we need 5V, 3.3V, 1.8V and 1.2V supply. The block diagram below shows the strategy to convert the 12V battery power supply into the required voltage levels as per application requirements.
One of the important and first steps in any circuit design is to derive the power budget calculations. Based on the I/O of the system we need to calculate the no load current, full load current and sleep mode current to effectively design the product. Optimal design of the power section is very critical in product design, at the same time the power source should be able to provide required current to the end devices in all worst-case conditions.
As shown in above block diagram schematic, power supply can be designed for converting the battery input voltage to 5V supply and subsequently for 3.3V, 1.8V and 1.2V supply which can be derived from the 5V supplying using the low dropout regulators.
Based on the application requirements, we need to appropriately size the converters and achieve the current consumption targets. While considering current consumption derating of components plays a vital role, each and every component has to be considered for derating analysis and then only the current requirements should be derived. Then based on the power, topology should be selected on whether to use switched regulators or the Linear regulators.
Below are the general guidelines during PCB design for switched/Linear regulator IC:
- While designing the PCB for the regulator sections all the components associated to the IC should be placed as close as possible.
- Switching regulator IC ground impedance should be very low to avoid unstable out during EMI/EMC testing.
- Switching regulator IC land pattern should be wide as much as possible for proper power dissipation.
- Heat dissipation pads to be designed based on thermal calculations.
- Regulators should not be placed on edge of PCB to avoid ESD spikes.
2.4 Interface modules
This section briefs on what are the interfaces of the instrument cluster connected to the M0A23 microcontroller and design guidelines.
2.4.1 Speed sensor signal conditioning module
The purpose of this module is to sense the speed signal from vehicle and give it to the microcontroller for displaying the information in the TFT LCD. Speed sensor in most of the vehicles is of Hall sensor type which has a rectangular wave output. The input voltage to the sensor is given from ignition or the battery power supply, the sensor module which is inline with the circuit start sinking the current and thereby giving the rectangular wave output when the wheel starts rotating.
As shown in above schematic, the sensor is connected to the ignition input and resistor R84 limits the current to the sensor and the voltage divider are sized appropriately at two stages so that the voltage to the microcontroller is not over the limit. Also a diode is used to clamp the voltage to 5V.
The challenge in this section is the collector output taken from the sensor should withstand high and low frequency noises and capacitors should be sized accordingly.
2.4.2 Oil temperature sensor signal conditioning module
In most of the vehicles, we have an oil temperature switch, which is of a resistive type. Whenever the switch is closed due to high oil temperature the instrument cluster should notify a warning to the driver.
As shown in above schematic, whenever the oil switch is closed resistors R88 and R89 acts as a voltage divider and the resultant voltage is given to the microcontroller ADC pin which compares the data and sets the warning in the instrument cluster.
2.4.3 Battery monitoring, ignition monitoring & ignition sensing module
The purpose of this module is to monitor the battery and ignition voltage levels to initialize the memory and whenever there is a drop in voltage than the threshold value, we can configure the microcontroller to save the current process; or whenever the voltage is above threshold, we can wakeup the microcontroller from sleep mode. The ignition sensing input is directly connected to the microcontroller interrupt pin.
This is achieved with simple voltage divider circuit is used to stepdown the ignition and battery voltage from 12V to 5V and send the voltage to the ADC pin of the microcontroller where the ADC compares the voltage with the lower limit threshold value.
2.4.4 Fuel Sensor module
Fuel sensor module indicates the customer level of fuel in the tank and helps in determining when to refill the tank. Mostly float type fuel sensors are used. When the float is moved due to change in fuel levels, the wiper moves across the resistor. And causing change is voltage which is then processed at the controller section and displayed to the driver. Below schematic is an example of fuel sensor interface circuit with M0A23.
2.4.5 Oil Pressure Sensor module
Oil pressure sensor module is to alert the driver whenever the oil pressure in the vehicle drops below the threshold limit. An engine running with low oil pressure can quickly damage the engine. Based on the active low input from the vehicle side, the microcontroller detects the change in state of the oil pressure switch and turns on the alert signal.
2.4.6 Ambient Light Sensor module
Ambient light sensor module automatically adjusts the backlighting of the instrument cluster in the vehicle according to varying lighting conditions. It is used to improve the user experience and also reduce the power dissipation in the LEDs.
2.4.7 CAN communication module
All the critical information from the instrument cluster are shared to the other ECUs via CAN communication module. Ideally the high speed CAN transceiver should be used in automotive applications. It needs to support the differential bus signal representation described in the international standard for in-vehicle high speed CAN applications (ISO11898). This CAN transceiver can be connected directly to our M0A23 series controller and accessed. Below schematic shows the typical application circuit of the CAN transceiver section.
2.4.8 UART Module
All the data collected in the M0A23 is sent to N9H30 to be displayed on the LCD. This is done via UART communication. In order to achieve the communication, the UART0 channel of the M0A23 is directly interfaced with UART0 of the N9H30 for the data transfer.
3. N9H30 design guidelines
For this instrument cluster design, we are going to use N9H30 microprocessor specifically for GUIs as the N9H30 embeds an outstanding CPU core ARM926EJ-S, and meet the hardware, software, and architectural requirements of a typical instrument cluster. The N9H30 series integrates a DRAM interface that runs up to 150MHz, supporting DDR and DDR2 type SDRAM. This, in turn, reduces the overall BOM cost of needing an additional external SDRAM. N9H30 provides MCP (Multi-chip package) to ensure higher performance and to minimize the system design efforts.
Determining the graphical requirements of instrument cluster is also essential in defining the right architecture and component selection. For example, below are the fundamental criteria to be considered during display interface design.
a. Calculating the required frame buffer size and location.
b. Checking the compatibility of framebuffer memory bandwidth requirements vs. the TFT LCD because refreshing the LCD display can require a large amount of bus bandwidth.
N9H30 supports resolution up to 1024 X 768 and SDRAM with a programmable refresh rate. The refresh and power-on control module generates the refresh request signal and SDRAM power-on sequence. The SDRAM controller also supports software reset, SDRAM self-refresh, and auto power-down function.
|Core Operation Voltage||VCORE_VDD||1.1399999999999999||1.2||1.26||V|
|I/O Operation Voltage||VIO_VDD||2.97||3.3||3.63||V|
|DDR I/O Operation Voltage||VDDR_VDD||1.7||1.8||1.9||V|
|Pin No.||Pin Configured as||Signal||Function|
|111||PB6||SPIO_SSO||SPI Flash Interface|
|123||PC0||NAND_D0||NAND Flash Interface|
Guidelines for N9H30 circuit design
The general guideline on the decoupling capacitance requirements is to use a 0.1uF capacitor between each VDD/VSS pair and a stabilizing 10μF capacitor. Improved stability on the power supplies may be achieved by placing a pair of capacitors at each pin pair, but the best results are achieved by placing the capacitor as close as possible to its microcontroller pin. Designers need to be sure to consider the capacitor ESR characteristics while selecting the capacitor part number.
The high-speed external (HXT) clock can be supplied with a 4 to 24 MHz crystal oscillator and for low speed it is 32.768KHz. For instrument cluster application, the external components have to be placed as close as possible. Below are the recommended values for external low speed and high-speed crystal.
|Crystal||ESR (mohm)||Cx, Cy|
|12 MHz - External High-speed Crystal||< 50||14 pf|
|32.768 KHz – External Low speed crystal||<50||20pF|
Memory and storage Management:
In order to interface with higher resolution displays, an external Quad-SPI Flash memory with up to 128 Mbytes addressable memory-mapped can be used to store graphic primitives.
This article serves as a starting point for developing an instrument cluster using Nuvoton’s M0A23 and N9H30 series microcontrollers. Modern day instrument clusters require many more inputs and data processing, which can be designed using Nuvoton’s offerings based on the application requirements.
List of references