Hi Sahand,
Thanks for your reply.
We managed to fix the issues which were:
- The JTAG debugger would randomly freeze and block the program
- The semaphore had to be acquired first (the task was the first one to acquire it so the program simply ended)
- Using the HAL somehow decreased the probability that the program got stuck at an IOWR_32DIRECT (which is weird since it only does an IO_WR...)
Cheers,
Alex