Giter Club home page Giter Club logo

esp32_loraprs's People

Contributors

gabehc avatar mrpatrick1991 avatar sh123 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

esp32_loraprs's Issues

iOS software "APRS.FI" cannot work

This is my setting。
#define CFG_BT_USE_BLE true
My APRS.FI can be connected to ESP32 (BLE), but the app sends packet, ESP32 does not work (TX LORA signal)
photo_2022-06-16_14-13-20

#define LED_TOGGLE_PERIOD     1000

#define SERIAL_BAUD_RATE      115200

// change pinouts if not defined through native board LORA_* definitions
#define USE_RADIOLIB

#ifndef LORA_RST
#pragma message("LoRa pin definitions are not found, redefining...")
#define LORA_RST              14
#define LORA_IRQ              33
#endif

#ifndef BUILTIN_LED
#pragma message("BUILDIN_LED is not found, defining as 12")
#define BUILTIN_LED           12
#endif
//#define BUILTIN_LED           12
#define CFG_IS_CLIENT_MODE    true        // false - server mode (APRS-IS gate mode)

// lora pinouts, CAD and ISR usage
#define CFG_LORA_PIN_SS       SS
#define CFG_LORA_PIN_RST      LORA_RST
#define CFG_LORA_PIN_DIO0     LORA_IRQ
#ifdef USE_RADIOLIB
#define CFG_LORA_PIN_DIO1     LORA_IRQ    // set to your DIO1 pin number if connected
#define CFG_LORA_USE_ISR      true        // always ON for RadioLib
#else
#define CFG_LORA_PIN_DIO1     RADIOLIB_NC   // not used in arduino-LoRa
#define CFG_LORA_USE_ISR      false       // set to true for ISR usage in arduino-LoRa
#endif
#define CFG_LORA_USE_CAD      true        // set to true to utilize carrier detection

// lora protocol parameters
#define CFG_LORA_FREQ         432.19E6 //改 430.64
#define CFG_LORA_BW           125e3
#define CFG_LORA_SF           12
#define CFG_LORA_CR           8
#define CFG_LORA_PWR          30
#define CFG_LORA_ENABLE_CRC   true        // set to false for speech data

// wifi client and AP options
#define CFG_WIFI_ENABLE_AP    false       // run as wifi access point, for CFG_KISS_TCP_IP mode
#define CFG_WIFI_SSID         "PTY"      // connect to SSID or run as this SSID in AP mode
#define CFG_WIFI_KEY          "0422412908"  // wifi key

// bluetooth
#define CFG_BT_NAME           "loraprs"
#define CFG_BT_USE_BLE        true        // set to true to use bluetooth low energy (for ios devices)

// USB
#define CFG_USB_SERIAL_ENABLE false       // true - enable communication over USB Serial

// KISS protocol options
#define CFG_KISS_EXTENSIONS   true    // true - enable modem control from application with KISS commands 改ture
#define CFG_KISS_TCP_IP       true   // true - run as KISS TCP/IP server, no bluetooth operations performed

// APRS-IS options, valid in when CFG_IS_CLIENT_MODE = false
#define CFG_APRS_LOGIN        "BX4ACP-10"
#define CFG_APRS_PASS         "18091"
#define CFG_APRS_FILTER	      "r/24.11/120.42/50"
//#define CFG_APRS_RAW_BKN      "BV5DJ-10>APZMDM,WIDE1-1:!0000.00N/00000.00E#LoRA 433.775MHz/BW125/SF12/CR7/0x34"
#define CFG_APRS_RAW_BKN      "BX4ACP>APZMDM,WIDE1-1:!2410.70N/12043.00E#LoRA 438.2MHz/BW125/SF12/CR8/0x12"
// APRS-IS gateway options, valid in when CFG_IS_CLIENT_MODE = false
#define CFG_PERSISTENT_APRS   false   // keep tcp/ip connection open (lot of traffic), otherwise connect on new packet (very rare traffic)
#define CFG_DIGIREPEAT        false   // digirepeat incoming packets
#define CFG_RF_TO_IS          true    // forward packets from radio to internet
#define CFG_IS_TO_RF          false    // forward packets from internet to radio basedon CFG_APRS_FILTER
#define CFG_BEACON            false    // enable perdiodc beacon from CFG_APRS_RAW_BKN

// frequency correction for narrow band bandwidths
#define CFG_FREQ_CORR         false   // true - correct own frequency based on received packet
#define CFG_FREQ_CORR_DELTA   1000    // correct when frequency difference is larger than this value

// PTT control
#define CFG_PTT_ENABLE        false   // enable external ptt (relay) control (for amplifier)
#define CFG_PTT_PIN           4       // PTT pin
#define CFG_PTT_TX_DELAY_MS   50      // time between relay swited on and transmission
#define CFG_PTT_TX_TAIL_MS    10      // time between stop transmission and relay off`

Error: 'xTaskNotifyWaitIndexed' was not declared in this scope

Hi. Thanks for your good job.
I have a problem while compiling, error:
[cut] loraprs_service.cpp: In static member function 'static void LoraPrs::Service::rigTask(void*)':
[cut] loraprs_service.cpp:322:75: error: 'xTaskNotifyWaitIndexed' was not declared in this scope

Bad IDEs version?

Is it possible to create repeater modem?

Is it possible to create a repeater node using ESP32 to relay messages between few clients to extend the range ?

Ideally repeater modem consisting of ESP32 and LoRa chip will be mounted at higher location with powerful omnidirectional antenna and it's job will be to re transmit all the messages it receives via LoRa?

Thanks.

CRC mismatch on ACKs

I'm trying to get direct messages working in TNC2/text mode. I'm using 2 boards running loraprs, one as iGate, the other as client connected to APRSdroid. Messages from APRS-IS to RF work. The ACK is generated in APRSdroid, sent to the client module and sent out but on the iGate I receive a CRC error. Please see the console output with LVL_TRACE attached.

(Messages from the client to other stations work fine and the ACK is correctly received)

ack-crc-error.txt

Collaboration with Codec2talkie

1.Do I need to make any other changes to config.h (besides CFG_KISS_EXTENSIONS true) to use this project together with Codec2talkie.

  1. Is it possible to use the settings
    CFG_TEXT_PACKETS true
    CFG_TEXT_PACKETS_3 true
    when working with Codec2talkie?

Digipeating in TNC2/text mode losing last character

Issue seems to be in loraprs_service.cpp lines 505ff:

  // TNC2 text mode
  if (config_.EnableTextPackets) {
    String textPayload = payload.ToString();
    bytesWritten = textPayload.length() > (CfgMaxPacketSize - 1)? CfgMaxPacketSize : (textPayload.length() + 1);
    textPayload.getBytes(buf, bytesWritten);
    buf[bytesWritten-1] = '\0';

I updated above lines to work. Still, it should not work as that because we are reading more bytes than we should have in textPayload. Still, reducing textPayload.getBytes(buf, bytesWritten-1); again misses the last character of the message. I don´t know what is wrong here and how to properly fix it.

Digipeater: via call "WIDE1-1" invalid after transmitting

Reciving station got this after LoRa Modul has digipeated packet.
Bildschirmfoto von 2022-10-16 08-24-22

The last packet u can see on the screenshot is sended as beacon from the Modul ( Sketch ) self. The first is sended via a kiss connection to a linux ax25 device and was digipeated from 2 different moduls.

The trace from the digipeating station for the 1. packet show this.

08:17:08.143 -> [INFO] performFrequencyCorrection : Correcting frequency: -5319
08:17:08.143 -> [INFO] processIncomingRawPacketAsServer : MD3SAW>TESTER,WIDE1-1:TEST
08:17:08.143 -> [INFO] processIncomingRawPacketAsServer : rssi: -66.00dBm, snr: 12.75>
08:17:08.143 -> [INFO] processIncomingRawPacketAsServer : Packet digirepeated
08:17:08.210 -> [TRACE] onRigTx : ⸮ a8
08:17:08.210 -> [TRACE] onRigTx : ⸮ 8a
08:17:08.210 -> [TRACE] onRigTx : ⸮ a6
08:17:08.210 -> [TRACE] onRigTx : ⸮ a8
08:17:08.210 -> [TRACE] onRigTx : ⸮ 8a
08:17:08.210 -> [TRACE] onRigTx : ⸮ a4
08:17:08.210 -> [TRACE] onRigTx : 0
08:17:08.210 -> [TRACE] onRigTx : ⸮ 9a
08:17:08.210 -> [TRACE] onRigTx : ⸮ 88
08:17:08.210 -> [TRACE] onRigTx : f 66
08:17:08.210 -> [TRACE] onRigTx : ⸮ a6
08:17:08.210 -> [TRACE] onRigTx : ⸮ 82
08:17:08.210 -> [TRACE] onRigTx : ⸮ ae
08:17:08.210 -> [TRACE] onRigTx : 0
08:17:08.243 -> [TRACE] onRigTx : ⸮ ae
08:17:08.243 -> [TRACE] onRigTx : ⸮ 92
08:17:08.243 -> [TRACE] onRigTx : ⸮ 88
08:17:08.243 -> [TRACE] onRigTx : ⸮ 8a
08:17:08.243 -> [TRACE] onRigTx : b 62
08:17:08.243 -> [TRACE] onRigTx : T 54
08:17:08.243 -> [TRACE] onRigTx : 1
08:17:08.243 -> [TRACE] onRigTx : 3
08:17:08.243 -> [TRACE] onRigTx : ⸮ f0
08:17:08.243 -> [TRACE] onRigTx : T 54
08:17:08.243 -> [TRACE] onRigTx : E 45
08:17:08.243 -> [TRACE] onRigTx : S 53
08:17:08.243 -> [TRACE] onRigTx : T 54

Hope it help a bit. Seems there are more then just the invalid call issuse , because axlisten shows EAX25 Protocoll also DAMA ..

Maybe it would be possible to digipeat all kind of packets, not just UI Frames.
Maybe digipeting all Packets would be easier as well because u need just flipping the bit on the end of the own call in via address space ..

But i know.. It's easier said than done.. Was just a idea .

If u need some more information about AX.25 Protocol i found this quite helpful. It's in German but maybe Google Translator helps here..
TNN-Manual https://github.com/DeltaLima/TheNetNode-CB/blob/master/doc/tnn178.pdf
From page 121 you will find detailed definitions of the ax25 protocol.

Thanks, 73 and Good look ..

Update:

I dump this directly from a third device conneted via serial port.

dump.txt

Update2:
Another Dump..

dump2.txt

can't run project on lora1263F30 module

at startup it gives an error 707 or 705. If NReset is connected to pin26, then the error is -707. If you connect NReset to gnd, then the error is -705.
Please help me figure out what is the reason.
pin

Problem during start

Hello,

My setup:
ESP32
RA02 - SX1278

During startup I receive message:

rst:0x1 (POWERON_RESET),boot:0x1b (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0030,len:1184
load:0x40078000,len:13232
load:0x40080400,len:3028
entry 0x400805e4
[INFO] setup : KISS extensions are disabled in TNC2 mode
[INFO] setupRig : Initializing LoRa
[INFO] setupRig : Frequency: 433775000 Hz
[INFO] setupRig : Bandwidth: 125000 Hz
[INFO] setupRig : Spreading: 12
[INFO] setupRig : Coding rate: 7
[INFO] setupRig : Power: 20 dBm
[INFO] setupRig : Sync: 0x12
[INFO] setupRig : CRC: 1
[INFO] setupRig : Header: explicit
[INFO] setupRig : Speed: 209 bps
[INFO] setupRig : TOA (compressed): ~ 1.42 sec
[INFO] setupRig : TOA (uncompressed): ~ 2.45 sec
[INFO] setupRig : Min level: -137.03 dBm
[INFO] printConfig : Version: LoRAPRS 1.0.15
[INFO] printConfig : Current mode: APRS-IS iGate
[INFO] printConfig : Using TNC2 text mode
[INFO] printConfig : UsbSerialEnable: no
[INFO] printConfig : EnableSignalReport: yes
[INFO] printConfig : EnablePersistentAprsConnection: yes
[INFO] printConfig : EnableRfToIs: yes
[INFO] printConfig : EnableIsToRf: no
[INFO] printConfig : EnableRepeater: no
[INFO] printConfig : EnableBeacon: yes
[ 106][E][esp32-hal-gpio.c:102] __pinMode(): Invalid pin selected
[INFO] setupRig : Using SX127X module
[INFO] setupRig : LoRa initialized
[INFO] setupWifi : WIFI connecting to DomekTomek
[INFO] rigTask : Radio task started
[INFO] setupWifi : WIFI retrying 0
[INFO] setupWifi : WIFI retrying 1
[INFO] setupWifi : WIFI connected to DomekTomek
[INFO] setupWifi : IP address: 192.168.0.169
[INFO] reconnectAprsis : APRSIS connecting to rotate.aprs2.net
[INFO] reconnectAprsis : APRSIS connected
[INFO] reconnectAprsis : APRSIS logged in
[INFO] sendPeriodicBeacon : Periodic beacon is sent
[TRACE] onRigTxBegin : onRigTxBegin
[TRACE] onRigTaskStartTx : onRigTaskStartTx
[TRACE] onRigTx : < 3c
[TRACE] onRigTx : � ff
[TRACE] onRigTx : ␁ 1
[TRACE] onRigTx : S 53
[TRACE] onRigTx : Q 51
[TRACE] onRigTx : 6 36
[TRACE] onRigTx : S 53
[TRACE] onRigTx : L 4c
[TRACE] onRigTx : B 42
[TRACE] onRigTx : - 2d
[TRACE] onRigTx : 1 31
[TRACE] onRigTx : 0 30
[TRACE] onRigTx : > 3e
[TRACE] onRigTx : A 41
[TRACE] onRigTx : P 50
[TRACE] onRigTx : Z 5a
[TRACE] onRigTx : M 4d
[TRACE] onRigTx : D 44
[TRACE] onRigTx : M 4d
[TRACE] onRigTx : , 2c
[TRACE] onRigTx : W 57
[TRACE] onRigTx : I 49
[TRACE] onRigTx : D 44
[TRACE] onRigTx : E 45
[TRACE] onRigTx : 1 31
[TRACE] onRigTx : - 2d
[TRACE] onRigTx : 1 31
[TRACE] onRigTx : : 3a
[TRACE] onRigTx : ! 21
[TRACE] onRigTx : 5 35
[TRACE] onRigTx : 1 31
[TRACE] onRigTx : 0 30
[TRACE] onRigTx : 7 37
[TRACE] onRigTx : . 2e
[TRACE] onRigTx : 8 38
[TRACE] onRigTx : 4 34
[TRACE] onRigTx : N 4e
[TRACE] onRigTx : L 4c
[TRACE] onRigTx : 0 30
[TRACE] onRigTx : 1 31
[TRACE] onRigTx : 6 36
[TRACE] onRigTx : 4 34
[TRACE] onRigTx : 7 37
[TRACE] onRigTx : . 2e
[TRACE] onRigTx : 8 38
[TRACE] onRigTx : 2 32
[TRACE] onRigTx : E 45
[TRACE] onRigTx : a 61
[TRACE] onRigTx : L 4c
[TRACE] onRigTx : o 6f
[TRACE] onRigTx : R 52
[TRACE] onRigTx : A 41
[TRACE] onRigTx : 20
[TRACE] onRigTx : D 44
[TRACE] onRigTx : i 69
[TRACE] onRigTx : g 67
[TRACE] onRigTx : i 69
[TRACE] onRigTx : 20
[TRACE] onRigTx : i 69
[TRACE] onRigTx : G 47
[TRACE] onRigTx : a 61
[TRACE] onRigTx : t 74
[TRACE] onRigTx : e 65
[TRACE] onRigTx : 20
[TRACE] onRigTx : 4 34
[TRACE] onRigTx : 3 33
[TRACE] onRigTx : 3 33
[TRACE] onRigTx : . 2e
[TRACE] onRigTx : 7 37
[TRACE] onRigTx : 7 37
[TRACE] onRigTx : 5 35
[TRACE] onRigTx : M 4d
[TRACE] onRigTx : H 48
[TRACE] onRigTx : z 7a
[TRACE] onRigTx : / 2f
[TRACE] onRigTx : B 42
[TRACE] onRigTx : W 57
[TRACE] onRigTx : 1 31
[TRACE] onRigTx : 2 32
[TRACE] onRigTx : 5 35
[TRACE] onRigTx : / 2f
[TRACE] onRigTx : S 53
[TRACE] onRigTx : F 46
[TRACE] onRigTx : 1 31
[TRACE] onRigTx : 2 32
[TRACE] onRigTx : ␀ 0
[TRACE] onRigTxEnd : onRigTxEnd 86
[TRACE] onRigTaskTxPacket : onRigTaskTxPacket 86
[ERROR] onRigTaskTxPacket : TX error: -5
[TRACE] onRigTaskStartRx : onRigTaskStartRx
[INFO] onAprsisDataAvailable : # aprsc 2.1.14-g5e22b37
[INFO] onAprsisDataAvailable : # logresp SQ6SLB-10 verified, server T2NANJING
[INFO] onAprsisDataAvailable : # aprsc 2.1.14-g5e22b37 7 Dec 2023 07:41:17 GMT T2NANJING 172.18.0.2:14580

Although the beacon was sent it receives an error: TX error: -5
Unfortunately, the device is not receiving anything from LORA and stops flashing the LED on the board.

Regards
Tomasz

CSMA and CAD mode

Further to our other chats,. I see that there is no collision control right now.
I see that KISS has P-persistent CSMA as part of the protocol.
And the Mysensors library I use RFM95_sendWithRetry with some form of CSMA.
I think that using APRS on these Lora units is really cool, however the time-on-air at large spreading factors is quite high.
What do you think of implementing CAD/CSMA to take advantage of the fact that we are generally using transceivers for our Lora APRS so we can have better control of the traffic flows?
73
Patrick
ZS1DBM

can´t compile

C:\Users\acer\Desktop\esp32_loraprs\esp32_loraprs.ino:11:48: note: #pragma message: Using default built-in config
#pragma message("Using default built-in config")
^
C:\Users\acer\Desktop\esp32_loraprs\esp32_loraprs.ino:16:45: note: #pragma message: Configured for client mode
#pragma message("Configured for client mode")
^
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp:8:33: note: #pragma message: Using RadioLib
#pragma message("Using RadioLib")
^
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp: In member function 'void LoraPrs::Service::setupLora(long int, long int, int, int, int, int, int, bool)':
loraprs_service.cpp:240:16: error: 'ERR_NONE' was not declared in this scope
if (state != ERR_NONE) {
^~~~~~~~
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp:240:16: note: suggested alternative: 'DST_NONE'
if (state != ERR_NONE) {
^~~~~~~~
DST_NONE
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp:255:35: note: #pragma message: Using SX127X
#pragma message("Using SX127X")
^
loraprs_service.cpp:272:16: error: 'ERR_NONE' was not declared in this scope
if (state != ERR_NONE) {
^~~~~~~~
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp:272:16: note: suggested alternative: 'DST_NONE'
if (state != ERR_NONE) {
^~~~~~~~
DST_NONE
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp: In member function 'void LoraPrs::Service::loop()':
loraprs_service.cpp:368:22: error: 'ERR_NONE' was not declared in this scope
if (state != ERR_NONE) {
^~~~~~~~
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp:368:22: note: suggested alternative: 'DST_NONE'
if (state != ERR_NONE) {
^~~~~~~~
DST_NONE
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp: In static member function 'static void LoraPrs::Service::onLoraDataAvailableIsr()':
loraprs_service.cpp:410:20: error: 'ERR_NONE' was not declared in this scope
if (state == ERR_NONE) {
^~~~~~~~
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp:410:20: note: suggested alternative: 'DST_NONE'
if (state == ERR_NONE) {
^~~~~~~~
DST_NONE
loraprs_service.cpp:417:20: error: 'ERR_NONE' was not declared in this scope
if (state != ERR_NONE) {
^~~~~~~~
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp:417:20: note: suggested alternative: 'DST_NONE'
if (state != ERR_NONE) {
^~~~~~~~
DST_NONE
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp: In static member function 'static void LoraPrs::Service::processIncomingDataTask(void*)':
loraprs_service.cpp:434:22: error: 'ERR_NONE' was not declared in this scope
if (state == ERR_NONE) {
^~~~~~~~
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp:434:22: note: suggested alternative: 'DST_NONE'
if (state == ERR_NONE) {
^~~~~~~~
DST_NONE
loraprs_service.cpp:441:22: error: 'ERR_NONE' was not declared in this scope
if (state != ERR_NONE) {
^~~~~~~~
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp:441:22: note: suggested alternative: 'DST_NONE'
if (state != ERR_NONE) {
^~~~~~~~
DST_NONE
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp: In member function 'void LoraPrs::Service::setupFreq(long int) const':
loraprs_service.cpp:600:18: error: 'ERR_NONE' was not declared in this scope
if (state != ERR_NONE) {
^~~~~~~~
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp:600:18: note: suggested alternative: 'DST_NONE'
if (state != ERR_NONE) {
^~~~~~~~
DST_NONE
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp: In member function 'virtual void LoraPrs::Service::onRigTxEnd()':
loraprs_service.cpp:723:16: error: 'ERR_NONE' was not declared in this scope
if (state != ERR_NONE) {
^~~~~~~~
C:\Users\acer\Desktop\esp32_loraprs\loraprs_service.cpp:723:16: note: suggested alternative: 'DST_NONE'
if (state != ERR_NONE) {
^~~~~~~~
DST_NONE
Foram encontradas múltiplas bibliotecas para «WiFi.h»
Utilizado: C:\Users\acer\Documents\ArduinoData\packages\esp32\hardware\esp32\2.0.4\libraries\WiFi
Não utilizado: C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.57.0_x86__mdqgnx93n4wtt\libraries\WiFi
exit status 1
'ERR_NONE' was not declared in this scope

Pinout

Hello, would you be so kind as to tell me the connections between the pins of a wroom-32 38 pins and an rfm95?
Thanks in advance.

Bluetooth Passthrough Option

Would it be possible to add bluetooth passthrough ?

For example use a bluetooth terminal application and sent a text message between android phones.

Carrier detect for avoid packet collision.

Lora register have a bit set to 1 when packet is currently decoded by radio module. I made test on these bit and the bit remain at 1 until packet decoding complete and stored in fifo. You can use this bit as carrier detect. Here my code: (Using standard persist/slottime)

This code work perfectly, have avoid any on-the-air collisions with other packet. I use them since two year with my own lora aprs implementation. Right now I watch witch mode become standard and I would convert my network to most common protocol.

Rémi, VE2YAG.

//SX1278_REG_MODEM_STAT
#define SX1278_STATUS_SIG_DETECT 0b00000001
#define SX1278_STATUS_SIG_SYNCED 0b00000010
#define SX1278_STATUS_RX_ONGOING 0b00000100

#define SX1278_REG_MODEM_STAT 0x18

/******************************************************************************

  • Watch clear channel, 100ms slottime, persistance 63.
    *****************************************************************************/
    void WaitClearChannel() {
    uint32_t t;
    return;

    do {
    t = millis() + CHANNEL_SLOTTIME;
    do {
    if(lora.rxBusy()) t = millis() + CHANNEL_SLOTTIME;
    } while(millis() < t);
    } while(random(0,256) > CHANNEL_PERSIST);
    }

uint8_t SX1278::rxBusy(void) {

/* CHECK IF RX ARE IN RX_CONTINUOUS MODE */
if(_mode != SX1278_RXCONTINUOUS) InitReceiver(); 

/* CHECK SIGNAL DETECT BIT */
if(readRegister(SX1278_REG_MODEM_STAT) & SX1278_STATUS_SIG_DETECT) return 1;
return 0;

}

lora32 v 2.1

Hello, can this firmware be used on the lora32 v2.1 1.6 card?
I would love to be able to use this cheap card as KISS TNC for mobile phones.
Thank you!

Duplicate LoRa-APRS-OE header when digipeating in TNC2/text mode

uncommenting the usePrefix3_ section in kiss_processor.cpp line 344ff:

bool Processor::receiveByteRaw(byte rxByte) 
{
  if (isRawIdle_) {
    if (!onRigTxBegin()) {
      return false;
    }
    // if (usePrefix3_) {
    //   onRigTx('<');
    //   onRigTx(0xff);
    //   onRigTx(0x01);
    // }
    isRawIdle_ = false;
  }
  // NOTE, TNC2 uses \n as a packet delimiter
  if (rxByte == '\n') {
    onRigTxEnd();
    isRawIdle_ = true;
  } else {
    onRigTx(rxByte);
  }
  return true;
}

seems to resolve the issue - but I am not sure about possible side-effects.

Error during compile

Hi, I have this error: 'LoraPrs::Service::serialBt_' will be initialized after [-Werror=reorder]
Error is in loraaprs_service.h on row 106
Please help me.

Possibility to adapt code for the T-Beam ?

Hello,
I'm trying to figure out how to adapt the code to the ttgo tbeam as it seems a nice device for aprs use.
I've disabled the aprsIS and wifi part to be able to fit the code in the tbeam, the idea is to only use it as a kiss radio modem, without gateway feature for now. I've changed the lora module pins to fit the t-beam.
It pairs with aprsdroid and send a lora packet as far as I can see on the sdr. But the lora32-v2 using the lora-aprs/LoRa_APRS_iGate code doesn't decode the packet (it does when I'm using OE5BPA tracker code).
As I am a total noob in development, I thought I should ask if you have any idea or suggestion I could try to make the code run on the t-beam. This device and aprsdroid would be a good match for a very nice aprs package if it can be adapted.
Thanks for any help and for the work you already did !
73 de Tom F8COD

Add support for KISS over TCP/IP and WiFi AP mode

It would be useful if modem will connect to home WiFi network or run as AP, so that instead of short range Bluetooth, application such as Codec2 Talkie, Direwolf or Xastir will be usable through home WiFi, which has longer range. So modem could be put to higher elevation, such as roof top in a waterproof box for larger coverage.

  • Add option to enable AP
  • Add option to enable KISS over TCP/IP
    • In this case app must listen on a default KISS port and when client connects communicate with him by the given socket

no TX via LoRa

Hi,
may I ask for some help?

I´m not able to TX/RX any APRS packets via antenna.
I see, the board is connected via WiFi to APRS Server and is sending beacons to the server.
But, no RX or TX via antenna is possible.

I´m using a Heltec WiFi LoRa32 V2 board and defined
#define LORA_RST 14
#define LORA_IRQ 26
#define SS 18 (I have added it later as I thought it could be the issue as no definition is shown)

I put my other iGate next to it, testing any TX
and also my Tracker , testing any RX.

I have installed different SW and see with that SW,
I´m able to RX/TX any LoRa packets, so HW is not defect.

and clue

regards

Packets not reach APRS-IS network

Hello

Thank you for your hard work coding this project. I succesfully flashed a TTGO Lora32, to use it by a standalone iGate, its working OK except for the APRS-IS connection. The packets dont reach the APRS-IS network, looks like they are being dropped by the APRSC Server.

I tried with the server of a friend ( http://radioaficion.pro:14501/ ) and noticed the packet RX count sent by the iGate on red on the client list.

I dont know what is wrong. Any help is apreciated

Alejandro CE3VRT

Question: Interfacing Codec2 DV with a different RF library/device like nrf24

Hi there.
Would it be possible to interface the Android Codec2 talkie app with your arduino code with different RF modules to send the raw audio packets through?
If so which parts of your code would have to be used or modified?
I do realize this question is not directly related to your project but I think this should be possible so any hint is highly appreciated.

Not showing up on APRS map

I have load it to TTGo LoRA board. Set CFG_IS_CLIENT_MODE to false
#define CFG_DIGIREPEAT true
#define CFG_RF_TO_IS true
#define CFG_IS_TO_RF true
#define CFG_BEACON true
Also configured Wifi, APRS login.
However, the beacon never showed up on APRS map and never forward any other LoRA APRS to APRS-IS
What could possibly go wrong? The LoRa board did successfully get an IP address from the router as I could see it from router DHCP table.

LoRaWAN support for i-gate functionality

There are quite a few LoRaWAN networks coming up that provide a lot of useful coverage in the ISM band. Examples are Helium and The Things Network. In particular, Helium has LoRa gateways in almost every major city. There is no technical reason these cannot be used as two-way i-gates for esp32_loraprs TNC devices.

The benefit to esp32_loraprs would be that anyone could use the project to send data to APRS-IS over RF, immediately, and without setting up any infrastructure. There is a strong chance that, with this feature, a user could download the repository, flash it to their ESP32 board, and see their packets sent to aprs.fi (and others) right away. Currently, there is little existing dedicated ham radio LoRa infrastructure, and there are no standard frequencies and settings. This may lead to frustration among users who want a solution that "just works" in the sense of getting their packets on the map. We could duplicate the experience which users of commercial radios with packet TNC's on AFSK 144.390 currently have, without the need to bootstrap our own system.

I suggest that this would be implemented as an optional switch in loraprs_config.h, alongside a switch for sending RF packets point-to-point. Both, one, or none could be selected. This would only be available for radios on 915 Mhz (North America), 868 Mhz (Europe) or 470 Mhz (China).

This feature would need to be combined with a process running on a server to forward packets between the LoRaWAN and APRS-IS services. I have already created this and am using it for my own testing.

One potential problem is the fact that LoRaWAN uses encryption to send packets. This could be mitigated by publishing the encryption keys used for this particular application EUI, so that anybody could decode the packets. On the other hand, this system is similar to just using the internet to forward packets to APRS-IS over wifi, over which the use of encryption has never been problematic. I'd appreciate any feedback or clarity on this.

I'm submitting this as a feature-enhancement idea because I know how to make it work, am essentially using it for my own purposes, and wanted to know if it sounded like a good idea and something that could be useful to the community.

Help with ax25

Is there a way to contact you to learn to decode and encode ax25 packets to avoid copying all without understanding what you did?

This is for a Lora Tracker in developing

Guru Meditation Error: Core 1 panic'ed (Interrupt wdt timeout on CPU1)

I've got some crashes like u see in the topic.

I can't verifying crashes on your original version because i had to modify the sketch a bit so that it works with RadioLib and SX1276 ( 868 MHz ).

But it seems the crashes decreasing when i increase CfgPollDelayMs to 10. Now i have set it to 15 and it seems ok but i still testing.. ( Get still some losts of ip connection from the Modul but i can't tell if it's related to the crash or just to a weak wifi connection )

Another think i did, but don't laugh, i am just a amateur, i commented out
delay(CfgPollDelayMs);
in
Service::processIncomingDataTask
.

I came to the decision to do so, because i googled the problem.
It seems to came to this problem when u delay a secondary task ( like a thread, like i understand).
And like i understand Service::processIncomingDataTask is a secondary task in ISR Mode.

Like i said.. This both changes seemed to work on my side. I also discovered that the Moduls are really hot after they crashed..

So it makes sens to increase CfgPollDelayMs to get load from the CPU and it wouldn't be necessary to comment out the delay(CfgPollDelayMs) in Service::processIncomingDataTask .

Add support for USB-OTG mode

  • It would be useful if modem could be used with Android Phone in USB-OTG mode.
  • So data will be transferred through USB serial port instead of Bluetooth.
  • In this case user can power modem from the phone USB-OTG port and use the same port for data transfer by APRSDroid and Codec2 Talkie applications.
  • Need to disable debug printing usage to serial when USB mode is enabled and use serial for data transfer only, default baud rate could be changed for both APRSDroid and Codec2 Talkie, so keep existing one
  • Additionally, user can print 3d holder for the modem.

'Radio start error: -13' and 'GPIO isr service is not installed, call gpio_install_isr_service() first'

What is wrong? Errors:

  1. setupRig : Radio start error: -13
  2. gpio: gpio_isr_handler_remove(480): GPIO isr service is not installed, call gpio_install_isr_service() first

From console:

configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:1
load:0x3fff0030,len:1344
load:0x40078000,len:13864
load:0x40080400,len:3608
entry 0x400805f0
[INFO] printConfig : Current mode: NORMAL
[INFO] printConfig : Using TNC KISS and AX.25 mode
[INFO] printConfig : UsbSerialEnable: no
[INFO] setupRig : Initializing LoRa
[INFO] setupRig : Frequency: 434855000 Hz
[INFO] setupRig : Bandwidth: 125000 Hz
[INFO] setupRig : Spreading: 9
[INFO] setupRig : Coding rate: 7
[INFO] setupRig : Power: 30 dBm
[INFO] setupRig : Sync: 0x12
[INFO] setupRig : CRC: 1
[INFO] setupRig : Header: explicit
[INFO] setupRig : Speed: 1255 bps
[INFO] setupRig : TOA (compressed): 0.24 sec
[INFO] setupRig : TOA (uncompressed): 0.41 sec
[INFO] setupRig : Min level: -129.63 dBm
**[ERROR] setupRig : Radio start error: -13**
[INFO] setupRig : Using SX126X module
**E (103) gpio: gpio_isr_handler_remove(480): GPIO isr service is not installed, call gpio_install_isr_service() first**
[INFO] setupRig : LoRa initialized
[INFO] setupBt : BT init[INFO] rigTask : Radio task started
 loraprs
[INFO] setupBt : BT initialized
[TRACE] onSerialRx : � c0
[TRACE] onSerialRx :  0
[TRACE] onRigTxBegin : onRigTxBegin
[TRACE] onSerialRx : � 82
[...]

PINOUT:

//in pins_arduino.h
//TX = 1;
//RX = 3;
//SDA = 21;
//SCL = 22;
//SS    = 5;
//MOSI  = 23;
//MISO  = 19;
//SCK   = 18;

//in config.h:
#define CFG_LORA_PIN_SS         5
#define CFG_LORA_PIN_RST        14
#define CFG_LORA_PIN_A          33 //DIO1
#define CFG_LORA_PIN_B          39 //BUSY - SVN 
#define CFG_LORA_PIN_RXEN       2
#define CFG_LORA_PIN_TXEN       4
#define BUILTIN_LED             12

Board: AZ-Delivery (esp32-wroom-32), ESP32 Dev module (in Arduino IDE from Board Manager),
Radio module: E22 400M30S

No errors while compiling:

C:\Users\does_not_matter\Documents\Arduino\esp32_loraprs\esp32_loraprs.ino:11:48: note: #pragma message: Using default built-in config
 #pragma message("Using default built-in config")
                                                ^
C:\Users\does_not_matter\Documents\Arduino\esp32_loraprs\esp32_loraprs.ino:16:45: note: #pragma message: Configured for client mode
 #pragma message("Configured for client mode")
                                             ^
C:\Users\does_not_matter\Documents\Arduino\esp32_loraprs\loraprs_service.cpp: In member function 'void LoraPrs::Service::setupRig(long int, long int, int, int, int, int, int, bool)':
C:\Users\does_not_matter\Documents\Arduino\esp32_loraprs\loraprs_service.cpp:226:35: note: #pragma message: Using SX126X
     #pragma message("Using SX126X")

ESP32 hangs after getting package from lora Tracker!

Hardware : ESP32 Lora board design by myself (BV5DJ)
Lora : E22 SX1268
config: server mode (APRS-IS gate mode)
ERR:

[INFO]_ sendPeriodicBeacon : Periodic beacon is sent
Guru Meditation Error: Core 1 panic'ed (Coprocessor exception)
Core 1 register dump:
PC : 0x400d57c6 PS : 0x00060330 A0 : 0x800d2ec8 A1 : 0x3ffcfe60
A2 : 0x3ffc4a9c A3 : 0x00000001 A4 : 0x0000003f A5 : 0x00000000
A6 : 0x000000c0 A7 : 0x3ffcff48 A8 : 0x800d57c6 A9 : 0x3ffcff00
A10 : 0xc22c0000 A11 : 0x000000c0 A12 : 0x00000001 A13 : 0x00000001
A14 : 0x00060b20 A15 : 0x00000000 SAR : 0x0000001d EXCCAUSE: 0x00000004
EXCVADDR: 0x00000000 LBEG : 0x40092d59 LEND : 0x40092d69 LCOUNT : 0xfffffffe
Core 1 was running in ISR context:
EPC1 : 0x400d57c6 EPC2 : 0x00000000 EPC3 : 0x00000000 EPC4 : 0x40090db8
ELF file SHA256: 0000000000000000
Backtrace: 0x400d57c6:0x3ffcfe60 0x400d2ec5:0x3ffcff20 0x400d2ec5:0x3ffcff70 0x400d5acd:0x3ffcffe0 0x400d2939:0x3ffd0020 0x400e1904:0x3ffd0040 0x40094cf2:0x3ffd0060
Rebooting...
ets...

Feature request: stripdown version of the sketch to use as walkie-talkie

I have installed your great app https://github.com/sh123/codec2_talkie.

can you make simple one file sketch for ESP32 to use with above app removing all Kiss, APRS and WiFi Stuff for general purpose (non HAM) use ?

I am not well versed into HAM radio stuff. If there is simple sketch dealing with codec2 raw packets with LoRa transport my plan is to use it as a template to implement some newer LoRa chips like SX1262 and SX1280.

Thanks.

This a great idea!

I really like this idea.
Im building a testing one today here in Cape Town.!
Patrick
ZS1dBm

Request: Adjustable Preamble lenght

Hi,

i use LoRa as a additional Port on my Node ( TNN ) for testing the possibilities of Lora and how useful and piratical it is.
So i don't use it just for "unprot" Data transfer like in APRS Application.

So i need Bandwidth or better speed.
The main speed factor on simplex isn't the baudrate. The main factor is how many packet i can send at once.

Sure, the payload length is a factor too because of saving header but it seems limited to the LoRa Coding rate.
If i use coding rate 8 i double the airtime ( overall packet length ) . So a AX25 pac lengh > 100 seems exceed the LoRa Pac lengh.. Or the LoRa Chips can't handle so much air time.
I am still testing it.

Back to topic.. Sorry but maybe
It wasn't possible to send more than one packet at once until i increased the preamble length to 16.
I got the issues on both librarys ( LoRa and RadioLib ) also on different devices (T-BEAM, Heltec WIFI LORA 32 V2, Heltec Wireles Stick ) and the solution worked on both libarys for me.

Just a idea: Maybe the kiss cmd for txd can be used to set preamble length. But there are issuse if preamble length isn't set the same on both ends.

int state = radio_->begin((float)loraFreq / 1e6, (float)bw / 1e3, sf, cr, sync, pwr, preamble);
LoRa.setPreambleLength(preamble);

Thanks for your work.. I love this AX25 shit.. It isn't perfect but that's it what it makes interesting . .

Broken txt aprs packet?

Hello

I was try use igate to recevice txt aprs from Lora Tracker from this project: https://github.com/lora-aprs/LoRa_APRS_iGate.
My setup: Lora RA-02 trx + TTGO T7 v1.3.
I was know to change config:
#define CFG_TEXT_PACKETS true

Broken(?) packet received over LORA from tracker:

[TRACE] onSerialTx : < 3c
[TRACE] onSerialTx : ⸮ ff
[TRACE] onSerialTx :  1
[TRACE] onSerialTx : S 53
[TRACE] onSerialTx : Q 51
[TRACE] onSerialTx : 6 36
[TRACE] onSerialTx : N 4e
[TRACE] onSerialTx : C 43
[TRACE] onSerialTx : C 43
[TRACE] onSerialTx : - 2d
[TRACE] onSerialTx : 7 37
[TRACE] onSerialTx : > 3e
[TRACE] onSerialTx : A 41
[TRACE] onSerialTx : P 50
[TRACE] onSerialTx : L 4c
[TRACE] onSerialTx : T 54
[TRACE] onSerialTx : 0 30
[TRACE] onSerialTx : 0 30
[TRACE] onSerialTx : , 2c
[TRACE] onSerialTx : W 57
[TRACE] onSerialTx : I 49
[TRACE] onSerialTx : D 44
[TRACE] onSerialTx : E 45
[TRACE] onSerialTx : 1 31
[TRACE] onSerialTx : - 2d
[TRACE] onSerialTx : 1 31
[TRACE] onSerialTx : : 3a
[TRACE] onSerialTx : ! 21
[TRACE] onSerialTx : 5 35
[TRACE] onSerialTx : 1 31
[TRACE] onSerialTx : 0 30
[TRACE] onSerialTx : 8 38
[TRACE] onSerialTx : . 2e
[TRACE] onSerialTx : 2 32
[TRACE] onSerialTx : 1 31
[TRACE] onSerialTx : N 4e
[TRACE] onSerialTx : / 2f
[TRACE] onSerialTx : 0 30
[TRACE] onSerialTx : 1 31
[TRACE] onSerialTx : 6 36
[TRACE] onSerialTx : 4 34
[TRACE] onSerialTx : 7 37
[TRACE] onSerialTx : . 2e
[TRACE] onSerialTx : 4 34
[TRACE] onSerialTx : 8 38
[TRACE] onSerialTx : E 45
[TRACE] onSerialTx : [ 5b
[TRACE] onSerialTx : 3 33
[TRACE] onSerialTx : 6 36
[TRACE] onSerialTx : 0 30
[TRACE] onSerialTx : / 2f
[TRACE] onSerialTx : 0 30
[TRACE] onSerialTx : 0 30
[TRACE] onSerialTx : 3 33
[TRACE] onSerialTx : / 2f
[TRACE] onSerialTx : A 41
[TRACE] onSerialTx : = 3d
[TRACE] onSerialTx : 0 30
[TRACE] onSerialTx : 0 30
[TRACE] onSerialTx : 0 30
[TRACE] onSerialTx : 4 34
[TRACE] onSerialTx : 6 36
[TRACE] onSerialTx : 4 34
[TRACE] onSerialTx :   20
[TRACE] onSerialTx : - 2d
[TRACE] onSerialTx :   20
[TRACE] onSerialTx :   20
[TRACE] onSerialTx : _ 5f
[TRACE] onSerialTx : B 42
[TRACE] onSerialTx : a 61
[TRACE] onSerialTx : t 74
[TRACE] onSerialTx : . 2e
[TRACE] onSerialTx : : 3a
[TRACE] onSerialTx :   20
[TRACE] onSerialTx : 3 33
[TRACE] onSerialTx : . 2e
[TRACE] onSerialTx : 6 36
[TRACE] onSerialTx : 6 36
[TRACE] onSerialTx : V 56
[TRACE] onSerialTx :   20
[TRACE] onSerialTx : - 2d
[TRACE] onSerialTx :   20
[TRACE] onSerialTx : C 43
[TRACE] onSerialTx : u 75
[TRACE] onSerialTx : r 72
[TRACE] onSerialTx : . 2e
[TRACE] onSerialTx : : 3a
[TRACE] onSerialTx :   20
[TRACE] onSerialTx : 6 36
[TRACE] onSerialTx : 4 34
[TRACE] onSerialTx : 4 34
[TRACE] onSerialTx : m 6d
[TRACE] onSerialTx : A 41
[TRACE] onSerialTx :   20
[TRACE] onSerialTx : ! 21
[TRACE] onSerialTx : w 77
[TRACE] onSerialTx : 8 38
[TRACE] onSerialTx : R 52
[TRACE] onSerialTx : ! 21
[TRACE] onSerialTx : 
 a

This packet is not valid and is not transmited to APRS-IS
I was try to debug and seen that source and destination calls was not recognized:
Serial.println(payload.ToString());

>:!5108.21N/01647.48E[360/003/A=000464 -  _Bat.: 3.66V - Cur.: 644mA !w8R
[WARN] processIncomingRawPacketAsServer : Skipping non-AX25 payload

What can i do?

Best regards
Tom

boards?

Hello! This looks awesome. I would like to try it out, are there specific boards this is compatable with? For instance could I use it with the TTGO T-Beam ESP32?

Thanks! KD8IAY

Sketch too big for T-BEAM

Hello,

at first, thank u a lot for u work. Seems Lora can be interesting as a cheap and simple to made option as an Secondary entry to our free ax25 Network in Germany ( mostly on CB Radio and via AXIP ) .

The Sketch seems to big for the T-Beam. Also i got issues while compiling it with LoRa libbary.
"'loraprs_service.cpp: In member function 'void LoraPrs::Service::setupLora(long int, long int, int, int, int, int, int, bool)':
loraprs_service.cpp:295:7: error: 'enableCrc' was not declared in this scope
if (enableCrc) {"

Bildschirmfoto von 2022-10-16 06-59-07

I solved it for me like u can see in the screenshot.
I also solved for me the "Sketch to big issues" be commenting out the Bluetooth section in the setup() routine.
In the config i allready cleared out the BT device name (
// Bluetooth
#define CFG_BT_NAME "" // set to empty to disable Bluetooth
#define CFG_BT_USE_BLE false // set to true to use bluetooth low energy (for ios devices)
) .

I already spotted some other issues but better I submit it as an other Issues here because it's another topic..

Thanks .. .. .

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.