Here in this project we will combine two projects one is fading of LED light and second one is reading the analog value of pot-meter. Then resultant we will control the LED light with variation in the value of pot-meter.
Application:
We can control the speed of DC motor.
We can control the position of solenoid valve.
And some other related to this application
Circuit diagram:
Calculation of factor:
A little bit calculation to manage the values of Analog read
with PWM output.
Analog reading pin internally have 10bit of ADC so it means
that
Vin (max) = 5v
Converted into 10bit digital means 0000000000 to 1111111111
from 0 to 1024
And PWM range is 0 to 255 so simple to fine the factor
Factor = 1024/255
Simulation of PICSimLab:
If you like my post then like share and comment if any Question
No comments:
Write commentsI am very thankful for your precious time