-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to switch to another network card when the current network card can not connect to the broker with paho mqtt library #1469
Comments
The 1.4 branch has an update to allow this. You can take a look at the paho_c_sub and paho_c_pub samples to see how this works. |
The 1.4 branch has an update to allow this. You can take a look at the paho_c_sub and paho_c_pub samples to see how this works. If you invoke paho_c_pub (on the 1.4 branch) like this:
it will display a list of interfaces and addresses:
You can use the interface name or an address to select the interface to use. |
thank you very much. I'll try it later and give you feedback |
Which interface is called to set the ip of the specified network card ? |
Look in the paho_c_pub/paho_c_sub sample programs on the 1.4 branch for usage: https://github.com/eclipse/paho.mqtt.c/blob/1.4/src/samples/paho_c_pub.c https://github.com/eclipse/paho.mqtt.c/blob/1.4/src/samples/paho_c_sub.c |
Discussed in #1468
Originally posted by okyihu April 13, 2024
there are 4 network ports on my circuit board (running the embedded linux system), how to switch to another network card when the current network cann't connect to the broker with paho mqtt API ? thanks for helping.
The text was updated successfully, but these errors were encountered: