LPC2478 arm7 core, after chip reset, the clock and power of timer 0 and timer 1 are turned on by default, but timer 2 and timer 3 are turned off by default, so there is no statement to turn on the clock and power in the program for initializing timer 0 and 1. Then I looked at some reference materials and found that the initialization of timer 2 and timer 3 was not given either. I was very curious about why the code that was not run dared to be sold as information (NXP LPC2478 development board CD information). So much nonsense, post the code, long memory.
//Init TIMER3 to measure PG inf
void Time3Init(void){
PINSEL5&=(~(3<<14));
PINSEL5|=(2<<14);//CAP3.1 P2.23
PCONP |= (1<<23);//Open TIME3 power and clock
T3CTCR = (1<<0) | (1<<2); //Config T3 as a Counter, counting on rising edge of CAP3.1 pin
T3TC=0; //reset T3
T3TCR=0; //Stop Counting
}
Previous article:STM32 timer writes precise delay function
Next article:LPC2478 Timer 1 2-way PWM configuration
- Popular Resources
- Popular amplifiers
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- LED chemical incompatibility test to see which chemicals LEDs can be used with
- Application of ARM9 hardware coprocessor on WinCE embedded motherboard
- What are the key points for selecting rotor flowmeter?
- LM317 high power charger circuit
- A brief analysis of Embest's application and development of embedded medical devices
- Single-phase RC protection circuit
- stm32 PVD programmable voltage monitor
- Introduction and measurement of edge trigger and level trigger of 51 single chip microcomputer
- Improved design of Linux system software shell protection technology
- What to do if the ABB robot protection device stops
- Huawei's Strategic Department Director Gai Gang: The cumulative installed base of open source Euler operating system exceeds 10 million sets
- Download from the Internet--ARM Getting Started Notes
- Learn ARM development(22)
- Learn ARM development(21)
- Learn ARM development(20)
- Learn ARM development(19)
- Learn ARM development(14)
- Learn ARM development(15)
- Analysis of the application of several common contact parts in high-voltage connectors of new energy vehicles
- Wiring harness durability test and contact voltage drop test method
- Working Principle of SRAM Circuit
- STM32 pin short circuit to ground analysis
- [ART-Pi Review] 1: Demo Experience
- DSP core + coprocessor
- Fundamentals of Electronic Components and Practical Circuits (Revised Edition)
- Mastering Verilog HDL: Detailed Examples of IC Design Core Technologies.part01.rar
- PCI bus interface design based on FPGA.pdf
- Double gifts are waiting for you! In 2022, let Infineon understand you better!
- Tuya Smart Module SDK Development Course Series - 5. Secondary Development of Modules
- The following points should be noted when selecting semiconductor discharge tubes