Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: sparkfun/SparkFun_RTK_Firmware
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v3.2
Choose a base ref
...
head repository: sparkfun/SparkFun_RTK_Firmware
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref
Loading
Showing 473 changed files with 54,179 additions and 30,250 deletions.
73 changes: 60 additions & 13 deletions .github/workflows/compile-rtk-firmware.yml
Original file line number Diff line number Diff line change
@@ -5,7 +5,7 @@ on:

env:
FILENAME_PREFIX: RTK_Surveyor_Firmware
FIRMWARE_VERSION_MAJOR: 3
FIRMWARE_VERSION_MAJOR: 4
FIRMWARE_VERSION_MINOR: 2
POINTPERFECT_TOKEN: ${{ secrets.POINTPERFECT_TOKEN }}

@@ -40,12 +40,14 @@ jobs:
echo "JSON_ENDING=" >> "$GITHUB_ENV"
echo "JSON_FILE_NAME=RTK-Firmware.json" >> "$GITHUB_ENV"
echo "ENABLE_DEVELOPER=false" >> "$GITHUB_ENV"
echo "DEBUG_LEVEL=none" >> "$GITHUB_ENV"
else
echo "FILE_ENDING_UNDERSCORE=_RC-${{ steps.date.outputs.date }}" >> "$GITHUB_ENV"
echo "FILE_ENDING_NOUNDERSCORE=_RC-${{ steps.dateNoScores.outputs.dateNoScores }}" >> "$GITHUB_ENV"
echo "JSON_ENDING=-${{ steps.dateNoScores.outputs.dateNoScores }}" >> "$GITHUB_ENV"
echo "JSON_FILE_NAME=RTK-RC-Firmware.json" >> "$GITHUB_ENV"
echo "ENABLE_DEVELOPER=true" >> "$GITHUB_ENV"
echo "DEBUG_LEVEL=debug" >> "$GITHUB_ENV"
fi
- name: Setup Arduino CLI
@@ -63,16 +65,19 @@ jobs:

- name: Get Known Libraries
run: arduino-cli lib install
ArduinoJson@6.19.4
ESP32Time@2.0.0
ESP32_BleSerial@1.0.5
"ESP32-OTA-Pull"@1.0.0
Ethernet@2.0.2
JC_Button@2.1.2
sdFat@2.1.1
ArduinoJson@6.19.4
pubsubclient@2.8.0
ESP32_BleSerial@1.0.4
"SparkFun u-blox GNSS v3"@3.0.3
"SparkFun MAX1704x Fuel Gauge Arduino Library"@1.0.4
PubSubClient@2.8.0
"SdFat"@2.1.1
"SparkFun LIS2DH12 Arduino Library"@1.0.3
"ESP32-OTA-Pull"@1.0.0
"SparkFun MAX1704x Fuel Gauge Arduino Library"@1.0.4
"SparkFun u-blox GNSS v3"@3.0.14
SparkFun_WebServer_ESP32_W5500@1.5.5
SSLClientESP32@2.0.0

- name: Enable external libs
run: arduino-cli config set library.enable_unsafe_install true
@@ -89,9 +94,48 @@ jobs:
# cd Firmware/RTK_Surveyor/Patch/
# cp WiFiGeneric.cpp /home/runner/.arduino15/packages/esp32/hardware/esp32/2.0.2/libraries/WiFi/src/WiFiGeneric.cpp

#Patch Server.h to avoid https://github.com/arduino-libraries/Ethernet/issues/88#issuecomment-455498941
#Note: this patch can be removed if/when we upgrade to ESP32 core >= v2.0.6
- name: Patch ESP32 Server.h for Ethernet
run: |
cd Firmware/RTK_Surveyor/Patch/
cp Server.h /home/runner/.arduino15/packages/esp32/hardware/esp32/2.0.2/cores/esp32/Server.h
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.10'

# Configure Python - now we have Python installed, we need to provide everything needed by esptool otherwise the compile fails
- name: Configure Python
run: |
pip3 install pyserial
- name: Update index_html
run: |
cd Firmware/Tools
python index_html_zipper.py ../RTK_Surveyor/AP-Config/index.html ../RTK_Surveyor/form.h
- name: Update main_js
run: |
cd Firmware/Tools
python main_js_zipper.py ../RTK_Surveyor/AP-Config/src/main.js ../RTK_Surveyor/form.h
- name: Commit and push form.h
uses: actions-js/push@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
directory: ./Firmware/RTK_Surveyor
branch: ${{ env.BRANCH }}
message: 'Update form.h via Python'

- name: Copy custom app3M_fat9M_16MB.csv
run:
cp Firmware/app3M_fat9M_16MB.csv /home/runner/.arduino15/packages/esp32/hardware/esp32/2.0.2/tools/partitions/app3M_fat9M_16MB.csv

- name: Compile Sketch
run: arduino-cli compile --fqbn esp32:esp32:esp32 ./Firmware/RTK_Surveyor/RTK_Surveyor.ino
--build-property build.partitions=partitions
run: arduino-cli compile --fqbn "esp32:esp32:esp32":DebugLevel=${{ env.DEBUG_LEVEL }} ./Firmware/RTK_Surveyor/RTK_Surveyor.ino
--build-property build.partitions=app3M_fat9M_16MB
--build-property upload.maximum_size=3145728
--build-property "compiler.cpp.extra_flags=\"-DPOINTPERFECT_TOKEN=$POINTPERFECT_TOKEN\" \"-DFIRMWARE_VERSION_MAJOR=$FIRMWARE_VERSION_MAJOR\" \"-DFIRMWARE_VERSION_MINOR=$FIRMWARE_VERSION_MINOR\" \"-DENABLE_DEVELOPER=${{ env.ENABLE_DEVELOPER }}\""
--export-binaries
@@ -102,13 +146,15 @@ jobs:
mv RTK_Surveyor.ino.bin ${{ env.FILENAME_PREFIX }}${{ env.FILE_ENDING_UNDERSCORE }}.bin
- name: Upload binary to action
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: ${{ env.FILENAME_PREFIX }}${{ env.FILE_ENDING_UNDERSCORE }}
path: ./Firmware/RTK_Surveyor/build/esp32.esp32.esp32/${{ env.FILENAME_PREFIX }}${{ env.FILE_ENDING_UNDERSCORE }}.bin


- name: Push binary to Binaries Repo
uses: dmnemec/copy_file_to_another_repo_action@main
# uses: dmnemec/copy_file_to_another_repo_action #Workaround for Issue: https://github.com/orgs/community/discussions/55820#discussioncomment-5946136
uses: Jason2866/copy_file_to_another_repo_action@http408_fix
env:
API_TOKEN_GITHUB: ${{ secrets.API_GITHUB_RTK_FILE_TOKEN }}
with:
@@ -128,7 +174,8 @@ jobs:
{"Configurations": [{"Version":"${{ env.FIRMWARE_VERSION_MAJOR }}.${{ env.FIRMWARE_VERSION_MINOR }}${{ env.JSON_ENDING }}", "URL":"https://raw.githubusercontent.com/sparkfun/SparkFun_RTK_Firmware_Binaries/main/${{ env.FILENAME_PREFIX }}${{ env.FILE_ENDING_UNDERSCORE }}.bin"}]}
- name: Push JSON to Binaries Repo
uses: dmnemec/copy_file_to_another_repo_action@main
# uses: dmnemec/copy_file_to_another_repo_action #Workaround for Issue: https://github.com/orgs/community/discussions/55820#discussioncomment-5946136
uses: Jason2866/copy_file_to_another_repo_action@http408_fix
env:
API_TOKEN_GITHUB: ${{ secrets.API_GITHUB_RTK_FILE_TOKEN }}
with:
5 changes: 3 additions & 2 deletions .github/workflows/mkdocs.yml
Original file line number Diff line number Diff line change
@@ -10,6 +10,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: 3.x
- run: pip install mkdocs-material mkdocs-monorepo-plugin
python-version: 3.12.0
- run: pip install mkdocs-material mkdocs-monorepo-plugin setuptools
- run: pip install mkdocs-with-pdf
- run: mkdocs gh-deploy --force
150 changes: 150 additions & 0 deletions .github/workflows/non-release-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,150 @@
name: RTK Firmware Non-Release Build
on:
workflow_dispatch:
branches:

env:
FILENAME_PREFIX: RTK_Surveyor_Firmware
FIRMWARE_VERSION_MAJOR: 99
FIRMWARE_VERSION_MINOR: 99
POINTPERFECT_TOKEN: ${{ secrets.POINTPERFECT_TOKEN }}

jobs:
build:

name: Build
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@master

- name: Get current date
id: date
run: echo "date=$(date +'%b_%d_%Y')" >> $GITHUB_OUTPUT

- name: Get current date
id: dateNoScores
run: echo "dateNoScores=$(date +'%b %d %Y')" >> $GITHUB_OUTPUT

- name: Extract branch name
run: echo "BRANCH=${{github.ref_name}}" >> $GITHUB_ENV

#File_Name_v3_1.bin
#File_Name_RC-Jan_26_2023.bin
- name: Create file ending and compiler flags based on branch
run: |
echo "FILE_ENDING_UNDERSCORE=_RC-${{ steps.date.outputs.date }}" >> "$GITHUB_ENV"
echo "FILE_ENDING_NOUNDERSCORE=_RC-${{ steps.dateNoScores.outputs.dateNoScores }}" >> "$GITHUB_ENV"
echo "JSON_ENDING=-${{ steps.dateNoScores.outputs.dateNoScores }}" >> "$GITHUB_ENV"
echo "JSON_FILE_NAME=RTK-RC-Firmware.json" >> "$GITHUB_ENV"
echo "ENABLE_DEVELOPER=true" >> "$GITHUB_ENV"
echo "DEBUG_LEVEL=debug" >> "$GITHUB_ENV"
- name: Setup Arduino CLI
uses: arduino/setup-arduino-cli@v1

- name: Start config file
run: arduino-cli config init --additional-urls "https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json"

- name: Update index
run: arduino-cli core update-index

#We limit the ESP32 core to v2.0.2
- name: Install platform
run: arduino-cli core install esp32:esp32@2.0.2

- name: Get Known Libraries
run: arduino-cli lib install
ArduinoJson@6.19.4
ESP32Time@2.0.0
ESP32_BleSerial@1.0.5
"ESP32-OTA-Pull"@1.0.0
Ethernet@2.0.2
JC_Button@2.1.2
PubSubClient@2.8.0
"SdFat"@2.1.1
"SparkFun LIS2DH12 Arduino Library"@1.0.3
"SparkFun MAX1704x Fuel Gauge Arduino Library"@1.0.4
"SparkFun u-blox GNSS v3"@3.0.14
SparkFun_WebServer_ESP32_W5500@1.5.5
SSLClientESP32@2.0.0

- name: Enable external libs
run: arduino-cli config set library.enable_unsafe_install true

- name: Get Libraries
run: arduino-cli lib install --git-url
https://github.com/sparkfun/SparkFun_Qwiic_OLED_Arduino_Library.git
https://github.com/me-no-dev/ESPAsyncWebServer.git
https://github.com/me-no-dev/AsyncTCP.git

#Incorporate ESP-Now patch into core: https://github.com/espressif/arduino-esp32/pull/7044/files
#- name: Patch ESP32 Core
# run: |
# cd Firmware/RTK_Surveyor/Patch/
# cp WiFiGeneric.cpp /home/runner/.arduino15/packages/esp32/hardware/esp32/2.0.2/libraries/WiFi/src/WiFiGeneric.cpp

#Patch Server.h to avoid https://github.com/arduino-libraries/Ethernet/issues/88#issuecomment-455498941
#Note: this patch can be removed if/when we upgrade to ESP32 core >= v2.0.6
- name: Patch ESP32 Server.h for Ethernet
run: |
cd Firmware/RTK_Surveyor/Patch/
cp Server.h /home/runner/.arduino15/packages/esp32/hardware/esp32/2.0.2/cores/esp32/Server.h
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.10'

# Configure Python - now we have Python installed, we need to provide everything needed by esptool otherwise the compile fails
- name: Configure Python
run: |
pip3 install pyserial
- name: Update index_html
run: |
cd Firmware/Tools
python index_html_zipper.py ../RTK_Surveyor/AP-Config/index.html ../RTK_Surveyor/form.h
- name: Update main_js
run: |
cd Firmware/Tools
python main_js_zipper.py ../RTK_Surveyor/AP-Config/src/main.js ../RTK_Surveyor/form.h
- name: Commit and push form.h
uses: actions-js/push@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
directory: ./Firmware/RTK_Surveyor
branch: ${{ env.BRANCH }}
message: 'Update form.h via Python'

- name: Copy custom app3M_fat9M_16MB.csv
run:
cp Firmware/app3M_fat9M_16MB.csv /home/runner/.arduino15/packages/esp32/hardware/esp32/2.0.2/tools/partitions/app3M_fat9M_16MB.csv

- name: Compile Sketch
run: arduino-cli compile --fqbn "esp32:esp32:esp32":DebugLevel=${{ env.DEBUG_LEVEL }} ./Firmware/RTK_Surveyor/RTK_Surveyor.ino
--build-property build.partitions=app3M_fat9M_16MB
--build-property upload.maximum_size=3145728
--build-property "compiler.cpp.extra_flags=\"-DPOINTPERFECT_TOKEN=$POINTPERFECT_TOKEN\" \"-DFIRMWARE_VERSION_MAJOR=$FIRMWARE_VERSION_MAJOR\" \"-DFIRMWARE_VERSION_MINOR=$FIRMWARE_VERSION_MINOR\" \"-DENABLE_DEVELOPER=${{ env.ENABLE_DEVELOPER }}\""
--export-binaries

- name: Create artifact name
run: |
echo "ARTIFACT=${{ env.FILENAME_PREFIX }}${{ env.FILE_ENDING_UNDERSCORE }}" >> $GITHUB_ENV
- name: Create artifact directory
run: |
cd Firmware/RTK_Surveyor/build/esp32.esp32.esp32/
mkdir ${{ env.ARTIFACT }}
mv RTK_Surveyor.ino.bin ${{ env.ARTIFACT }}
mv RTK_Surveyor.ino.elf ${{ env.ARTIFACT }}
- name: Upload artifact directory to action - avoid double-zip
uses: actions/upload-artifact@v3
with:
name: ${{ env.ARTIFACT }}
path: Firmware/RTK_Surveyor/build/esp32.esp32.esp32/${{ env.ARTIFACT }}
retention-days: 7
14 changes: 14 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
partitions.csv

tokens.h
.vscode/*

# Windows image file caches
Thumbs.db
@@ -43,3 +46,14 @@ Icon
# Files that might appear on external disk
.Spotlight-V100
.Trashes

# =========================
# Linux Files
# =========================

Compare
NMEA_Client
Read_Map_File
RTK_Reset
Split_Messages
X.509_crt_bundle_bin_to_c
File renamed without changes.
Loading