Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
53 commits
Select commit Hold shift + click to select a range
18ae653
Update max TX power definitions for Si1060 radios
povik Feb 25, 2022
02b2b86
Fix serial flow control on Si1060 radios
povik Feb 25, 2022
dd59e70
Clean up Si1060 radio init
povik Feb 25, 2022
448539f
On ISM01A start supporting antenna diversity
povik Feb 26, 2022
737cfeb
Add TFSIK01A board
povik Jul 26, 2023
b6e5dd8
Clean up stale comments in ISM01A header
povik Jul 26, 2023
30090a4
tools/modem_reset.py: Take port from command line
povik Jul 26, 2023
45832ec
Rely on Git for version string
povik Jul 26, 2023
382d8c9
Add GitHub CI
povik Jul 28, 2023
c45b5fe
ci: Rename release archive
povik Jul 28, 2023
888d0bb
ci: Change trigger of release building
povik Jul 28, 2023
af42176
Revert "ci: Change trigger of release building"
povik Jul 28, 2023
136de1a
Update README.markdown
kaklik Jul 28, 2023
77bee45
ci: Upload build test artifacts
povik Jul 31, 2023
abb0f9a
Fix obtaining version during build
povik Jul 31, 2023
cd87a81
ci: Increase fetch depth on test builds
povik Aug 3, 2023
3cd8974
Update README.markdown
kaklik Aug 18, 2023
33a177b
Update README.markdown
kaklik Aug 18, 2023
a8913d8
Update README.markdown
kaklik Aug 18, 2023
da8fb08
Update at.c
kaklik Aug 18, 2023
feac1e6
Correct TFSIK01A board name.
kaklik Aug 18, 2023
4b328ef
Update README.markdown
kaklik Aug 22, 2023
bb9152b
Add definition to LED D1 on TFSIK01A modem.
kaklik Aug 30, 2023
f124391
Enable selected antenna indication #8.
kaklik Sep 3, 2023
031da82
Adjust diversity LED indication on TFSIK
povik Sep 6, 2023
9550610
Update test_build.yml
MarkSuckerberg Feb 27, 2025
61c0f39
Update test_build.yml
MarkSuckerberg Feb 27, 2025
73aa490
Update test_build.yml
MarkSuckerberg Feb 27, 2025
4d533da
Update README.markdown
kaklik Mar 25, 2025
039e94b
Update README.markdown
kaklik Mar 25, 2025
14eed33
Merge pull request #14 from ArduPilot/master
kaklik Mar 29, 2025
fc31080
Merge pull request #15 from MarkSuckerberg/master
kaklik Mar 29, 2025
04ece98
Upload github actions versions.
kaklik Mar 29, 2025
9438551
Remove pithon2 from install list.
kaklik Mar 29, 2025
729ec0d
Update README.markdown
kaklik Apr 7, 2025
e2b5540
Update README.markdown
kaklik Apr 7, 2025
d42c358
Update README.markdown
kaklik Apr 8, 2025
5592f1f
Update link to correct version of EC2 tools.
kaklik Jun 13, 2025
e1858ec
Update README.markdown
kaklik Sep 25, 2025
02c9cf3
Update README.markdown
kaklik Sep 25, 2025
bfebec6
Improve handling of non-default crystal frequencies (#19)
kaklik Sep 27, 2025
9000c4a
Update release.yaml
kaklik Sep 27, 2025
e0cf32c
Add CW test mode using standard transmit loop
kaklik Sep 27, 2025
8bcc01e
Reuse existing TX buffer for CW test mode
kaklik Sep 27, 2025
75cee79
Merge pull request #21 from ThunderFly-aerospace/codex/add-at_test_cw…
kaklik Sep 27, 2025
7a56934
Update README.markdown
kaklik Sep 27, 2025
c5058f0
Update testing script to make it executable again.
kaklik Nov 11, 2025
bac0c22
Fix python errors.
kaklik Nov 11, 2025
2a33931
Normalize line endings to LF per .gitattributes
slimonslimon Apr 24, 2026
f9bfa5b
Make sources compile with SDCC 4.5
slimonslimon Apr 24, 2026
f1385d4
Prevent crash from unexpected characters.
kaklik Apr 30, 2026
392f681
Merge remote-tracking branch 'origin/master'
slimonslimon May 14, 2026
556d62f
Fix intermittent timeout in rssi.py
kaklik Jun 16, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
* text=auto
*.c text eol=lf
*.h text eol=lf

25 changes: 25 additions & 0 deletions .github/workflows/build-firmware.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Build firmware

on:
push:
branches: [ "*" ]

jobs:
build-firmware:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 20
- name: Install dependencies
run: |
sudo apt update && sudo apt install -y sdcc build-essential
- name: Build
run: |
make -C Firmware/ all install
- name: Archive build artifacts
uses: actions/upload-artifact@v4
with:
name: firmware
path: |
Firmware/dst/*
36 changes: 36 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Release

on:
release:
types:
- published
permissions:
contents: write

jobs:
build-firmware:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install dependencies
run: |
sudo apt update && sudo apt install -y sdcc build-essential zip
- name: Build
run: |
make -C Firmware/ all install
- name: Compress
run: |
mkdir -p $ARCHIVE
cp Firmware/dst/* $ARCHIVE/
zip -o $ARCHIVE.zip -r $ARCHIVE/
env:
ARCHIVE: SiK-Firmware-${{ github.event.release.tag_name }}
- name: Upload
uses: actions/upload-release-asset@v1.0.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: SiK-Firmware-${{ github.event.release.tag_name }}.zip
asset_name: SiK-Firmware-${{ github.event.release.tag_name }}.zip
asset_content_type: binary/octet-stream
4 changes: 2 additions & 2 deletions .github/workflows/test_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
runs-on: ubuntu-22.04
steps:
# git checkout the PR
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Install sdcc
run: |
Expand All @@ -20,7 +20,7 @@ jobs:
tests/test_build.sh

- name: Archive build binaries
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: SiK build
path: |
Expand Down
4 changes: 2 additions & 2 deletions Firmware/bootloader/flash.c
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,7 @@ __at(FLASH_CALIBRATION_AREA_HIGH) uint8_t __code calibration[FLASH_CALIBRATION_A
__at(FLASH_CALIBRATION_CRC_HIGH) uint8_t __code calibration_crc;

void
flash_transfer_calibration()
flash_transfer_calibration(void)
{
uint8_t idx, crc = 0;

Expand Down Expand Up @@ -318,7 +318,7 @@ flash_transfer_calibration()
#if defined BOARD_mro900
static __at(FLASH_CALIBRATION_OSC_HIGH) uint8_t __code calibration;

void flash_transfer_calibration()
void flash_transfer_calibration(void)
{
if (flash_read_byte(FLASH_CALIBRATION_OSC) != 0xFF)
{
Expand Down
2 changes: 1 addition & 1 deletion Firmware/bootloader/flash.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ void flash_write_byte(uint16_t address, uint8_t c);
uint8_t flash_read_byte(uint16_t address);
#endif // FLASH_BANKS
#if defined BOARD_rfd900a || defined BOARD_rfd900p || defined BOARD_mro900
void flash_transfer_calibration();
void flash_transfer_calibration(void);
#endif

#endif // _FLASH_H_
2,488 changes: 1,244 additions & 1,244 deletions Firmware/include/Si1020_defs.h

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions Firmware/include/board.h
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,10 @@
# include "board_mro900.h"
#elif defined(BOARD_3dr1060)
# include "board_3dr1060.h"
#elif defined(BOARD_tfsik01_26MHz)
# include "board_tfsik01_26MHz.h"
#elif defined(BOARD_tfsik01_30MHz)
# include "board_tfsik01_30MHz.h"
#else
# error Must define a BOARD_ value before including this file.
#endif
Expand Down
8 changes: 5 additions & 3 deletions Firmware/include/board_3dr1060.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// -*- Mode: C; c-basic-offset: 8; -*-
//
// Copyright (c) 2011 Michael Smith, All Rights Reserved
// Copyright (c) 2022 ThunderFly s.r.o., All Rights Reserved
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions
Expand Down Expand Up @@ -93,7 +93,9 @@ SBIT(PIN_ENABLE, SFR_P0, 3);
SBIT(NSS1, SFR_SPI1CN, 2); // SI106x Internal Connection
SBIT(SDN, SFR_P0, 7);

#define GPIO_0_CONFIG 33 // RX_STATE
#define GPIO_1_CONFIG 32 // TX_STATE
#define GPIO_0_CONFIG GPIO_RX_STATE
#define GPIO_1_CONFIG GPIO_TX_STATE
#define GPIO_2_CONFIG GPIO_CTS
#define GPIO_3_CONFIG GPIO_RX_STATE

#endif // _BOARD_3DR1060_H
20 changes: 16 additions & 4 deletions Firmware/include/board_hb1060.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// -*- Mode: C; c-basic-offset: 8; -*-
//
// Copyright (c) 2011 Michael Smith, All Rights Reserved
// Copyright (c) 2022 ThunderFly s.r.o., All Rights Reserved
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions
Expand Down Expand Up @@ -46,7 +46,7 @@
#define CPU_SI1060

#define BOARD_MINTXPOWER 0 // Minimum transmit power level
#define BOARD_MAXTXPOWER 0x7f // Maximum transmit power level
#define BOARD_MAXTXPOWER 20 // Maximum transmit power level

// GPIO definitions (not exported)
SBIT(LED_RED, SFR_P1, 4);
Expand Down Expand Up @@ -74,6 +74,9 @@ SBIT(PIN_ENABLE, SFR_P0, 3);
do { \
/* GPIO config */ \
P0SKIP |= 0x0E; /* input pins & nIRQ */ \
P0MDOUT |= 0x04; /* CTS pushpull */ \
P0MDOUT &= ~0x08; /* RTS open drain */ \
P0DRV &= ~0x04; /* CTS low drive */ \
P1SKIP |= 0x30; /* LEDs */ \
P0MDOUT |= 0x80; /* radio SDN */ \
P1MDOUT |= 0x3D; /* LEDs & radio SPI */ \
Expand All @@ -87,13 +90,22 @@ SBIT(PIN_ENABLE, SFR_P0, 3);
IT0 = 0; /* INT0 level triggered */ \
} while(0)

// application/board-specific hardware config
#define HW_INIT_APPLICATION \
do { \
SFRPAGE = CONFIG_PAGE; \
P0DRV |= 0x04; /* CTS */ \
SFRPAGE = LEGACY_PAGE; \
} while(0)

#define EZRADIOPRO_OSC_CAP_VALUE 100

SBIT(NSS1, SFR_SPI1CN, 2); // SI106x Internal Connection
SBIT(SDN, SFR_P0, 7);

#define GPIO_0_CONFIG 33 // RX_STATE
#define GPIO_1_CONFIG 32 // TX_STATE
#define GPIO_0_CONFIG GPIO_RX_STATE
#define GPIO_1_CONFIG GPIO_TX_STATE
#define GPIO_2_CONFIG GPIO_CTS
#define GPIO_3_CONFIG GPIO_RX_STATE

#endif // _BOARD_HB1060_H
31 changes: 22 additions & 9 deletions Firmware/include/board_ism01a.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// -*- Mode: C; c-basic-offset: 8; -*-
//
// Copyright (c) 2011 Michael Smith, All Rights Reserved
// Copyright (c) 2022 ThunderFly s.r.o., All Rights Reserved
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions
Expand All @@ -27,13 +27,10 @@
//

///
/// @file board_rf50.h
/// @file board_ism01a.h
///
/// Board-specific definitions for the RF50-DEMO board.
/// Board-specific definitions for the ISM01A board.
///

/// @file board.h
/// Board definitions for the ISM01A board

#ifndef _BOARD_ISM01A_H
#define _BOARD_ISM01A_H
Expand All @@ -46,14 +43,18 @@
#define CPU_SI1060

#define BOARD_MINTXPOWER 0 // Minimum transmit power level
#define BOARD_MAXTXPOWER 0x7f // Maximum transmit power level
#define BOARD_MAXTXPOWER 20 // Maximum transmit power level

// GPIO definitions (not exported)
SBIT(LED_RED, SFR_P1, 4);
SBIT(LED_GREEN, SFR_P1, 5);
SBIT(PIN_CONFIG, SFR_P0, 2);
SBIT(PIN_ENABLE, SFR_P0, 3);

// Serial flow control
#define SERIAL_RTS PIN_ENABLE // always an input
#define SERIAL_CTS PIN_CONFIG // input in bootloader, output in app

// Signal polarity definitions
#define LED_ON 1
#define LED_OFF 0
Expand All @@ -70,6 +71,9 @@ SBIT(PIN_ENABLE, SFR_P0, 3);
do { \
/* GPIO config */ \
P0SKIP |= 0x0E; /* input pins & nIRQ */ \
P0MDOUT |= 0x04; /* CTS pushpull */ \
P0MDOUT &= ~0x08; /* RTS open drain */ \
P0DRV &= ~0x04; /* CTS low drive */ \
P1SKIP |= 0x30; /* LEDs */ \
P0MDOUT |= 0x80; /* radio SDN */ \
P1MDOUT |= 0x3D; /* LEDs & radio SPI */ \
Expand All @@ -83,13 +87,22 @@ SBIT(PIN_ENABLE, SFR_P0, 3);
IT0 = 0; /* INT0 level triggered */ \
} while(0)

// application/board-specific hardware config
#define HW_INIT_APPLICATION \
do { \
SFRPAGE = CONFIG_PAGE; \
P0DRV |= 0x04; /* CTS */ \
SFRPAGE = LEGACY_PAGE; \
} while(0)

#define EZRADIOPRO_OSC_CAP_VALUE 100

SBIT(NSS1, SFR_SPI1CN, 2); // SI106x Internal Connection
SBIT(SDN, SFR_P0, 7);

#define GPIO_0_CONFIG 32 // TX_STATE
#define GPIO_1_CONFIG 35 // TX_FIFO_EMPTY
#define GPIO_0_CONFIG ant1
#define GPIO_1_CONFIG ant2
#define GPIO_2_CONFIG GPIO_RX_STATE
#define GPIO_3_CONFIG GPIO_TX_STATE

#endif // _BOARD_ISM01A_H
112 changes: 112 additions & 0 deletions Firmware/include/board_tfsik01_26MHz.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,112 @@
// -*- Mode: C; c-basic-offset: 8; -*-
//
// Copyright (c) 2022 ThunderFly s.r.o., All Rights Reserved
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions
// are met:
//
// o Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// o Redistributions in binary form must reproduce the above copyright
// notice, this list of conditions and the following disclaimer in
// the documentation and/or other materials provided with the distribution.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
// FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
// COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
// INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
// HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
// OF THE POSSIBILITY OF SUCH DAMAGE.
//

///
/// @file board_tfsik01_26MHz.h
///
/// Board-specific definitions for the TFSIK01 hardware fitted with a 26 MHz crystal.
///

#ifndef _BOARD_TFSIK01_26MHZ_H
#define _BOARD_TFSIK01_26MHZ_H

#include <compiler_defs.h>
#include <Si1060_defs.h>

#define BOARD_ID 0x53
#define BOARD_NAME "TFSIK01 26MHz"
#define CPU_SI1060

#define BOARD_MINTXPOWER 0 // Minimum transmit power level
#define BOARD_MAXTXPOWER 20 // Maximum transmit power level

#define XO_FREQ 26000000UL

// GPIO definitions (not exported)
SBIT(LED_RED, SFR_P1, 4);
SBIT(LED_GREEN, SFR_P1, 5);
SBIT(LED_ORANGE, SFR_P1, 6);
SBIT(PIN_CONFIG, SFR_P0, 2);
SBIT(PIN_ENABLE, SFR_P0, 3);

// Serial flow control
#define SERIAL_RTS PIN_ENABLE // always an input
#define SERIAL_CTS PIN_CONFIG // input in bootloader, output in app

// Signal polarity definitions
#define LED_ON 1
#define LED_OFF 0
#define BUTTON_ACTIVE 0

// UI definitions
#define LED_BOOTLOADER LED_RED
#define LED_RADIO LED_GREEN
#define LED_ACTIVITY LED_RED
#define LED_DIVERSITY LED_ORANGE
#define BUTTON_BOOTLOAD PIN_CONFIG

// board-specific hardware config
#define HW_INIT \
do { \
/* GPIO config */ \
P0SKIP |= 0x0E; /* input pins & nIRQ */ \
P0MDOUT |= 0x04; /* CTS pushpull */ \
P0MDOUT &= ~0x08; /* RTS open drain */ \
P0DRV &= ~0x04; /* CTS low drive */ \
P1SKIP |= 0x30; /* LEDs */ \
P0MDOUT |= 0x80; /* radio SDN */ \
P1MDOUT |= 0x3D; /* LEDs & radio SPI */ \
\
SFRPAGE = CONFIG_PAGE; \
P1DRV |= 0x0D; \
SFRPAGE = LEGACY_PAGE; \
\
/* INT0 is the radio interrupt, on P0.1 */ \
IT01CF = 0x01; /* active low, P0.1 */ \
IT0 = 0; /* INT0 level triggered */ \
} while(0)

// application/board-specific hardware config
#define HW_INIT_APPLICATION \
do { \
SFRPAGE = CONFIG_PAGE; \
P0DRV |= 0x04; /* CTS */ \
SFRPAGE = LEGACY_PAGE; \
} while(0)

#define EZRADIOPRO_OSC_CAP_VALUE 100

SBIT(NSS1, SFR_SPI1CN, 2); // SI106x Internal Connection
SBIT(SDN, SFR_P0, 7);

#define GPIO_0_CONFIG ant1
#define GPIO_1_CONFIG GPIO_TX_STATE
#define GPIO_2_CONFIG GPIO_TX_STATE
#define GPIO_3_CONFIG ant2

#endif // _BOARD_TFSIK01_26MHZ_H
Loading
Loading