From f9bbbfccb3b2d215d8f179210be23aa2c60dbdb3 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Sat, 18 Jun 2022 14:03:58 -0500 Subject: [PATCH 1/9] Fix typo --- src/mesh/http/WiFiAPClient.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesh/http/WiFiAPClient.cpp b/src/mesh/http/WiFiAPClient.cpp index 85f8d2a99..9f610e5ce 100644 --- a/src/mesh/http/WiFiAPClient.cpp +++ b/src/mesh/http/WiFiAPClient.cpp @@ -222,7 +222,7 @@ bool initWifi(bool forceSoftAP) // The configurations on softAP are from the espresif library int ok = WiFi.softAP(wifiName, wifiPsw, 1, 1, 4); - DEBUG_MSG("Starting hiddem WIFI AP: ssid=%s, ok=%d\n", wifiName, ok); + DEBUG_MSG("Starting hidden WIFI AP: ssid=%s, ok=%d\n", wifiName, ok); } else { int ok = WiFi.softAP(wifiName, wifiPsw); DEBUG_MSG("Starting WIFI AP: ssid=%s, ok=%d\n", wifiName, ok); From e87c5d8d34bc0061024e0aa4a7c1604aadd6a5c5 Mon Sep 17 00:00:00 2001 From: Mark Trevor Birss Date: Mon, 20 Jun 2022 16:08:35 +0200 Subject: [PATCH 2/9] Update EInkDisplay2.cpp (#1524) Co-authored-by: Ben Meadors --- src/graphics/EInkDisplay2.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/graphics/EInkDisplay2.cpp b/src/graphics/EInkDisplay2.cpp index 7c002d928..ad3488545 100644 --- a/src/graphics/EInkDisplay2.cpp +++ b/src/graphics/EInkDisplay2.cpp @@ -210,8 +210,7 @@ bool EInkDisplay::connect() #elif defined(M5_COREINK) auto lowLevel = new TECHO_DISPLAY_MODEL(PIN_EINK_CS, PIN_EINK_DC, PIN_EINK_RES, PIN_EINK_BUSY); adafruitDisplay = new GxEPD2_BW(*lowLevel); - delay(100); - adafruitDisplay->init(115200, true, 20, false, SPI, SPISettings(4000000, MSBFIRST, SPI_MODE0)); + adafruitDisplay->init(115200, true, 40, false, SPI, SPISettings(4000000, MSBFIRST, SPI_MODE0)); adafruitDisplay->setRotation(0); adafruitDisplay->setPartialWindow(0, 0, EPD_WIDTH, EPD_HEIGHT); #endif From 63238cb810be696798c0251426726844160717bf Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Mon, 20 Jun 2022 09:13:27 -0500 Subject: [PATCH 3/9] Add m5stack core boards to CI --- .github/workflows/main_matrix.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main_matrix.yml b/.github/workflows/main_matrix.yml index 4c23011ac..7428f2904 100644 --- a/.github/workflows/main_matrix.yml +++ b/.github/workflows/main_matrix.yml @@ -38,7 +38,9 @@ jobs: - board: rak4631_eink - board: t-echo - board: nano-g1 - + - board: m5stack_core + - board: m5stack_core_eink + runs-on: ubuntu-latest steps: - name: Checkout code @@ -93,6 +95,8 @@ jobs: - board: tbeam0.7 - board: meshtastic-diy-v1 - board: nano-g1 + - board: m5stack_core + - board: m5stack_core_eink runs-on: ubuntu-latest steps: From 877d72cbadd9fa233fbf286ae408212a9566db5c Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Mon, 20 Jun 2022 09:15:30 -0500 Subject: [PATCH 4/9] Helps if you get the name right --- .github/workflows/main_matrix.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main_matrix.yml b/.github/workflows/main_matrix.yml index 7428f2904..a271a79e6 100644 --- a/.github/workflows/main_matrix.yml +++ b/.github/workflows/main_matrix.yml @@ -39,7 +39,7 @@ jobs: - board: t-echo - board: nano-g1 - board: m5stack_core - - board: m5stack_core_eink + - board: m5stack_coreink runs-on: ubuntu-latest steps: @@ -96,7 +96,7 @@ jobs: - board: meshtastic-diy-v1 - board: nano-g1 - board: m5stack_core - - board: m5stack_core_eink + - board: m5stack_coreink runs-on: ubuntu-latest steps: From 4a2522dbd3b85db9a298ac2ab1e1ed377f74a82e Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Mon, 20 Jun 2022 09:16:00 -0500 Subject: [PATCH 5/9] Add m5stack core targets to release --- bin/build-all.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/build-all.sh b/bin/build-all.sh index 809c9fcbe..eb76c451f 100755 --- a/bin/build-all.sh +++ b/bin/build-all.sh @@ -5,7 +5,7 @@ set -e VERSION=`bin/buildinfo.py long` SHORT_VERSION=`bin/buildinfo.py short` -BOARDS_ESP32="rak11200 tlora-v2 tlora-v1 tlora_v1_3 tlora-v2-1-1.6 tbeam heltec-v1 heltec-v2.0 heltec-v2.1 tbeam0.7 meshtastic-diy-v1 nano-g1" +BOARDS_ESP32="rak11200 tlora-v2 tlora-v1 tlora_v1_3 tlora-v2-1-1.6 tbeam heltec-v1 heltec-v2.0 heltec-v2.1 tbeam0.7 meshtastic-diy-v1 nano-g1 m5stack_core m5stack_coreink" #BOARDS_ESP32=tbeam # FIXME note nrf52840dk build is for some reason only generating a BIN file but not a HEX file nrf52840dk-geeksville is fine From 21c6e595a1c758fff8727fe902b7e2485b983127 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Mon, 20 Jun 2022 11:18:30 -0500 Subject: [PATCH 6/9] Update build-all.sh --- bin/build-all.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/build-all.sh b/bin/build-all.sh index eb76c451f..79486cda8 100755 --- a/bin/build-all.sh +++ b/bin/build-all.sh @@ -5,7 +5,7 @@ set -e VERSION=`bin/buildinfo.py long` SHORT_VERSION=`bin/buildinfo.py short` -BOARDS_ESP32="rak11200 tlora-v2 tlora-v1 tlora_v1_3 tlora-v2-1-1.6 tbeam heltec-v1 heltec-v2.0 heltec-v2.1 tbeam0.7 meshtastic-diy-v1 nano-g1 m5stack_core m5stack_coreink" +BOARDS_ESP32="rak11200 tlora-v2 tlora-v1 tlora_v1_3 tlora-v2-1-1.6 tbeam heltec-v1 heltec-v2.0 heltec-v2.1 tbeam0.7 meshtastic-diy-v1 nano-g1 m5stack-core m5stack-coreink" #BOARDS_ESP32=tbeam # FIXME note nrf52840dk build is for some reason only generating a BIN file but not a HEX file nrf52840dk-geeksville is fine From 388865aba7c77689cfaba27733006b4eb51c8c6e Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Mon, 20 Jun 2022 11:19:20 -0500 Subject: [PATCH 7/9] Dashes not underscores --- .github/workflows/main_matrix.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main_matrix.yml b/.github/workflows/main_matrix.yml index a271a79e6..c0caaa86b 100644 --- a/.github/workflows/main_matrix.yml +++ b/.github/workflows/main_matrix.yml @@ -38,8 +38,8 @@ jobs: - board: rak4631_eink - board: t-echo - board: nano-g1 - - board: m5stack_core - - board: m5stack_coreink + - board: m5stack-core + - board: m5stack-coreink runs-on: ubuntu-latest steps: @@ -95,8 +95,8 @@ jobs: - board: tbeam0.7 - board: meshtastic-diy-v1 - board: nano-g1 - - board: m5stack_core - - board: m5stack_coreink + - board: m5stack-core + - board: m5stack-coreink runs-on: ubuntu-latest steps: From 2e2c485f4c7e29e9f2fd8631e3be7bb1c5a32915 Mon Sep 17 00:00:00 2001 From: Mark Trevor Birss Date: Mon, 20 Jun 2022 19:33:44 +0200 Subject: [PATCH 8/9] M5Stack CoreInk Pins_Arduino.h (#1527) * Update EInkDisplay2.cpp * Create pins_arduino.h Co-authored-by: Ben Meadors --- variants/m5stack_coreink/pins_arduino.h | 57 +++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 variants/m5stack_coreink/pins_arduino.h diff --git a/variants/m5stack_coreink/pins_arduino.h b/variants/m5stack_coreink/pins_arduino.h new file mode 100644 index 000000000..93329f499 --- /dev/null +++ b/variants/m5stack_coreink/pins_arduino.h @@ -0,0 +1,57 @@ +#ifndef Pins_Arduino_h +#define Pins_Arduino_h + +#include + +#define EXTERNAL_NUM_INTERRUPTS 16 +#define NUM_DIGITAL_PINS 40 +#define NUM_ANALOG_INPUTS 16 + +#define analogInputToDigitalPin(p) (((p)<20)?(esp32_adc2gpio[(p)]):-1) +#define digitalPinToInterrupt(p) (((p)<40)?(p):-1) +#define digitalPinHasPWM(p) (p < 34) + +#define TX2 -1 +#define RX2 -1 + +static const uint8_t TX = 1; +static const uint8_t RX = 3; + +static const uint8_t SDA = 32; +static const uint8_t SCL = 33; + +static const uint8_t SS = 9; +static const uint8_t MOSI = 23; +static const uint8_t MISO = 34; +static const uint8_t SCK = 18; + +static const uint8_t G26 = 26; +static const uint8_t G36 = 36; +static const uint8_t G25 = 25; + +static const uint8_t G32 = 32; +static const uint8_t G33 = 33; + +static const uint8_t G21 = 21; +static const uint8_t G22 = 22; + +static const uint8_t G13 = 13; +static const uint8_t G14 = 14; + +static const uint8_t G12 = 12; +static const uint8_t G19 = 19; + +static const uint8_t G5 = 5; +static const uint8_t G10 = 10; +static const uint8_t G2 = 2; +static const uint8_t G37 = 37; +static const uint8_t G38 = 38; +static const uint8_t G39 = 39; + +static const uint8_t DAC1 = 25; +static const uint8_t DAC2 = 26; + +static const uint8_t ADC1 = 35; +static const uint8_t ADC2 = 36; + +#endif /* Pins_Arduino_h */ From a7d527c3c346bf4c2cea2d1ec50ff830560bf15f Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Mon, 20 Jun 2022 12:41:03 -0500 Subject: [PATCH 9/9] Pins for m5stack-core --- variants/m5stack_core/pins_arduino.h | 55 ++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 variants/m5stack_core/pins_arduino.h diff --git a/variants/m5stack_core/pins_arduino.h b/variants/m5stack_core/pins_arduino.h new file mode 100644 index 000000000..8b86a0d6f --- /dev/null +++ b/variants/m5stack_core/pins_arduino.h @@ -0,0 +1,55 @@ +#ifndef Pins_Arduino_h +#define Pins_Arduino_h + +#include + +#define EXTERNAL_NUM_INTERRUPTS 16 +#define NUM_DIGITAL_PINS 20 +#define NUM_ANALOG_INPUTS 16 + +#define analogInputToDigitalPin(p) (((p)<20)?(analogChannelToDigitalPin(p)):-1) +#define digitalPinToInterrupt(p) (((p)<40)?(p):-1) +#define digitalPinHasPWM(p) (p < 34) + +static const uint8_t TX = 1; +static const uint8_t RX = 3; + +static const uint8_t TXD2 = 17; +static const uint8_t RXD2 = 16; + +static const uint8_t SDA = 21; +static const uint8_t SCL = 22; + +static const uint8_t SS = 5; +static const uint8_t MOSI = 23; +static const uint8_t MISO = 19; +static const uint8_t SCK = 18; + +static const uint8_t G23 = 23; +static const uint8_t G19 = 19; +static const uint8_t G18 = 18; +static const uint8_t G3 = 3; +static const uint8_t G16 = 16; +static const uint8_t G21 = 21; +static const uint8_t G2 = 2; +static const uint8_t G12 = 12; +static const uint8_t G15 = 15; +static const uint8_t G35 = 35; +static const uint8_t G36 = 36; +static const uint8_t G25 = 25; +static const uint8_t G26 = 26; +static const uint8_t G1 = 1; +static const uint8_t G17 = 17; +static const uint8_t G22 = 22; +static const uint8_t G5 = 5; +static const uint8_t G13 = 13; +static const uint8_t G0 = 0; +static const uint8_t G34 = 34; + +static const uint8_t DAC1 = 25; +static const uint8_t DAC2 = 26; + +static const uint8_t ADC1 = 35; +static const uint8_t ADC2 = 36; + +#endif /* Pins_Arduino_h */