cancel
Showing results for 
Search instead for 
Did you mean: 

Bug Found in LoRaWAN_AT_Salve_DualCore sequencer utility

ECarr.1
Associate

Hey community, it took me some time to track this bug down because I thought I wasn't implementing the sequencer library correctly and was looking at my own code.

Turns out, there is a bug with stm32_seq.c. Every time I ran a task with UTIL_SEQ_SetTask() with a priority over 2, the STM would get a hard fault.

Turns out that setting SEQ_CONF_TASK_NBR and SEQ_CONF_PRIO_NBR, DOES NOTHING because stm32_seq.c is actually using UTIL_SEQ_CONF_TASK_NBR and UTIL_SEQ_CONF_PRIO_NBR. There is a discrepancy between the defines of the two files. This is just am FYI for anyone using the sequencer utility library.

Replacing SEQ_CONF_TASK_NBR with UTIL_SEQ_CONF_TASK_NBR and SEQ_CONF_PRIO_NBR with UTIL_SEQ_CONF_PRIO_NBR in utilities_conf.h will solve this problem.

1 REPLY 1
YBOUV.1
Senior

Hello @ECarr.1​ ,

You are right, there is an issue here. THanks for pointing this issue at us.

We could fix it as:

1- include utilities_def.h in utilities conf.h

2- define UTIL_SEQ_CONF_TASK_NBR as CFG_SEQ_Task_NBR

3- define SEQ_CONF_PRIO_NBR as CFG_SEQ_Prio_NBR

then in utilities_def.h, you can add more tasks and prio within the enum. Hence, the UTIL_SEQ_CONF_TASK_NBR and SEQ_CONF_PRIO_NBR would be automatically incremented.

Let me know if this would work for you

Sorry for the inconvenience,

best regards