Merge pull request #4205 from hierophect/esp32s2-fix-pinfree

ESP32S2: pin_number_is_free should not check never_reset tables
This commit is contained in:
Dan Halbert 2021-02-15 15:12:34 -05:00 committed by GitHub
commit 5ccbb0be62
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -134,7 +134,7 @@ bool pin_number_is_free(gpio_num_t pin_number) {
uint8_t offset = pin_number / 32;
uint32_t mask = 1 << (pin_number % 32);
return (never_reset_pins[offset] & mask) == 0 && (in_use[offset] & mask) == 0;
return (in_use[offset] & mask) == 0;
}
bool common_hal_mcu_pin_is_free(const mcu_pin_obj_t *pin) {