Giter VIP home page Giter VIP logo

Comments (7)

facchinm avatar facchinm commented on June 3, 2024

This line makes the interrupt wakeup capable https://github.com/arduino-libraries/ArduinoLowPower/blob/master/src/samd/ArduinoLowPower.cpp#L93 , but it's also called in the core itself (https://github.com/arduino/ArduinoCore-samd/blob/master/cores/arduino/WInterrupts.c#L80) so once EIC clock is not stopped during sleep every configured pin can wakeup the board.
@cmaglie @sandeepmistry should we remove the wakeup setting from the core and leave it in the library only?

from arduinolowpower.

sandeepmistry avatar sandeepmistry commented on June 3, 2024

@facchinm I think that line was added for people not using the low power lib: arduino/ArduinoCore-samd#90

I'm ok with removing it, if you think it's best.

from arduinolowpower.

trogper avatar trogper commented on June 3, 2024

What about breaking older projects/sketches, which "rely" on this bug and are not using LowPower.attachInterruptWakeup on all required pins?

from arduinolowpower.

sslupsky avatar sslupsky commented on June 3, 2024

@trogper Can we include a warning at compile time?

from arduinolowpower.

trogper avatar trogper commented on June 3, 2024

@sslupsky I personally have used this library only once, so I won't be affected by the change.
How would you differentiate correct usage from incorrect?
When would you show the warning? Always?
Do Arduino users/programmers read warnings if the program compiles and works? (in other words: is warning appropriate?)
Wouldn't warning bother people who use it correctly?

from arduinolowpower.

sslupsky avatar sslupsky commented on June 3, 2024

Good points. Maybe the object can be changed so that when the method is called you specify which external interrupt is attached. The "default" can be "all"?

from arduinolowpower.

mamama1 avatar mamama1 commented on June 3, 2024

whatever solution is chosen, proper documentation will fix all issues and questions, i think.
another option would be to add an additional (optional) boolean parameter to attachInterrupt like standbyWakeupCapability or something like that. that way it stays in the core and is obvious to anyone who is attaching an interrupt.

from arduinolowpower.

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.