diff options
Diffstat (limited to 'boards/base/STM32F746-Discovery')
-rw-r--r-- | boards/base/STM32F746-Discovery/gmouse_lld_FT5336_board.h | 6 | ||||
-rw-r--r-- | boards/base/STM32F746-Discovery/stm32f7_i2c.c | 6 | ||||
-rw-r--r-- | boards/base/STM32F746-Discovery/stm32f7_i2c.h | 2 |
3 files changed, 7 insertions, 7 deletions
diff --git a/boards/base/STM32F746-Discovery/gmouse_lld_FT5336_board.h b/boards/base/STM32F746-Discovery/gmouse_lld_FT5336_board.h index 7d61bb25..d8c4c2e1 100644 --- a/boards/base/STM32F746-Discovery/gmouse_lld_FT5336_board.h +++ b/boards/base/STM32F746-Discovery/gmouse_lld_FT5336_board.h @@ -30,7 +30,7 @@ #define AFRH AFR[1] #endif -static bool_t init_board(GMouse* m, unsigned instance) +static gBool init_board(GMouse* m, unsigned instance) { (void)m; (void)instance; @@ -51,10 +51,10 @@ static bool_t init_board(GMouse* m, unsigned instance) // Initialize the I2C3 peripheral if (!(i2cInit(I2C3))) { - return FALSE; + return gFalse; } - return TRUE; + return gTrue; } static void write_reg(GMouse* m, uint8_t reg, uint8_t val) diff --git a/boards/base/STM32F746-Discovery/stm32f7_i2c.c b/boards/base/STM32F746-Discovery/stm32f7_i2c.c index 90bb9635..75af9de7 100644 --- a/boards/base/STM32F746-Discovery/stm32f7_i2c.c +++ b/boards/base/STM32F746-Discovery/stm32f7_i2c.c @@ -34,7 +34,7 @@ static void _i2cResetCr2(I2C_TypeDef* i2c) i2c->CR2 &= (uint32_t) ~((uint32_t) (I2C_CR2_SADD | I2C_CR2_HEAD10R | I2C_CR2_NBYTES | I2C_CR2_RELOAD | I2C_CR2_RD_WRN)); } -bool_t i2cInit(I2C_TypeDef* i2c) +gBool i2cInit(I2C_TypeDef* i2c) { // Enable I2Cx peripheral clock. // Select APB1 as clock source @@ -51,7 +51,7 @@ bool_t i2cInit(I2C_TypeDef* i2c) RCC->DCKCFGR2 &= ~RCC_DCKCFGR2_I2C4SEL; RCC->APB1ENR |= RCC_APB1ENR_I2C4EN; } else { - return FALSE; + return gFalse; } // Disable the I2Cx peripheral @@ -76,7 +76,7 @@ bool_t i2cInit(I2C_TypeDef* i2c) // Enable the I2Cx peripheral i2c->CR1 |= I2C_CR1_PE; - return TRUE; + return gTrue; } void i2cSend(I2C_TypeDef* i2c, uint8_t slaveAddr, uint8_t* data, uint16_t length) diff --git a/boards/base/STM32F746-Discovery/stm32f7_i2c.h b/boards/base/STM32F746-Discovery/stm32f7_i2c.h index 625aeed8..4d481903 100644 --- a/boards/base/STM32F746-Discovery/stm32f7_i2c.h +++ b/boards/base/STM32F746-Discovery/stm32f7_i2c.h @@ -3,7 +3,7 @@ #include "stm32f7xx.h" #include "gfx.h" -bool_t i2cInit(I2C_TypeDef* i2c); +gBool i2cInit(I2C_TypeDef* i2c); void i2cSend(I2C_TypeDef* i2c, uint8_t slaveAddr, uint8_t* data, uint16_t length); void i2cSendByte(I2C_TypeDef* i2c, uint8_t slaveAddr, uint8_t data); |