v1.4.23
This commit is contained in:
parent
fcd9357116
commit
5880b7e9ff
@ -43,10 +43,18 @@ build_flags =
|
||||
; ---> NOTE: For production run set DEBUG_LEVEL level to NONE! <---
|
||||
; otherwise device may leak RAM
|
||||
;
|
||||
; -DCORE_DEBUG_LEVEL=ARDUHAL_LOG_LEVEL_NONE
|
||||
-DCORE_DEBUG_LEVEL=ARDUHAL_LOG_LEVEL_INFO
|
||||
; -DCORE_DEBUG_LEVEL=ARDUHAL_LOG_LEVEL_DEBUG
|
||||
; -DCORE_DEBUG_LEVEL=ARDUHAL_LOG_LEVEL_VERBOSE
|
||||
; None
|
||||
; -DCORE_DEBUG_LEVEL=0
|
||||
; Error
|
||||
; -DCORE_DEBUG_LEVEL=1
|
||||
; Warn
|
||||
-DCORE_DEBUG_LEVEL=2
|
||||
; Info
|
||||
; -DCORE_DEBUG_LEVEL=3
|
||||
; Debug
|
||||
; -DCORE_DEBUG_LEVEL=4
|
||||
; Verbose
|
||||
; -DCORE_DEBUG_LEVEL=5
|
||||
;
|
||||
; override lora settings from LMiC library in lmic/config.h and use main.h instead
|
||||
-D_lmic_config_h_
|
||||
|
@ -4,11 +4,8 @@
|
||||
// The mother of all embedded development...
|
||||
#include <Arduino.h>
|
||||
|
||||
// needed for ESP_LOGx on arduino framework
|
||||
#include <esp32-hal-log.h>
|
||||
|
||||
// attn: increment version after modifications to configData_t truct!
|
||||
#define PROGVERSION "1.4.22" // use max 10 chars here!
|
||||
#define PROGVERSION "1.4.23" // use max 10 chars here!
|
||||
#define PROGNAME "PAXCNT"
|
||||
|
||||
// std::set for unified array functions
|
||||
|
@ -8,8 +8,8 @@ void SendData(uint8_t port) {
|
||||
|
||||
SendBuffer.MessageSize = payload.getSize();
|
||||
SendBuffer.MessagePort = PAYLOAD_ENCODER <= 2
|
||||
? port
|
||||
: (PAYLOAD_ENCODER == 4 ? LPP2PORT : LPP1PORT);
|
||||
? port
|
||||
: (PAYLOAD_ENCODER == 4 ? LPP2PORT : LPP1PORT);
|
||||
memcpy(SendBuffer.Message, payload.getBuffer(), payload.getSize());
|
||||
|
||||
// enqueue message in LoRa send queue
|
||||
@ -79,9 +79,6 @@ void IRAM_ATTR SendCycleIRQ() {
|
||||
// cyclic called function to eat data from RTos send queues and transmit it
|
||||
void processSendBuffer() {
|
||||
|
||||
int m1 = 0, m2 = 0;
|
||||
m1 = ESP.getFreeHeap();
|
||||
|
||||
MessageBuffer_t SendBuffer;
|
||||
|
||||
#ifdef HAS_LORA
|
||||
@ -93,7 +90,7 @@ void processSendBuffer() {
|
||||
// SendBuffer gets struct MessageBuffer with next payload from queue
|
||||
LMIC_setTxData2(SendBuffer.MessagePort, SendBuffer.Message,
|
||||
SendBuffer.MessageSize, (cfg.countermode & 0x02));
|
||||
//ESP_LOGI(TAG, "%d bytes sent to LoRa", SendBuffer.MessageSize);
|
||||
ESP_LOGI(TAG, "%d bytes sent to LoRa", SendBuffer.MessageSize);
|
||||
sprintf(display_line7, "PACKET QUEUED");
|
||||
}
|
||||
}
|
||||
@ -101,14 +98,10 @@ void processSendBuffer() {
|
||||
|
||||
#ifdef HAS_SPI
|
||||
if (xQueueReceive(SPISendQueue, &SendBuffer, (TickType_t)0) == pdTRUE) {
|
||||
//ESP_LOGI(TAG, "%d bytes sent to SPI", SendBuffer.MessageSize);
|
||||
ESP_LOGI(TAG, "%d bytes sent to SPI", SendBuffer.MessageSize);
|
||||
}
|
||||
#endif
|
||||
|
||||
m2 = ESP.getFreeHeap();
|
||||
if (m2 - m1)
|
||||
ESP_LOGI(TAG, "processSendBuffer consumed %d bytes", m2 - m1);
|
||||
|
||||
} // processSendBuffer
|
||||
|
||||
void flushQueues() {
|
||||
|
Loading…
Reference in New Issue
Block a user