-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Publish multiple sets of Data #14
Comments
I have managed to upload my code however an Error occurred on Serial Window. Here is my Code: // Button that will put device into Access Point mode to allow for re-entering WiFi and MQTT settings WiFiMQTTManager wmm(RESET_BUTTON, AP_PASSWORD); // AP_PASSWORD is defined in the secrets.h file void setup() { } void loop() { // optional - example of publishing to MQTT a sensor reading once a 1 minute } and here is the Serial monitor: |
Tried to upload the sample code "basic" and got the same error. any idea on why i got this error, |
Please Help me to convert multiple data into one and publish it to mqtt.
i have these data:
Temperature: [0-120]
Pump: [0-100]
Heater: [0-100]
Status: [0 or 1]
the format to send must be [Temperature,Pump,Heater,Status]
the "[" and "]" must be included in the message.
will i have to create a variable to collect all data into one like
message= "[" + Temperature + "," + Pump ... "]"
wmm.client->publish(topic, String(message).c_str(), true);
thanks
The text was updated successfully, but these errors were encountered: