adafruit / Adafruit_HX8357_Library

Arduino library for HX8357
39 stars 37 forks source link

Add Feather Sense to HX8357 example sketches #37

Open DJDevon3 opened 3 years ago

DJDevon3 commented 3 years ago

All of the HX8357 example sketches do not have the feather sense board explicitly listed and will fail to compile. Compile error states this line is faulty: Adafruit_HX8357 tft = Adafruit_HX8357(TFT_CS, TFT_DC); 'TFT_CS' was not declared in this scope

To fix simply add the board (ARDUINO_NRF52840_FEATHER_SENSE) to the anything else list and the sketches work. Very simple fix. Every HX8357 example sketch needs to be updated.

`// Anything else!

if defined (AVR_ATmega32U4__) || defined(ARDUINO_SAMD_FEATHER_M0) || defined (AVR_ATmega328P__) || \

defined(ARDUINO_SAMD_ZERO) || defined(SAMD51) || defined(SAM3X8E) || defined(ARDUINO_NRF52840_FEATHER) || defined(ARDUINO_NRF52840_FEATHER_SENSE)

define STMPE_CS 6

define TFT_CS 9

define TFT_DC 10

define SD_CS 5

endif`

ladyada commented 3 years ago

hi can you submit a PR? that would be great! :)