when switching leds you can use either gpio or pwm
gpio,14,0 (led off)
gpio 14,1 (led on)
pwm,14,0 (led off)
pwm,14,500(led on at certain level)
so i should either use gpio or PWM but not both for the same gpio pin (unless i reset pwm with pwm,14,0 first)
what happens if you use them together
eg
pwm,14,500
gpio,14,0
gpio,14,1
regardless if this will work can this damage the esp chip?
simple pwm question
Moderators: grovkillen, Stuntteam, TD-er
Re: simple pwm question
It will stop sending PWM and switch to GPIO mode.
So giving a GPIO command is also usable to turn off a PWM signal.
Just keep in mind that sending a high DC signal to something like a speaker, may not be a good idea, so always keep that in mind when you switch modes like this.
So giving a GPIO command is also usable to turn off a PWM signal.
Just keep in mind that sending a high DC signal to something like a speaker, may not be a good idea, so always keep that in mind when you switch modes like this.
Re: simple pwm question
thanks
i am going it only to dim leds so it should be safe
i am going it only to dim leds so it should be safe
Who is online
Users browsing this forum: No registered users and 127 guests