Hello,
I am using USB Multilink Universal FX debugger with S32DS IDE, and GNU toolchain to program my MPC5777C MCU.
I am testing the module under different circumstances. I was wondering what would happen if an interrupt would happen during the self-test. I have put a for loop with 50 iterations, before I set the watchdog timer(STCU2->WDG), then I run the test procedure. I do this for two WDG values, 0x000FFFFF and 0x00000001.
During the test, I get a lot of IVOR errors because after the test is done (successful or not), in my main code, I try to write values into swt->SR=SWT_SR_WSC() register, but I cannot write to that bit field. If I remove the for loop, I can write since STCU sends a reset after the execution of tests, WD value is removed from the register and its free to write for 0x000FFFFF, but not for 0x00000001.
So my question is, do these modules, SWT and STCU, use the same WD timers?
Even if I don't write the SKC key 2 after each 30 instructions, can I still unlock WD of SW?
Also, after STCU reset, debugger does not recognize any of the break points I put, i.e., code runs on the break points I put after the reset. I can realize the code runs normally on Putty interface, but it never stops on the points that I put a break point on. The same problem also arises with external reset.
Thanks in advance.