gpio_hal_hold_en macro
Enable gpio pad hold function. The gpio pad hold function works in both input and output modes, but must be output-capable gpios. If pad hold enabled: in output mode: the output level of the pad will be force locked and can not be changed. in input mode: the input value read will not change, regardless the changes of input signal. On ESP32/S2/C3/S3/C2, the state of digital gpio cannot be held during Deep-sleep, and it will resume the hold function when the chip wakes up from Deep-sleep. If the digital gpio also needs to be held during Deep-sleep, `gpio_deep_sleep_hold_en` should also be called. Power down or call gpio_hold_dis will disable this function.
Arguments
hal
Context of the HAL layer
gpio_num
GPIO number, only support output GPIOs