mirror of
https://github.com/HASwitchPlate/openHASP.git
synced 2025-07-24 11:46:34 +00:00
Check for custom used pins
This commit is contained in:
parent
91835d3684
commit
917fe508b3
@ -802,6 +802,12 @@ bool gpioIsSystemPin(uint8_t gpio)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
if(haspDevice.is_system_pin(gpio)) return true;
|
||||
|
||||
#if defined(HASP_USE_CUSTOM)
|
||||
if(custom_pin_in_use(gpio)) return true;
|
||||
#endif
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -1549,7 +1549,7 @@ void webHandleGpioConfig()
|
||||
for(uint8_t gpio = 0; gpio < NUM_DIGITAL_PINS; gpio++) {
|
||||
for(uint8_t id = 0; id < HASP_NUM_GPIO_CONFIG; id++) {
|
||||
hasp_gpio_config_t conf = gpioGetPinConfig(id);
|
||||
if((conf.pin == gpio) && gpioConfigInUse(id) && gpioInUse(gpio) && !gpioIsSystemPin(gpio)) {
|
||||
if((conf.pin == gpio) && gpioConfigInUse(id) && !gpioIsSystemPin(gpio)) {
|
||||
httpMessage += F("<tr><td>");
|
||||
// httpMessage += halGpioName(gpio);
|
||||
httpMessage += haspDevice.gpio_name(gpio).c_str();
|
||||
|
@ -20,7 +20,7 @@ build_flags =
|
||||
${touch.xpt2046}
|
||||
${esp32.vspi} ; Use VSPI hardware SPI bus
|
||||
-D TFT_DC=4
|
||||
-D TFT_CS=5
|
||||
-D TFT_CS=5
|
||||
-D TFT_RST=22 ; RST
|
||||
-D TFT_BCKL=15
|
||||
-D TOUCH_CS=14
|
||||
|
Loading…
x
Reference in New Issue
Block a user