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.

MSP430F67751A: What is the default hex values BSL(BOOTLOADER) Memory Area ?

Part Number: MSP430F67751A
Other Parts Discussed in Thread: UNIFLASH, MSP430F5529

Hi all, 

1 - What is the default hex values BSL(BOOTLOADER) Memory Area? 

2 - İf I just erase the code in the bsl memory area and not write anything. All values in BSL memory will be 0xFF, am I right?

  • In BSL flash segments by default is stored factory BSL. If device have USB hardware module than it is HID, if not than it is UART or I2C.

    By default BSL segment is locked. To read it must be unlocked first. If you want to modify BSL, than you can make backup of original one with MSP430Flasher. At the end of BSL is stored JTAG fuse value (factory default 0FFFFh), so take care to not brick device (blown JTAG fuse and non-functional BSL).

    BSL can be erased. It must be unlocked first. After erase, all BSL flash segments bytes will be 0FFh. JTAG fuse value also will be 0FFFFh (factory default, unlocked device).

  • Hi zrno soli,

    I readed BSL memory with Uniflash not MSP430Flasher. All values in BSL memory is 3FFF 3FFF ... (same values contuniue). I think that values is not default values in BSL.

    Can someone  share hex values in BSL memory?

     

  • I read BSL memory of two ms430f6777A mcus and both were different. One mcu has no values in BSL memory(0x3FFF 0x3FFF ...), while the other has UART BSL codes.

    Shouldn't all mcus have same bsl code by default? Or is it just a random situation?

  • Same MSP430 devices from the same batch, untouched (factory state) have same BSL binary, not different. All leaving factory with preloaded BSL in BSL flash segments or stored in ROM. In my post on linked topic there is attached factory BSL binary for F5510 and F5659...

    e2e.ti.com/.../2144309

  • Very strange, when I read the bsl memory of the msp430f5529 launchpad, there are values in the form of 0x3f 0xff 0x3f 0xff 0x3f 0xff. I have never touched bsl memory.

  • Depending on used software tool, BSL must be unlocked first, because it is locked also for read by default. MSP430Flasher will do this automatically. Here is factory HID BSL from target device on my 5529 LP dumped by MSP430Flasher...

    d:\msp>msp430flasher -i COM7 -r [BSL5529.txt, BSL] -z [VCC]
    * -----/|-------------------------------------------------------------------- *
    *     / |__                                                                   *
    *    /_   /   MSP Flasher v1.3.20                                             *
    *      | /                                                                    *
    * -----|/-------------------------------------------------------------------- *
    *
    * Evaluating triggers...done
    * Checking for available FET debuggers:
    * Found USB FET @ COM7 <- Selected
    * Initializing interface @ COM7...done
    * Checking firmware compatibility:
    * FET firmware is up to date.
    * Reading FW version...
    * Debugger does not support target voltages other than 3000 mV!
    * Setting VCC to 3000 mV...done
    * Accessing device...done
    * Reading device information...done
    * Unlocking BSL memory...done
    * Dumping memory from BSL into BSL5529.txt...done
    *
    * ----------------------------------------------------------------------------
    * Arguments   : -i COM7 -r [BSL5529.txt, BSL] -z [VCC]
    * ----------------------------------------------------------------------------
    * Driver      : loaded
    * Dll Version : 31501001
    * FwVersion   : 31200000
    * Interface   : COM7
    * HwVersion   : E 3.0 (eZ-FET lite)
    * JTAG Mode   : AUTO
    * Device      : MSP430F5529
    * EEM         : Level 7, ClockCntrl 2
    * Read File   : BSL5529.txt (memory segment = BSL)
    * VCC ON      : 3000 mV
    * ----------------------------------------------------------------------------
    * Starting target code execution...done
    * Disconnecting from device...done
    *
    * ----------------------------------------------------------------------------
    * Driver      : closed (No error)
    * ----------------------------------------------------------------------------

    BSL5529.zip

  • Thanks you so much zrno soli, 

    When I read with the msp430flasher program, I saw the default bsl memory codes. Uniflash program does not unlock bsl as you said while reading the whole memory.

    Could you please try to read it with uniflash just to be sure? What values will you see in bsl memory?

  • Hi again zrno soli, 

    How do I lock bsl memory with msp430flasher after programming? 

    Actually, I program ti mcus with external mcu(different vendor). I'm using slau320 library and there is function like that 

    UnlockBsl_430Xv2Flash. I can successfully install fw to target and locked bsl memory, but target's bsl memory protection remains unlocked.
    void UnlockBsl_430Xv2Flash(void)
    {  
        unsigned short BslCur;
       
            // Read SYSBSLC register
            BslCur = ReadMem_430Xv2(F_WORD, 0x0182);
            // Disable BSL area protection
            BslCur &= ~SYSBSLPE;
            // Write back SYSBSLC register
            WriteMem_430Xv2(F_WORD, 0x0182, BslCur);
    }

    void LockBsl_430Xv2Flash(void)  ->>> This function is not in the library, I added it myself
    {
        unsigned short BslCur;
            // Read SYSBSLC register
            BslCur = ReadMem_430Xv2(F_WORD, 0x0182);
            // Enable BSL area protection
            BslCur |= SYSBSLPE;
            // Write back SYSBSLC register
            WriteMem_430Xv2(F_WORD, 0x0182, BslCur);
    }
  • I am not sure if the BSL can be unlocked / locked on identical way as Info A segment, because I didn't check this. I used (on slau320 based solution) only unlocking during BSL segments rewrite, and than device was reseted by itself (WD), and after reset BSL was automatically locked again.

    There was few times topic on e2e related to locking / unlocking  JTAG (fuse blow / unblow)  multiple times. Maybe there you can there how  to correctly  lock / unlock BSL.

  • Hi zrno soli,

    MSP430Flasher -b -w justBSL.txt -v -z [VCC] (-i USB) (-e ERASE_SEGMENT)

    I use this command for the just write to BSL area, but MAIN flash is also erased. What could be the problem?

**Attention** This is a public forum