SOLVED: Possible error: analogWrite/PWM from Arduino IDE
Posted: Wed Nov 25, 2015 6:47 pm
Using analogWrite(GPIO, value) to a GPIO pin gives a PWM signal that can be used for instance to fade LEDs.
It has 10 bit resolution, input values ranging from 0 through 1023.
So far so good.
However, I see instabilities for the highest values:
1023: OK, gives a flat signal
In the range 1022 down to around 1010 the signal becomes unstable, with short bursts of wrong pulses at seemingly random intervals from half a second to several seconds.
From around 1010 and downwards, it seems to be stable.
Has anyone else seen this?
I think it might be an error in the Arduino IDE compiler, as I am running several LED faders programmed with LUA, and I have never seen this issue on those modules.
It has 10 bit resolution, input values ranging from 0 through 1023.
So far so good.
However, I see instabilities for the highest values:
1023: OK, gives a flat signal
In the range 1022 down to around 1010 the signal becomes unstable, with short bursts of wrong pulses at seemingly random intervals from half a second to several seconds.
From around 1010 and downwards, it seems to be stable.
Has anyone else seen this?
I think it might be an error in the Arduino IDE compiler, as I am running several LED faders programmed with LUA, and I have never seen this issue on those modules.