mirror of
https://github.com/esp8266/Arduino.git
synced 2025-04-22 21:23:07 +03:00
fix pwm first step getting skipped
This commit is contained in:
parent
897a475fdb
commit
1d2237bc9d
@ -103,7 +103,7 @@ void ICACHE_RAM_ATTR pwm_timer_isr(){
|
|||||||
current_step = 0;
|
current_step = 0;
|
||||||
stepcount = 0;
|
stepcount = 0;
|
||||||
if(pwm_mask == 0) return;
|
if(pwm_mask == 0) return;
|
||||||
T1L = (pwm_steps[current_step+1] * pwm_multiplier);
|
T1L = (pwm_steps[current_step] * pwm_multiplier);
|
||||||
TEIE |= TEIE1;
|
TEIE |= TEIE1;
|
||||||
if(pwm_mask & 0xFFFF) GPOS = pwm_mask & 0xFFFF;
|
if(pwm_mask & 0xFFFF) GPOS = pwm_mask & 0xFFFF;
|
||||||
if(pwm_mask & 0x10000) GP16O = 1;
|
if(pwm_mask & 0x10000) GP16O = 1;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user