cyberman54 / ESP32-Paxcounter

Wifi & BLE driven passenger flow metering with cheap ESP32 boards
https://cyberman54.github.io/ESP32-Paxcounter/
Other
1.69k stars 397 forks source link

lorawan-device repo initial files #815

Closed Drasek closed 3 years ago

Drasek commented 3 years ago

This includes all the initial files necessary for a first realease in the lorawan-devices repo https://github.com/TheThingsNetwork/lorawan-devices. I though it would be best to include this here into the repo, so we can work on it together till its ready to release, then follow the steps below to include it into the lorawan-devices repo. If we change stuff in the future (maybe sensor data like pm25 and pm10 on port 10 and such things), we need to change the payload decoder, the examples, etc. and we can do this here together and one of us will update the lorawan-device repo from time to time (after each release with changes to the payload, or things related to the repo).

Things to talk about:

How to add the files to the repo:

If we want we can add a image. I don't know wether the licence is CC0 or such, so i have not included one atm, if you want to include one, tell me which and i add it.

cyberman54 commented 3 years ago

@spmrider could you take a closer look at this?

oliverbrandmueller commented 3 years ago

@spmrider could you take a closer look at this?

I do have that on my list; however due to summer holidays it's unlikely this is before mid july.

Drasek commented 3 years ago

If you want, we can set up a call, so i can explain more easily why i did what i did and you have more details to decide about how to move on with this.

Drasek commented 3 years ago

One of the reasons to support the lorawan-device repo was the 4k limit of the payload decoder in the ttn v3, this is under discussion again: https://github.com/TheThingsNetwork/lorawan-stack/issues/4278#issuecomment-864061169 - could take a while (its marked with Q3 release).

The other reason for the lorawan-device repo is that it is more convenient for users just to choose a vendor/device and things like the lorawan version and the payload decoder is set automaticly.

cyberman54 commented 3 years ago

@Drasek i merged this to master, thank you! Could you open the pull request on TTN side?

Drasek commented 3 years ago

Great! I will open the pull request on TTN side.

cyberman54 commented 2 years ago

@Drasek Sometimes i see "missing codec" entries in the LiveMessage Console. Probably this happenes when MAC commands are delivered. Is there a way to enhance the decoder to display the payload / MAC commands?

image

Drasek commented 2 years ago

Do you know a way to reproduce it? I am in moers at the hackdays from 30. to 31. october and will have a look into it there - should have a bit of free time for it. I would like to tackle the "every sensor sends data over port 1" problem there too, maybe i can adjust the particle matter data (and more) to be send over the custom ports.

cyberman54 commented 2 years ago

It's easy to reproduce it: Use TTN v3 stack and activate time sync via LORAWAN in paxounter.conf. This generates MAC commands DeviceTimeReq / DeviceTimeAns in LMIC, and those will showup in the v3 console as shown above. Probably the same happens for all MAC commands, i.e. ADR requests from the network. Would be nice to have a monitor for this, by decoding the MAC payload.