Publishing Sensor Data with cloud api for python use

I am having trouble in terms of publishing thermal IR sensor data. I get a frame of 2051 unsigned bytes from my 32 x 32 thermal sensor. I am trying to publish this data in a char array but when I check the event data in the cloud API the data are just weird characters. Is the data I am trying to publish too large? Does my data need to be in a different format? Is publishing the data even the best way to expose the data to python wirelessly ( I am using an electron)?

Thanks.

The APIs do not support transfer of binary data as. You’d need to convert them into something like Base64 or Base85 and also adhere to the max. amount limits for the APIs in question (e.g. 622 bytes for Particle.publish())

If your data doesn’t require encryption you could use go for a “raw” TCP transfer rather than going via the Particle cloud.

2 Likes

Ahhh I see, thanks for the reply. I would need an external server for the TCP transfer I assume since I am using an electron?

@DarrenD, the Electron supports unencrypted TCP and UDP transfers directly, in line with what @ScruffR indicated.

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.