mirror of
https://github.com/meshtastic/firmware.git
synced 2026-01-27 04:02:05 +00:00
Compare commits
6 Commits
v1.2.54.28
...
v1.2.55.9d
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9db7c62a49 | ||
|
|
d79dc631f1 | ||
|
|
7ea6babb7f | ||
|
|
0b4b901504 | ||
|
|
cc7b5cf136 | ||
|
|
e3df4fe4b4 |
11
.github/workflows/main.yml
vendored
11
.github/workflows/main.yml
vendored
@@ -6,11 +6,14 @@ on:
|
|||||||
paths-ignore:
|
paths-ignore:
|
||||||
- '**.md'
|
- '**.md'
|
||||||
- '**.yml'
|
- '**.yml'
|
||||||
|
|
||||||
|
# Note: This is different from "pull_request". Need to specify ref when doing checkouts.
|
||||||
pull_request_target:
|
pull_request_target:
|
||||||
branches: [ master ]
|
branches: [ master ]
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- '**.md'
|
- '**.md'
|
||||||
- '**.yml'
|
- '**.yml'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
ci-check:
|
ci-check:
|
||||||
@@ -21,6 +24,8 @@ jobs:
|
|||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
submodules: 'recursive'
|
submodules: 'recursive'
|
||||||
|
ref: ${{github.event.pull_request.head.ref}}
|
||||||
|
repository: ${{github.event.pull_request.head.repo.full_name}}
|
||||||
|
|
||||||
- name: Install cppcheck
|
- name: Install cppcheck
|
||||||
run: |
|
run: |
|
||||||
@@ -60,6 +65,8 @@ jobs:
|
|||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
submodules: 'recursive'
|
submodules: 'recursive'
|
||||||
|
ref: ${{github.event.pull_request.head.ref}}
|
||||||
|
repository: ${{github.event.pull_request.head.repo.full_name}}
|
||||||
|
|
||||||
- name: Setup Python
|
- name: Setup Python
|
||||||
uses: actions/setup-python@v2
|
uses: actions/setup-python@v2
|
||||||
@@ -114,6 +121,10 @@ jobs:
|
|||||||
echo "Simulator started, launching python test..."
|
echo "Simulator started, launching python test..."
|
||||||
python3 -c 'from meshtastic.test import testSimulator; testSimulator()'
|
python3 -c 'from meshtastic.test import testSimulator; testSimulator()'
|
||||||
|
|
||||||
|
- name: Cat bin/build-all.sh
|
||||||
|
run: |
|
||||||
|
cat bin/build-all.sh
|
||||||
|
|
||||||
- name: Build everything
|
- name: Build everything
|
||||||
run: bin/build-all.sh
|
run: bin/build-all.sh
|
||||||
|
|
||||||
|
|||||||
2
.github/workflows/release.yml
vendored
2
.github/workflows/release.yml
vendored
@@ -1,7 +1,7 @@
|
|||||||
name: Make Release
|
name: Make Release
|
||||||
on:
|
on:
|
||||||
# Can optionally take parameters from the github UI, more info here https://github.blog/changelog/2020-07-06-github-actions-manual-triggers-with-workflow_dispatch/#:~:text=You%20can%20now%20create%20workflows,the%20workflow%20is%20run%20on.
|
# Can optionally take parameters from the github UI, more info here https://github.blog/changelog/2020-07-06-github-actions-manual-triggers-with-workflow_dispatch/#:~:text=You%20can%20now%20create%20workflows,the%20workflow%20is%20run%20on.
|
||||||
# workflow_dispatch:
|
workflow_dispatch:
|
||||||
# inputs:
|
# inputs:
|
||||||
|
|
||||||
# Only want to run if version.properties is bumped in master
|
# Only want to run if version.properties is bumped in master
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ set -e
|
|||||||
VERSION=`bin/buildinfo.py long`
|
VERSION=`bin/buildinfo.py long`
|
||||||
SHORT_VERSION=`bin/buildinfo.py short`
|
SHORT_VERSION=`bin/buildinfo.py short`
|
||||||
|
|
||||||
BOARDS_ESP32="tlora-v2 tlora-v1 tlora_v1_3 tlora-v2-1-1.6 tbeam heltec-v1 heltec-v2.0 heltec-v2.1 tbeam0.7 meshtastic-diy-v1"
|
BOARDS_ESP32="rak11200 tlora-v2 tlora-v1 tlora_v1_3 tlora-v2-1-1.6 tbeam heltec-v1 heltec-v2.0 heltec-v2.1 tbeam0.7 meshtastic-diy-v1"
|
||||||
#BOARDS_ESP32=tbeam
|
#BOARDS_ESP32=tbeam
|
||||||
|
|
||||||
# FIXME note nrf52840dk build is for some reason only generating a BIN file but not a HEX file nrf52840dk-geeksville is fine
|
# FIXME note nrf52840dk build is for some reason only generating a BIN file but not a HEX file nrf52840dk-geeksville is fine
|
||||||
@@ -28,7 +28,7 @@ function do_build() {
|
|||||||
BOARD=$1
|
BOARD=$1
|
||||||
isNrf=$3
|
isNrf=$3
|
||||||
|
|
||||||
echo "Building for $BOARD with $PLATFORMIO_BUILD_FLAGS"
|
echo "Building for $BOARD ($isNrf) with $PLATFORMIO_BUILD_FLAGS"
|
||||||
rm -f .pio/build/$BOARD/firmware.*
|
rm -f .pio/build/$BOARD/firmware.*
|
||||||
|
|
||||||
# The shell vars the build tool expects to find
|
# The shell vars the build tool expects to find
|
||||||
@@ -59,6 +59,7 @@ function do_boards() {
|
|||||||
declare isNrf=$2
|
declare isNrf=$2
|
||||||
for board in $boards; do
|
for board in $boards; do
|
||||||
# Build universal
|
# Build universal
|
||||||
|
echo "about to build $board $isNrf"
|
||||||
do_build $board "" "$isNrf"
|
do_build $board "" "$isNrf"
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,10 +13,10 @@ if [[ $# -gt 0 ]]; then
|
|||||||
# can override which environment by passing arg
|
# can override which environment by passing arg
|
||||||
BOARDS="$@"
|
BOARDS="$@"
|
||||||
else
|
else
|
||||||
BOARDS="tlora-v2 tlora-v1 tlora_v1_3 tlora-v2-1-1.6 tbeam heltec-v1 heltec-v2.0 heltec-v2.1 tbeam0.7 meshtastic-diy-v1 rak4631_5005 rak4631_19003 t-echo"
|
BOARDS="tlora-v2 tlora-v1 tlora_v1_3 tlora-v2-1-1.6 tbeam heltec-v1 heltec-v2.0 heltec-v2.1 tbeam0.7 meshtastic-diy-v1 rak4631_5005 rak4631_19003 rak11200 t-echo"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
#echo "BOARDS:${BOARDS}"
|
echo "BOARDS:${BOARDS}"
|
||||||
|
|
||||||
CHECK=""
|
CHECK=""
|
||||||
for BOARD in $BOARDS; do
|
for BOARD in $BOARDS; do
|
||||||
|
|||||||
@@ -474,6 +474,9 @@ size_t NodeDB::getNumOnlineNodes()
|
|||||||
void NodeDB::updatePosition(uint32_t nodeId, const Position &p, RxSource src)
|
void NodeDB::updatePosition(uint32_t nodeId, const Position &p, RxSource src)
|
||||||
{
|
{
|
||||||
NodeInfo *info = getOrCreateNode(nodeId);
|
NodeInfo *info = getOrCreateNode(nodeId);
|
||||||
|
if (!info) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (src == RX_SRC_LOCAL) {
|
if (src == RX_SRC_LOCAL) {
|
||||||
// Local packet, fully authoritative
|
// Local packet, fully authoritative
|
||||||
@@ -517,6 +520,9 @@ void NodeDB::updatePosition(uint32_t nodeId, const Position &p, RxSource src)
|
|||||||
void NodeDB::updateUser(uint32_t nodeId, const User &p)
|
void NodeDB::updateUser(uint32_t nodeId, const User &p)
|
||||||
{
|
{
|
||||||
NodeInfo *info = getOrCreateNode(nodeId);
|
NodeInfo *info = getOrCreateNode(nodeId);
|
||||||
|
if (!info) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
DEBUG_MSG("old user %s/%s/%s\n", info->user.id, info->user.long_name, info->user.short_name);
|
DEBUG_MSG("old user %s/%s/%s\n", info->user.id, info->user.long_name, info->user.short_name);
|
||||||
|
|
||||||
@@ -546,6 +552,9 @@ void NodeDB::updateFrom(const MeshPacket &mp)
|
|||||||
DEBUG_MSG("Update DB node 0x%x, rx_time=%u\n", mp.from, mp.rx_time);
|
DEBUG_MSG("Update DB node 0x%x, rx_time=%u\n", mp.from, mp.rx_time);
|
||||||
|
|
||||||
NodeInfo *info = getOrCreateNode(getFrom(&mp));
|
NodeInfo *info = getOrCreateNode(getFrom(&mp));
|
||||||
|
if (!info) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (mp.rx_time) // if the packet has a valid timestamp use it to update our last_heard
|
if (mp.rx_time) // if the packet has a valid timestamp use it to update our last_heard
|
||||||
info->last_heard = mp.rx_time;
|
info->last_heard = mp.rx_time;
|
||||||
@@ -572,8 +581,12 @@ NodeInfo *NodeDB::getOrCreateNode(NodeNum n)
|
|||||||
NodeInfo *info = getNode(n);
|
NodeInfo *info = getNode(n);
|
||||||
|
|
||||||
if (!info) {
|
if (!info) {
|
||||||
|
if (*numNodes >= MAX_NUM_NODES) {
|
||||||
|
screen->print("error: node_db full!\n");
|
||||||
|
DEBUG_MSG("ERROR! could not create new node, node_db is full! (%d nodes)", *numNodes);
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
// add the node
|
// add the node
|
||||||
assert(*numNodes < MAX_NUM_NODES);
|
|
||||||
info = &nodes[(*numNodes)++];
|
info = &nodes[(*numNodes)++];
|
||||||
|
|
||||||
// everything is missing except the nodenum
|
// everything is missing except the nodenum
|
||||||
|
|||||||
46
variants/rak11200/pins_arduino.h
Normal file
46
variants/rak11200/pins_arduino.h
Normal file
@@ -0,0 +1,46 @@
|
|||||||
|
#ifndef Pins_Arduino_h
|
||||||
|
#define Pins_Arduino_h
|
||||||
|
|
||||||
|
#include <stdint.h>
|
||||||
|
|
||||||
|
#define EXTERNAL_NUM_INTERRUPTS 16
|
||||||
|
#define NUM_DIGITAL_PINS 40
|
||||||
|
#define NUM_ANALOG_INPUTS 16
|
||||||
|
|
||||||
|
#define analogInputToDigitalPin(p) (((p) < 20) ? (esp32_adc2gpio[(p)]) : -1)
|
||||||
|
#define digitalPinToInterrupt(p) (((p) < 40) ? (p) : -1)
|
||||||
|
#define digitalPinHasPWM(p) (p < 34)
|
||||||
|
|
||||||
|
#define LED_GREEN 12
|
||||||
|
#define LED_BLUE 2
|
||||||
|
|
||||||
|
#define LED_BUILTIN LED_GREEN
|
||||||
|
|
||||||
|
static const uint8_t TX = 1;
|
||||||
|
static const uint8_t RX = 3;
|
||||||
|
|
||||||
|
#define TX1 21
|
||||||
|
#define RX1 19
|
||||||
|
|
||||||
|
#define WB_IO1 14
|
||||||
|
#define WB_IO2 27
|
||||||
|
#define WB_IO3 26
|
||||||
|
#define WB_IO4 23
|
||||||
|
#define WB_IO5 13
|
||||||
|
#define WB_IO6 22
|
||||||
|
#define WB_SW1 34
|
||||||
|
#define WB_A0 36
|
||||||
|
#define WB_A1 39
|
||||||
|
#define WB_CS 32
|
||||||
|
#define WB_LED1 12
|
||||||
|
#define WB_LED2 2
|
||||||
|
|
||||||
|
static const uint8_t SDA = 4;
|
||||||
|
static const uint8_t SCL = 5;
|
||||||
|
|
||||||
|
static const uint8_t SS = 32;
|
||||||
|
static const uint8_t MOSI = 25;
|
||||||
|
static const uint8_t MISO = 35;
|
||||||
|
static const uint8_t SCK = 33;
|
||||||
|
|
||||||
|
#endif /* Pins_Arduino_h */
|
||||||
@@ -2,4 +2,4 @@
|
|||||||
extends = esp32_base
|
extends = esp32_base
|
||||||
board = wiscore_rak11200
|
board = wiscore_rak11200
|
||||||
build_flags =
|
build_flags =
|
||||||
${esp32_base.build_flags} -D RAK_11200 -I variants/WisCore_RAK11200_Board
|
${esp32_base.build_flags} -D RAK_11200 -I variants/rak11200
|
||||||
@@ -42,14 +42,16 @@ static const uint8_t SS = 32;
|
|||||||
static const uint8_t MOSI = 25;
|
static const uint8_t MOSI = 25;
|
||||||
static const uint8_t MISO = 35;
|
static const uint8_t MISO = 35;
|
||||||
static const uint8_t SCK = 33;
|
static const uint8_t SCK = 33;
|
||||||
|
#endif /* Pins_Arduino_h */
|
||||||
|
|
||||||
/* -------- Meshtastic pins -------- */
|
/* -------- Meshtastic pins -------- */
|
||||||
|
|
||||||
#define I2C_SDA SDA
|
#define I2C_SDA SDA
|
||||||
#define I2C_SCL SCL
|
#define I2C_SCL SCL
|
||||||
|
|
||||||
#define GPS_RX_PIN RX
|
#undef GPS_RX_PIN
|
||||||
#define GPS_RX_PIN TX
|
#define GPS_RX_PIN (RX1)
|
||||||
|
#undef GPS_TX_PIN
|
||||||
|
#define GPS_TX_PIN (TX1)
|
||||||
|
|
||||||
#define LED_PIN LED_BLUE
|
#define LED_PIN LED_BLUE
|
||||||
|
|
||||||
@@ -63,18 +65,20 @@ static const uint8_t SCK = 33;
|
|||||||
#define LORA_DIO2 WB_IO5 // BUSY for SX1262/SX1268
|
#define LORA_DIO2 WB_IO5 // BUSY for SX1262/SX1268
|
||||||
#define LORA_DIO3 // Not connected on PCB, but internally on the TTGO SX1262/SX1268, if DIO3 is high the TXCO is enabled
|
#define LORA_DIO3 // Not connected on PCB, but internally on the TTGO SX1262/SX1268, if DIO3 is high the TXCO is enabled
|
||||||
|
|
||||||
// This is a hack for the radio pin run-around with ESP32 variants
|
#undef RF95_SCK
|
||||||
#define RF95_SCK SCK
|
#define RF95_SCK SCK
|
||||||
|
#undef RF95_MISO
|
||||||
#define RF95_MISO MISO
|
#define RF95_MISO MISO
|
||||||
|
#undef RF95_MOSI
|
||||||
#define RF95_MOSI MOSI
|
#define RF95_MOSI MOSI
|
||||||
|
#undef RF95_NSS
|
||||||
#define RF95_NSS SS
|
#define RF95_NSS SS
|
||||||
|
|
||||||
#define USE_SX1262
|
#define USE_SX1262
|
||||||
#define SX126X_CS (RF95_NSS)// NSS for SX126X
|
#define SX126X_CS (SS)// NSS for SX126X
|
||||||
#define SX126X_DIO1 (LORA_DIO1)
|
#define SX126X_DIO1 (LORA_DIO1)
|
||||||
#define SX126X_BUSY (LORA_DIO2)
|
#define SX126X_BUSY (LORA_DIO2)
|
||||||
#define SX126X_RESET (LORA_RESET)
|
#define SX126X_RESET (LORA_RESET)
|
||||||
#define SX126X_TXEN (-1)
|
#define SX126X_TXEN (-1)
|
||||||
#define SX126X_RXEN (WB_IO3)
|
#define SX126X_RXEN (WB_IO3)
|
||||||
#define SX126X_E22 // DIO2 controlls an antenna switch and the TCXO voltage is controlled by DIO3
|
#define SX126X_E22 // DIO2 controlls an antenna switch and the TCXO voltage is controlled by DIO3
|
||||||
#endif /* Pins_Arduino_h */
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
[VERSION]
|
[VERSION]
|
||||||
major = 1
|
major = 1
|
||||||
minor = 2
|
minor = 2
|
||||||
build = 54
|
build = 55
|
||||||
|
|||||||
Reference in New Issue
Block a user