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.

MSP430F6638: Problems about custom flash-based BSL

Part Number: MSP430F6638
Other Parts Discussed in Thread: UNIFLASH,

I am trying to use the flash-based BSL to update our products. The pre-programmed BSL based on USB works well with 4MHz XT2, but our new products use 16MHz XT2 instead. According to slaa450(Creating a Custom Flash-Based Bootloader (BSL)), it should be easy to be fixed by changing some #define in BSL_Device_File.h. I downloaded (slaa450)MSP430BSL_1_00_12_00.zip and it only has an IAR project about USB-based-BSL, named as "MSP430F552x_USB". I modified the BSL_Device_File.h with #include "msp430x552x.h" to #include "msp430f6638.h", changed the target device in option and recompiled it successfully. I download this new txt by IAR and UniFlash, it couldn't work even with 4MHz XT2. Are there anything else I should do? Or are there any availablecodes for F6638 ?

Thanks for anything.

Regards, 

Tianyi Zhang

  • Hi Tianyi,

    I am looking into this for you. I see in this previous E2E post that you may not need to compile the full source code to achieve this and only need to change a small portion of the binary image:

    e2e.ti.com/.../2142862

    I need to look into this further and verify that it works. I'll have more detail to you by tomorrow.

    Best regards,
    Caleb Overbay
  • Hi Caleb,

    It is really great to see your reply!

    According to the given E2E post, I download the UG for xx5x and xx6x (slau208p). The section 42.2.3 mentioned how to determine the UPQB and UPMB in USBPLLDIVB Register. I tried to change 24MHz to 16MHz, so the value of these regs should be changed from 05 0F to 04 11.

    I found two places contained 0F 05 in \5xx_6xx_Released_BSL_Images\MSP430F663x_Family\BSL_00.08.88.39.txt, at line 8 and line 60 (in my editor). I modified them to 11 04, but the firmware couldn't work yet.

    Then I changed 24MHz to 16MHz in the  F552x source IAR project and recompiled it. Comparing these two txts, I found there are two more differences. The old txt (24MHz)contains 96 08 while in the new one (16MHz) they are AD 06. I don't know what do they mean, but after I do the same changes in BSL_00.08.88.39.txt, the new BSL works on my board with XT2=16MHz.

    Thanks for your useful help and suggestions! I wonder if I should do something to close this question or something like that?

    Regards,

    Tianyi Zhang.

**Attention** This is a public forum