I have recently been lent a MCF88-LW12TERWP to play with, hardware-wise its a nice device and I like the NFC config capability however I cannot work out how to decode the payloads…
The “data sheet” from the manufacturers’ website is next to useless at describing anything other than the very high-level features of the device - https://www.mcf88.it/prodotto/mcf-lw12terwp/
I was hoping somebody may already have a JS decoder I can use for this device that plugs directly into the Payload Decoder in TTN console.
Here is an example of the payload spat out by the device… 048DB1F62883095EA38C01CFB2F62880095FA28C0112B4F628770961A58C0164
Yep that seems to work fine, I am not a great JS guy so my conversion will probably be less elegant than others could achieve, I’ll probably shove my attempts on Github as it seems nobody else has a decoder for the TTN decoder yet.
The time is the first 4 bytes of each measurement and then the minutes is the last 3 bits of the 3rd byte and the first 3 bits of the 4th byte. I am successfully decoding the day/month/hours etc… it’s just the minutes that I can’t decode, the minutes in the output gist are incorrect. I tried doing what I did for the month as that also straddles two bytes, but I couldn’t get it working .
Any help to get this up and running would be greatly appreciated. It’s probably something simple/dumb that I am missing.
Just to be sure: did you see the remarks I left 5 days ago? You may not need support for negative temperatures, but I’m quite sure the bug with the date handling will bite you in 2021, if you rely on that.
(Aside: in case you did not know, you can edit gists; no need to create a new one for fixes.)
Thank you very much for your contribution, I have now updated the decoder to include the correct year handling and also negative temperatures. Here is the latest for anyone who is also trying to decode this sensor.
This is a very unfortunate design - it’s quite pointlessly burning a lot of airtime sending information that might as well just be taken from the receive metadata. On TTN that means you’ll probably need to reduce the transmission rate (at least when operating at slower spreading factors) to comply with the usage policy; in some jurisdictions this packet wouldn’t even be legal unless running at SF9 or faster.
As such this is a reminder why off the shelf nodes with fixed firmware are probably not a good idea; rather you want off-the-shelf hardware where you can (either with or without support of the manufacturer) make the firmware behave in a way optimal for actual use.
Yes, I can agree with this, you could just offset these date / times from the receive time meta data, normally with my own nodes I use the bare minimum data for the payload. I did a tear down of these and found under the hood its a BME280 sensor so this could be replicated fairly cheaply (<£30, TTGO ESP32 + BME280 and a lithium battery, probably get a decent duration out of it at SF7 and deep sleep) which makes me wonder how on earth MCF88 got to a £240 price point, I guess they use a really expensive test house or their volumes are not high enough to achieve cheaper pricing. In this case I had to use off the shelf nodes due to compliance reasons. But yes 12 bytes could be saved per transmission which is quite some air time at higher spread factors, for completeness they could make this optional in the firmware I guess…