Other Parts Discussed in Thread: MSP430FR5969, MSP-FET
MSP430FR5969 Software/Firmware Initialization of BSL
Hello there,
I am working with the MSP430FR5969 and trying to invoke the BSL using the firmware function found in the datasheet. I am also using the MSP-FET to act as the go between the BSL-Scripter and MSP430FR5969. I am using the UART A0 Port for BSL programming.
My issue is that I cannot get the firmware invocation to work reliably. The hardware invocation is bulletproof and can get that to work every time, however it is not the method I can use to program the device in the field and therefore need to use firmware method to do this. The firmware invocation seems to work one out of every ten times, if that. It’s extremely unreliable and impossible to duplicate back to back. I’ve tried multiple things, and as of right now the most reliable method is setting the MCLK to 1 MHz and still I have issues.
Below is my code. I’ve been so frustrated with this that I just have the device jump right to the bootloader after I set my clocks.
Here is my scripter text file
Order of operations.
- Program the MSP430FR5969 using the MSP-FET using Two-Wire Programming
- Disable/disconnect from the debugger
- Pop over to the scripter and run my script.
- Mass confusion ensues.
The error messages I see via BSL-Scripter are:
- Unknown ACK – which I understand to be a bad acknowledgement and that the BSL is not being invoked. This is for both the wrong and correct password RX transmissions
- BSL Password is correct! – I get this sometimes when I pass the wrong password through. Usually after multiple attempts of using the scripter. Which is odd because the password is intentionally wrong.
- BSL is locked – This error makes sense for when the wrong password is passed through but the chip doesn’t go jump to BSL. I see this with the correct password and when I attempt to upload my hex file via the BSL-Scripter. I did notice something however, its that when I send the wrong password and I get the BSL is locked error more often than not it seems to work. Odd and inconsistent, may mean nothing at all.
- Invalid header – not sure what this is, need to dig around more. Is usually paired with an Unknown Command error.
When it does decide to behave this is the log from the Scripter
My question is:
What am I missing? Do I need to set up my CLK’s differently? Do I need to do something with the UART port as well? Why is it so inconsistent? Do I need to clear my configuration registers?
The documentation is of little to no help either, all the documents say is use and then reference another document which references another document and its all just one big run around.
If anyone has any suggestions please let me know. Thank you for taking the time to read and help! I really do appreciate it