-
-
Notifications
You must be signed in to change notification settings - Fork 129
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
toggle(); #77
Comments
+1 |
1 similar comment
+1 |
Any chance you could be more specific about which ones? Maybe even link to the specific lines of code in their repositories? |
It is a XOR on the register with a mask forma the pin, differenti core are forma different architecture and may have different and specific application. Notice this will also work for enable/disable pull up. This is the classic simple and quick modification for the core, and uneccessary hard for the newbie. |
+1 |
@PaulStoffregen the code in it is very simple:
|
+1 |
Please do not post useless comments with only "+1" in it, there is a specific function of github for doing so that adds "likes" to the comment without spamming the mailbox of 800+ people. Thanks. |
By the way, no need to use XOR. ATmega already provides toggle functionality by writing a 1 to the PINx registers (the ones normally used for reading), so I guess it'd be a good idea to use that. |
@cousteaulecommandant exactly. We want this feature 😄😄 |
In this lib there is also a very useful toggleMillis(Pin, time_ms); |
@5N44P Ah, right, I missed that -_-" |
Cool, it has been labeled! This means that it will be considered? It would be nice if someone from arudino could explain if and how this type of requests are handled. |
ST added Toggle function to the ST Official Arduino Core
|
Ping. |
I just noticed there's two issues about this. I'm closing this one in favor of #130, which has a bit more rationale and some code examples. |
many core have a toogle() function.
Also some third part arduino core have it.
a toogle() function is useful on many or all project,
please add it to the official arduino core.
The text was updated successfully, but these errors were encountered: