diff --git a/.github/workflows/build_push.yml b/.github/workflows/build_push.yml index 7d4098001..4aa52b0a3 100644 --- a/.github/workflows/build_push.yml +++ b/.github/workflows/build_push.yml @@ -183,6 +183,7 @@ jobs: - name: Configure configs.h for Flipper Zero WiFi Dev Board run: | + sed -i 's/^ #define MARAUDER_M5STAMP_S3/ \/\/#define MARAUDER_M5STAMP_S3/' esp32_marauder/configs.h sed -i 's/^ #define MARAUDER_M5STICKC/ \/\/#define MARAUDER_M5STICKC/' esp32_marauder/configs.h sed -i 's/^ #define MARAUDER_MINI/ \/\/#define MARAUDER_MINI/' esp32_marauder/configs.h sed -i 's/^ #define MARAUDER_V4/ \/\/#define MARAUDER_V4/' esp32_marauder/configs.h @@ -237,10 +238,35 @@ jobs: run: | mv ./esp32_marauder/build/esp32.esp32.esp32s3/esp32_marauder.ino.bin ./esp32_marauder/build/esp32.esp32.esp32s3/esp32_marauder.multiboardS3.bin + - name: Configure configs.h for M5 Stamp S3 Dev Board + run: | + sed -i 's/^ #define MARAUDER_M5STICKC/ \/\/#define MARAUDER_M5STICKC/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_MINI/ \/\/#define MARAUDER_MINI/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_V4/ \/\/#define MARAUDER_V4/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_V6/ \/\/#define MARAUDER_V6/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_V6_1/ \/\/#define MARAUDER_V6_1/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_KIT/ \/\/#define MARAUDER_KIT/' esp32_marauder/configs.h + sed -i 's/^ #define GENERIC_ESP32/ \/\/#define GENERIC_ESP32/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_FLIPPER/ \/\/#define MARAUDER_FLIPPER/' esp32_marauder/configs.h + sed -i 's/^ #define ESP32_LDDB/ \/\/#define ESP32_LDDB/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_DEV_BOARD_PRO/ \/\/#define MARAUDER_DEV_BOARD_PRO/' esp32_marauder/configs.h + sed -i 's/^ \/\/#define MARAUDER_M5STAMP_S3/ #define MARAUDER_M5STAMP_S3/' esp32_marauder/configs.h + + - name: Build Marauder for StampS3 Board + uses: ArminJo/arduino-test-compile@v3.2.1 + with: + sketch-names: esp32_marauder.ino + arduino-board-fqbn: esp32:esp32:esp32s3:PartitionScheme=min_spiffs,FlashSize=8M,PSRAM=enabled + extra-arduino-cli-args: "--warnings none" + + - name: Rename Marauder StampS3 bin + run: | + mv ./esp32_marauder/build/esp32.esp32.esp32s3/esp32_marauder.ino.bin ./esp32_marauder/build/esp32.esp32.esp32s3/esp32_marauder.stampS3.bin + - name: Configure TFT_eSPI and configs.h for OG Marauder run: | pwd - find /home/runner/ -name "*TFT_eSPI*" + find /home/runner/ -name "*TFT_eSPI*" sed -i 's/^#include /\/\/#include /' /home/runner/Arduino/libraries/CustomTFT_eSPI/User_Setup_Select.h sed -i 's/^\/\/#include /#include /' /home/runner/Arduino/libraries/CustomTFT_eSPI/User_Setup_Select.h sed -i 's/^ #define MARAUDER_MINI/ \/\/#define MARAUDER_MINI/' esp32_marauder/configs.h @@ -252,6 +278,7 @@ jobs: sed -i 's/^ #define MARAUDER_FLIPPER/ \/\/#define MARAUDER_FLIPPER/' esp32_marauder/configs.h sed -i 's/^ #define ESP32_LDDB/ \/\/#define ESP32_LDDB/' esp32_marauder/configs.h sed -i 's/^ #define MARAUDER_DEV_BOARD_PRO/ \/\/#define MARAUDER_DEV_BOARD_PRO/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_M5STAMP_S3/ \/\/#define MARAUDER_M5STAMP_S3/' esp32_marauder/configs.h - name: Build Marauder for OG Marauder uses: ArminJo/arduino-test-compile@v3.2.1 @@ -277,6 +304,7 @@ jobs: sed -i 's/^ #define MARAUDER_FLIPPER/ \/\/#define MARAUDER_FLIPPER/' esp32_marauder/configs.h sed -i 's/^ #define ESP32_LDDB/ \/\/#define ESP32_LDDB/' esp32_marauder/configs.h sed -i 's/^ #define MARAUDER_DEV_BOARD_PRO/ \/\/#define MARAUDER_DEV_BOARD_PRO/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_M5STAMP_S3/ \/\/#define MARAUDER_M5STAMP_S3/' esp32_marauder/configs.h #- name: Build Marauder for v6 Marauder with arduino/compile-sketches # uses: arduino/compile-sketches@v1 @@ -317,6 +345,7 @@ jobs: sed -i 's/^ #define MARAUDER_FLIPPER/ \/\/#define MARAUDER_FLIPPER/' esp32_marauder/configs.h sed -i 's/^ #define ESP32_LDDB/ \/\/#define ESP32_LDDB/' esp32_marauder/configs.h sed -i 's/^ #define MARAUDER_DEV_BOARD_PRO/ \/\/#define MARAUDER_DEV_BOARD_PRO/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_M5STAMP_S3/ \/\/#define MARAUDER_M5STAMP_S3/' esp32_marauder/configs.h - name: Build Marauder for v6.1 Marauder uses: ArminJo/arduino-test-compile@v3.2.1 @@ -342,6 +371,7 @@ jobs: sed -i 's/^ #define MARAUDER_FLIPPER/ \/\/#define MARAUDER_FLIPPER/' esp32_marauder/configs.h sed -i 's/^ #define ESP32_LDDB/ \/\/#define ESP32_LDDB/' esp32_marauder/configs.h sed -i 's/^ #define MARAUDER_DEV_BOARD_PRO/ \/\/#define MARAUDER_DEV_BOARD_PRO/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_M5STAMP_S3/ \/\/#define MARAUDER_M5STAMP_S3/' esp32_marauder/configs.h - name: Build Marauder for Marauder Kit uses: ArminJo/arduino-test-compile@v3.2.1 @@ -367,6 +397,7 @@ jobs: sed -i 's/^ #define MARAUDER_FLIPPER/ \/\/#define MARAUDER_FLIPPER/' esp32_marauder/configs.h sed -i 's/^ #define ESP32_LDDB/ \/\/#define ESP32_LDDB/' esp32_marauder/configs.h sed -i 's/^ #define MARAUDER_DEV_BOARD_PRO/ \/\/#define MARAUDER_DEV_BOARD_PRO/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_M5STAMP_S3/ \/\/#define MARAUDER_M5STAMP_S3/' esp32_marauder/configs.h - name: Build Marauder for Marauder Mini uses: ArminJo/arduino-test-compile@v3.2.1 @@ -390,6 +421,7 @@ jobs: sed -i 's/^ #define MARAUDER_FLIPPER/ \/\/#define MARAUDER_FLIPPER/' esp32_marauder/configs.h sed -i 's/^ \/\/#define ESP32_LDDB/ #define ESP32_LDDB/' esp32_marauder/configs.h sed -i 's/^ #define MARAUDER_DEV_BOARD_PRO/ \/\/#define MARAUDER_DEV_BOARD_PRO/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_M5STAMP_S3/ \/\/#define MARAUDER_M5STAMP_S3/' esp32_marauder/configs.h - name: Build Marauder for ESP32 LDDB uses: ArminJo/arduino-test-compile@v3.2.1 @@ -413,6 +445,7 @@ jobs: sed -i 's/^ #define MARAUDER_FLIPPER/ \/\/#define MARAUDER_FLIPPER/' esp32_marauder/configs.h sed -i 's/^ #define ESP32_LDDB/ \/\/#define ESP32_LDDB/' esp32_marauder/configs.h sed -i 's/^ \/\/#define MARAUDER_DEV_BOARD_PRO/ #define MARAUDER_DEV_BOARD_PRO/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_M5STAMP_S3/ \/\/#define MARAUDER_M5STAMP_S3/' esp32_marauder/configs.h - name: Build Marauder for Marauder Dev Board Pro uses: ArminJo/arduino-test-compile@v3.2.1 @@ -441,6 +474,7 @@ jobs: sed -i 's/^ #define ESP32_LDDB/ \/\/#define ESP32_LDDB/' esp32_marauder/configs.h sed -i 's/^ #define MARAUDER_DEV_BOARD_PRO/ \/\/#define MARAUDER_DEV_BOARD_PRO/' esp32_marauder/configs.h sed -i 's/^ \/\/#define MARAUDER_M5STICKC/ #define MARAUDER_M5STICKC/' esp32_marauder/configs.h + sed -i 's/^ #define MARAUDER_M5STAMP_S3/ \/\/#define MARAUDER_M5STAMP_S3/' esp32_marauder/configs.h - name: Build Marauder for Marauder M5StickC uses: ArminJo/arduino-test-compile@v3.2.1 @@ -533,6 +567,13 @@ jobs: name: esp32_marauder.m5stickc_plus.bin path: ./esp32_marauder/build/esp32.esp32.m5stick-c/esp32_marauder.m5stickc_plus.bin retention-days: 5 + + - name: 'Upload Marauder StampS3 Artifact' + uses: actions/upload-artifact@v3 + with: + name: esp32_marauder.stampS3.bin + path: ./esp32_marauder/build/esp32.esp32.esp32s3/esp32_marauder.stampS3.bin + retention-days: 5 - name: Create Release id: create_release @@ -677,3 +718,15 @@ jobs: asset_name: esp32_marauder.m5stickc_plus.bin asset_content_type: application/bin if: github.event_name != 'pull_request' + + - name: Upload StampS3 Asset + id: upload-stampS3-release-asset + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + asset_path: ./esp32_marauder/build/esp32.esp32.esp32s3/esp32_marauder.stampS3.bin + asset_name: esp32_marauder.stampS3.bin + asset_content_type: application/bin + if: github.event_name != 'pull_request' \ No newline at end of file diff --git a/esp32_marauder/WiFiScan.cpp b/esp32_marauder/WiFiScan.cpp index abbb234ad..5439cf185 100644 --- a/esp32_marauder/WiFiScan.cpp +++ b/esp32_marauder/WiFiScan.cpp @@ -4562,4 +4562,4 @@ void WiFiScan::main(uint32_t currentTime) packets_sent = 0; } } -} +} \ No newline at end of file diff --git a/esp32_marauder/WiFiScan.h b/esp32_marauder/WiFiScan.h index 46f076ac2..ac1aa9247 100644 --- a/esp32_marauder/WiFiScan.h +++ b/esp32_marauder/WiFiScan.h @@ -373,4 +373,4 @@ class WiFiScan static void wifiSnifferCallback(void* buf, wifi_promiscuous_pkt_type_t type); static void addPacket(wifi_promiscuous_pkt_t *snifferPacket, int len); }; -#endif +#endif \ No newline at end of file diff --git a/esp32_marauder/configs.h b/esp32_marauder/configs.h index 103c511bd..09e6a28f1 100644 --- a/esp32_marauder/configs.h +++ b/esp32_marauder/configs.h @@ -9,6 +9,7 @@ //#define WRITE_PACKETS_SERIAL //// BOARD TARGETS + //#define MARAUDER_M5STAMP_S3 //#define MARAUDER_M5STICKC //#define MARAUDER_MINI //#define MARAUDER_V4 @@ -25,6 +26,22 @@ #define MARAUDER_VERSION "v0.13.4" //// BOARD FEATURES + #ifdef MARAUDER_M5STAMP_S3 + //#define FLIPPER_ZERO_HAT + //#define HAS_BATTERY + //#define HAS_BT + //#define HAS_BUTTONS + #define HAS_NEOPIXEL_LED + //#define HAS_PWR_MGMT + //#define HAS_SCREEN + #define HAS_GPS + #ifndef WRITE_PACKETS_SERIAL + #define HAS_SD + #define USE_SD + #endif + //#define HAS_TEMP_SENSOR + #endif + #ifdef MARAUDER_M5STICKC //#define FLIPPER_ZERO_HAT #define HAS_BATTERY @@ -670,6 +687,10 @@ #define SD_CS -1 #endif + #ifdef MARAUDER_M5STAMP_S3 + #define SD_CS 10 + #endif + #ifdef MARAUDER_FLIPPER #define SD_CS 10 #endif @@ -731,6 +752,8 @@ #define MEM_LOWER_LIM 20000 #elif defined(MARAUDER_FLIPPER) #define MEM_LOWER_LIM 20000 + #elif defined(MARAUDER_M5STAMP_S3) + #define MEM_LOWER_LIM 20000 #elif defined(ESP32_LDDB) #define MEM_LOWER_LIM 20000 #elif defined(MARAUDER_DEV_BOARD_PRO) @@ -743,7 +766,9 @@ //// NEOPIXEL STUFF #ifdef HAS_NEOPIXEL_LED - #if defined(ESP32_LDDB) + #if defined(MARAUDER_M5STAMP_S3) + #define PIN 21 + #elif defined(ESP32_LDDB) #define PIN 17 #elif defined(MARAUDER_DEV_BOARD_PRO) #define PIN 16 @@ -778,6 +803,8 @@ #define MAX_HTML_SIZE 20000 #elif defined(MARAUDER_FLIPPER) #define MAX_HTML_SIZE 20000 + #elif defined(MARAUDER_M5STAMP_S3) + #define MAX_HTML_SIZE 20000 #elif defined(ESP32_LDDB) #define MAX_HTML_SIZE 20000 #elif defined(MARAUDER_DEV_BOARD_PRO) @@ -825,6 +852,15 @@ #define GPS_TX 9 #define GPS_RX 21 #define mac_history_len 512 + #elif defined(MARAUDER_M5STAMP_S3) + #ifdef WRITE_PACKETS_SERIAL + #define GPS_SOFTWARE_SERIAL + #else + #define GPS_SERIAL_INDEX 1 + #endif + #define GPS_TX 9 + #define GPS_RX 21 + #define mac_history_len 512 #elif defined(MARAUDER_M5STICKC) #define GPS_SERIAL_INDEX 1 #define GPS_TX 33 diff --git a/esp32_marauder/esp32_marauder.ino b/esp32_marauder/esp32_marauder.ino index 83a664162..3ba7becf3 100644 --- a/esp32_marauder/esp32_marauder.ino +++ b/esp32_marauder/esp32_marauder.ino @@ -176,10 +176,10 @@ void setup() #endif backlightOff(); -#if BATTERY_ANALOG_ON == 1 - pinMode(BATTERY_PIN, OUTPUT); - pinMode(CHARGING_PIN, INPUT); -#endif + #if BATTERY_ANALOG_ON == 1 + pinMode(BATTERY_PIN, OUTPUT); + pinMode(CHARGING_PIN, INPUT); + #endif // Preset SPI CS pins to avoid bus conflicts #ifdef HAS_SCREEN