diff --git a/CHANGELOG.md b/CHANGELOG.md index b71856b9..da0b8e45 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/). - Properly report compile errors in GitHub Actions (#296) - Put build artifacts in a separate directory to reduce clutter. - Change 266 files from CRLF to LF. +- Add `_BV()` macro. - Replace `#define yield() _NOP()` with `inline void yield() { _NOP(); }` so that other code can define a `yield()` function. - Update .gitattributes so we have consistent line endings - Run tests on push as well as on a pull request so developers can see impact diff --git a/cpp/arduino/Arduino.h b/cpp/arduino/Arduino.h index 7061023a..b301ec21 100644 --- a/cpp/arduino/Arduino.h +++ b/cpp/arduino/Arduino.h @@ -50,10 +50,7 @@ inline void noInterrupts() { _NOP(); } typedef unsigned int word; -#define bit(b) (1UL << (b)) - - - +#define _BV(bit) (1 << (bit)) // Get the bit location within the hardware port of the given virtual pin. // This comes from the pins_*.c file for the active board configuration.