Dimming of the LED drive circuit can be achieved by a variable duty cycle (pulse width modulation or PWM) method. The PWM method can make full use of the function of the LED , because the larger the current, the larger the LED light output at a specific power (temperature) level. Therefore, after the PWM current is applied across the LED, the average power consumption of the output is equivalent to the average power consumption generated by the DC control method, but the operating current is larger and the light output is higher.
Even if the available control signal is a DC signal, PWM control can be implemented with a simple circuit with predictable performance and good linearity. This circuit consists of a dual comparator and some external components. It uses a 0~5V control signal to generate a 500Hz PWM signal with a nonlinearity of 2% and an adjustable duty cycle of 0~100% (see Figure 1).
Figure 1: Converting a 0~5V DC control signal into a PWM signal to drive the LED circuit diagram.
The "OUTB" end of the comparator is configured as an oscillator operating at around 500 Hz. The positive input produces a triangular wave with an amplitude of approximately 1/10 of the supply voltage. The "OUTA" terminal of the comparator compares the triangular wave with the DC control signal and generates a PWM signal at the OUTA terminal. The PWM generator and DC control signal generator should use the same +5V power supply.
The oscillator frequency (f) can be adjusted by changing the capacitance of the capacitor C. f = 6345 / RC, where R is in kΩ, C is in μF, and f is in kHz. In order to make the frequency of the circuit of this example 500 Hz, take C = 0.47 μF and R = 27 kΩ.
Figure 2 shows the circuit response of the PWM duty cycle as a function of the DC control signal level.
Figure 2: The PWM duty cycle versus control voltage shows that the circuit has a linearity of approximately 20%.
(Text / Maxim Integrated Products Company Ahmad Ayar)
The pin refers to the connection between the internal circuit of the integrated circuit (chip) and the peripheral circuit, and the pin constitutes the interface of the chip. According to the function, the pins of AT89S52 can be divided into four categories: main power supply, external crystal oscillator or oscillator, multi-function I/O port, and control, strobe and reset.
Terminal Pins,Terminal Hardware Pin,High Precision Terminal Pins,Terminal Pins For Pcb
Sichuan Xinlian electronic science and technology Company , https://www.sztmlchs.com