How to send downlink payload over mqtt?

hello, I’m newer to chirpstack,
For the chirpstack, I’m running it in docker-ce on a pc using ubuntu 18.04,
The settings used are just the docker-compose default settings.
I can get data sent from lorawan nodes correctly at the terminal of ubuntu by mqtt like “mosquitto_sub -t “application/2/device/+/event/up” -v”,

but the node can’t get the downlink payload like “hello” ,my code is like this:mosquitto_pub -t “application/2/device/383833356d396a10/command/down” -m “aGVsbG8=”

If someone has try it please teach me.
Thanks everybody :wink:

The string “hello” does not conform to the downlink format. See:

hi, Thank you very much.
do you mean it like this:
mosquitto_pub -t “application/2/device/383833356d396a10/command/down” -m “{“confirmed”: true,“fPort”: 10,“data”: “aGVsbG8=”}”

Yes, assuming your marshaler is set to JSON and not the default protobuf.

A question about this approach.
Is it just a matter of time to respond to this topic once I get an uplink and use same window cycle to process the uplink and send a command to the device ?

I mean, may I build a downlink command based on the uplink and respond it on same window through MQTT ?
Never did it with CS, always used the API.

Yes, if publish the message fast enough it will work. Else it will be added to the queue and sent on the next downlink opportunity.

1 Like

That’s really cool !


have you fix the problem?