Skip to content

Instantly share code, notes, and snippets.

@Ames Ames/mqtt_publish.lua
Last active Oct 24, 2016

Embed
What would you like to do?
Publishing to MQTT on NodeMCU
-- Publish a message to the MQTT Broker
client:publish(
"temp/0", -- topic name
tF, -- message payload
1, -- QOS level
1, -- retain
function(conn) -- on-send callback
print("sent.")
end
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.