Design of car grille scanning light based on single chip microcomputer STC89C52RC

Publisher:WhisperingSoulLatest update time:2011-03-13 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
Abstract: With the continuous improvement of living standards, cars have gradually entered thousands of households. The pursuit of fashion and individuality has made car owners do their best to dress up their cars. The LED car grille scanning light can not only show personality, but also serve as a warning. It even has a nice name called Ranger Light. This article introduces the design and production method of a car grille scanning light. It mainly uses the common STC89C52RC microcontroller as the main controller, uses a photocoupler for signal conversion, and uses the piranha LED light strip purchased on the market to modify it into eight groups of LED scanning lights. It can produce effects such as tailing and breathing, and can also expand functions such as chassis lights and wireless remote control.

0 Introduction

The rapid development of the LED industry has brought a great impact on lighting and decoration, especially the combination of LED and automobiles is a hot topic at present. LEDs are gradually appearing in the reading lights, width lights, brake lights, and even headlights in cars. Of course, as decorative instrument lights, scanning lights and chassis lights are not far behind. This article introduces the design and production of an LED scanning light.

1 System Configuration

This system consists of a high-brightness LED light bar and a car network scanning light controller. The controller also includes a logic control (microcontroller minimum system) part, a power supply part, a power drive part, and a circuit delay part. The specific block diagram is shown in Figure 1.

System Block Diagram

Figure 1 System Block Diagram

2 Circuit Design

Figure 2 is the logic control part of this design, which adopts the classic 8051 microcontroller minimum system, model STC89C52RC. The most convenient thing about the STC series of microcontrollers is that they only leave out the pins of P3.0 and P3.1. The program can be downloaded to the microcontroller through the serial port RS232 circuit of any experimental board, which is convenient for future modifications and upgrades of the work and also provides convenience for debugging.

It should be noted that the 31st pin of the MCU must be connected to a high level, otherwise the MCU will not read the memory in the chip, causing the MCU to not work. Although the 40-pin MCU is a bit too large, the pins are brought out with pins to facilitate future function expansion.

Logic control unit

Figure 2 Logic control unit

Figure 3 is the power supply part of this design. Because it involves powering the high-brightness LED light strip and the microcontroller separately, the power supply needs to have two voltage outputs: 12V and 5V.

The voltage of the car battery is about 12.5V. The LED light strip can be powered directly by 12V. The microcontroller needs to be converted to 5V by 7805. In order to enhance the safety of the car circuit, a fuse is added to the power circuit.

J2 is the car power input, the positive pole can be connected to the positive pole of the car width indicator light, and the negative pole can be connected to the metal part of the car structure. J1 can be used to lead out the control switch, or directly short-circuit with a jumper cap.

Power supply

Figure 3 Power supply Figure 4 is the focus of this design. There are three groups of structures similar to Figure 4. The main device is a photocoupler. The model can be EL817. They can achieve electrical isolation and control the 12V light bar with the signal of the single-chip computer. Two groups are selected, and the input end is connected to P2.7~P2.0 as the signal control end of the scanning light. It is used to control the eight groups of lights LED1~LED8 in the LED light bar.

It is worth noting that the input end of the optocoupler is very fragile and needs to be connected to a current limiting resistor when connected. The other end of the optocoupler can be connected to a group of LED light strips to form a loop with the 12V power supply, which is equivalent to the switch circuit controlled by the internal LED in front.

The capacitors C2 to C5 in the figure act as a delay circuit. When the optocoupler is turned on, the LED group lights up, and the capacitor is connected to the 12V power supply for charging. When the optocoupler is turned off, the capacitor and the LED group form a discharge circuit to keep the LED group from going out immediately. The tailing effect of the scanning light is achieved by this circuit.

The third group of four optocouplers is used for expansion functions.

Schematic diagram of this design

Figure 4 Schematic diagram of this design

Figure 5 shows the signal output port of this design, where the signal output from J5 is used to control eight groups of car scanning lights, and the four groups of LED signals output from J4 are used to expand chassis lights or breathing lights. J9 is connected to the P3 port of the microcontroller to expand wireless remote control or communication modules.

This design signal lead port

Figure 5 Signal output port of this design

Figure 6 is a reference PCB layout diagram. The use of a single-sided copper-clad board increases the difficulty of wiring and requires a large number of flying wires. If a double-layer board is used, the layout problem can be simplified a lot. In Figure 3, RX can use a 75-ohm high-power resistor. Because the design uses a four-pin optocoupler, and the optocoupler is a component that may fail, a 16-pin IC socket is used in the package. In this way, each socket can install four optocouplers.

Reference PCB layout diagram

Figure 6 Reference PCB layout

3 Component Selection

It is recommended to use silicone insulated wires of appropriate thickness for connecting to the car power supply, which can withstand high temperature and high current. The fuse can be 1A or 2A.

Select EL817 as the optocoupler. Be sure to connect a current limiting resistor to the input of the optocoupler. Be careful not to burn out the optocoupler due to excessive current when doing experiments. As a capacitor for delayed energy storage, choose a high-quality 330UF or 470UF large capacitor. 4 Installation and Debugging

This design is easy to debug. You only need to write the program of the water light or sample light into the microcontroller. The data is output from the P2 port, which is the port connected to the scanning light control optocoupler. It should be noted that the delay setting in the program should be modified according to the actual flashing light effect. As long as the time is selected appropriately, a trailing effect like a flame will be produced. In the test, a voltage of 12.5V is selected, and the maximum current is only 150mA.

5. Notes

The car is moving, and the temperature of the engine compartment is also high. Therefore, the installation environment of this design is a high temperature and vibrating environment. Pay attention to shockproof and heat dissipation during installation. The power supply is taken from the car's width indicator light, so the scanning light can work as long as the dashboard is lit.

6 Conclusion

This article uses concise ideas to realize the simple application of LED and single-chip microcomputer, providing personalized decoration for your car and adding color to your life.

Attachment: Experimental works pictures:








Reference address:Design of car grille scanning light based on single chip microcomputer STC89C52RC

Previous article:Design of intelligent pneumatic pump control system based on single chip microcomputer (Figure)
Next article:Design of wind speed and direction detection system 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号