Have you ever faced the situation of needing to add support for a specific hardware? Or to perform some computing intensive task that would be more efficiently executed in C/C++ rather than with managed C# code?
This is possible with the support that .NET nanoFramework has to plug “code extensions”. It’s called Interop.
What exactly does this? Allows you to add C/C++ code (any code, really!) along with the correspondent C# API.
The C/C++ code of the Interop library is added to an nanoFramework image along with the rest of the nanoCLR.
As for the C# API: that one is compiled into a nice .NET nanoFramework library that you can reference in Visual Studio, just like you usually do.
The fact that this is treated as an extension of the core is intended and, in fact, very positive and convenient. A couple of reasons:
- Doesn’t require any changes in the main…
View original post 3,071 more words