The usage of serial registers give us the advantage that remaining IOs are free for other purposes.
Since most of bigger applications get use of all available pins, SRIO is the first choice and therefore the standard. (*)
Scanning the SRIOs doesn’t really take that much CPU time, as MIOS32 handles the (hardware) SPIs via DMA transfers in background. While the complete SRIO chain is scanned, the CPU is doing something else. Therefore the serial clock rate doesn’t matter (I selected a slow clock rate to make the transfers more robust).
Only the propagation of pin changes to the application takes CPU time, but a handler for parallel IOs would have to do exactly the same!
Note that it is possible to call MIOS32_SRIO_ScanStart() from the application to scan the SRIO more frequently. This will require to remove the
MIOS32_SRIO_ScanStart(SRIO_ServiceFinish); call in vApplicationTickHook - I could add a #ifndef based switch if you want, so that this code doesn’t need to be modified.
Instead you would enable this switch in your mios32_config.h file, and call MIOS32_SRIO_ScanStart from a timer function (-> MIOS32_TIMER) embedded into your app.c file at the desired frequency.
I don’t see the need to integrate an alternative method into MIOS32, but nobody prevents you (or somebody else) from writing a driver for parallel scanning and to put it into $MIOS32_PATH/modules so that other applications can access it.
In difference to MIOS8, MIOS32 is very modular (e.g. it’s possible to remove the software parts which scan the SRIO chains from the binary).
Or to disable the default scanning method and to do it on a different way (e.g. more frequently) as described above.
Everything which is special and not used by most of the applications should be located under $MIOS32_PATH/modules
This has the advantage that multiple solutions for the same “function(s)” can be provided and selected by the application.
You are writing that there isn’t a MIOS32 equivalent to STM32F10xgpio c
This isn’t completely true - because this driver provided by STM is already compiled into each application (the sources are here) so that you can already use these functions w/o Makefile modifications.
You are even able to re-use most of the example applications provided by STM for the first experiments if you remove the system initialization parts that are mostly located in the main.c file of these examples (because the system is initialized by [MIOS32_SYS_Init](http://www.midibox.org/mios32/manual/group m_i_o_s32 s_y_s.html))
Best Regards, Thorsten.
(*) another reason for using SRIO is, that they are working at 5V level instead of 3.3V, and that 74HC595 can drive multiple LEDs w/o loading the microcontroller.
This isn’t relevant for your plans, but I think that I should highlight this to make clear why SRIO is better for most applications.