// buttons_input.h — 5-way analog ladder on GPIO19 (FNK0102H), IDF port of
// ui_freenove_allinone's ButtonManager (same thresholds, debounce, semantics).
//
// Key numbers follow the original firmware: 1=SELECT 2=DOWN 3=MENU
// 4=LEFT/RIGHT 5=UP. Events are delivered to display_ui_handle_key() from a
// dedicated scan task (50 Hz, 30 ms debounce).
//
// GPIO19 is ADC2 on the ESP32-S3 — concurrent Wi-Fi can make individual
// reads fail with ESP_ERR_TIMEOUT; those samples are silently skipped (the
// 50 Hz scan re-samples immediately after).
#pragma once
#include "esp_err.h"

#ifdef __cplusplus
extern "C" {
#endif

esp_err_t buttons_input_init(void);

#ifdef __cplusplus
}
#endif
