|
rcbench
Servo and ESC test bench: panel, IOmcu and shared C
|
Board bring-up for the 7-inch ESP32-P4 display board: the touch I2C (Inter-Integrated Circuit) bus, the backlight's PWM (pulse-width modulation) and the touch controller's reset. More...
#include <stdbool.h>#include <stdint.h>#include "driver/i2c_master.h"#include "esp_err.h"#include "board_pins.h"Go to the source code of this file.
Functions | |
| esp_err_t | board_init (void) |
| Bring up the touch I2C bus and the backlight PWM, the backlight at 0% (dark). | |
| i2c_master_bus_handle_t | board_i2c_bus (void) |
| The touch bus: the GT911 and, in a build with it, the touch injector. | |
| esp_err_t | board_backlight_percent (int percent) |
| Set the backlight brightness. | |
| esp_err_t | board_backlight (bool on) |
| Backlight at 100% or 0%. | |
| esp_err_t | board_touch_reset_sequence (void) |
| Run the GT911 reset on BOARD_TOUCH_PIN_RST: low 20ms, high, then 60ms before the first read. Does nothing with GPIO_NUM_NC. INT is not wired to the SoC, so the address the GT911 takes is its own choice; gt911_new() probes 0x5D, then 0x14. | |
Board bring-up for the 7-inch ESP32-P4 display board: the touch I2C (Inter-Integrated Circuit) bus, the backlight's PWM (pulse-width modulation) and the touch controller's reset.
Every line is a GPIO (general-purpose input/output) of the SoC (system on chip); the board has no I/O expander.
SPDX-License-Identifier: MIT
| esp_err_t board_backlight | ( | bool | on | ) |
Backlight at 100% or 0%.
| on | true for 100%, false for 0% (dark). |
| esp_err_t board_backlight_percent | ( | int | percent | ) |
Set the backlight brightness.
| percent | 0 to 100%; values outside are clamped. |
| i2c_master_bus_handle_t board_i2c_bus | ( | void | ) |
The touch bus: the GT911 and, in a build with it, the touch injector.
| esp_err_t board_init | ( | void | ) |
Bring up the touch I2C bus and the backlight PWM, the backlight at 0% (dark).
Safe to call repeatedly: a second call returns at once.
| esp_err_t board_touch_reset_sequence | ( | void | ) |
Run the GT911 reset on BOARD_TOUCH_PIN_RST: low 20ms, high, then 60ms before the first read. Does nothing with GPIO_NUM_NC. INT is not wired to the SoC, so the address the GT911 takes is its own choice; gt911_new() probes 0x5D, then 0x14.