1 Principle of infrared remote control system
The structure of infrared remote control circuit is generally divided into three types, namely: single-channel remote control switch circuit, single-channel step-by-step remote control circuit and multi-channel remote control circuit. This design adopts a single-channel remote control switch circuit. This infrared remote control system is generally composed of two major parts: transmitting and receiving. The transmitting part generally includes a pulse generator, a pulse power amplifier and an infrared transmitter. The receiving part generally includes infrared reception, voltage amplification, limiter amplification, bistable trigger and relays. Some also use special remote control integrated circuits to simplify the structure. This remote control system is mainly composed of switch control buttons, timing data input buttons, brightness control buttons, timing control circuits, display circuits, infrared transmitting circuits, infrared receiving circuits, brightness control and execution circuits, etc.
2 Hardware Circuit
2.1 Switch Control
This part mainly realizes remote control to turn on or off the light, which is a button. When the button is pressed, the infrared transmitting part emits an infrared pulse, which is received by the infrared receiving part and causes the relay to change its original state, turning the light from on to off or from off to on.
2.2 Timing part
This part mainly includes: input and processing of timing data, timing circuit and time display circuit.
The input of timing data adopts the working mode of non-coded keys, where "0~9" are number keys, "H" is the hour key, and "Y" is the confirmation key. The circuit diagram of this part is shown in Figure 1.
Figure 1 Timing time input
The timer uses a subtraction counter. The initial input data is given by the lower 4 bits of the P0 port of 89C51. After decoding and inversion by P2.7 and P2.0, it is latched on the set end of the corresponding counter CD4069 and displayed by the decoding display device CL002. At the same time, the subtraction count starts. When the RP is adjusted to about 2.4 M, NE555 will generate a 60 s pulse. The unit of control data is min, and the left side is the low bit. When it is reduced to all 0, the counting stops and a low level is output to the infrared transmitting part. The transmitting part emits infrared pulses, which are received by the infrared receiving part to flip the switch part, thereby changing the original state of the bulb to achieve timing control. The timing circuit is shown in Figure 2. The display part is CL002, which is a CMOS-LED combination device integrating storage, decoding and display. Its function is equivalent to a CD4543 or CD4511 plus a common cathode digital tube. The use of this combination device can simplify the circuit structure.
Figure 2 Timing circuit
2.3 Brightness Control Circuit
The circuit of this part is shown in Figure 3. It consists of infrared receiving and preamplification, pulse recognition, electronic analog switch, electronic analog potentiometer and other parts.
Figure 3 Brightness control circuit
The infrared receiver and preamplifier use the μPC1373 dedicated integrated circuit. When the SB1 key of the infrared transmitter circuit is pressed, the infrared transmitter circuit will emit a long pulse or a short pulse according to the length of the key press time. The pulse is received by BA5204 and outputs a high level at the 4th pin of BA5204. After inversion, it is sent to the 7th pin of μPC1373 for pulse recognition processing. The pulse recognition circuit uses an integrated six-phase inverter CD4069, in which the part input from the 1st pin and output from the 4th pin is a short pulse recognition circuit, and the short pulse reduces the brightness. The part input from the 13th pin and output from the 6th pin is a long pulse recognition circuit, and the long pulse increases the brightness. The electronic analog switch uses a four-way analog conversion switch CD4066. The electronic analog potentiometer uses an N-channel field effect tube VMOS tube, which is a voltage-controlled device. It uses the gate voltage to control the drain current, that is, to control the channel resistance. This feature can be used to treat the field effect tube as a voltage-controlled variable resistor.
2.4 Infrared Transmitter Circuit
The circuit diagram of this part is shown in Figure 4 (a). The infrared remote control transmitter uses the BA5104 special coding integrated circuit, where pins 1 and 2 are the user code selection terminals to prevent remote control by others. Pin 3 is connected to pin 6 of the output terminal 74LS27 of the timing circuit, and pins 4 and 5 are connected to the brightness and switch control buttons respectively. When any one of pins 3 to 5 has a low level, the LED immediately emits modulated infrared light, and the emission frequency is controlled by the crystal oscillator between pins 12 and 13.
Figure 4 Infrared transmitting and receiving circuit
2.5 Infrared receiving part
The circuit of this part is shown in Figure 4 (b). BA3502 is an integrated infrared receiver. BA5204 in the receiver is a device used in conjunction with the transmitter BA5104. Its operating voltage is 5 V. The linear regulator LR6 with high input voltage and low output current without a transformer converts 220 V AC into 10 V DC, and then converts it into 5 V power supply through 7805. When any key of SB1 or SB2 of BA5104 is pressed or the third foot receives a low level, the corresponding port of BA5204 outputs a high level. When released, the port returns to a low level. The time to maintain the high level is the same as the time of pressing the key. SK-II in the figure is a voice-controlled integrated circuit. The signals output by the third and fifth feet of BA5204 are input to SK-II by C2. After amplification, frequency selection, shaping, and delay by the internal circuit, they are sent to the trigger and flipped. The 9th foot outputs a low level, which turns on VT3 and the relay J is attracted to turn on the power control switch. When the control signal is received for the second time, the 9th foot of SK-II outputs a high level, VT3 is cut off, the relay is released, and the power is disconnected.
3 Software Design
The software design mainly involves designing the key processing program. The key processing program uses the interrupt mode, and the interrupt uses the external interrupt 0. When a key is pressed, it will cause an interrupt to the microcontroller, and the microcontroller will execute the key processing program to determine the type of key pressed and make corresponding processing. The key processing program flow chart is shown in Figure 5.
Figure 5 Key processing program flow chart
4 Conclusion
The infrared remote control lamp head system based on single chip microcomputer realizes the switch, timing and brightness adjustment control of the lamp head, which makes people's life more convenient and realizes the special requirements of lamp head control in some cases. The remote control system works stably and reliably, with the maximum effective control distance of 8~10 m and the longest timing time of 16 h.
Previous article:Hardware circuit diagram of automatic shearing machine control system based on single chip microcomputer
Next article:Design of Intelligent Community Monitoring System Based on Single Chip Microcomputer
- High signal-to-noise ratio MEMS microphone drives artificial intelligence interaction
- Advantages of using a differential-to-single-ended RF amplifier in a transmit signal chain design
- ON Semiconductor CEO Appears at Munich Electronica Show and Launches Treo Platform
- ON Semiconductor Launches Industry-Leading Analog and Mixed-Signal Platform
- Analog Devices ADAQ7767-1 μModule DAQ Solution for Rapid Development of Precision Data Acquisition Systems Now Available at Mouser
- Domestic high-precision, high-speed ADC chips are on the rise
- Microcontrollers that combine Hi-Fi, intelligence and USB multi-channel features – ushering in a new era of digital audio
- Using capacitive PGA, Naxin Micro launches high-precision multi-channel 24/16-bit Δ-Σ ADC
- Fully Differential Amplifier Provides High Voltage, Low Noise Signals for Precision Data Acquisition Signal Chain
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- New real-time microcontroller system from Texas Instruments enables smarter processing in automotive and industrial applications
- Triangle wave generating circuit
- [RT-Thread Reading Notes] Part 2 (1) Porting, Running and Thread Management
- Are you confused about gate driver selection? Download the latest selection guide
- Wish you all a happy Dragon Boat Festival
- Using MCU to implement speech recognition? MSP432 can do it!
- Lead Angle/Conduction Angle of Brushless DC Motor
- FIR filter design based on FPGA (source code download attached)
- The timing relationship between voltage and current lead and lag
- LSM6DSO MicroPython driver porting
- Keil C51 MCU Programming Software and Instructions Learning Tutorial (Full Version)