updated gpio_pad_select_gpio to gpio_reset_pin

This commit is contained in:
Eric Poulsen 2023-03-20 20:11:25 -07:00
parent 2440b9b434
commit 335d444e45
14 changed files with 36 additions and 36 deletions

View file

@ -262,7 +262,7 @@ void TFT_bitmap_display(void)
void FT81x_init(void)
{
//gpio_pad_select_gpio(EVE_PDN);
gpio_reset_pin(EVE_PDN);
gpio_set_level(EVE_CS, 1);
gpio_set_direction(EVE_PDN, GPIO_MODE_OUTPUT);

View file

@ -122,13 +122,13 @@ void GC9A01_init(void)
#endif
//Initialize non-SPI GPIOs
//gpio_pad_select_gpio(GC9A01_DC);
gpio_reset_pin(GC9A01_DC);
gpio_set_direction(GC9A01_DC, GPIO_MODE_OUTPUT);
//gpio_pad_select_gpio(GC9A01_RST);
gpio_reset_pin(GC9A01_RST);
gpio_set_direction(GC9A01_RST, GPIO_MODE_OUTPUT);
#if GC9A01_ENABLE_BACKLIGHT_CONTROL
//gpio_pad_select_gpio(GC9A01_BCKL);
gpio_reset_pin(GC9A01_BCKL);
gpio_set_direction(GC9A01_BCKL, GPIO_MODE_OUTPUT);
#endif
//Reset the display

View file

@ -160,13 +160,13 @@ static uint8_t displayType = HX8357D;
void hx8357_init(void)
{
//Initialize non-SPI GPIOs
//gpio_pad_select_gpio(HX8357_DC);
gpio_reset_pin(HX8357_DC);
gpio_set_direction(HX8357_DC, GPIO_MODE_OUTPUT);
//gpio_pad_select_gpio(HX8357_RST);
gpio_reset_pin(HX8357_RST);
gpio_set_direction(HX8357_RST, GPIO_MODE_OUTPUT);
#if HX8357_ENABLE_BACKLIGHT_CONTROL
//gpio_pad_select_gpio(HX8357_BCKL);
gpio_reset_pin(HX8357_BCKL);
gpio_set_direction(HX8357_BCKL, GPIO_MODE_OUTPUT);
#endif

View file

@ -196,11 +196,11 @@ void il3820_init(void)
uint8_t tmp[3] = {0};
/* Initialize non-SPI GPIOs */
//gpio_pad_select_gpio(IL3820_DC_PIN);
gpio_reset_pin(IL3820_DC_PIN);
gpio_set_direction(IL3820_DC_PIN, GPIO_MODE_OUTPUT);
//gpio_pad_select_gpio(IL3820_RST_PIN);
gpio_reset_pin(IL3820_RST_PIN);
gpio_set_direction(IL3820_RST_PIN, GPIO_MODE_OUTPUT);
//gpio_pad_select_gpio(IL3820_BUSY_PIN);
gpio_reset_pin(IL3820_BUSY_PIN);
gpio_set_direction(IL3820_BUSY_PIN, GPIO_MODE_INPUT);
/* Harware reset */

View file

@ -91,13 +91,13 @@ void ili9341_init(void)
#endif
//Initialize non-SPI GPIOs
//gpio_pad_select_gpio(ILI9341_DC);
gpio_reset_pin(ILI9341_DC);
gpio_set_direction(ILI9341_DC, GPIO_MODE_OUTPUT);
//gpio_pad_select_gpio(ILI9341_RST);
gpio_reset_pin(ILI9341_RST);
gpio_set_direction(ILI9341_RST, GPIO_MODE_OUTPUT);
#if ILI9341_ENABLE_BACKLIGHT_CONTROL
//gpio_pad_select_gpio(ILI9341_BCKL);
gpio_reset_pin(ILI9341_BCKL);
gpio_set_direction(ILI9341_BCKL, GPIO_MODE_OUTPUT);
#endif
//Reset the display

View file

@ -74,13 +74,13 @@ void ili9481_init(void)
};
//Initialize non-SPI GPIOs
//gpio_pad_select_gpio(ILI9481_DC);
gpio_reset_pin(ILI9481_DC);
gpio_set_direction(ILI9481_DC, GPIO_MODE_OUTPUT);
//gpio_pad_select_gpio(ILI9481_RST);
gpio_reset_pin(ILI9481_RST);
gpio_set_direction(ILI9481_RST, GPIO_MODE_OUTPUT);
#if ILI9481_ENABLE_BACKLIGHT_CONTROL
//gpio_pad_select_gpio(ILI9481_BCKL);
gpio_reset_pin(ILI9481_BCKL);
gpio_set_direction(ILI9481_BCKL, GPIO_MODE_OUTPUT);
#endif

View file

@ -76,13 +76,13 @@ void ili9486_init(void)
#endif
//Initialize non-SPI GPIOs
//gpio_pad_select_gpio(ILI9486_DC);
gpio_reset_pin(ILI9486_DC);
gpio_set_direction(ILI9486_DC, GPIO_MODE_OUTPUT);
//gpio_pad_select_gpio(ILI9486_RST);
gpio_reset_pin(ILI9486_RST);
gpio_set_direction(ILI9486_RST, GPIO_MODE_OUTPUT);
#if ILI9486_ENABLE_BACKLIGHT_CONTROL
//gpio_pad_select_gpio(ILI9486_BCKL);
gpio_reset_pin(ILI9486_BCKL);
gpio_set_direction(ILI9486_BCKL, GPIO_MODE_OUTPUT);
#endif

View file

@ -76,13 +76,13 @@ void ili9488_init(void)
};
//Initialize non-SPI GPIOs
//gpio_pad_select_gpio(ILI9488_DC);
gpio_reset_pin(ILI9488_DC);
gpio_set_direction(ILI9488_DC, GPIO_MODE_OUTPUT);
//gpio_pad_select_gpio(ILI9488_RST);
gpio_reset_pin(ILI9488_RST);
gpio_set_direction(ILI9488_RST, GPIO_MODE_OUTPUT);
#if ILI9488_ENABLE_BACKLIGHT_CONTROL
//gpio_pad_select_gpio(ILI9488_BCKL);
gpio_reset_pin(ILI9488_BCKL);
gpio_set_direction(ILI9488_BCKL, GPIO_MODE_OUTPUT);
#endif

View file

@ -159,10 +159,10 @@ void ra8875_init(void)
#endif
// Initialize non-SPI GPIOs
//gpio_pad_select_gpio(RA8875_RST);
gpio_reset_pin(RA8875_RST);
gpio_set_direction(RA8875_RST, GPIO_MODE_OUTPUT);
#ifdef CONFIG_LV_DISP_PIN_BCKL
//gpio_pad_select_gpio(CONFIG_LV_DISP_PIN_BCKL);
gpio_reset_pin(CONFIG_LV_DISP_PIN_BCKL);
gpio_set_direction(CONFIG_LV_DISP_PIN_BCKL, GPIO_MODE_OUTPUT);
#endif

View file

@ -92,9 +92,9 @@ void sh1107_init(void)
};
//Initialize non-SPI GPIOs
//gpio_pad_select_gpio(SH1107_DC);
gpio_reset_pin(SH1107_DC);
gpio_set_direction(SH1107_DC, GPIO_MODE_OUTPUT);
//gpio_pad_select_gpio(SH1107_RST);
gpio_reset_pin(SH1107_RST);
gpio_set_direction(SH1107_RST, GPIO_MODE_OUTPUT);
//Reset the display

View file

@ -97,9 +97,9 @@ void st7735s_init(void)
};
//Initialize non-SPI GPIOs
//gpio_pad_select_gpio(ST7735S_DC);
gpio_reset_pin(ST7735S_DC);
gpio_set_direction(ST7735S_DC, GPIO_MODE_OUTPUT);
//gpio_pad_select_gpio(ST7735S_RST);
gpio_reset_pin(ST7735S_RST);
gpio_set_direction(ST7735S_RST, GPIO_MODE_OUTPUT);
//Reset the display

View file

@ -88,16 +88,16 @@ void st7789_init(void)
};
//Initialize non-SPI GPIOs
//gpio_pad_select_gpio(ST7789_DC);
gpio_reset_pin(ST7789_DC);
gpio_set_direction(ST7789_DC, GPIO_MODE_OUTPUT);
#if !defined(CONFIG_LV_DISP_ST7789_SOFT_RESET)
//gpio_pad_select_gpio(ST7789_RST);
gpio_reset_pin(ST7789_RST);
gpio_set_direction(ST7789_RST, GPIO_MODE_OUTPUT);
#endif
#if ST7789_ENABLE_BACKLIGHT_CONTROL
//gpio_pad_select_gpio(ST7789_BCKL);
gpio_reset_pin(ST7789_BCKL);
gpio_set_direction(ST7789_BCKL, GPIO_MODE_OUTPUT);
#endif

View file

@ -92,13 +92,13 @@ void st7796s_init(void)
#endif
//Initialize non-SPI GPIOs
//gpio_pad_select_gpio(ST7796S_DC);
gpio_reset_pin(ST7796S_DC);
gpio_set_direction(ST7796S_DC, GPIO_MODE_OUTPUT);
//gpio_pad_select_gpio(ST7796S_RST);
gpio_reset_pin(ST7796S_RST);
gpio_set_direction(ST7796S_RST, GPIO_MODE_OUTPUT);
#if ST7796S_ENABLE_BACKLIGHT_CONTROL
//gpio_pad_select_gpio(ST7796S_BCKL);
gpio_reset_pin(ST7796S_BCKL);
gpio_set_direction(ST7796S_BCKL, GPIO_MODE_OUTPUT);
#endif
//Reset the display

View file

@ -139,10 +139,10 @@ static void setup_axis(gpio_num_t plus, gpio_num_t minus, gpio_num_t measure, gp
{
// Set GPIOs:
// - Float "ignore" and "measure"
//gpio_pad_select_gpio(ignore);
gpio_reset_pin(ignore);
gpio_set_direction(ignore, GPIO_MODE_DISABLE);
gpio_set_pull_mode(ignore, GPIO_FLOATING);
//gpio_pad_select_gpio(measure);
gpio_reset_pin(measure);
gpio_set_direction(measure, GPIO_MODE_DISABLE);
gpio_set_pull_mode(measure, GPIO_FLOATING);
// - Set "plus" to 1, "minus" to 0