This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSPM0C1104: SWCLK as digital Input not working

Part Number: MSPM0C1104
Other Parts Discussed in Thread: UNIFLASH, SYSCONFIG,

Dear Ti team,

I am using MSPM0C1104 for 1 of my application and need to use PA20/SWCLK as digital input but making so I need to remove the debug option from the sysconfig. Once I configure is as input and flash the devices with uniflash I am unable to program the device again. Please let me know if any one faced the same issue or how to reprogram the same chip.

Regards,

Aman

  • Hi Aman,

    This is unfortunate and I am sorry to hear you got stuck in this situation.

    Typically you would to do this after all your code has been developed, else you find yourself in the predicament.  But I completely understand needing to debug your code that uses that pin before committing to disabling the SWCLK.

    So the issue is once your device has been programmed and your code executes the instructions to switch the SWCLK pin, the only possible way for a debug/programmer to regain control is through a POR (power on reset).

    Now a POR can be done two ways;  cycle power on the device or hold the NRST line low > 1 second. Cycling the power on the MSP is not practical so the only other method is to allow the debug programmer to control the NRST pin, which it can hold low for one second, then regain control of the SWCLK pin.

    However, there is an errata on this device related to the NRST pin.  Essentially, the 1 second NRST functionality does not work in this current (PG1.1) version of silicon, so even if you had access to the NRST pin, it won't help.  This will be fixed in PG1.2 (April 24).

    So to answer your question, yes, this device is no longer re-programmable, but there are a couple of ways around this issue until the new version of silicon comes out.

    Here is what you can do in your code until you have new version.  Add a delay after your code starts up that prevents the instructions that switch the SWCLK to GPIO from executing to give the debug/programmer enough time to can take control of the MSP. In otherwords, give the debug/programmer a long delay (5 to 10sec you may have to experiment), then execute the switch over.  Better yet, if you have a switch (button), like on the MSPM0C Launchpad, add some code to wait until the button is pressed.  That way your code can startup and give the debug/programmer as much time as it needs to take control.  This is the preferred method.