Merge pull request #440 from cyberman54/development

Development
This commit is contained in:
Verkehrsrot 2019-09-17 15:06:02 +02:00 committed by GitHub
commit f7f68c61dc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 2 deletions

View File

@ -437,7 +437,7 @@ esp_err_t lora_stack_init() {
"lmictask", // name of task
4096, // stack size of task
(void *)1, // parameter of the task
2, // priority of the task
5, // priority of the task
&lmicTask, // task handle
1); // CPU core

View File

@ -31,9 +31,9 @@ ledloop 0 3 blinks LEDs
spiloop 0 2 reads/writes data on spi interface
IDLE 0 0 ESP32 arduino scheduler -> runs wifi sniffer
lmictask 1 5 MCCI LMiC LORAWAN stack
clockloop 1 4 generates realtime telegrams for external clock
timesync_req 1 3 processes realtime time sync requests
lmictask 1 2 MCCI LMiC LORAWAN stack
irqhandler 1 1 display, timesync, gps, etc. triggered by timers
gpsloop 1 1 reads data from GPS via serial or i2c
lorasendtask 1 1 feed data from lora sendqueue to lmcic
@ -58,6 +58,7 @@ fired by hardware
DisplayIRQ -> esp32 timer 0 -> irqHandlerTask (Core 1)
CLOCKIRQ -> esp32 timer 1 -> ClockTask (Core 1)
ButtonIRQ -> external gpio -> irqHandlerTask (Core 1)
PMUIRQ -> PMU chip gpio -> irqHandlerTask (Core 1)
fired by software (Ticker.h)
TIMESYNC_IRQ -> timeSync() -> irqHandlerTask (Core 1)

View File

@ -72,6 +72,7 @@ void wifi_sniffer_init(void) {
esp_wifi_set_storage(WIFI_STORAGE_RAM)); // we don't need NVRAM
ESP_ERROR_CHECK(esp_wifi_set_mode(WIFI_MODE_NULL));
ESP_ERROR_CHECK(esp_wifi_set_ps(WIFI_PS_NONE)); // no modem power saving
ESP_ERROR_CHECK(esp_wifi_start()); // must be started to be able to switch ch
ESP_ERROR_CHECK(esp_wifi_set_promiscuous_filter(&filter)); // set frame filter
ESP_ERROR_CHECK(esp_wifi_set_promiscuous_rx_cb(&wifi_sniffer_packet_handler));
ESP_ERROR_CHECK(esp_wifi_set_promiscuous(true)); // now switch on monitor mode