cancel
Showing results for 
Search instead for 
Did you mean: 

tx_initialize_low_level.S SYSTICK BASEPRI error

ScottyWinsome
Associate II

The erroneous configuration in the tx_initialize_low_level.S is this:

    LDR     r1, =0x40FF0000                         // SysT, PnSV, Rsrv, DbgM


The tx_initialize_low_level.S file is generated upon selecting ThreadX 'Core' in the STM32CubeMX v6.15.0, and the above line is thereafter never changed. Specifically, upon enabling 'Enable BASEPRI support' and selecting a very common value of 5 for the TX_BASEPRI_VALUE, the above line is not updated accordingly. Not syncing the SYSTICK IRQ priority with the TX_BASE_PRI_VALUE of course leads to a system failure.

This issue can be duplicated by creating a brand new project with STM32CubeMX v6.15.0 and it can be seen in the sample projects included in the Applications/ThreadX in the STM32Cube_FW_U5_V1.8.0




10 REPLIES 10
ScottyWinsome
Associate II

@Pavel A. thanks for confirming my observation - I did specify line 149 in my post above, so I was very confused by the response from @Mahmoud Ben Romdhane  Anyway, it was beside the point since I didn't realize that I could "fix" the code-generation problem of always overwriting my local fix by simply patching my local copy to the ST library code - for some reason I was assuming that the assembly file was being uniquely generated by CubeMX instead of just copy and pasted from the library.