Skip to content

Commit

Permalink
define Teensy 4.1 pins
Browse files Browse the repository at this point in the history
  • Loading branch information
moononournation committed Jun 12, 2021
1 parent e1796e3 commit 8d7f2c7
Show file tree
Hide file tree
Showing 12 changed files with 23 additions and 1 deletion.
1 change: 1 addition & 0 deletions examples/Clock/Clock.ino
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
* Raspberry Pi Pico dev board : TFT_CS: 17, TFT_DC: 27, TFT_RST: 26, TFT_BL: 28
* RTL872x various dev board : TFT_CS: 18, TFT_DC: 17, TFT_RST: 2, TFT_BL: 23
* Seeeduino XIAO dev board : TFT_CS: 3, TFT_DC: 2, TFT_RST: 1, TFT_BL: 0
* Teensy 4.1 dev board : TFT_CS: 39, TFT_DC: 41, TFT_RST: 40, TFT_BL: 22
******************************************************************************/
#include <Arduino_GFX_Library.h>

Expand Down
1 change: 1 addition & 0 deletions examples/HelloWorld/HelloWorld.ino
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
* Raspberry Pi Pico dev board : TFT_CS: 17, TFT_DC: 27, TFT_RST: 26, TFT_BL: 28
* RTL872x various dev board : TFT_CS: 18, TFT_DC: 17, TFT_RST: 2, TFT_BL: 23
* Seeeduino XIAO dev board : TFT_CS: 3, TFT_DC: 2, TFT_RST: 1, TFT_BL: 0
* Teensy 4.1 dev board : TFT_CS: 39, TFT_DC: 41, TFT_RST: 40, TFT_BL: 22
******************************************************************************/
#include <Arduino_GFX_Library.h>

Expand Down
1 change: 1 addition & 0 deletions examples/HelloWorldGfxfont/HelloWorldGfxfont.ino
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
* Raspberry Pi Pico dev board : TFT_CS: 17, TFT_DC: 27, TFT_RST: 26, TFT_BL: 28
* RTL872x various dev board : TFT_CS: 18, TFT_DC: 17, TFT_RST: 2, TFT_BL: 23
* Seeeduino XIAO dev board : TFT_CS: 3, TFT_DC: 2, TFT_RST: 1, TFT_BL: 0
* Teensy 4.1 dev board : TFT_CS: 39, TFT_DC: 41, TFT_RST: 40, TFT_BL: 22
******************************************************************************/
#include <Arduino_GFX_Library.h>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
* Raspberry Pi Pico dev board : TFT_CS: 17, TFT_DC: 27, TFT_RST: 26, TFT_BL: 28
* RTL872x various dev board : TFT_CS: 18, TFT_DC: 17, TFT_RST: 2, TFT_BL: 23
* Seeeduino XIAO dev board : TFT_CS: 3, TFT_DC: 2, TFT_RST: 1, TFT_BL: 0
* Teensy 4.1 dev board : TFT_CS: 39, TFT_DC: 41, TFT_RST: 40, TFT_BL: 22
******************************************************************************/
#include <Arduino_GFX_Library.h>

Expand Down
1 change: 1 addition & 0 deletions examples/ImgViewer/ImgViewerBmp/ImgViewerBmp.ino
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
* Raspberry Pi Pico dev board : TFT_CS: 17, TFT_DC: 27, TFT_RST: 26, TFT_BL: 28
* RTL872x various dev board : TFT_CS: 18, TFT_DC: 17, TFT_RST: 2, TFT_BL: 23
* Seeeduino XIAO dev board : TFT_CS: 3, TFT_DC: 2, TFT_RST: 1, TFT_BL: 0
* Teensy 4.1 dev board : TFT_CS: 39, TFT_DC: 41, TFT_RST: 40, TFT_BL: 22
******************************************************************************/
#include <Arduino_GFX_Library.h>

Expand Down
1 change: 1 addition & 0 deletions examples/ImgViewer/ImgViewerJpeg/ImgViewerJpeg.ino
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
* Raspberry Pi Pico dev board : TFT_CS: 17, TFT_DC: 27, TFT_RST: 26, TFT_BL: 28
* RTL872x various dev board : TFT_CS: 18, TFT_DC: 17, TFT_RST: 2, TFT_BL: 23
* Seeeduino XIAO dev board : TFT_CS: 3, TFT_DC: 2, TFT_RST: 1, TFT_BL: 0
* Teensy 4.1 dev board : TFT_CS: 39, TFT_DC: 41, TFT_RST: 40, TFT_BL: 22
******************************************************************************/
#include <Arduino_GFX_Library.h>

Expand Down
1 change: 1 addition & 0 deletions examples/ImgViewer/ImgViewerMjpeg/ImgViewerMjpeg.ino
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
* Raspberry Pi Pico dev board : TFT_CS: 17, TFT_DC: 27, TFT_RST: 26, TFT_BL: 28
* RTL872x various dev board : TFT_CS: 18, TFT_DC: 17, TFT_RST: 2, TFT_BL: 23
* Seeeduino XIAO dev board : TFT_CS: 3, TFT_DC: 2, TFT_RST: 1, TFT_BL: 0
* Teensy 4.1 dev board : TFT_CS: 39, TFT_DC: 41, TFT_RST: 40, TFT_BL: 22
******************************************************************************/
#include <Arduino_GFX_Library.h>

Expand Down
1 change: 1 addition & 0 deletions examples/ImgViewer/ImgViewerPng/ImgViewerPng.ino
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
* Raspberry Pi Pico dev board : TFT_CS: 17, TFT_DC: 27, TFT_RST: 26, TFT_BL: 28
* RTL872x various dev board : TFT_CS: 18, TFT_DC: 17, TFT_RST: 2, TFT_BL: 23
* Seeeduino XIAO dev board : TFT_CS: 3, TFT_DC: 2, TFT_RST: 1, TFT_BL: 0
* Teensy 4.1 dev board : TFT_CS: 39, TFT_DC: 41, TFT_RST: 40, TFT_BL: 22
******************************************************************************/
#include <Arduino_GFX_Library.h>

Expand Down
8 changes: 7 additions & 1 deletion examples/PDQgraphicstest/PDQgraphicstest.ino
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,13 @@ Arduino_GFX *gfx = new Arduino_ST7789(bus, -1 /* RST */, 2 /* rotation */, true

#else /* not selected specific hardware */

#if defined(ARDUINO_BLACKPILL_F411CE)
#if defined(__IMXRT1052__) || defined(__IMXRT1062__)
// PJRC Teensy 4.x
#define TFT_CS 39 // -1 for display without CS pin
#define TFT_DC 41
#define TFT_RST 40
#define TFT_BL 22
#elif defined(ARDUINO_BLACKPILL_F411CE)
#define TFT_CS 4 // -1 for display without CS pin
#define TFT_DC 3
#define TFT_RST 2
Expand Down
1 change: 1 addition & 0 deletions examples/WiFiAnalyzer/ESPWiFiAnalyzer/ESPWiFiAnalyzer.ino
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
* Raspberry Pi Pico dev board : TFT_CS: 17, TFT_DC: 27, TFT_RST: 26, TFT_BL: 28
* RTL872x various dev board : TFT_CS: 18, TFT_DC: 17, TFT_RST: 2, TFT_BL: 23
* Seeeduino XIAO dev board : TFT_CS: 3, TFT_DC: 2, TFT_RST: 1, TFT_BL: 0
* Teensy 4.1 dev board : TFT_CS: 39, TFT_DC: 41, TFT_RST: 40, TFT_BL: 22
******************************************************************************/
#include <Arduino_GFX_Library.h>

Expand Down
1 change: 1 addition & 0 deletions examples/WiFiPhotoFrame/WiFiPhotoFrame.ino
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
* Raspberry Pi Pico dev board : TFT_CS: 17, TFT_DC: 27, TFT_RST: 26, TFT_BL: 28
* RTL872x various dev board : TFT_CS: 18, TFT_DC: 17, TFT_RST: 2, TFT_BL: 23
* Seeeduino XIAO dev board : TFT_CS: 3, TFT_DC: 2, TFT_RST: 1, TFT_BL: 0
* Teensy 4.1 dev board : TFT_CS: 39, TFT_DC: 41, TFT_RST: 40, TFT_BL: 22
******************************************************************************/
#include <Arduino_GFX_Library.h>

Expand Down
6 changes: 6 additions & 0 deletions src/Arduino_GFX_Library.h
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,12 @@
#define TFT_DC 8
#define TFT_RST 7
#define TFT_BL 6
#elif defined(__IMXRT1052__) || defined(__IMXRT1062__)
// PJRC Teensy 4.x
#define TFT_CS 39 // -1 for display without CS pin
#define TFT_DC 41
#define TFT_RST 40
#define TFT_BL 22
#elif defined(ARDUINO_BLACKPILL_F411CE)
#define TFT_CS 4
#define TFT_DC 3
Expand Down

0 comments on commit 8d7f2c7

Please sign in to comment.