Merge pull request #645 from ChrSchultz/master

add Payloadmask description + file renames
This commit is contained in:
Verkehrsrot 2020-09-29 17:11:21 +02:00 committed by GitHub
commit 1d13914922
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 108 additions and 98 deletions

2
.gitignore vendored
View File

@ -12,3 +12,5 @@
.gcc-flags.json .gcc-flags.json
src/loraconf.h src/loraconf.h
src/ota.conf src/ota.conf
platformio.ini
src/paxcounter.conf

View File

@ -85,11 +85,11 @@ By default bluetooth sniffing not installed (#define *BLECOUNTER* 0 in paxcounte
Compile time configuration is spread across several files. Before compiling the code, edit or create the following files: Compile time configuration is spread across several files. Before compiling the code, edit or create the following files:
## platformio.ini ## platformio_orig.ini
Edit `platformio.ini` and select desired hardware target in section boards. To add a new board, create an appropriate hardware abstraction layer file in hal subdirectory, and add a pointer to this file in sections boards. Edit `platformio_orig.ini` and select desired hardware target in section boards. To add a new board, create an appropriate hardware abstraction layer file in hal subdirectory, and add a pointer to this file in sections board. Rename to `platformio.ini`
## src/paxcounter.conf ## src/paxcounter_orig.conf
Edit `src/paxcounter.conf` and tailor settings in this file according to your needs and use case. Please take care of the duty cycle regulations of the LoRaWAN network you're going to use. Edit `src/paxcounter_orig.conf` and tailor settings in this file according to your needs and use case. Please take care of the duty cycle regulations of the LoRaWAN network you're going to use. Rename to `paxcounter.conf`
If your device has a **real time clock** it can be updated bei either LoRaWAN network or GPS time, according to settings *TIME_SYNC_INTERVAL* and *TIME_SYNC_LORAWAN* in `paxcounter.conf`. If your device has a **real time clock** it can be updated bei either LoRaWAN network or GPS time, according to settings *TIME_SYNC_INTERVAL* and *TIME_SYNC_LORAWAN* in `paxcounter.conf`.
@ -480,7 +480,16 @@ Send for example `8386` as Downlink on Port 2 to get battery status and time/dat
0x14 set payload mask 0x14 set payload mask
byte 1 = sensor data payload mask (0..255, meaning of bits see above) byte 1 = sensor data payload mask (0..255, meaning of bits see below)
0x01 = GPS_DATA
0x02 = ALARM_DATA
0x04 = MEMS_DATA
0x08 = COUNT_DATA (default)
0x10 = SENSOR_1_DATA (ENS-COUNTS)
0x20 = SENSOR_2_DATA
0x40 = SENSOR_3_DATA
0x80 = BATT_DATA
bytes can be combined eg COUNT_DATA ;SENSOR_1_DATA ;BATT_DATA: `0x08 | 0x10 |0x80 = 0x98`
0x15 set BME data on/off 0x15 set BME data on/off

View File

@ -25,7 +25,6 @@
* displayed in TTN console, so you can cut & paste from there. This is different * displayed in TTN console, so you can cut & paste from there. This is different
* from standard LMIC-Arduino which expects DEVEUI and APPEUI in LSB format. * from standard LMIC-Arduino which expects DEVEUI and APPEUI in LSB format.
* For TTN, APPEUI in MSB format always starts with 0x70, 0xB3, 0xD5. * For TTN, APPEUI in MSB format always starts with 0x70, 0xB3, 0xD5.
* Set your DEVEUI here, if your device has have a fixed one. * Set your DEVEUI here, if your device has have a fixed one.
* If you leave this untouched, then the DEVEUI will be derived from device's * If you leave this untouched, then the DEVEUI will be derived from device's
* MAC adress during startup and will be displayed on device's screen as well as * MAC adress during startup and will be displayed on device's screen as well as

View File

@ -89,7 +89,7 @@
#define TIME_SYNC_INTERVAL_RETRY 10 // retry time sync after lost sync each .. minutes [default = 10], 0 means off #define TIME_SYNC_INTERVAL_RETRY 10 // retry time sync after lost sync each .. minutes [default = 10], 0 means off
#define TIME_SYNC_SAMPLES 1 // number of time requests for averaging, max. 255 #define TIME_SYNC_SAMPLES 1 // number of time requests for averaging, max. 255
#define TIME_SYNC_CYCLE 60 // delay between two time samples [seconds] #define TIME_SYNC_CYCLE 60 // delay between two time samples [seconds]
#define TIME_SYNC_TIMEOUT 300 // timeout waiting for timeserver answer [seconds] #define TIME_SYNC_TIMEOUT 400 // timeout waiting for timeserver answer [seconds]
#define TIME_SYNC_COMPILEDATE 0 // set to 1 to use compile date to initialize RTC after power outage [default = 0] #define TIME_SYNC_COMPILEDATE 0 // set to 1 to use compile date to initialize RTC after power outage [default = 0]
// time zone, see https://github.com/JChristensen/Timezone/blob/master/examples/WorldClock/WorldClock.ino // time zone, see https://github.com/JChristensen/Timezone/blob/master/examples/WorldClock/WorldClock.ino