Cayenne particulate matter sensor

Hi, there are two issues I’d like to get help / explanation with:

We’re measuring particulate matter (fine dust) in two categories, PM10 and PM2.5. There is no standard Cayenne encoding for that, so I chose to encode it as an analog input (with id 100 and 25) respectively. We’re measuring this along with temperature and humidity. I can see the data on the TTN console (selected cayenne payload) and it looks fine.

My questions:

  1. I can define my own type of device, with 2 analog inputs, 1 temperature and 1 humidity (as described above), right? Or am I limited to one of the pre-defined devices?
  2. I can register only one application on mydevices for this data source (device EUI). I’m trying to help someone who is having trouble visualizing the PM-data (encoded as analog input), so I’d like to build my own view of this data source. But apparently it’s forbidden by mydevices to listen to the data on my own dashboard to experiment, because the EUI ‘conflicts’. Why is this? Is there a way around it?

you cannot define your own cayenne LPP data type. here are the list Cayenne LPP 2.0

You can only add one device to one account only. there is no way around this.

Thanks for your reply.

I’m not trying to invent my own Cayenne LPP type, just trying to use the existing analog input type as a carrier for transferring particulate matter (PM10) concentrations. Cayenne does not have a more specific type for this as far as I can tell.

I found out that somewhere in the chain from TTN to mydevices, an assumption is made that an analog input on channel 100 represents the RSSI (received signal strength indication), so it’s already in use and the PM data on channel 100 always appears as RSSI. I’ll have to see if I can change the channel for either the virtual RSSI value, or for my own data.

you can send the data to any channel other than already preselected in this format:-

1 Byte 1 Byte N Bytes 1 Byte 1 Byte M Bytes
Data1 Ch. Data1 Type Data1 Data2 Ch. Data2 Type Data2

We will avoid use of channel 100, as this is hardcoded to the TheThingsNetwork RSSI.

To avoid such ‘collisions’, we’ll probably use:

  • PM10: channel=1, type=2 (analog input, in ug/m3)
  • PM2.5: channel=2, type=2 (analog input, in ug/m3)
  • Temperature: channel=3, type=103 (temperature in 0.1 deg C)
  • Humidity: channel=4, type=104 (humidity in 0.5%)

And for particulate matter sensors that support it:

  • PM1.0: channel=0, type=2 (analog input, in ug/m3)

I’ll post back to report how this works out.


It works fine now, using the encoding as described above.
The only limitation is that an analog input can encode at maximum a value of 327.67. As a particulate matter concentration (ug/m3), this is attainable on days with extreme smog, on new year’s eve (with fireworks) or perhaps in close proximity of a fire. Still it is about 6 times higher than the daily recommended limit, so not really a practical problem.

We can preview the data in the TTN console, where the cayenne appears as decoded values.
The cayenne integration makes the data appear on the cayenne dashboard.

I have written a Java application that decodes the Cayenne data and forwards it to the Luftdaten / particulate matter project.

So everything seems to work out OK so far.

1 Like