GithubHelp home page GithubHelp logo

Comments (5)

rjsc avatar rjsc commented on August 15, 2024 1

There is a pending pull request to add a timeout to the write operation but the repo owner didn't respond for over a year.
You can try to merge it privately and test.
miwagner/ESP32-Arduino-CAN#45

from battery-emulator.

rjsc avatar rjsc commented on August 15, 2024

The miwagner arduino driver and Thomas Barthe's arduino ESP-32 CAN driver are significantly different than the current ESP-IDF CAN driver. They are NOT direct ports.

The miwagner and Thomas Barth Arduino ESP32 CAN drivers have some big issues with queues, and it doesnt have any protection/safety with large multi-threaded/tasked programs. If you are trying to send CAN messages from several different areas of your multi-tasked code, it usually gets choked sooner or later....

And the biggest issue of all is that it doesnt have the IRAM_ATTR directive, which would allow it to try to access random parts of flash/code at ANY time....this includes during an OTA update (which disables flash-cache). If you leave the miwagner/Thomas Barth Arduino ESP32 CAN driver running during an OTA update, it was guaranteed to crash the whole ESP32.

The official ESP-IDF CAN driver doesnt have any of these issues, and is completely safe to use with any program, and have running at all times, including during an OTA update.

https://esp32.com/viewtopic.php?t=12607

Seems that the Arduino can stack indeed has problems and we need to use the official one from the esp32 idf.

from battery-emulator.

dalathegreat avatar dalathegreat commented on August 15, 2024

Some good info here: sandeepmistry/arduino-CAN#118

from battery-emulator.

dalathegreat avatar dalathegreat commented on August 15, 2024

Another repo with same problem: timurrrr/arduino-CAN#2

from battery-emulator.

dalathegreat avatar dalathegreat commented on August 15, 2024

Pull request merged to main that prevents the crash 💪 ! Thanks @rjsc and Caboom! #48

from battery-emulator.

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.