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.

CCS/MSP430G2213: How to use UART Bootloader

Part Number: MSP430G2213
Other Parts Discussed in Thread: MSPBSL,

Tool/software: Code Composer Studio

Hi !

I am trying to understand how the Bootloader works, and I have several questions.

  • the Bootloader is integrated in a protected memory (ROM or FLASH) in MSP, I can communicate with it using the UART protocol. it is correct ? 
  • is it me who must ensure the BSL Entry Sequence or I can do that automatically in the code ? and if I'm in the BLS mode, I can start sending the data to the BLS by following the Data-Stream Structure (HDR, CMD, L1, L2, .... ACK).
  • to change the contents of the flash memory of an MSP by the BSL, I must imperatively make the BSL Entry Sequence in this MSP? and if I want my MSP to change the flash content of another MSP (i.e I want to swap the data between two devices) ?

I hope you will answer me to discuss the solutions and ask another question.


Thank you.

  • Hello Zakaria,

    Your best resource for this is our MSPBSL page (http://www.ti.com/tool/mspbsl ). [ At the time of this posting the webpage seems to be down for improvements. We are working to restore the page.] The page explains the basics of the MSPBSL and provides guidance on what documentation you need to get started using the BSL .

    That being said, the main piece of documentation that you will need to look at is the MSP430 Flash Devices BSL User Guide. (http://www.ti.com/lit/slau319 )

  • Hello Jace ! 


    I just visit the page and I think it's interesting, thank you.
    I still have a question to ask you:
    to enablethe sequence bootloader, is there a hardware configuration to do?

  • Hello Zakaria,

    If I interpret your question correctly, I believe you asking for ways to invoke the BSL. As you can see in Table 1, the MSP430G2213 only has two ways to invoke the BSL. An toggling sequence on the TEST and /RST pins caused by an external device, or via a SW entry from the device itself.

    Particulars of how to invoke via Hardware entry are in the documentation linked above. For SW Entry see the same document as well as the following E2E post.
    e2e.ti.com/.../1448380
  • Hello Jace !

    I thank you very much for your quick and efficient answers.

    to explain, my project is to do an Over-Air-Update FW, for that I try to understand the BLS UART, how can I use my MSP to program other MSPs, so I would need to do An toggling sequence on the TEST and / RST pins caused by an external device (which is my MSP). correct?
    and when I'm in BSL mode, how can I burn the new firmware to another MSP ?
  • Zakaria,

    Let's take your scenario here. Say you are receiving new FW from over the air to a Wireless MCU or Wireless Chip hanging off of your Master MSP430. The Master MSP430, would then need to toffle the Test/RSt pins of one of your MSP430 Slaves in order for the MSP430 Slave to be placed into BSL mode. With the appropriate UART connection between the Master and Slave MSP430s, the Master MSP430 will then need use the BSL protocol in order to write new firmware into the Slave MSP430. Once that is done, just toggle the Reset line to reset the slave and the new Firmware will start working.

    Now the other situation I can see is if you want to update the firmware on your Master MSP430. If you are using a Wireless MCU for your over the air updates, then it can act like the Master MSP430 in the previous situation. If you just have a radio attached, then you have limited options. You could potentially move the firmware to a slave MSP430, place yourself in BSL mode via SW entry, then have the Slave MSP430 update the master. Other techniques would include adding an application side bootloader (MSPBOOT) to customize and external memory boot with an EEPROM.
  • Hello Jace
    I always thank you for your clear and helpful answers.
    now, if i start the BSL mode, i have to start sending commands following the following BSL protocol?

    Is the communication via two UART wires, ie a normal UART and no need for TX OFF, RX ON ?.

    thank you very much

  • Zakaria,

    Yes, those are the commands you need to implement. Descriptions for each command can be found in the User Guide pointed to earlier. For your second question, for the UART communication, you only need the UART TX and UART RX. Flow control is not support on BSL.
  • thank you sir
    thank you so much.....

**Attention** This is a public forum