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

ISR() macros of LUFA and ASF interfering #124

Open
laid opened this issue Feb 15, 2018 · 1 comment
Open

ISR() macros of LUFA and ASF interfering #124

laid opened this issue Feb 15, 2018 · 1 comment
Labels

Comments

@laid
Copy link

laid commented Feb 15, 2018

There is a problem with ASF and LUFA fighting for what the ISR() has to be. Both actually end up defining the same thing at the end, but ASF does it using ISR macro with 3 parameters (out of which 2 are not used ...).

@laid
Copy link
Author

laid commented Feb 15, 2018

My current workaround is to modify the asf.h file each time it is generated and insert

#undef ISR

right before LUFA include files are loaded.
Like:

...
// From module: Interrupt management - UC3 implementation
#include <interrupt.h>

#undef ISR

// From module: LUFA Common Infrastructure
#include <LUFA/Common/Common.h>
#include <LUFA/Version.h>
...
...

This allows LUFA and ASF co-exist. (I am using only ISR() macro from LUFA, so I have not tested if any of the interrupt-driven ASF component fails on that or not)

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

No branches or pull requests

2 participants