Hi,
Assume you are using example mqtt_simple.
You shall set the server name to config variable CONFIG_MQTT_BROKER_HOSTNAME in prj.conf. And make sure CONFIG_MQTT_BROKER_HOSTNAME is not commented in this file.
Or you can set it to MQTT_BROKER_HOSTNAME in Kconfig.
Thanks your answer
i dont see MQTT_BROKER_HOSTNAME in confg.just see config using ipv6,port,topic to access mqtt bro...
Hi,
Can you provide more information about the example?
Where is it and which one?
Are you running one example from the nRF Connect SDK?
Thanks!
Thank your support.I use example in IoT mqtt to do this and try to find host_name but i dont see in library.Now i try to connect nrf52 dev board with W5100 first.After i will find the way to send data into MQTT.I will show it for you late.
Thank you so much!
Sure, no problem!
Hi,
You can set m_broker_addr to your mqtt server IP address. Please note that this is an IPv6 address format.
In function app_mqtt_connect(), you can see how mqtt is setup for client.
Hi,
You can set m_broker_addr to your mqtt server IP address. Please note that this is an IPv6 address format.
In function app_mqtt_connect(), you can see how mqtt is setup for client.
this mean i need config ipv6 and replace ipv6_addr_t???
Thankss
Yes.
Hi sir,
Just only the way connect MQTT use ipv6???
Thanks
Yes, the Nordic Bluetooth IoT library only supports IPv6.
if your gateway does not support IPv6, you can install an IPv6 and IPv4 tunneling service to transit.
There are some posts you can get more information, for example:
https://devzone.nordicsemi.com/f/nordic-q-a/15055/mqtt-example---about-broker-s-ip/57454#57454
https://devzone.nordicsemi.com/support-private/support/39065
I use W5100 gateway.I will try to research base your link.If have any trouble i hope recieve your support.
Thanks