8000 Don't stop a waveform simply by calling pinMode (#4906) · jsdevel/Arduino@d948a1f · GitHub
[go: up one dir, main page]

Skip to content

Commit d948a1f

Browse files
Don't stop a waveform simply by calling pinMode (esp8266#4906)
Setting a pin direction would cause a waveform generator attached to it to stop. This could cause PWM to stop if pinMode() is called while running (as it was called in __analogWrite()). Remove the stopWaveform call from pinMode, the Tone, analogWrite, or Servo that initiated the waveform has responsibility for stopping it (and it does) when complete, irrespective of the pinMode. Fixes esp8266#4905
1 parent e486887 commit d948a1f

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

cores/esp8266/core_esp8266_wiring_digital.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
uint8_t esp8266_gpioToFn[16] = {0x34, 0x18, 0x38, 0x14, 0x3C, 0x40, 0x1C, 0x20, 0x24, 0x28, 0x2C, 0x30, 0x04, 0x08, 0x0C, 0x10};
3030

3131
extern void __pinMode(uint8_t pin, uint8_t mode) {
32-
stopWaveform(pin);
3332
if(pin < 16){
3433
if(mode == SPECIAL){
3534
GPC(pin) = (GPC(pin) & (0xF << GPCI)); //SOURCE(GPIO) | DRIVER(NORMAL) | INT_TYPE(UNCHANGED) | WAKEUP_ENABLE(DISABLED)

0 commit comments

Comments
 (0)
0