mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
boards/adafruit-pybadge: enable ST7735 display
This commit is contained in:
parent
4d400307bf
commit
4af29ab549
@ -23,7 +23,7 @@ config BOARD_ADAFRUIT_PYBADGE
|
||||
select HAS_PERIPH_UART
|
||||
select HAS_PERIPH_USBDEV
|
||||
|
||||
# select HAVE_ST7735 # not supported yet
|
||||
select HAVE_ST7735
|
||||
select HAVE_SAUL_GPIO
|
||||
select HAVE_MTD_SPI_NOR
|
||||
# This specific board requires SPI_ON_QSPI for the MTD_SPI_NOR
|
||||
|
@ -3,8 +3,7 @@ ifneq (,$(filter saul_default,$(USEMODULE)))
|
||||
endif
|
||||
|
||||
ifneq (,$(filter disp_dev,$(USEMODULE)))
|
||||
# Driver not supported yet
|
||||
# USEMODULE += st7735
|
||||
USEMODULE += st7735
|
||||
endif
|
||||
|
||||
ifneq (,$(filter mtd,$(USEMODULE)))
|
||||
|
@ -64,8 +64,7 @@ void board_init(void)
|
||||
gpio_set(SPEAKER_ENABLE_PIN);
|
||||
}
|
||||
|
||||
/* ST7735 driver is not supported yet uncomment the following code once it is */
|
||||
/* if (IS_USED(MODULE_ST7735)) {
|
||||
if (IS_USED(MODULE_ST7735)) {
|
||||
gpio_init(BACKLIGHT_PIN, GPIO_OUT);
|
||||
}*/
|
||||
}
|
||||
}
|
||||
|
@ -67,13 +67,16 @@ extern "C" {
|
||||
* @name Display configuration (not supported yet)
|
||||
* @{
|
||||
*/
|
||||
#define ST7735_PARAM_SPI SPI_DEV(1) /**< SPI device */
|
||||
#define ST7735_PARAM_CS GPIO_PIN(PB, 7) /**< Chip select pin */
|
||||
#define ST7735_PARAM_DCX GPIO_PIN(PB, 5) /**< DCX pin */
|
||||
#define ST7735_PARAM_RST GPIO_PIN(PA, 0) /**< Reset pin */
|
||||
#define ST7735_PARAM_NUM_LINES (128U) /**< Number of screen lines */
|
||||
#define ST7735_PARAM_RGB (1) /**< RGB configuration */
|
||||
#define ST7735_PARAM_INVERTED (1) /**< Inversion configuration */
|
||||
#define ST7735_PARAM_SPI SPI_DEV(1) /**< SPI device */
|
||||
#define ST7735_PARAM_CS GPIO_PIN(PB, 7) /**< Chip select pin */
|
||||
#define ST7735_PARAM_DCX GPIO_PIN(PB, 5) /**< DCX pin */
|
||||
#define ST7735_PARAM_RST GPIO_PIN(PA, 0) /**< Reset pin */
|
||||
#define ST7735_PARAM_NUM_LINES (160U) /**< Number of screen lines */
|
||||
#define ST7735_PARAM_RGB_CHANNELS (128U) /**< Number of screen rgb channel (height) */
|
||||
#define ST7735_PARAM_RGB (1) /**< RGB configuration */
|
||||
#define ST7735_PARAM_INVERTED (0) /**< Inversion configuration */
|
||||
#define LCD_SCREEN_WIDTH (ST7735_PARAM_NUM_LINES) /**< LCD screen width */
|
||||
#define LCD_SCREEN_HEIGHT (ST7735_PARAM_RGB_CHANNELS) /**< LCD screen height */
|
||||
/** @} */
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user