br-automation-com / paho.mqtt.c-ar

MQTT Client for Automation Runtime based on eclipse/paho.mqtt.c
18 stars 6 forks source link

JSON array conversion #27

Open ROQOnline opened 1 year ago

ROQOnline commented 1 year ago

Hello,

I'm using the library IotMqtt and I'm sending and receiving a data structure with arrays using the data format IOTMQTT_VAR_JSON, but what I'm receiving in my broker is a variable per array position instead of an array in JSON.

Is there a way to change this?

This is what I’m receiving.

image

This is what I want to receive.

image

This is the function block to send the data.

image

priesf commented 1 year ago

Hello, sorry for my late reply. Currently we can not change this since we are relying on the PVJson library which has the same behavior. There is already an issue open for this, but not yet planned. https://github.com/br-automation-com/PvJson/issues/10

We will keep the issue open as part of the backlog. I'm sorry for your inconvenience. BR Fabian

ROQOnline commented 1 year ago

Hi Fabian,

Thanks for the reply.