Skip to content

Commit 66c88fa

Browse files
authored
Update esp32-hal-rmt.c (#8216)
Optimizing Peripheral Manager Test
1 parent 0320f4d commit 66c88fa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: cores/esp32/esp32-hal-rmt.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -444,7 +444,7 @@ bool rmtInit(int pin, rmt_ch_dir_t channel_direction, rmt_reserve_memsize_t mem_
444444
}
445445

446446
// Try to dettach any (Tx|Rx|Whatever) previous bus or just keep it as not attached
447-
if (perimanGetPinBusType(pin) != ESP32_BUS_TYPE_INIT && !perimanSetPinBus(pin, ESP32_BUS_TYPE_INIT, NULL)) {
447+
if (!perimanSetPinBus(pin, ESP32_BUS_TYPE_INIT, NULL)) {
448448
log_w("GPIO %d - Can't detach previous peripheral.", pin);
449449
return false;
450450
}

0 commit comments

Comments
 (0)