Viewing MQTT messages
Posted: Mon Nov 04, 2024 4:07 pm
Is there a way to view the MQTT messages sent by the node and received by the Rainmaker broker during development?
Code: Select all
pip install espressif-rainmaker-cli
Code: Select all
\usage: esp-rainmaker-cli [-h]
{configure,signup,login,logout,forgotpassword,getnodes,getnodeconfig,getnodestatus,setparams,getparams,removenode,provision,getmqtthost,claim,test,otaupgrade,getuserinfo,sharing,create_cmd_request,get_cmd_requests} ...
positional arguments:
{configure,signup,login,logout,forgotpassword,getnodes,getnodeconfig,getnodestatus,setparams,getparams,removenode,provision,getmqtthost,claim,test,otaupgrade,getuserinfo,sharing,create_cmd_request,get_cmd_requests}
Functions
configure Configure ESP RainMaker
signup Sign up for ESP RainMaker
login Login to ESP RainMaker
logout Logout current (logged-in) user
forgotpassword Reset the password
getnodes List all nodes associated with the user
getnodeconfig Get node configuration
getnodestatus Get online/offline status of the node
setparams Set node parameters
Note: Enter JSON data in single quotes
getparams Get node parameters
removenode Remove user node mapping
provision Provision the node to join Wi-Fi network
getmqtthost Get the MQTT Host URL to be used in the firmware
claim Claim the node connected to the given serial port
(Get cloud credentials)
test Test commands to check user node mapping
otaupgrade Upload OTA Firmware image and start OTA Upgrade
getuserinfo Get details of current (logged-in) user
sharing Node Sharing Operations
create_cmd_request Create a Command Response Request (Beta)
get_cmd_requests Get Command Response Requests (Beta)
options:
-h, --help show this help message and exit
Code: Select all
topic: $aws/rules/esp_set_params/node/F412FA68E350/params/local,
data: {"Battery":{"Voltage (V)":12}}
Code: Select all
topic: account/user/node/metric/device/battery/voltage => 2 bytes with MQTT5 topic aliasing
data: 12