MSV-MingW port and CMSIS defines are causing problems
Hi, I'm currently working with the MSV-MingW port on an X86 and Windows. The controller I want to use at the end of the simulation is a SAML21 Cortex M0 MCU. I'm currently using templates and fake files to simulate the peripherals. in the file 'portmacro.h' these files are included, which causes problems for me: #ifdef WIN32_LEAN_AND_MEAN #include <winsock2.h> #else #include <winsock.h> #endif #include <windows.h> #include <timeapi.h> #include <mmsystem.h> #include <winbase.h> it seems that these CMSIS defines are causing problems: __I, __O, __IO, __IM, __OM, __IOM, __I
with the appropriate undefs before the includes it works: #undef __O #undef __IO #undef __IM #undef __OM #undef __IOM The prerequisite is that there are no further CMSIS files and hardware files after that come.
I have now moved the includes to the file 'port.c' and there don't seem to be any problems.
Could you please take this into account in the next update? thx