Closed Maharajacentrado closed 1 year ago
char msgmqtt[50]; void callback(char * topic, byte * payload, unsigned int length) { String MQTT_DATA= ""; for (int i = 1; i <= length; i += 1) { MQTT_DATA += (char)payload[i]; } } void setup() { snprintf (msgmqtt, 50, "%d", ""); client.publish( , msgmqtt); } void loop() { }
pl add the above code. need to add the void callback lines. others are same