Automobile electronic combination instrument based on single chip microcomputer

Publisher:RadiantBreezeLatest update time:2013-03-06 Source: 21IC Keywords:MCU Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
The instrument is the interactive interface between people and cars. It provides drivers with the required information such as car operating parameters, faults, mileage, etc. It is an indispensable part of every car. The intuitive and beautiful display of the instrument makes driving not only a necessity for transportation, but also a part of comfortable life. The accuracy and reliability of parameter transmission are directly related to the safety of car driving.

The most prominent feature of modern instruments is the modularization of functions. Usually, to assemble an instrument, you only need to combine several functional modules on the basis of a customized PCB to get a complete system. The pointer instruments of economical cars such as Changan are generally independent modules, and the prompt/alarm function is completed by a small light bulb on the PCB. The pointers of the SANTANA series are driven by a cross coil on the printed circuit board, and the prompt/alarm lights are all light-emitting diodes. The main data, sources and corresponding display methods displayed on the dashboard of the car are as follows (based on SANTANA2000):

Table 1

It can be seen that the current automobile instruments are still mainly mechanical, and the communication method is mainly wire harness. The biggest drawback of this model is that it is too dependent on wire harness, which leads to complex systems.

With the rapid development of the automobile industry, the automotive electronics market, which still has great potential, is increasingly attracting the attention of major automobile manufacturers and electronic product suppliers, including clean energy vehicles that are still in the development and experimental stage, car audio equipment that is currently dominated by ***, promising car computer information terminal equipment, and various in-vehicle electronic control units, such as engine electronic control units, ABS, buses, new electronic instruments, etc.

For automobile instruments, the advantages of using electronic instrument panels over traditional instruments are:

the softwareization of hardware functions
With the development of microelectronics technology, the processing speed of microprocessors is getting faster and faster. Some functions that have high real-time requirements and were originally completed by hardware can be completely realized by programming microprocessors. The

system integration is greatly improved
. Today, with the rapid development of large-scale integrated circuit technology, the density of integrated circuits is getting higher and higher, the size is getting smaller, the internal structure is getting more and more complex, and the functions are getting more and more powerful. As some functional hardware of the instrument is constantly replaced by software, the integration of the entire system is also increasing accordingly.

This design is a car combination instrument panel based on Freescale microcontrollers. The design is aimed at the traditional cars that currently dominate the market, and uses the instrument of Changan car as a template. The main purpose is to realize a low-end solution for the combination of electronic dashboards in cars.

1. Design Overview

The objects of this solution mainly include vehicle speed, rotation speed, pressure, temperature, mileage, time and some prompt/warning light signals, which are respectively reflected in the speedometer, engine tachometer, oil pressure gauge, water temperature gauge (pointer) and odometer. Among them, the odometer records the vehicle speed signal regularly, performs numerical integration during the driving time, and obtains the mileage, which is saved in the user Flash as mileage. The mileage data is accumulated regularly (1s).

Since this design is aimed at popular traditional cars, cost becomes the most important criterion for device selection. In the selection of microcontrollers, we did not consider the CAN bus, which has a bright future but is not yet popular, but chose the 8-bit microcontroller LJ12 with built-in LCD driver.

MC68HC908LJ12 is a member of Freescale's 908 microcontroller family. Its main parameters and functional modules are as follows:

• 8M maximum bus frequency;
• 12k user Flash;
• 512b RAM;
• Two independent dual-channel timer modules;
• Internal real-time clock, which can record year, month, day, hour, minute and second;
• SCI and SPI communication modules;
• 6-channel 10-bit A/D;
• LCD module, which can drive 27×3 or 26×4 segment LCD modules.

The stepper motor driver chip MC33970 is a member of the Freescale analog family. It contains 6 registers, which are written by SPI command status words, namely configuration/calibration register, pointer speed register, pointer 0/1 position register, pointer return to zero register, and return to zero setting register. Features of MC33970:

• Compatible with MMT certified two-phase stepper motors;
• The pointer can stay in 4095 stable positions;
• Maximum rotation angle 340°;
• Maximum acceleration 4500 deg/s2;
• Maximum speed 400 deg/s;
• Simulated microstepping (pointer movement 12 steps for 1°);
• Pointer calibration and zero return;
• SPI control, 16-bit command word;
• Internal calibration clock;
• Low current in sleep mode. [page]

2. Hardware Description


Figure 1

LJ12 chip has rich hardware resources inside, we have made the following configuration:

• PLL: external crystal oscillator 32.768k; internal bus frequency multiplied to 4M;
• SCI: used for host computer communication, bit rate 9600, interrupt mode;
• SPI: clock 1M, as the control of MC33970, use two general pins as SPI chip select signal;
• LCD: use 26×4 mode, that is, 26 front poles and 4 back poles, dynamic drive; because the design uses a 6-bit LCD module, it is enough to use FP1~FP12 and BP0~BP3;
• Flash: use the resident memory function (ROM-Resident Routine) to save the mileage data in the user flash memory in the form of 32-bit data.

The stepper motor produced by SWITEC is selected as the actuator. The six-bit segment-type dynamic drive LCD module is used to display the mileage, single mileage or time and date. Out of habit, the car instrument needs to be kept powered at all times, and there is no need to reset the time parameters. In order to facilitate the demonstration, two buttons are used to switch the LCD display mode. The six LEDs are used to display brake, danger, oil pressure, battery, engine and neutral information respectively. MC1413 is used as the driver of the LEDs. MC33970

is directly driven by the SPI of the microcontroller; the vehicle speed and engine speed are pulse width modulation signals or input from the serial port. The frequency is obtained through the input capture function of the timer module and converted into data.

(1) The power supply and power-off protection

input uses 7805. In order to save the mileage data in time when the power is off, a 1000uF or two 470uF electrolytic capacitors are added to the power ground input. When the power is disconnected, an interrupt signal will be generated at the IRQ pin. The large capacitor can maintain the power supply of the microcontroller for a long enough time so that the microcontroller can complete the service program of the external interrupt.

(2) Conditioning circuit

In order to improve the waveform, a conditioning circuit is added outside the timer pin.

(3) Overall design

This design is aimed at the low-end and medium-end cars on the market. In order to express this original intention, the instrument PCB is designed according to the instrument shell and internal dimensions of Changan sedans, and the layout is re-designed.


Figure 2 System Block Diagram

3. Software Description

(1) Initialization function:

Multiply the internal bus frequency to 4M; Set the channel of the timer module to the capture function; SCI baud rate 9600, open the receive interrupt; SPI clock frequency 1M; LCD module 26×4 mode; Enable the Real Time Clock module; MC33970 and pointer initialization; Read the previously recorded mileage data from the user Flash and display it according to the ODO/TRIP signal.

(2) Interrupt service program:

• External interrupt: Use the discharge of a large capacitor to return the pointer to zero in a short time after power failure.
• SCI interrupt: Follow a certain host computer protocol, accept commands, change the LCD display content; change the vehicle speed and speed data.
• RTC interrupt: Record mileage data once a second; Convert mileage data according to the vehicle speed signal.

(3) Main function

: Read mileage data regularly and display it on the LCD; Restart WATCHDOG at the end of each main loop; Respond to changes in the pointer position when the vehicle speed or speed signal changes.


Figure 3 Main program flow chart [page]

The following is a simple comparison between the stepper motor driver chip x15.089 and MC33970 produced by SWITEC, and then draws a conclusion.

Excellent performance

The following table is a performance comparison of the two, among which the good real-time response is the biggest advantage of MC33970:

Table 2 Comparison of performance of stepper motor driver chip x15.089 and MC33970

Compact structure
The working principle of x15.089 is to control a stepper motor with two pins of the microcontroller, one of which outputs the direction control signal and the other outputs the pulse. Therefore, two microcontroller pins are required to control each motor, and eight microcontroller general IO ports are required to control four motors.

MC33970 is different. It can control two stepper motors by inputting command words through SPI. When four stepper motors are needed, two MC33970s are used, but only one chip select signal is needed. In this way, only SPI modules and two general IOs are needed, thus saving the resources of the microcontroller.

Competitive cost (data obtained from www.freescale.com)
The price of the microcontroller LJ12 is RMB20 per piece for more than 10,000 pieces, and because of the built-in LCD control driver, there is no need to add an external LCD driver such as SED1335.

The price of MC33970 is $1.3, RMB13 per piece for more than 10,000 pieces, which is cost-effective.

In comparison, the price of a SWITEC stepper motor 312.017 is about RMB18, and the price of a driver chip x15.089 is about RMB16.

The following is a simple table of cost estimates:

Table 3 Cost estimate summary

From the above, we can see that in the case of mass production, as a fully digital system, its total cost is less than RMB150, about RMB120-140, which is quite competitive.

4. Conclusion

This solution is a low-end solution for automotive electronic instrument panels based on Freescale microcontrollers, targeting various economical cars, with complete functions, compact structure, and low price. It will have broad market prospects. (end)
Keywords:MCU Reference address:Automobile electronic combination instrument based on single chip microcomputer

Previous article:Application of ATmega16L ISP Technology in Automotive Electronic Differential Control
Next article:New Concept Design of Single Chip Microcomputer Controlled Motorcycle Ignition Device

Recommended ReadingLatest update time:2024-11-16 17:44

Low power MCU design concept
    Where does MCU power consumption come from?     Before discussing low-power MCU design, we must first explore the sources of MCU power consumption, which mainly consists of static power consumption and operating power consumption. Considering the actual application, the average power consumption must be calculated
[Microcontroller]
Low power MCU design concept
Design of an intelligent induction lamp based on single chip microcomputer
introduction As energy becomes increasingly scarce, the main consideration for product design is energy saving. Design that can save energy and make reasonable use of electricity should be the main goal of product design. At the same time, the development direction of lighting fixtures has gradually shifted
[Security Electronics]
Design of an intelligent induction lamp based on single chip microcomputer
Design of proportional remote control system based on single chip microcomputer STCl2C2052AD
    Remote control technology, also known as remote control technology, refers to the remote control of the controlled target. It is widely used in industrial control, household appliances, radio sports, children's toys and other fields. Remote control technology can be divided into single-channel remote control and m
[Microcontroller]
Design of proportional remote control system based on single chip microcomputer STCl2C2052AD
51 MCU Tutorial from Scratch - Part 6 Delay Program Analysis
Master the delay program in assembly In the last class, we already know that the symbols R7 and R6 in the program represent RAM units, which are used to store some data. Now let’s take a look at the meaning of other symbols. DELAY: MOV R7,#250   ;(6) D1: MOV R6,#250   ;(7) D2: DJNZ R6,D2    ;
[Microcontroller]
51 MCU Tutorial from Scratch - Part 6 Delay Program Analysis
DC motor PID control speed source code based on STC15 single chip microcomputer chip
STC15W4K56S4 MCU PID controls the speed of the DC motor. The following is a picture of the actual product: The motor runs smoothly after power on L298N controls motor speed STC control panel   The microcontroller source program is as follows: #include "STC15W4K56S2.h" #include "Counter1.h" #include "USART.h" #
[Microcontroller]
DC motor PID control speed source code based on STC15 single chip microcomputer chip
Do I need to buy a development board for self-study of microcontroller? How do beginners use microcontroller development boards?
It can be said that 99% of the old engineers who are engaged in microcontroller development, or the new microcontroller software engineers, have bought development boards, or have been using development boards to engage in microcontroller development. Some people may question this statement. If you question it, then y
[Microcontroller]
MCS - 51 Series Microcontroller Interpretation
  MCS — 51 MCU Series   By process:   ◆ HMOS process products: such as 8031, 8051, 8751, etc.;   ◆ HCMOS process products: such as 80C31, 80C51, 87C51, etc.; classified by ROM type:   ◆ ROM type products,   ◆ PROM type products, 8051   ◆ EPROM products, 87C51, 87C52   ◆ Flash products: AT89C51, AT89C52   (II) Internal
[Microcontroller]
Design of portable color adaptive recognition circuit based on single chip microcomputer
Color recognition is an important research direction in the field of pattern recognition. The use of color recognition technology can fundamentally change the traditional method of color discrimination based on human eyes. This new technology uses color sensors to obtain external color information, and then
[Security Electronics]
Design of portable color adaptive recognition circuit based on single chip microcomputer
Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号