Skip to content

Commit

Permalink
Update OneWire_direct_gpio.h
Browse files Browse the repository at this point in the history
Comment out invalid >= 33 check , Most ESP32 pins are IN/OUT this check is invalid and thus all ESP32 that are IN/Out can be used please check the doc for the ESP32 Chip to make sure it is a IN/OUT pin .
  • Loading branch information
jflasch2 authored Sep 3, 2024
1 parent 72249e2 commit fee1b44
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion util/OneWire_direct_gpio.h
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ void directModeOutput(IO_REG_TYPE pin)
#if CONFIG_IDF_TARGET_ESP32C3
GPIO.enable_w1ts.val = ((uint32_t)1 << (pin));
#else
if ( digitalPinIsValid(pin) && pin <= 33 ) // pins above 33 can be only inputs
if ( digitalPinIsValid(pin) /* && pin <= 33 */ ) // Use Any In/Out pins
{
#if ESP_IDF_VERSION_MAJOR < 4 // IDF 3.x ESP32/PICO-D4
uint32_t rtc_reg(rtc_gpio_desc[pin].reg);
Expand Down

0 comments on commit fee1b44

Please sign in to comment.