This commit is contained in:
Ken Van Hoeylandt 2026-01-22 20:51:57 +01:00
parent 9b428d76db
commit 179ec6ca6a
2 changed files with 3 additions and 1 deletions

View File

@ -215,6 +215,8 @@ def generate_devicetree_h(filename: str):
''')) '''))
def generate(output_path: str, items: list[object], bindings: list[Binding], verbose: bool): def generate(output_path: str, items: list[object], bindings: list[Binding], verbose: bool):
if not os.path.exists(output_path):
os.makedirs(output_path)
devicetree_c_filename = os.path.join(output_path, "devicetree.c") devicetree_c_filename = os.path.join(output_path, "devicetree.c")
generate_devicetree_c(devicetree_c_filename, items, bindings, verbose) generate_devicetree_c(devicetree_c_filename, items, bindings, verbose)
devicetree_h_filename = os.path.join(output_path, "devicetree.h") devicetree_h_filename = os.path.join(output_path, "devicetree.h")

View File

@ -46,7 +46,7 @@ static bool set_options(Device* device, gpio_pin_t pin, gpio_flags_t options) {
.pull_down_en = (options & GPIO_PULL_DOWN) ? GPIO_PULLDOWN_ENABLE : GPIO_PULLDOWN_DISABLE, .pull_down_en = (options & GPIO_PULL_DOWN) ? GPIO_PULLDOWN_ENABLE : GPIO_PULLDOWN_DISABLE,
.intr_type = GPIO_INTERRUPT_FROM_OPTIONS(options), .intr_type = GPIO_INTERRUPT_FROM_OPTIONS(options),
#if SOC_GPIO_SUPPORT_PIN_HYS_FILTER #if SOC_GPIO_SUPPORT_PIN_HYS_FILTER
.hys_ctrl_mode = GPIO_HYS_CTRL_EFUSE .hys_ctrl_mode = GPIO_HYS_SOFT_DISABLE
#endif #endif
}; };