.Net Micro Framework on ESP32 chip
-
- Posts: 2
- Joined: Sun Oct 30, 2016 9:52 pm
.Net Micro Framework on ESP32 chip
Hi,
I would like to ask if Espressif/ESP32 team plans to support .Net Micro Framework on ESP32 chip in the future?
Thanks in advance!
Best regards,
Aron Kolozs
I would like to ask if Espressif/ESP32 team plans to support .Net Micro Framework on ESP32 chip in the future?
Thanks in advance!
Best regards,
Aron Kolozs
-
- Posts: 9766
- Joined: Thu Nov 26, 2015 4:08 am
Re: .Net Micro Framework on ESP32 chip
We have no plans to do any porting of the .Net Micro Framework ourselves. Someone else is entirely free to do so, however.
-
- Posts: 2
- Joined: Sun Oct 30, 2016 9:52 pm
Re: .Net Micro Framework on ESP32 chip
OK, thank you for your quick answer!
Re: .Net Micro Framework on ESP32 chip
I would like to do it. Does anybody want to help me?
Re: .Net Micro Framework on ESP32 chip
Maybe post some links and thoughts and what .Net micro framework is. I for one don't know and if there was a link, I'd click it. Also, what skills do you need assistance with? What do you foresee as the major tasks?
Free book on ESP32 available here: https://leanpub.com/kolban-ESP32
Re: .Net Micro Framework on ESP32 chip
.NET MicroFramework is an Open Source .NET Runtime for SOC's. It was created by Microsoft.
The .NET code is interpreted by the runtime, but allows for remote debugging from Visual Studio so the development experience is pretty good.
I believe the requirement is 512KB Flash, if that must be on the chip or can be in an external chip I don't know - but this might be the biggest challenge.
Wikipedia:
https://en.wikipedia.org/wiki/.NET_Micro_Framework
Home page
https://www.netmf.com/
Source Code
http://netmf.github.io/
Beginners guid to porting .NET MF (old but a lot of info, not 100% up to date)
http://www.ghielectronics.com/downloads ... 0NETMF.pdf
HW that supports .NET MF
ghielectronics.com and netduino.com
Another approach could be porting the Illum project to support the ESP chips
(Compiling .NET ByteCode to runnable images for ArmV4 and V5 using LLVM)
https://github.com/NETMF/llilum
The .NET code is interpreted by the runtime, but allows for remote debugging from Visual Studio so the development experience is pretty good.
I believe the requirement is 512KB Flash, if that must be on the chip or can be in an external chip I don't know - but this might be the biggest challenge.
Wikipedia:
https://en.wikipedia.org/wiki/.NET_Micro_Framework
Home page
https://www.netmf.com/
Source Code
http://netmf.github.io/
Beginners guid to porting .NET MF (old but a lot of info, not 100% up to date)
http://www.ghielectronics.com/downloads ... 0NETMF.pdf
HW that supports .NET MF
ghielectronics.com and netduino.com
Another approach could be porting the Illum project to support the ESP chips
(Compiling .NET ByteCode to runnable images for ArmV4 and V5 using LLVM)
https://github.com/NETMF/llilum
Re: .Net Micro Framework on ESP32 chip
Hey,
I would love to see something like this! Would be amazing when someone of you guys do this!
I would love to see something like this! Would be amazing when someone of you guys do this!
Re: .Net Micro Framework on ESP32 chip
I think there are three ways that can be followed:
1. The .NET MicroFramework.
For this approach the .NET code will be compiled into an optimized IL (intermediate language). On the ESP32 there must be an IL interpreter that interprets the IL code at runtime. That's not a JIT (Just-In-Time) compiler. So every single instruction must be interpreted again and again. I've worked with a Netduino plus 2 and I found that code execution was not so fast.
The hurdle for this approach would be porting the .NET MicroFramework interpreter to the ESP32. Currently only the ARM architecture is supported in the code. I think porting this code to another processor architecture would be very difficult.
2. The LLILUM AOT (Ahead-Of-Time) compiling approach
With LLILUM you compile a .NET IL code into a LLVM IL representation and then into machine code for a given target processor. LLVM is a new sort of compiler that can compile several input languages into LLVM IL representation and then into machine code.
But the problem here is that the ESP32 is not supported by LLVM. For getting the ESP32 supported a LLVM backend must be written. I've looked into the description http://llvm.org/docs/WritingAnLLVMBackend.html how to write such a backend and found that this would also too complicated.
3. Transforming the .NET code into C/C++ and compile it with GCC - an AOT approach
The one and only tool that can create ESP32 machine code is the xtensa GCC compiler. So maybe a tool that transforms the .NET IL code or the input C# code into C/C++ code is needed. This C/C++ code should then be compiled with the xtensa GCC compiler.
1. The .NET MicroFramework.
For this approach the .NET code will be compiled into an optimized IL (intermediate language). On the ESP32 there must be an IL interpreter that interprets the IL code at runtime. That's not a JIT (Just-In-Time) compiler. So every single instruction must be interpreted again and again. I've worked with a Netduino plus 2 and I found that code execution was not so fast.
The hurdle for this approach would be porting the .NET MicroFramework interpreter to the ESP32. Currently only the ARM architecture is supported in the code. I think porting this code to another processor architecture would be very difficult.
2. The LLILUM AOT (Ahead-Of-Time) compiling approach
With LLILUM you compile a .NET IL code into a LLVM IL representation and then into machine code for a given target processor. LLVM is a new sort of compiler that can compile several input languages into LLVM IL representation and then into machine code.
But the problem here is that the ESP32 is not supported by LLVM. For getting the ESP32 supported a LLVM backend must be written. I've looked into the description http://llvm.org/docs/WritingAnLLVMBackend.html how to write such a backend and found that this would also too complicated.
3. Transforming the .NET code into C/C++ and compile it with GCC - an AOT approach
The one and only tool that can create ESP32 machine code is the xtensa GCC compiler. So maybe a tool that transforms the .NET IL code or the input C# code into C/C++ code is needed. This C/C++ code should then be compiled with the xtensa GCC compiler.
-
- Posts: 263
- Joined: Sun Jun 19, 2016 12:00 am
Re: .Net Micro Framework on ESP32 chip
Someone at Espressif is writing an LLVM backend for the Xtensa right now. I'd wait for that.
Re: .Net Micro Framework on ESP32 chip
Did anyone get .Net Micro Framework running on the ESP32?
Who is online
Users browsing this forum: Bing [Bot] and 143 guests