Use _BV32 to avoid name conflict
This commit is contained in:
parent
6339b506c0
commit
f5cfdf6efe
5 changed files with 15 additions and 10 deletions
|
|
@ -95,13 +95,18 @@
|
|||
#define STRINGIFY(M) STRINGIFY_(M)
|
||||
|
||||
// Macros for bit masks
|
||||
#undef _BV // Marlin needs 32-bit unsigned!
|
||||
#define _BV(b) (1UL << (b))
|
||||
#define TEST(n,b) (((n)&_BV(b))!=0)
|
||||
#undef _BV
|
||||
#define _BV(b) (1<<(b))
|
||||
#define TEST(n,b) !!((n)&_BV(b))
|
||||
#define SBI(n,b) (n |= _BV(b))
|
||||
#define CBI(n,b) (n &= ~_BV(b))
|
||||
#define SET_BIT(n,b,value) (n) ^= ((-value)^(n)) & (_BV(b))
|
||||
|
||||
#define _BV32(b) (1UL << (b))
|
||||
#define TEST32(n,b) !!((n)&_BV32(b))
|
||||
#define SBI32(n,b) (n |= _BV32(b))
|
||||
#define CBI32(n,b) (n &= ~_BV32(b))
|
||||
|
||||
// Macros for maths shortcuts
|
||||
#ifndef M_PI
|
||||
#define M_PI 3.14159265358979323846
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue