Application Gui Management.
Copyright (c) 2014-2018 Microchip Technology Inc. and its subsidiaries.
#include "et024006dhu.h"
Functions | |
void | gui_change_update_fs (uint32_t time_ms) |
This function change the frequency rate of the update of the display. More... | |
void | gui_clear_view (void) |
uint32_t | gui_get_update_fs (void) |
void | gui_init (uint32_t cpu_hz, uint32_t hsb_hz, uint32_t pba_hz, uint32_t pbb_hz) |
void | gui_set_selection (int32_t box_id) |
Select a new box (can select only one box a time) More... | |
void | gui_task (void) |
#define GUI_BOXES |
#define GUI_FONT FONT8x8 |
#define GUI_FONT_HEIGHT 8 |
#define GUI_FONT_WIDTH 8 |
#define GUI_MAIN_BG_COLOR 0xF79E |
#define GUI_MAIN_FG_COLOR BLACK |
#define GUI_NO_COLOR ((uint16_t) -1) |
Referenced by gui_set_selection().
#define GUI_NO_SEL -1 |
Referenced by gui_set_selection().
#define GUI_OUTPUT1_BG_COLOR GUI_MAIN_BG_COLOR |
#define GUI_OUTPUT1_FG_COLOR GUI_MAIN_FG_COLOR |
#define GUI_OUTPUT1_HEIGHT 24 |
#define GUI_OUTPUT1_ID 1 |
Referenced by gui_task(), state_machine_global(), and state_machine_task().
#define GUI_OUTPUT1_WIDTH 62 |
#define GUI_OUTPUT1_X 20 |
#define GUI_OUTPUT1_Y 112 |
#define GUI_OUTPUT2_BG_COLOR GUI_MAIN_BG_COLOR |
#define GUI_OUTPUT2_FG_COLOR GUI_MAIN_FG_COLOR |
#define GUI_OUTPUT2_HEIGHT 24 |
#define GUI_OUTPUT2_ID 2 |
Referenced by gui_task(), state_machine_global(), and state_machine_task().
#define GUI_OUTPUT2_WIDTH 62 |
#define GUI_OUTPUT2_X 128 |
#define GUI_OUTPUT2_Y 22 |
#define GUI_OUTPUT3_BG_COLOR GUI_MAIN_BG_COLOR |
#define GUI_OUTPUT3_FG_COLOR GUI_MAIN_FG_COLOR |
#define GUI_OUTPUT3_HEIGHT 24 |
#define GUI_OUTPUT3_ID 3 |
Referenced by gui_task(), state_machine_global(), and state_machine_task().
#define GUI_OUTPUT3_WIDTH 62 |
#define GUI_OUTPUT3_X 128 |
#define GUI_OUTPUT3_Y 190 |
#define GUI_SELECTION_COLOR 0xAA3F |
Referenced by gui_set_selection().
#define GUI_SOURCE1_BG_COLOR GUI_MAIN_BG_COLOR |
#define GUI_SOURCE1_FG_COLOR GUI_MAIN_FG_COLOR |
#define GUI_SOURCE1_HEIGHT 24 |
#define GUI_SOURCE1_ID 0 |
Referenced by gui_task(), state_machine_global(), and state_machine_task().
#define GUI_SOURCE1_WIDTH 62 |
#define GUI_SOURCE1_X 238 |
#define GUI_SOURCE1_Y 112 |
#define GUI_TEXT_BUFFER_SIZE 256 |
This does not take care of the buffer overflow,.
#define GUI_TEXT_COLOR 0xAEAE |
#define GUI_ZOOM_BOX_HEIGHT 240 |
Referenced by gui_print_signal_box().
#define GUI_ZOOM_BOX_WIDTH 320 |
Referenced by gui_print_signal_box().
#define GUI_ZOOM_BOX_X 0 |
Referenced by gui_print_signal_box().
#define GUI_ZOOM_BOX_Y 0 |
Referenced by gui_print_signal_box().
void gui_change_update_fs | ( | uint32_t | time_ms | ) |
This function change the frequency rate of the update of the display.
References cpu_ms_2_cy(), cpu_set_timeout(), gui_cpu_hz, gui_fs, and time_ms.
Referenced by gui_init().
void gui_clear_view | ( | void | ) |
References ET024006_HEIGHT, ET024006_WIDTH, and gui_draw_background().
Referenced by gui_init(), and state_machine_task().
uint32_t gui_get_update_fs | ( | void | ) |
References gui_fs.
void gui_init | ( | uint32_t | cpu_hz, |
uint32_t | hsb_hz, | ||
uint32_t | pba_hz, | ||
uint32_t | pbb_hz | ||
) |
References cpu_hz, DEFAULT_SCREEN_UPDATE_FS_MS, et024006_Init(), ET024006DHU_BL_PIN, gpio_set_gpio_pin(), gui_change_update_fs(), gui_clear_view(), and gui_cpu_hz.
Referenced by main().
void gui_set_selection | ( | int32_t | box_id | ) |
Select a new box (can select only one box a time)
References gui_box::bg_color, et024006_DrawFilledRect(), gui_draw_background(), GUI_NO_COLOR, GUI_NO_SEL, GUI_SELECTION_COLOR, gui_box::height, gui_box::width, gui_box::x, and gui_box::y.
Referenced by state_machine_global().
void gui_task | ( | void | ) |
References cpu_is_timeout(), cpu_ms_2_cy(), cpu_set_timeout(), gui_cpu_hz, gui_fs, GUI_OUTPUT1_ID, GUI_OUTPUT2_ID, GUI_OUTPUT3_ID, gui_print_signal_box(), GUI_SOURCE1_ID, signal1_buf, signal2_buf, signal3_buf, and signal4_buf.
Referenced by main().