This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Get values from light_switch_server on light_switch_client

I'm developing a sensor node using light_switch_serve as an endpoint to receive commands and send sensor's data to light_switch_client.

The examples works perfect, but I would like to send data from server to client. I try to use publish_state on server without success.

There are any example or how can I send data from server to client?

Parents
  • Hi Marcelo.

    depends of what type of data you are trying to publish. Are you making sure that the client is able to decode the data you sent?

    Is it some kind of error you see or the packet is not received at the client at all? Still hard to say what is wrong without looking at the code. 

    The most generic publish messages API are available in access.h and access_reliable.h.

     

Reply
  • Hi Marcelo.

    depends of what type of data you are trying to publish. Are you making sure that the client is able to decode the data you sent?

    Is it some kind of error you see or the packet is not received at the client at all? Still hard to say what is wrong without looking at the code. 

    The most generic publish messages API are available in access.h and access_reliable.h.

     

Children
No Data
Related