Giter VIP home page Giter VIP logo

Comments (4)

256dpi avatar 256dpi commented on May 25, 2024

It does. The mutex locks and unlocks, and selects on the socket will yield to other tasks until data is available or the mutexes are accessible. I never ran into issues with the watchdog until now.

Is it possible that your connection is very unstable? The errors -13 (pong timeout) and -4 (network timeout) suggest that the client waited a long time for data that didn't arrive in time.

from esp-mqtt.

btsimonh avatar btsimonh commented on May 25, 2024

it's strange; subscribing takes seconds most times. But the server (mosquitto) logs indicate immediate response. The esp was about 3m from the switch.
Subsequent to the above, I do have disconnects. I think it's an interaction between different threads (tasks) in esp. As soon as I enabled many subscriptions again (5), it started failing. I'd disabled a lot of the functionality to diagnose.... the app can have MANY subscriptions (40+).
I put some external protection around MQTT activity as well as your mutexes, and it still showed issues.

have to say, this is my first esp32 try, so learning all the time.
App is https://github.com/btsimonh/esp32-ble2mqtt/tree/btsimonh-platformio2
it involves BLE, so I'm on esp-edf 3.1.1 (in theory), and the BLE/wifi interaction could be an issue. Seems we're on bleeding edge with esp32 and BLE.

ref your reply;
when subscribing, it calls ***_until with available=0
Are you SURE that this will not tight loop until a packet comes in?

from esp-mqtt.

256dpi avatar 256dpi commented on May 25, 2024

I suspect these issues are caused by another component in your project.

The call to lwmqtt_cycle_until caused by a subscribe will block as the underyling read operation will block.

from esp-mqtt.

256dpi avatar 256dpi commented on May 25, 2024

I will close this for now, please reopen if there is still an issue.

from esp-mqtt.

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.