Has anyone successfully ran an impulse on the PortentaH7 inner M4 core? OpenMV only uses the outer core and presently does not allow acces to the inner core using microPython.
I have tried both a C++ PDM microphone and a C++ Camera Impulse that work on the M7 outer core without success on the M4 inner core, each having different errors. I know the inner core has Serial printing issues which Arduino is trying to make work using RPC, but I have ran Machine Learning programs on the inner M4 core with some success here, just not one made by Edge Impulse. Wondering if anyone knows of why the inner core would be causing issues.
I did some crash tests a while back and the inner M4 core has huge potential for running larger models, the processor however is slower than the M7 core…
I don’t, but note that the Portenta shares its flash between the two cores, and right now I think the M4 has more flash allocated (1M) than the M7 (768K), but there’s talk that that’ll be changed (which I’d like :-)).
I heard from OpenMV that Arduino might allow either core to use the flash memory, but until then I would really like to be able to put an impulse on either core as they both have their strengths.
I have made a repo folder here for my research on this. Has example sketches that don’t use Serial.print just LED output that work on the M7 core.
The errors look like Arduino issues. Which I have told them about here for the camera.
Arduino Camera Issue
error: 'SCB_InvalidateDCache_by_Addr' was not declared in this scope
Arduino microphone issue
'SCB_InvalidateDCache_by_Addr' was not declared in this scope
SCB_InvalidateDCache_by_Addr((uint32_t *)&recordPDMBuf[start], AUDIO_IN_PDM_BUFFER_SIZE * 2);
C:\Users\me.windows\AppData\Local\Arduino15\packages\arduino\hardware\mbed\1.3.1\libraries\PDM\src\stm32\PDM.cpp:142:5: error: 'SCB_CleanDCache_by_Addr' was not declared in this scope
SCB_CleanDCache_by_Addr((uint32_t*)_doubleBuffer.data(), AUDIO_IN_PDM_BUFFER_SIZE * 2);
Has anyone ran an EdgeImpulse model on the M4 Core of the Arduino PortentaH7?
Fairly sure I can run a TensorflowLite model on M4 I just have to adjust for Serial.Println(); not activated on M4 (You can use RPC or other creative ways to communicate between the cores) and analogWrite(LED_BUILTIN, x); also not running as the Analog pins don’t run PWM on it.
Just wondering if anyone has got any EdgeImpulse models running on M4, if so I will dig deeper. My problem is that I want the Portenta to also do a bit of WiFi connectivity while my ML model is running and WiFi might be something that only works on M7.
Surprisingly everything compiles and runs on M7, just having minor issues with WiFi being blocking. I will try putting the WiFi into it’s own thread.