User Interface.
Copyright (c) 2012-2018 Microchip Technology Inc. and its subsidiaries.
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "compiler.h"
#include "sleepmgr.h"
#include "sysclk.h"
#include "board.h"
#include "c42364a.h"
#include "board_monitor.h"
#include "touch_api_sam4l.h"
#include "ioport.h"
Functions | |
void | ui_bm_init (void) |
User Interface - Board Monitor Initialization : and send SAM4L status. More... | |
void | ui_bm_send_mcu_status (void) |
User Interface Board Monitor send SAM4L status. More... | |
power_scaling_t | ui_get_power_scaling_mcu_status (void) |
Get MCU Power Scaling Status. More... | |
sleep_mode_t | ui_get_sleep_mode_mcu_status (void) |
Get MCU Sleep Mode Status. More... | |
void | ui_lcd_init (void) |
User Interface - LCD Initialization. More... | |
void | ui_lcd_refresh_alphanum (bool ui_lcd_refresh, int32_t event_qtouch_slider_position) |
User Interface LCD Refresh Alphanumeric area. More... | |
void | ui_lcd_refresh_txt (void) |
User Interface LCD Refresh Text area. More... | |
void | ui_set_mcu_status (power_scaling_t power_scaling, sleep_mode_t sleep_mode, uint32_t cpu_freq, cpu_src_t cpu_src) |
Set MCU power saving information used by the UI. More... | |
void | ui_set_power_scaling_mcu_status (power_scaling_t power_scaling) |
Set MCU Power Scaling Status. More... | |
void | ui_set_sleep_mode_mcu_status (sleep_mode_t sleep_mode) |
Set MCU Sleep Mode Status. More... | |
void ui_bm_init | ( | void | ) |
User Interface - Board Monitor Initialization : and send SAM4L status.
References bm_init(), BM_USART_USART, sysclk_disable_peripheral_clock(), sysclk_enable_peripheral_clock(), and ui_bm_send_mcu_status().
Referenced by app_init().
void ui_bm_send_mcu_status | ( | void | ) |
User Interface Board Monitor send SAM4L status.
References bm_send_mcu_status(), BM_USART_USART, sam4l_status_t::cpu_freq, sam4l_status_t::cpu_src, sam4l_status_t::power_scaling, sam4l_status_t::sleep_mode, sysclk_disable_peripheral_clock(), and sysclk_enable_peripheral_clock().
Referenced by app_init_lowpower(), main(), and ui_bm_init().
power_scaling_t ui_get_power_scaling_mcu_status | ( | void | ) |
Get MCU Power Scaling Status.
References sam4l_status_t::power_scaling.
Referenced by app_init_lowpower(), main(), and ui_lcd_refresh_txt().
sleep_mode_t ui_get_sleep_mode_mcu_status | ( | void | ) |
void ui_lcd_init | ( | void | ) |
User Interface - LCD Initialization.
References c42364a_circular_animation_start(), C42364A_CSR_RIGHT, C42364A_ICON_ARM, c42364a_init(), c42364a_show_icon(), c42364a_text_scrolling_start(), c42364a_text_scrolling_stop(), event_qtouch_sensors_idle_count, UI_IDLE_TIME, and ui_lcd_refresh_txt().
Referenced by app_init().
void ui_lcd_refresh_alphanum | ( | bool | ui_lcd_refresh, |
int32_t | event_qtouch_slider_position | ||
) |
User Interface LCD Refresh Alphanumeric area.
ui_lcd_refresh | boolean to refresh or not Alphanumeric area. |
event_qtouch_slider_position | set slider position in Alphanumeric area. |
References c42364a_write_num_packet().
Referenced by main().
void ui_lcd_refresh_txt | ( | void | ) |
User Interface LCD Refresh Text area.
References c42364a_show_text(), POWER_SCALING_PS1, POWER_SCALING_PS2, and ui_get_power_scaling_mcu_status().
Referenced by main(), and ui_lcd_init().
void ui_set_mcu_status | ( | power_scaling_t | power_scaling, |
sleep_mode_t | sleep_mode, | ||
uint32_t | cpu_freq, | ||
cpu_src_t | cpu_src | ||
) |
Set MCU power saving information used by the UI.
power_scaling | Power scaling. |
sleep_mode | Sleep mode. |
cpu_freq | CPU frequency. |
cpu_src | CPU source clock. |
References sam4l_status_t::cpu_freq, sam4l_status_t::cpu_src, sam4l_status_t::power_scaling, and sam4l_status_t::sleep_mode.
Referenced by app_init(), and app_init_lowpower().
void ui_set_power_scaling_mcu_status | ( | power_scaling_t | power_scaling | ) |
Set MCU Power Scaling Status.
power_scaling | Power scaling. |
References sam4l_status_t::power_scaling.
Referenced by main().
void ui_set_sleep_mode_mcu_status | ( | sleep_mode_t | sleep_mode | ) |
Set MCU Sleep Mode Status.
sleep_mode | Sleep Mode. |
References sam4l_status_t::sleep_mode.
Referenced by main().