aboutsummaryrefslogtreecommitdiffstats
path: root/boards/addons/ginput
diff options
context:
space:
mode:
Diffstat (limited to 'boards/addons/ginput')
-rw-r--r--boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_olimex_stm32_e407.h8
-rw-r--r--boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_st_stm32f4_discovery.h8
-rw-r--r--boards/addons/ginput/touch/ADS7843/stm32f4cube_hal.h12
-rw-r--r--boards/addons/ginput/touch/MCU/ginput_lld_mouse_board_olimex_pic32mx_lcd.h12
4 files changed, 20 insertions, 20 deletions
diff --git a/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_olimex_stm32_e407.h b/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_olimex_stm32_e407.h
index 94f393b5..6611d5bc 100644
--- a/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_olimex_stm32_e407.h
+++ b/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_olimex_stm32_e407.h
@@ -34,17 +34,17 @@ static const SPIConfig spicfg = {
// How much extra data to allocate at the end of the GMouse structure for the board's use
#define GMOUSE_ADS7843_BOARD_DATA_SIZE 0
-static bool_t init_board(GMouse* m, unsigned driverinstance) {
+static gBool init_board(GMouse* m, unsigned driverinstance) {
(void) m;
if (driverinstance)
- return FALSE;
+ return gFalse;
spiStart(&SPID2, &spicfg);
- return TRUE;
+ return gTrue;
}
-static GFXINLINE bool_t getpin_pressed(GMouse* m) {
+static GFXINLINE gBool getpin_pressed(GMouse* m) {
(void) m;
return (!palReadPad(GPIOG, 0));
diff --git a/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_st_stm32f4_discovery.h b/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_st_stm32f4_discovery.h
index 83fb04fb..7916cc6f 100644
--- a/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_st_stm32f4_discovery.h
+++ b/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_st_stm32f4_discovery.h
@@ -45,11 +45,11 @@ static const SPIConfig spicfg = {
// How much extra data to allocate at the end of the GMouse structure for the board's use
#define GMOUSE_ADS7843_BOARD_DATA_SIZE 0
-static bool_t init_board(GMouse* m, unsigned driverinstance) {
+static gBool init_board(GMouse* m, unsigned driverinstance) {
(void) m;
if (driverinstance)
- return FALSE;
+ return gFalse;
palSetPadMode(GPIOB, 13, PAL_MODE_ALTERNATE(5) ); /* SCK */
palSetPadMode(GPIOB, 14, PAL_MODE_ALTERNATE(5) ); /* MISO */
@@ -57,10 +57,10 @@ static bool_t init_board(GMouse* m, unsigned driverinstance) {
palSetPadMode(GPIOC, 4, PAL_MODE_OUTPUT_PUSHPULL); /* CS */
spiStart(&SPID2, &spicfg);
- return TRUE;
+ return gTrue;
}
-static GFXINLINE bool_t getpin_pressed(GMouse* m) {
+static GFXINLINE gBool getpin_pressed(GMouse* m) {
(void) m;
return (!palReadPad(GPIOC, 5));
diff --git a/boards/addons/ginput/touch/ADS7843/stm32f4cube_hal.h b/boards/addons/ginput/touch/ADS7843/stm32f4cube_hal.h
index 6bce29e6..e34dee84 100644
--- a/boards/addons/ginput/touch/ADS7843/stm32f4cube_hal.h
+++ b/boards/addons/ginput/touch/ADS7843/stm32f4cube_hal.h
@@ -16,7 +16,7 @@
static SPI_HandleTypeDef _hspi;
-static bool_t init_board(GMouse* m, unsigned driverinstance)
+static gBool init_board(GMouse* m, unsigned driverinstance)
{
GPIO_InitTypeDef GPIO_InitStruct;
@@ -93,20 +93,20 @@ static bool_t init_board(GMouse* m, unsigned driverinstance)
_hspi.Init.CRCCalculation = SPI_CRCCALCULATION_DISABLE;
_hspi.Init.CRCPolynomial = 10;
if (HAL_SPI_Init(&_hspi) != HAL_OK) {
- return FALSE;
+ return gFalse;
}
- return TRUE;
+ return gTrue;
}
-static GFXINLINE bool_t getpin_pressed(GMouse* m)
+static GFXINLINE gBool getpin_pressed(GMouse* m)
{
(void)m;
if (HAL_GPIO_ReadPin(GPIOC, GPIO_PIN_4) == GPIO_PIN_RESET)
- return TRUE;
+ return gTrue;
- return FALSE;
+ return gFalse;
}
static GFXINLINE void aquire_bus(GMouse* m)
diff --git a/boards/addons/ginput/touch/MCU/ginput_lld_mouse_board_olimex_pic32mx_lcd.h b/boards/addons/ginput/touch/MCU/ginput_lld_mouse_board_olimex_pic32mx_lcd.h
index 391eba9c..1b535473 100644
--- a/boards/addons/ginput/touch/MCU/ginput_lld_mouse_board_olimex_pic32mx_lcd.h
+++ b/boards/addons/ginput/touch/MCU/ginput_lld_mouse_board_olimex_pic32mx_lcd.h
@@ -59,18 +59,18 @@ static const ADCConversionGroup ADC_Y_CG = {
.channels = 1 << YPOS,
};
-static bool_t init_board(GMouse *m, unsigned driverinstance) {
+static gBool init_board(GMouse *m, unsigned driverinstance) {
(void) m;
if (driverinstance)
- return FALSE;
+ return gFalse;
adcObjectInit(&ADCD);
adcStart(&ADCD, &ADCC);
- return TRUE;
+ return gTrue;
}
-static bool_t read_xyz(GMouse *m, GMouseReading *prd) {
+static gBool read_xyz(GMouse *m, GMouseReading *prd) {
adcsample_t samples[2];
prd->buttons = 0;
@@ -89,7 +89,7 @@ static bool_t read_xyz(GMouse *m, GMouseReading *prd) {
// Shortcut - no need to read X or Y if the touch is off.
if (pdr->z < GMOUSE_MCU_Z_TOUCHON)
- return TRUE;
+ return gTrue;
// Read X
palSetPadMode(IOPORTB, XPOS, PAL_MODE_OUTPUT);
@@ -111,7 +111,7 @@ static bool_t read_xyz(GMouse *m, GMouseReading *prd) {
adcConvert(&ADCD, &ADC_X_CG, &samples[0], 1);
pdr->y = ADC_MAX - samples[0];
- return TRUE;
+ return gTrue;
}
#endif /* _GINPUT_LLD_MOUSE_BOARD_H */