Microchip® Advanced Software Framework

conf_test.h File Reference

Unit test configuration.

Copyright (c) 2014-2018 Microchip Technology Inc. and its subsidiaries.

Macros

#define CONF_TEST_BAUDRATE   115200
 Baudrate setting. More...
 
#define CONF_TEST_PARITY   UART_MR_PAR_NO
 Parity setting. More...
 
#define CONF_TEST_USART   CONSOLE_UART
 USART Interface. More...
 
#define QT_LEFT_KEY_MASK   0x01
 
#define QT_RIGHT_KEY_MASK   0x02
 

Functions

static bool ut_is_any_key_pressed (struct qt_status *qt_status)
 Check if any key pressed. More...
 
static void ut_set_qt_param (struct qt_setup_block *setup_block)
 Set QTouch parameter for the unit test. More...
 

#define CONF_TEST_BAUDRATE   115200

Baudrate setting.

Referenced by main().

#define CONF_TEST_PARITY   UART_MR_PAR_NO

Parity setting.

Referenced by main().

#define CONF_TEST_USART   CONSOLE_UART

USART Interface.

Referenced by main().

#define QT_LEFT_KEY_MASK   0x01

Referenced by ut_is_any_key_pressed().

#define QT_RIGHT_KEY_MASK   0x02

Referenced by ut_is_any_key_pressed().

static bool ut_is_any_key_pressed ( struct qt_status qt_status)
static

Check if any key pressed.

Parameters
qt_statusPointer to QT status buffer.
Return values
trueSome keys pressed.
falseNo key pressed.

References qt_status::general_status, qt_status::key_status_2, QT_GENERAL_STATUS_SDET, QT_LEFT_KEY_MASK, and QT_RIGHT_KEY_MASK.

Referenced by run_qt_test_get_status().

static void ut_set_qt_param ( struct qt_setup_block setup_block)
static

Set QTouch parameter for the unit test.

Parameters
setup_blockPointer to setup block buffer.

References qt_setup_block::gpio_direction, qt_setup_block::gpio_gpo_drive2, QT_SLIDER_RESOLUTION_7_BIT, qt_setup_block::slider_num_keys, and qt_setup_block::slider_resolution.

Referenced by run_qt_test_setup_block().