Skip to content
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

Compatibility with samd based and other boards #50

Closed
mabstl1997 opened this issue Aug 8, 2020 · 1 comment
Closed

Compatibility with samd based and other boards #50

mabstl1997 opened this issue Aug 8, 2020 · 1 comment

Comments

@mabstl1997
Copy link

Hello,
Thanks, developers, for the library.
I had a code that was running perfectly on an Arduino Nano clone with hardware SPI.
When trying to transfer it to an Arduino MKRZero (atsamd21 based board) with arduino native SPI, the compiler yelled:
... NRFLite\src/NRFLite.h:77:60: error: '_BV' was not declared in this scope
I have added:
#ifndef _BV
#define _BV(bit) (1 << (bit))
#endif
at the top of NRFLite.h and it solved the problem. May be there is more elegant way to solve this.
The sketch compiles with a warning that the library may be incompatible, but when uploaded it works as expected.
Could you update the library?

dparson55 added a commit that referenced this issue Aug 9, 2020
@dparson55
Copy link
Owner

Thanks for the tip, I updated the library and version 2.4.3 has the change. Also, I went ahead and removed the pessimistic architecture setting on the library which caused the warning. Now the library will be optimistic and I think this will be safe since Arduino SPI has consistently been included by new architectures.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants