I’m new with .NET MF and G120 module.
I’m planning a commercial application that will need a powerfull processing due to some reasons that I’ll explain.
Till now I have done projects using MCUs like PIC and PIC32 for main processing.
Now I have a project that will demand a very robust processing due to the amount of things that are going to be connected by serial ports and other interfaces.
I’ll need a MCU/SoM to do the following:
- Capture and decode data from a GPS receiver at 57600 bauds with GPS fix at an interval of 10Hz.
- Capture and decode data from a Distance sensor at 9600 bauds with variable interval up to 10Hz.
- Capture and decode data from an Inertial sensor at 19200 bauds with a fixed interval of 20 Hz.
- Capture and measure a Pulse Width / frequency constantly from a digital port input.
- Encode all data from the sensors inside a protocol to be sent by a serial interface.
- Capture and decode commands from an HMI that will be used to “command” a motor and that will display value of all these sensors.
- Forward all data from these sensors through a single serial interface at 57600 bauds to the HMI.
- Perform calculations in real time to control a PID actuator. That will demand one more interruption from a timer (interval of about 100ms) and some Floating point calculations
- Control a DC motor (The actuator) using PWM for speed control.
- Recalculate parameters in real time according to the commands received from HMI and send the new parameters to the sensors.
Well all these things can be done by dedicated peripherals on MCUs like PIC32 for example or the MCU used in G120 module.
Any ARM Cortex-M3 based MCU also should have these things but I’m more familiar with PIC32 (MIPS).
I’m going to programm in high level language so assembly is not a factor to insert in this comparsion.
It is very clear that the real challenge is to deal with interrupts and manage correctly to receive all these inputs without losing data due to buffer overflows.
Also it is important to mention that this is for a “Real Time” system, so the user will be looking what is happening and should have no considerable delays on the communication.
Now the question about the performance
The G120 uses an ARM CPU running at 120Mhz with 1.25 DMIPS/MHz which means a performance of 150 DMIPS
The PIC32 uses a MIPS32 M4K CPU running at 80MHz with 1.56 DMIPS/MHz which means a performance of about 125 DMIPS
The G120 module seems to have a few better performance, in the other hand it is running .NET MF that should cost considerable CPU performance in some cases.
The PIC32 will be running native code without RTOS or any management.
Using the peripherals in G120 may need access to the registers and that will ruin the purpose of .NET MF to simplify development. Or not…
In the other hand, manipulate strings and perform floating point operations is much more confortable having the .NET MF lib.
Having in mind all the tasks that I’m going to demand from the MCU/SOM, which solution would you choose for this project ?
The G120 ? The PIC32 ?
Should I consider to split the tasks in more than one CPU ? (Using G120 + PIC32)
I’ll be glad to hear your opinions and the details of it.