jonny_jr9 fc5aad0c14 Add menu (display + encoder) functional - wip
Added functional menu using display and encoder:
    - a menu item is defined in one struct
    - scroll in a list of defined items
    - select option
    - modify value
    - save value, return to list
Currently only menu is run (button and status display disabled)

- Add menu.cpp/hpp
- Add encoder.cpp/hpp mostly from previous test in board-control
- display.cpp: only run new handleMenu() function
- main.cpp: initialize encoder at startup, disable button task for testing
2024-02-13 19:36:06 +01:00

21 lines
434 B
C++

extern "C" {
#include "freertos/FreeRTOS.h" // FreeRTOS related headers
#include "freertos/task.h"
#include "encoder.h"
}
//config
#define QUEUE_SIZE 10
#define PIN_A GPIO_NUM_25
#define PIN_B GPIO_NUM_26
#define PIN_BUTTON GPIO_NUM_27
//global encoder queue
extern QueueHandle_t encoderQueue;
//init encoder with config in encoder.cpp
void encoder_init();
//task that handles encoder events
void task_encoderExample(void *arg);