Some checks failed
CC2530 Zigbee Firmware Build / build (push) Failing after 20s
- The changes to the CI workflow script update the installation commands for the MSP430 GCC toolchain and its dependencies, switching from alternative methods to direct downloads.
81 lines
3.1 KiB
YAML
81 lines
3.1 KiB
YAML
name: CC2530 Zigbee Firmware Build
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main # Triggers the action when code is pushed to the main branch
|
|
pull_request:
|
|
branches:
|
|
- main # Triggers the action for pull requests targeting the main branch
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest # You can use `windows-latest` or `macos-latest` as well if your toolchain is compatible
|
|
|
|
steps:
|
|
- name: Checkout Code
|
|
uses: actions/checkout@v4 # Checkout the code from your GitHub repository
|
|
with:
|
|
github-server-url: ${{ vars.GIT_SERVER_URL }}
|
|
|
|
- name: Set up toolchain (IAR or CCS)
|
|
run: |
|
|
# Install dependencies for IAR or CCS toolchain
|
|
# Example: For IAR Workbench you might need to install some packages or configure environment variables.
|
|
|
|
sudo apt-get update
|
|
sudo apt-get install -y gcc build-essential make
|
|
# sudo apt-get -y install gcc-msp430
|
|
|
|
# Install MSP430 GCC toolchain using alternative method
|
|
# Add the MSP430 tools repository and install the tools
|
|
sudo apt-get install -y wget p7zip-full
|
|
|
|
# Download the MSP430 GCC toolchain from TI's official link
|
|
wget https://dr-download.ti.com/software-development/ide-configuration-compiler-or-debugger/MD-LlCjWuAbzH/9.3.1.2/msp430-gcc-full-linux-x64-installer-9.3.1.2.7z
|
|
|
|
# Extract the .7z installer
|
|
7z x msp430-gcc-full-linux-x64-installer-9.3.1.2.7z -o/msp430-gcc
|
|
|
|
# Install the MSP430 GCC toolchain by copying to the appropriate location
|
|
sudo cp -r /msp430-gcc/gcc-msp430-9.3.1.2/* /usr/local/
|
|
|
|
# You would also install the necessary firmware building tools if they are available
|
|
# or set up cross-compilation for ARM
|
|
|
|
- name: Build Firmware (For IAR or CCS)
|
|
run: |
|
|
# Run the build command for your firmware
|
|
# Assuming you're using IAR or CCS, you'd need to invoke the build system here.
|
|
# For example:
|
|
# make
|
|
# Or use IAR's compiler directly (e.g., via command line invocation)
|
|
|
|
# Example for make-based build system:
|
|
make all
|
|
|
|
- name: Check Build Results
|
|
run: |
|
|
if [ ! -f "build/firmware.hex" ]; then
|
|
echo "Build failed: Firmware not found!"
|
|
exit 1
|
|
else
|
|
echo "Build successful!"
|
|
rm build/firmware.hex
|
|
fi
|
|
|
|
# - name: Flash Firmware to CC2530 (optional)
|
|
# run: |
|
|
# # If you have a setup to flash the firmware to a CC2530 device over USB or other methods, you can set that up here
|
|
# # This would require a USB device with the CC2530 or CC2530 development board connected to your machine
|
|
# # Example of flashing tool (modify accordingly):
|
|
# # python flash_tool.py build/firmware.hex
|
|
|
|
# echo "Flashing firmware would go here (not implemented)"
|
|
|
|
# - name: Upload Firmware Artifact (optional)
|
|
# uses: actions/upload-artifact@v2
|
|
# with:
|
|
# name: firmware
|
|
# path: build/firmware.hex
|