CMSIS-Driver Validation  Version 1.3.0
Driver Validation
 All Data Structures Files Functions Variables Typedefs Macros Groups Pages
Resource Requirements

Heap Requirements

Heap is used by memory allocation functions. It is configured in the startup_device.s file located under the Device component class.

Additional memory is allocated for the validation framework and for the buffers that are used in the driver tests.

For the validation framework add 1024 bytes of heap. Then, double the amount of the largest buffer size specified in the DV_Config.h file and add this as well.

Option (under section Heap Configuration) Increase Value by
Heap Size (in Bytes) + (1024 + 2 x maximum buffer size)

Calculation Example

Let's assume that the default heap size in your device's startup file is 0x400 (which is 1024 bytes). Add 1024 for the framework and for example another 2048 bytes if you are using the default Buffer Size of 512 bytes but you have set the Buffer size for baudrate tests to 1024 bytes. This computes to a total heap of 3584 bytes which is equivalent to 0xE00. Set this number in the startup file.

CMSIS-RTOS2 Requirements

The thread requirements need to be reflected in the CMSIS-RTOS2 configuration. Refer to the CMSIS-RTOS2 Reference for further details.

For CMSIS-RTOS2 RTX5, thread requirements are configured in the RTX_Config.h file located under the CMSIS component class:

Option (under section Thread Configuration) Set Value to
Default Thread stack size [bytes] 2048

CMSIS-RTOS Requirements

Instead of CMSIS-RTOS2 you can use CMSIS-RTOS. In this case the main thread is implicitly created. For proper operation, you need to add a certain amount of thread stack size to the main thread.

The thread requirements need to be reflected in the CMSIS-RTOS configuration. Refer to the CMSIS-RTOS Reference for further details.

For CMSIS-RTOS RTX, thread requirements are configured in the RTX_Conf_CM.c file located under the CMSIS component class:

Option (under section Thread Configuration) Set Value to
Default Thread stack size [bytes] 2048
Main Thread stack size [bytes] 2048
Note
Do not forget to set the correct RTOS Kernel Timer input clock frequency [Hz] otherwise the tests will not run properly on the device.
Only WiFi tests create one additional thread for socket testing and usually WiFi drivers have a thread for processing messages.