Among various devices, display devices play an important role. Without display devices, it is like a person without eyes. Many internal things cannot be seen. Display devices are very important and common, but their appearance is always so monotonous, like models. The rotating LED screen has attracted the attention of electronic enthusiasts with its novelty and 360° viewing angle. This project combines touch technology with the rotating LED screen through the main control chip STM32F103, which can realize the clock change. You can also use touch technology to play some small games on the rotating LED, so that the rotating LED is no longer just a single ornamental technology.
The rotating LED display screen is a new type of display screen that realizes graphic display by synchronously controlling the position and lighting state of light-emitting diodes (LEDs). It has been rapidly developed due to its novel structure, low cost and 360° visual angle. At present, common LED display screens are displayed in a scanning manner. The implementation principle is to control different batches of LEDs to light up in turn in different time periods. According to the visual persistence characteristics of the human eye, when the scanning frame rate reaches more than 24Hz, the human eye cannot feel the scanning process, but a stable image. The rotating display screen realizes the display of graphics by controlling a row or a column of LEDs to quickly move their positions and change the lighting state. If the LED changes rapidly at each position, a stable image can also be displayed. The POV principle (i.e., the visual retention principle) is used for display screens. The advantage is that a small number of LEDs can be used to realize a display screen that can only be realized by a large number of LEDs in traditional methods. The LED is controlled by a single-chip microcomputer, and the touch button provides user interaction with the system. The landscape of the rotating LED floating in the air brings visual enjoyment.
Based on this situation and principle, this paper proposes a design of a rotating LED screen display controller based on TI's TLC5947 driver chip and STM32F103. The rotating LED screen adopts the principle of human visual frequency retention. The rotating LED virtual screen made by the microcontroller can fully realize a new display technology that can only be achieved by a large number of LEDs in the traditional way with a small amount of LEDs under the precise control of the microcontroller. The rotating three-primary color full-color LED is based on the RGB principle. By changing the hue, saturation and intensity of the three colors, a maximum of 36 colors of true color picture display can be achieved, making the display more gorgeous and dazzling. Compared with flat-panel LED display screens and other display technologies (such as CRT, LCD, PDP), the rotating linear array LED screen has several obvious advantages such as low cost, high resolution and low power consumption.
1 System hardware design
STM32F103 is connected to LED through TLC5947 to control the display of LED lights on the rotating board. For example, the single-chip microcomputer STM32F103 can be used to control the LED lights to rotate and display the clock appearance or various graphics. If conditions permit, some simple games can be displayed. The LED is connected to the ARM processor, and the ARM processor processes the touch signal to change the display style of the LED light, from the base state pointer clock to the digital display style and change the display background, and can also perform time calibration operations. The TLC5947 drives the rotating LED screen display control circuit as shown in Figure 1.
1.1 Introduction to STM32F103
The STM32F103 controller was selected. The STM32F103 is an enhanced series with a maximum operating clock frequency of 72 MHz. It has an ARM Cortex-M3 core, 128-256 KB Flash, 20-48 KB RAM, 8 MHz CPU crystal, 32.768 kHz RTC crystal, and abundant peripherals (64 fast I/O ports) and 4 GB linear address space. The emulator used by ARM is very expensive, while the debugging tools for microcontrollers are very cheap. In contrast, the Cortex-M3 reference microcontroller uses a pin specifically for debugging, thus saving a lot of manpower and material resources. The Cortex-M3 integrates most of the memory controllers, so that the Flash can be directly connected to the outside of the MCU, reducing the design difficulty and application barriers. The Cortex-M3 processor combines a variety of breakthrough technologies, enabling it to achieve a combination of low power consumption, low cost, and high performance (or two). The programming supports ISP download function and can be powered by USB port and JLINK emulator, which is very convenient to use.
1.2 Introduction to TLC5947
TLC5947 is a 24-channel 12-bit PWM pulse width modulation LED driver chip launched by TI (Texas Instruments). TLC5947 adopts ultra-small 32-pin QFN advanced package. It provides accurate constant current value for LED, and the difference between channels and chips is only ±2%; high-speed transmission rate (30 MHz for single chip, 15 MHz for cascade); interleaving time delay between output channels to avoid transmission errors; the chip has a temperature detection system inside. When the temperature of the chip is too high, in order to protect the chip, it will automatically disconnect all output channels. When the temperature returns to normal, the chip will work normally; the chip supports cascading, and multiple chips can work together to drive a larger LED display screen. The current value of the 24 channels is set by the resistance between the external IREF and the ground. The resistance in the drive circuit is determined by the current of the driven LED lamp. The chip has a wide operating voltage range of 3.0 to 5.5 V and contains a 4 MHz internal crystal. TLC5947 is suitable for driving full-color LEDs and displays.
1.3 LED display screen
Use three-color (RGB) LED lights to achieve multiple color light sources and colorful output. At the same time, the LED itself also has considerable stability, high efficiency, high single color purity, and adjustable light intensity. The LED is connected to the ARM processor, and the ARM processor processes the touch signal to realize the change of the display style of the LED light, from the base state pointer clock to the digital display, and change its display background. It can also perform time calibration operations.
2 System software design
2.1 Design of point point-line-circle and its algorithm and formula
Point design mainly uses rectangular coordinates to circular coordinates to light up the lights at any position through coordinate conversion. Line design is derived from point design. On the basis of point design, Bresenham straight line algorithm is used to draw the required straight lines, oblique lines, and curves. Based on line design, rectangle painting, drawing, filling and other functions are derived.
After the program is initialized, the conversion from rectangular coordinates to polar coordinates is defined. In the program, radians are converted to degrees. When converting, negative data is considered. 360+ 0.5 is added to optimize the program to prevent errors. Distance and angle in the program
The algorithm for converting
rectangular
coordinates to circular coordinates is as follows:
After the rectangular coordinate conversion is completed, the light and dark of the point can be set, and then the Bresenham straight line algorithm is used to draw a straight line.
The overall flow of the program is shown in Figure 2. After the system is powered on, first read the initial state of the system, set the working state of ARM and TLC5947, and start wireless communication; then wait for the rotating screen to stabilize, initialize the menu, and wait for input commands; use Qtouch to control the transmission of commands to STM32F103 and execute commands (user interaction process); execute user command operations.
2.2 TLC5947 chip timing
The TLC5947 timing is shown in Figure 3. The chip has four main control pins: data input terminal SIN, external clock input terminal SCLK, grayscale register control terminal XIAT and output control terminal BLANK. The required grayscale data is sent to the SIN terminal through the data input port, and then the data is written into the grayscale data shift register inside the chip by controlling the clock signal SCLK. After that, the high and low level conversion of the grayscale register control terminal XLAT is used to update the internal grayscale data of the chip TLC5947. When the level of the XLAT pin changes and a rising edge is generated, the internal grayscale data of the TLC5947 will be updated once, that is, the data will be rewritten in the Grayscale LatchData in Figure 3. The data output of the chip is divided into two parts, one is the serial data output and the constant current source data output. The serial data output is connected after the grayscale data shift register. When the data in the register is full of 256 bits, the data can be output from the serial data port SOUT through a DQ trigger according to the change of the SCLK clock. This port is mainly the data input of the next chip when the chip is cascaded; and the constant current source data output OUT0~OUT23 is jointly controlled by the output control port BLANK and the chip's internal clock Oscillator Clock. The output current can be controlled by the external ground resistor of the chip's VREF pin, and the normal operation of the LED is guaranteed according to the current limiting parameters of the external LED. The system uses a 3.2 kΩ resistor, so the control of the chip is mainly the control of the 4 pin ports, which is relatively simple and convenient to operate.
3 Conclusions
In the experiment, two cascaded TLC5947 chips were tested through the main controller STM32F103. The peripheral circuit was connected to a three-color LED light. The external power supply voltage was a 5 V voltage regulator. After the conversion, the system power supply voltage was a 3.3 V voltage regulator. When the corresponding program control word was written, the three-color LED light could be displayed correctly, and both the single-color and mixed-color working modes were successfully realized. Moreover, the change time between LED lights can be controlled by the program. As long as the clock frequency of the main controller is appropriate, the change time is beyond the recognition ability of the human eye. In this way, the design of a full-color LED screen can be realized by changing different program control words.
Previous article:The difference between LED backlight, LED and OLED imaging technology
Next article:NXPSSL2103 14W dimmable LED driver solution
- Popular Resources
- Popular amplifiers
- Design paper of dot matrix electronic display screen
- [资料]-JIS B0907-1989 Mechanical Vibration of Rotating and Reciprocating Machinery-Requirements for In
- [Information]-JIS B0905-1992 Rotating machines-Balance quality requirements of rigid rotors.pdf
- [资料]-JIS Z 2286:2003 Method for high temperature rotating bending fatigue testing of metallic materi
- MathWorks and NXP Collaborate to Launch Model-Based Design Toolbox for Battery Management Systems
- STMicroelectronics' advanced galvanically isolated gate driver STGAP3S provides flexible protection for IGBTs and SiC MOSFETs
- New diaphragm-free solid-state lithium battery technology is launched: the distance between the positive and negative electrodes is less than 0.000001 meters
- [“Source” Observe the Autumn Series] Application and testing of the next generation of semiconductor gallium oxide device photodetectors
- 采用自主设计封装,绝缘电阻显著提高!ROHM开发出更高电压xEV系统的SiC肖特基势垒二极管
- Will GaN replace SiC? PI's disruptive 1700V InnoMux2 is here to demonstrate
- From Isolation to the Third and a Half Generation: Understanding Naxinwei's Gate Driver IC in One Article
- The appeal of 48 V technology: importance, benefits and key factors in system-level applications
- Important breakthrough in recycling of used lithium-ion batteries
- 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
- Q and D values of capacitors
- [Nucleo G071 Review] PWM breathing light
- [EETalk] Why do smart homes not use ZigBee but are keen on Bluetooth and Wi-Fi?
- Selection of the discharge resistor of the X capacitor
- Help on ADN8834 burning out
- Double 11 development board recommendation: MSP430 LaunchPad
- Characteristics and research analysis of wireless communications with examples
- 【RT-Thread Reading Notes】Reading Notes for Chapters 1~4
- A look inside the U.S. Army's counter-artillery radar system
- Qorvo Broadband Access CATV and FTTH Product Selection Guide