Skip to content

Commit df2ac55

Browse files
authored
Merge pull request #224 from sparkfun/release_candidate
v2.11 - with Dockerfile updates
2 parents 721d455 + 3265fae commit df2ac55

18 files changed

+310
-330
lines changed

.github/workflows/build-for-release.yml

Lines changed: 9 additions & 126 deletions
Original file line numberDiff line numberDiff line change
@@ -34,141 +34,24 @@ jobs:
3434
echo "firmwareMajorMinor=-V10-v${{ env.firmwareMajor }}${{ env.firmwareMinor }}" >> "$GITHUB_ENV"
3535
echo "firmwareMajorMinorX04=-X04-v${{ env.firmwareMajor }}${{ env.firmwareMinor }}" >> "$GITHUB_ENV"
3636
37-
- name: Setup Arduino CLI
38-
uses: arduino/setup-arduino-cli@v1
39-
40-
- name: Start config file
41-
run: arduino-cli config init --additional-urls "https://raw.githubusercontent.com/sparkfun/Arduino_Apollo3/main/package_sparkfun_apollo3_index.json"
42-
43-
- name: Update index
44-
run: arduino-cli core update-index
45-
46-
- name: Install platform
47-
run: arduino-cli core install "Sparkfun:[email protected]"
48-
49-
- name: Get Known Libraries
50-
run: arduino-cli lib install
51-
52-
"SparkFun 9DoF IMU Breakout - ICM 20948 - Arduino Library"
53-
"SparkFun I2C Mux Arduino Library"
54-
"SparkFun CCS811 Arduino Library"
55-
"SparkFun VL53L1X 4m Laser Distance Sensor"
56-
"SparkFun BME280"
57-
"SparkFun LPS25HB Pressure Sensor Library"
58-
"SparkFun VEML6075 Arduino Library"
59-
"SparkFun PHT MS8607 Arduino Library"
60-
"SparkFun MCP9600 Thermocouple Library"
61-
"SparkFun SGP30 Arduino Library"
62-
"SparkFun VCNL4040 Proximity Sensor Library"
63-
"SparkFun MS5637 Barometric Pressure Library"
64-
"SparkFun High Precision Temperature Sensor TMP117 Qwiic"
65-
"SparkFun u-blox GNSS Arduino Library"
66-
"SparkFun 6DoF ISM330DHCX"
67-
"SparkFun Qwiic Scale NAU7802 Arduino Library"
68-
"SparkFun SCD30 Arduino Library"
69-
"SparkFun Qwiic Humidity AHT20"
70-
"SparkFun SHTC3 Humidity and Temperature Sensor Library"
71-
"SparkFun ADS122C04 ADC Arduino Library"
72-
"SparkFun MicroPressure Library"
73-
"SparkFun Particle Sensor Panasonic SN-GCJA5"
74-
"SparkFun SGP40 Arduino Library"
75-
"SparkFun Qwiic Button and Qwiic Switch Library"
76-
"SparkFun Bio Sensor Hub Library"
77-
"SparkFun MMC5983MA Magnetometer Arduino Library"
78-
"SparkFun ADS1015 Arduino Library"
79-
"SparkFun KX13X Arduino Library"
80-
"SparkFun SDP3x Arduino Library"
81-
"SparkFun LPS28DFW Arduino Library"
82-
"SparkFun VEML7700 Arduino Library"
83-
"SparkFun TMP102 Breakout"
84-
85-
- name: Enable external libs
86-
run: arduino-cli config set library.enable_unsafe_install true
87-
88-
- name: Get Libraries
89-
run: arduino-cli lib install --git-url
90-
https://github.com/bluerobotics/BlueRobotics_MS5837_Library.git
91-
92-
- name: Enable ICM20948 DMP
93-
run: sed -i 's|//#define ICM_20948_USE_DMP|#define ICM_20948_USE_DMP|g' /home/runner/Arduino/libraries/SparkFun_9DoF_IMU_Breakout_-_ICM_20948_-_Arduino_Library/src/util/ICM_20948_C.h
94-
95-
- name: Patch Apollo3 Core
37+
- name: Run Dockerfile and copy files
9638
run: |
97-
cd ./Extras
98-
unzip UartPower3.zip
99-
cp HardwareSerial.h /home/runner/.arduino15/packages/SparkFun/hardware/apollo3/2.2.1/cores/arduino/mbed-bridge/core-extend/HardwareSerial.h
100-
cp HardwareSerial.cpp /home/runner/.arduino15/packages/SparkFun/hardware/apollo3/2.2.1/cores/arduino/mbed-bridge/core-implement/HardwareSerial.cpp
101-
cp UnbufferedSerial.h /home/runner/.arduino15/packages/SparkFun/hardware/apollo3/2.2.1/cores/mbed-os/drivers/UnbufferedSerial.h
102-
cp serial_api.c /home/runner/.arduino15/packages/SparkFun/hardware/apollo3/2.2.1/cores/mbed-os/targets/TARGET_Ambiq_Micro/TARGET_Apollo3/device/serial_api.c
103-
cp libmbed-os.a /home/runner/.arduino15/packages/SparkFun/hardware/apollo3/2.2.1/variants/SFE_ARTEMIS_ATP/mbed/libmbed-os.a
104-
cp SPI.cpp /home/runner/.arduino15/packages/SparkFun/hardware/apollo3/2.2.1/libraries/SPI/src/SPI.cpp
105-
rm *.h
106-
rm *.cpp
107-
rm *.a
108-
rm *.c
109-
rm *.odt
110-
111-
- name: Compile Sketch
112-
run: arduino-cli compile -v -e -b SparkFun:apollo3:sfe_artemis_atp ./Firmware/${{ env.FILENAME_PREFIX }}/${{ env.FILENAME_PREFIX }}.ino
39+
cd ./Firmware
40+
docker build -t openlog_artemis_image --no-cache .
41+
docker create --name=openlog_artemis_container openlog_artemis_image:latest
42+
mkdir ./build
43+
docker cp openlog_artemis_container:/${{ env.FILENAME_PREFIX }}.ino.bin ./build
44+
docker container rm openlog_artemis_container
11345
11446
- name: Rename binary
11547
run: |
116-
cd ./Firmware/${{ env.FILENAME_PREFIX }}/build/SparkFun.apollo3.sfe_artemis_atp/
48+
cd ./Firmware/build/
11749
mv ${{ env.FILENAME_PREFIX }}.ino.bin ${{ env.FILENAME_PREFIX }}${{ env.firmwareMajorMinor }}.bin
118-
echo "targetBinary=./Firmware/${{ env.FILENAME_PREFIX }}/build/SparkFun.apollo3.sfe_artemis_atp/${{ env.FILENAME_PREFIX }}${{ env.firmwareMajorMinor }}.bin" >> "$GITHUB_ENV"
119-
rm *.axf
120-
rm *.hex
121-
rm *.map
50+
echo "targetBinary=./Firmware/build/${{ env.FILENAME_PREFIX }}${{ env.firmwareMajorMinor }}.bin" >> "$GITHUB_ENV"
12251
12352
- name: Move binary
12453
run: mv ${{ env.targetBinary }} ./Binaries
12554

126-
- name: Enable Power Loss Protection
127-
run: sed -i 's|//#define noPowerLossProtection|#define noPowerLossProtection|g' ./Firmware/${{ env.FILENAME_PREFIX }}/${{ env.FILENAME_PREFIX }}.ino
128-
129-
- name: Compile Sketch
130-
run: arduino-cli compile -v -e -b SparkFun:apollo3:sfe_artemis_atp ./Firmware/${{ env.FILENAME_PREFIX }}/${{ env.FILENAME_PREFIX }}.ino
131-
132-
- name: Rename binary
133-
run: |
134-
cd ./Firmware/${{ env.FILENAME_PREFIX }}/build/SparkFun.apollo3.sfe_artemis_atp/
135-
mv ${{ env.FILENAME_PREFIX }}.ino.bin ${{ env.FILENAME_PREFIX }}${{ env.firmwareMajorMinor }}-NoPowerLossProtection.bin
136-
echo "targetBinary=./Firmware/${{ env.FILENAME_PREFIX }}/build/SparkFun.apollo3.sfe_artemis_atp/${{ env.FILENAME_PREFIX }}${{ env.firmwareMajorMinor }}-NoPowerLossProtection.bin" >> "$GITHUB_ENV"
137-
rm *.axf
138-
rm *.hex
139-
rm *.map
140-
141-
- name: Move binary
142-
run: mv ${{ env.targetBinary }} ./Binaries
143-
144-
- name: Disable Power Loss Protection
145-
run: sed -i 's|#define noPowerLossProtection|//#define noPowerLossProtection|g' ./Firmware/${{ env.FILENAME_PREFIX }}/${{ env.FILENAME_PREFIX }}.ino
146-
147-
- name: X04 Hardware
148-
run: |
149-
sed -i 's|#define HARDWARE_VERSION_MAJOR 1|#define HARDWARE_VERSION_MAJOR 0|g' ./Firmware/${{ env.FILENAME_PREFIX }}/${{ env.FILENAME_PREFIX }}.ino
150-
sed -i 's|#define HARDWARE_VERSION_MINOR 0|#define HARDWARE_VERSION_MINOR 4|g' ./Firmware/${{ env.FILENAME_PREFIX }}/${{ env.FILENAME_PREFIX }}.ino
151-
152-
- name: Compile Sketch
153-
run: arduino-cli compile -v -e -b SparkFun:apollo3:sfe_artemis_atp ./Firmware/${{ env.FILENAME_PREFIX }}/${{ env.FILENAME_PREFIX }}.ino
154-
155-
- name: Rename binary
156-
run: |
157-
cd ./Firmware/${{ env.FILENAME_PREFIX }}/build/SparkFun.apollo3.sfe_artemis_atp/
158-
mv ${{ env.FILENAME_PREFIX }}.ino.bin ${{ env.FILENAME_PREFIX }}${{ env.firmwareMajorMinorX04 }}.bin
159-
echo "targetBinary=./Firmware/${{ env.FILENAME_PREFIX }}/build/SparkFun.apollo3.sfe_artemis_atp/${{ env.FILENAME_PREFIX }}${{ env.firmwareMajorMinorX04 }}.bin" >> "$GITHUB_ENV"
160-
rm *.axf
161-
rm *.hex
162-
rm *.map
163-
164-
- name: Move binary
165-
run: mv ${{ env.targetBinary }} ./Binaries
166-
167-
- name: V01 Hardware
168-
run: |
169-
sed -i 's|#define HARDWARE_VERSION_MAJOR 0|#define HARDWARE_VERSION_MAJOR 1|g' ./Firmware/${{ env.FILENAME_PREFIX }}/${{ env.FILENAME_PREFIX }}.ino
170-
sed -i 's|#define HARDWARE_VERSION_MINOR 4|#define HARDWARE_VERSION_MINOR 0|g' ./Firmware/${{ env.FILENAME_PREFIX }}/${{ env.FILENAME_PREFIX }}.ino
171-
17255
- uses: actions-js/push@master
17356
with:
17457
github_token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/non-release-build.yml

Lines changed: 9 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -29,83 +29,20 @@ jobs:
2929
- name: Get firmware version 2
3030
run: echo "firmwareMajorMinor=-V10-v${{ env.firmwareMajor }}${{ env.firmwareMinor }}" >> "$GITHUB_ENV"
3131

32-
- name: Setup Arduino CLI
33-
uses: arduino/setup-arduino-cli@v1
34-
35-
- name: Start config file
36-
run: arduino-cli config init --additional-urls "https://raw.githubusercontent.com/sparkfun/Arduino_Apollo3/main/package_sparkfun_apollo3_index.json"
37-
38-
- name: Update index
39-
run: arduino-cli core update-index
40-
41-
- name: Install platform
42-
run: arduino-cli core install "Sparkfun:[email protected]"
43-
44-
- name: Get Known Libraries
45-
run: arduino-cli lib install
46-
47-
"SparkFun 9DoF IMU Breakout - ICM 20948 - Arduino Library"
48-
"SparkFun I2C Mux Arduino Library"
49-
"SparkFun CCS811 Arduino Library"
50-
"SparkFun VL53L1X 4m Laser Distance Sensor"
51-
"SparkFun BME280"
52-
"SparkFun LPS25HB Pressure Sensor Library"
53-
"SparkFun VEML6075 Arduino Library"
54-
"SparkFun PHT MS8607 Arduino Library"
55-
"SparkFun MCP9600 Thermocouple Library"
56-
"SparkFun SGP30 Arduino Library"
57-
"SparkFun VCNL4040 Proximity Sensor Library"
58-
"SparkFun MS5637 Barometric Pressure Library"
59-
"SparkFun High Precision Temperature Sensor TMP117 Qwiic"
60-
"SparkFun u-blox GNSS Arduino Library"
61-
"SparkFun 6DoF ISM330DHCX"
62-
"SparkFun Qwiic Scale NAU7802 Arduino Library"
63-
"SparkFun SCD30 Arduino Library"
64-
"SparkFun Qwiic Humidity AHT20"
65-
"SparkFun SHTC3 Humidity and Temperature Sensor Library"
66-
"SparkFun ADS122C04 ADC Arduino Library"
67-
"SparkFun MicroPressure Library"
68-
"SparkFun Particle Sensor Panasonic SN-GCJA5"
69-
"SparkFun SGP40 Arduino Library"
70-
"SparkFun Qwiic Button and Qwiic Switch Library"
71-
"SparkFun Bio Sensor Hub Library"
72-
"SparkFun MMC5983MA Magnetometer Arduino Library"
73-
"SparkFun ADS1015 Arduino Library"
74-
"SparkFun KX13X Arduino Library"
75-
"SparkFun SDP3x Arduino Library"
76-
"SparkFun LPS28DFW Arduino Library"
77-
"SparkFun VEML7700 Arduino Library"
78-
"SparkFun TMP102 Breakout"
79-
80-
- name: Enable external libs
81-
run: arduino-cli config set library.enable_unsafe_install true
82-
83-
- name: Get Libraries
84-
run: arduino-cli lib install --git-url
85-
https://github.com/bluerobotics/BlueRobotics_MS5837_Library.git
86-
87-
- name: Enable ICM20948 DMP
88-
run: sed -i 's|//#define ICM_20948_USE_DMP|#define ICM_20948_USE_DMP|g' /home/runner/Arduino/libraries/SparkFun_9DoF_IMU_Breakout_-_ICM_20948_-_Arduino_Library/src/util/ICM_20948_C.h
89-
90-
- name: Patch Apollo3 Core
32+
- name: Run Dockerfile and copy files
9133
run: |
92-
cd ./Extras
93-
unzip UartPower3.zip
94-
cp HardwareSerial.h /home/runner/.arduino15/packages/SparkFun/hardware/apollo3/2.2.1/cores/arduino/mbed-bridge/core-extend/HardwareSerial.h
95-
cp HardwareSerial.cpp /home/runner/.arduino15/packages/SparkFun/hardware/apollo3/2.2.1/cores/arduino/mbed-bridge/core-implement/HardwareSerial.cpp
96-
cp UnbufferedSerial.h /home/runner/.arduino15/packages/SparkFun/hardware/apollo3/2.2.1/cores/mbed-os/drivers/UnbufferedSerial.h
97-
cp serial_api.c /home/runner/.arduino15/packages/SparkFun/hardware/apollo3/2.2.1/cores/mbed-os/targets/TARGET_Ambiq_Micro/TARGET_Apollo3/device/serial_api.c
98-
cp libmbed-os.a /home/runner/.arduino15/packages/SparkFun/hardware/apollo3/2.2.1/variants/SFE_ARTEMIS_ATP/mbed/libmbed-os.a
99-
cp SPI.cpp /home/runner/.arduino15/packages/SparkFun/hardware/apollo3/2.2.1/libraries/SPI/src/SPI.cpp
100-
101-
- name: Compile Sketch
102-
run: arduino-cli compile -v -e -b SparkFun:apollo3:sfe_artemis_atp ./Firmware/${{ env.FILENAME_PREFIX }}/${{ env.FILENAME_PREFIX }}.ino
34+
cd ./Firmware
35+
docker build -t openlog_artemis_image --no-cache .
36+
docker create --name=openlog_artemis_container openlog_artemis_image:latest
37+
mkdir ./build
38+
docker cp openlog_artemis_container:/${{ env.FILENAME_PREFIX }}.ino.bin ./build
39+
docker container rm openlog_artemis_container
10340
10441
- name: Rename binary
10542
run: |
106-
cd ./Firmware/${{ env.FILENAME_PREFIX }}/build/SparkFun.apollo3.sfe_artemis_atp/
43+
cd ./Firmware/build
10744
mv ${{ env.FILENAME_PREFIX }}.ino.bin ${{ env.FILENAME_PREFIX }}${{ env.firmwareMajorMinor }}.bin
108-
echo "targetBinary=./Firmware/${{ env.FILENAME_PREFIX }}/build/SparkFun.apollo3.sfe_artemis_atp/${{ env.FILENAME_PREFIX }}${{ env.firmwareMajorMinor }}.bin" >> "$GITHUB_ENV"
45+
echo "targetBinary=./Firmware/build/${{ env.FILENAME_PREFIX }}${{ env.firmwareMajorMinor }}.bin" >> "$GITHUB_ENV"
10946
11047
- name: Upload binary to action
11148
uses: actions/upload-artifact@v4

CHANGELOG.md

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,33 @@
11
Change Log
22
======================
3+
4+
v2.11:
5+
---------
6+
7+
* Adds support for LPS28DFW Mode 2 (4060 hPa) - thank you @thebrownhobbit-commits #221
8+
* Updates the Dockerfile to include the required library versions
9+
* Adds `compile_with_docker.bat` to automatically generate the firmware binary - see [COMPILE_BINARY.md](./COMPILE_BINARY.md) for details
10+
* Updates the workflows to use the Dockerfile to generate the firmware binary
11+
12+
v2.10:
13+
---------
14+
15+
* Restructures the serial logging code in loop()
16+
* Where possible, residual serial data is written to file before closing
17+
* Allows all log files to be deleted via `RM *` or `DEL *` in the SD menu
18+
319
v2.9:
4-
* Adds support for the TMP102 temperature sensor
20+
---------
21+
22+
* Adds support for the TMP102 temperature sensor - thank you @summetj #200
523

624
v2.8:
725
---------
826

927
* Corrects the serial token timestamp printing - resolves #192
1028
* The charsReceived debug print ("Total chars received: ") now excludes the length of the timestamps
1129
* Consistent use of File32/ExFile/FsFile/File. Don't use SdFile for temporary files
30+
* Corrects the KX134 32G menu option - resolves #197
1231

1332
v2.7:
1433
---------

0 commit comments

Comments
 (0)