Several temperatures?

Hi! I have a small project going on where I would need to send several different temperature values to Cayenne. So far I’ve tried to just add another package to the buffer, with the same temperature datatype (LPP) but on the next channel, but Cayenne only seem to catch the first temperature data. So:

AppData.Buff[i++] = cchannel++;
AppData.Buff[i++] = LPP_DATATYPE_TEMPERATURE;
AppData.Buff[i++] = ( exampleTemp[0] >> 8 ) & 0xFF;
AppData.Buff[i++] = exampleTemp[0] & 0xFF;

I’m new to Cayenne, am I doing anything wrong? The other datatypes (humidity for example) is received normally.

can you share the entire code?

I guess I could. It’s the official code for a hardware with a LoRa-module on it. Do you want me to send the code segment where the buffer is being filled or the entire file?

entire file.

Main_file_code.txt (22.2 KB)

Here you go, the official code is a mess to work with. The part I’m working on right now is on lines 267-451, but primarily 319-341.

can you private message me your DevEUI and which network server are you using?

After playing around for a day with the order the data was sent, and trying to find if any numbers were lost when being packaged, the transfer worked all of a sudden.

I have no idea what did it, but thank you for the help!

2 Likes

glad to hear it is working now.