main.cpp: bugfix printKeys
This commit is contained in:
parent
1e5407b3c2
commit
4b52478caa
@ -11,8 +11,8 @@
|
|||||||
|
|
||||||
; ---> SELECT TARGET PLATFORM HERE! <---
|
; ---> SELECT TARGET PLATFORM HERE! <---
|
||||||
[platformio]
|
[platformio]
|
||||||
;env_default = generic
|
env_default = generic
|
||||||
env_default = heltec
|
;env_default = heltec
|
||||||
;env_default = ttgov1
|
;env_default = ttgov1
|
||||||
;env_default = ttgov2
|
;env_default = ttgov2
|
||||||
;env_default = ttgov21
|
;env_default = ttgov21
|
||||||
|
@ -13,5 +13,6 @@ void get_hard_deveui(uint8_t *pdeveui);
|
|||||||
void os_getDevKey(u1_t *buf);
|
void os_getDevKey(u1_t *buf);
|
||||||
void os_getArtEui(u1_t *buf);
|
void os_getArtEui(u1_t *buf);
|
||||||
void os_getDevEui(u1_t *buf);
|
void os_getDevEui(u1_t *buf);
|
||||||
|
void printKeys(void);
|
||||||
|
|
||||||
#endif
|
#endif
|
25
src/main.cpp
25
src/main.cpp
@ -80,9 +80,6 @@ void reset_counters() {
|
|||||||
macs_ble = 0;
|
macs_ble = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* begin LMIC specific parts
|
|
||||||
* ------------------------------------------------------------ */
|
|
||||||
|
|
||||||
#ifdef HAS_LORA
|
#ifdef HAS_LORA
|
||||||
|
|
||||||
// LMIC enhanced Pin mapping
|
// LMIC enhanced Pin mapping
|
||||||
@ -94,10 +91,6 @@ const lmic_pinmap lmic_pins = {.mosi = PIN_SPI_MOSI,
|
|||||||
.rst = RST,
|
.rst = RST,
|
||||||
.dio = {DIO0, DIO1, DIO2}};
|
.dio = {DIO0, DIO1, DIO2}};
|
||||||
|
|
||||||
#ifdef VERBOSE
|
|
||||||
void printKeys(void);
|
|
||||||
#endif // VERBOSE
|
|
||||||
|
|
||||||
// Get MCP 24AA02E64 hardware DEVEUI (override default settings if found)
|
// Get MCP 24AA02E64 hardware DEVEUI (override default settings if found)
|
||||||
#ifdef MCP_24AA02E64_I2C_ADDRESS
|
#ifdef MCP_24AA02E64_I2C_ADDRESS
|
||||||
get_hard_deveui(buf);
|
get_hard_deveui(buf);
|
||||||
@ -117,15 +110,8 @@ void lorawan_loop(void *pvParameters) {
|
|||||||
|
|
||||||
#endif // HAS_LORA
|
#endif // HAS_LORA
|
||||||
|
|
||||||
/* end LMIC specific parts
|
// Setup IRQ handler routines
|
||||||
* --------------------------------------------------------------- */
|
// attn see https://github.com/espressif/arduino-esp32/issues/855
|
||||||
|
|
||||||
/* beginn hardware specific parts
|
|
||||||
* -------------------------------------------------------- */
|
|
||||||
|
|
||||||
// Setup IRQ handler routines for button, channel rotation, send cycle´, display
|
|
||||||
// attention, enable cache:
|
|
||||||
// https://github.com/espressif/arduino-esp32/issues/855
|
|
||||||
|
|
||||||
void IRAM_ATTR ChannelSwitchIRQ() {
|
void IRAM_ATTR ChannelSwitchIRQ() {
|
||||||
portENTER_CRITICAL(&timerMux);
|
portENTER_CRITICAL(&timerMux);
|
||||||
@ -174,9 +160,6 @@ void readButton() {
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* end hardware specific parts
|
|
||||||
* -------------------------------------------------------- */
|
|
||||||
|
|
||||||
// Wifi channel rotation task
|
// Wifi channel rotation task
|
||||||
void wifi_channel_loop(void *pvParameters) {
|
void wifi_channel_loop(void *pvParameters) {
|
||||||
|
|
||||||
@ -404,8 +387,8 @@ void setup() {
|
|||||||
// join network
|
// join network
|
||||||
LMIC_startJoining();
|
LMIC_startJoining();
|
||||||
|
|
||||||
// start lmic runloop in rtos task on core 1 (note: arduino main loop runs
|
// start lmic runloop in rtos task on core 1
|
||||||
// on core 1, too)
|
// (note: arduino main loop runs on core 1, too)
|
||||||
// https://techtutorialsx.com/2017/05/09/esp32-get-task-execution-core/
|
// https://techtutorialsx.com/2017/05/09/esp32-get-task-execution-core/
|
||||||
|
|
||||||
ESP_LOGI(TAG, "Starting Lora task on core 1");
|
ESP_LOGI(TAG, "Starting Lora task on core 1");
|
||||||
|
Loading…
Reference in New Issue
Block a user