principle:
Due to the residual vision characteristics of the human eye: when the human eye observes the scene, it takes a short period of time for the light signal to be transmitted to the brain nerves. After the effect of the light ends, the visual image does not disappear immediately. This residual vision is called "afterimage", and this visual phenomenon is called "persistence of vision".
Example:
The lights we use at home are 50Hz, turning on and off 50 times in one second, but we feel that the lights are always on.
However, the degree of brightness and darkness depends on the ratio of the time of light and no light, but the duration of light and dark cannot exceed 1/24 second (the longest visual residual time)
programming:
#include typedef unsigned int u16; typedef unsigned char u8; sbit LED=P2^0; //LED void delay(u16 i) { while(i--); } void main() { while(1) { u16 and; for(i=10;i<=2000;i=i+10) { LED=0; //Low level lights up delay(i); LED=1; //High point off delay(1000); } for(i=2000;i>=10;i=i-10) { LED=0; //Low level lights up delay(i); LED=1; //High point off delay(1000); } } }
Previous article:Ultrasonic distance measurement based on 51 minimum system
Next article:Design of running water lamp based on 51 single chip microcomputer
- Popular Resources
- Popular amplifiers
- AN OPTICAL METHOD FOR MEASURING BLOOD GLUCOSE NON INVASIVELY
- Detailed I2C interface SI114 datasheet for proximity/ambient light sensor chip
- Multi-channel pressure measuring instrument based on C8051F020 single chip microcomputer
- Design of automatic player for work and rest signal based on 51 single chip microcomputer
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- 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
- Analysis of Typical Anti-Reverse Connection Circuits for Automotive Electronics
- Consulting employment
- [Runhe Neptune Review] Four network communications
- EEWORLD University Hall----What can universal fast charging bring?
- Complete learning manual for using RT-Thread on RISC-V (based on Longan development board)
- How does Tbox protect itself to ensure data security? What good methods can you recommend?
- Byte/word alignment issues in DSP
- Pre-registration for the live broadcast with prizes: Cytech & ADI discuss with you Gigabit digital isolators for video, converters, and communications
- GPIO Operation of TMS320C6748
- Gigabit Ethernet Courseware.zip