Other Parts Discussed in Thread: UNIFLASH
Hello,
I have been working on customising the BSL for MSP430F5310 and initial steps have worked fine. I've added basic checks for presence of a valid application by checking for example for erased application, in which case I remain in BSL mode.
I wanted to augment this to add a CRC check and added a function call to a C function (for example the existing BSL430_crcCheck()).
However I'm facing a lot of issues and have questions:
1. Somehow with this function call I've ended up bricking 3 parts already, as the device goes into a JTAG locked mode. Uniflash also no longer detects the part. So I'd like to know how to unbrick the part by unlocking JTAG. I found this link https://e2e.ti.com/support/microcontrollers/msp-low-power-microcontrollers-group/msp430/f/msp-low-power-microcontroller-forum/212060/issue-regarding-unlocking-jtag-on-a-msp430f5510 however the links in it are very old and I am not able to access the scripts provided there as a solution.
2. I confirmed above parts where debug interface is locked, the BSL still works and I can interact with it.
3. Is it a problem to call a function from within the BSL? Because until I added a function call my customisations worked fine and did not lock the debug interface.
4. Do I need to uncomment this line which was commented in the BSL source code? But it was not needed till now.
;BIS #BSL_REQ_JTAG_OPEN, RET_low ;make sure JTAG remains open for debugging
5. Could it be a stack issue for calling the CRC function? I initialised SP to the top of stack at start of BSL but then even the basic BSL functionality of check for BSL start request via the two pins no longer worked i.e.
bit #SYSBSLIND,&SYSCTL
did not exit into BSL as it used to before.
Please help! Lot of doubts and I've already lost the debug interface to so many parts and I'm down to my last one.
Thanks!
Arun