GithubHelp home page GithubHelp logo

Comments (4)

Patrik-Berglund avatar Patrik-Berglund commented on August 31, 2024 1

@jitin17

The IoT Hub SDK will it self handle the re-connection. I have made a small update to the "esp-azure" to make it work.

I will prepare a pull-request with the changes needed.

from esp-azure.

jitin17 avatar jitin17 commented on August 31, 2024

@Patrik-Berglund In case of AP connection loss, there is a need to re-connect to Azure IoT Hub.
And when there is an AP connection loss, we observe errno to be EHOSTUNREACH. So, we have added enhancement in iothub_client_sample_mqtt example to re-connect to Azure IoT Portal upon observing errno as EHOSTUNREACH. And we wait for WiFi STA state to be connected before connecting to Azure IoT Portal. Please refer to changes in iothub_client_sample_mqtt example to add corresponding changes in your example. Let us know whether this works or not.

from esp-azure.

jitin17 avatar jitin17 commented on August 31, 2024

@Patrik-Berglund We have seen that azure-iot-sdk-c handles internet re-connection and connection to WiFi AP loss with the help of retry control handle. But there is a bug in azure-iot-sdk-c which causes crash; we have found the solution to it and will raise a PR soon. Thanks.

from esp-azure.

Patrik-Berglund avatar Patrik-Berglund commented on August 31, 2024

Great!

We switched to using the mbedtls and berkeley sockets based PAL provided by the IoT Hub C SDK instead. Required only minimal changes to their code.

from esp-azure.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.