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.

How to use the hex430.exe

Other Parts Discussed in Thread: MSP430F2410

Hi there,

I have a MSP430 and try to get my programms run on it. 

First, I have the CCSv6 (the latest, I downloaded it yesterday) and write my Code (at this moment, it's only a LED which should go on). I build my Code and get a out-file as resume.

Second, I use the Command Terminal from Windows to navigate in the folder where the out-file is (also the hex430.exe, i've copy them to this) and use this commandline:

hex430.exe -i name.out -o name.hex

Thirdly, i use the FlashPro430 vom Elpotronic (it's the Company I've the Programmer from) and want to do a "AtuoProg" with the hex-file. Evry time i get the resume "failed"

This is my Code:

#include <msp430x24x.h>
 
void main(void)
{
	WDTCTL=WDTPW+WDTHOLD;  

	//LED @ P2.2
	P2DIR = 0x04;	
	P2SEL = 0x00;	
	P2IE  = 0x00;	
	P2OUT = 0x04;	

	while(1)
	{}
}

and this is the hex-file:

:202100000A09081920B280203F003F01193F003F01143A003A003A030A0A38003C7F4F0FD8
:202140001F003D8F1AF679390882203F003F00083A00023F8F3A00FB30AA3100B0B80C02E2
:20218000B0000CB08EB0BCB28020F21EC21FF21DFF3435363738393A303210FD1C3003FF4A
:01FFC000B28E
:01FFC200B28C
:01FFC400B28A
:01FFC600B288
:01FFC800B286
:01FFCA00B284
:01FFCC00B282
:01FFCE00B280
:01FFD000B27E
:01FFD200B27C
:01FFD400B27A
:01FFD600B278
:01FFD800B276
:01FFDA00B274
:01FFDC00B272
:01FFDE00B270
:01FFE000B26E
:01FFE200B26C
:01FFE400B26A
:01FFE600B268
:01FFE800B266
:01FFEA00B264
:01FFEC00B262
:01FFEE00B260
:01FFF000B25E
:01FFF200B25C
:01FFF400B25A
:01FFF600B258
:01FFF800B256
:01FFFA00B254
:01FFFC00B252
:01FFFE00748E
:00000001FF

 

  • CCS can output a hex file as well, there is no need to do it by yourself.

    http://processors.wiki.ti.com/index.php/Projects_and_Build_Handbook_for_CCS

    And your HEX-File looks a little bit different from what I am used to. Maybe you have selected the wrong format. You have to build an TI-TXT format file.

    And as far as I remember the Elpotronic FlashPro does not accept .hex files, at least the older versions, maybe now they do. I had to rename the .hex file to .txt and then FlashPro successfully wrote the data into the MCU.

    A TI-TXT file looks like this:

    @6400
    4F 14 20 3C D2 43 1E 1C B2 F0 EF FF C4 03 2C 3C
    B2 50 00 40 D6 03 28 3C B2 50 48 01 D8 03 B1 13
    EA 7F 22 3C B2 F0 EF FF CA 03 92 C3 DA 05 7C 40
    05 00 B1 13 D0 7F 18 3C B2 50 21 00 DC 03 B1 13
    A6 69 12 3C 1F 42 EE 03 0F 93 0E 24 2F 83 DA 27
    2F 83 DE 27 2F 83 E0 27 2F 83 E4 27 2F 83 EC 27
    2F 83 02 24 2F 83 00 24 4B 16 00 13 0F 14 17 3C
    92 D3 E0 05 B2 F0 EB FF 10 05 B2 40 0F 00 1A 05
    3F 40 00 80 1F 52 D0 03 82 4F D4 03 B2 D0 10 00
    C4 03 B2 D0 14 00 10 05 92 C3 E0 05 06 3C 1F 42
    3E 02 3F 80 0A 00 E4 27 00 3C 0F 16 00 13 4F 14
    11 3C B2 F0 EB FF 10 05 F2 F0 EF 00 3B 02 D2 43
    18 1C D2 43 19 1C 0F 3C B1 13 3C 7E 0C 3C B1 13
    2C 66 09 3C 1F 42 0E 05 2F 83 EB 27 2F 83 F4 27
    2F 83 F5 27 00 3C 4B 16 00 13 0F 14 00 3C 1F 42
    6E 04 0F 93 0B 24 2F 83 09 24 2F 83 07 24 2F 83
    05 24 2F 83 03 24 3F 80 06 00 00 24 0F 16 00 13
    0F 14 00 3C 1F 42 6E 03 0F 93 07 24 2F 83 05 24
    2F 83 03 24 3F 80 0A 00 00 24 0F 16 00 13 0F 14
    00 3C 1F 42 AE 03 0F 93 ...
  • Hi Dennis,

    thanks for the link. I will try it out tomorrow.

    I've try and set the properties as you show in the Screenshots, but I don't get a hex-file. Only the out-file...

    I know that my hex-file don't look like it should. I have only no clue what went wrong...

    The hex-files are now supported by the Elpotronic FlashPro. 

     

  • Erich Wenecke said:
    and this is the hex-file:
    :202100000A09081920B280203F003F01193F003F01143A003A003A030A0A38003C7F4F0FD8
    :202140001F003D8F1AF679390882203F003F00083A00023F8F3A00FB30AA3100B0B80C02E2
    :20218000B0000CB08EB0BCB28020F21EC21FF21DFF3435363738393A303210FD1C3003FF4A
    :01FFC000B28E
    :01FFC200B28C
    :01FFC400B28A
    :01FFC600B288
    :01FFC800B286
    :01FFCA00B284
    :01FFCC00B282
    :01FFCE00B280
    :01FFD000B27E
    :01FFD200B27C
    :01FFD400B27A
    :01FFD600B278
    :01FFD800B276
    :01FFDA00B274
    :01FFDC00B272
    :01FFDE00B270
    :01FFE000B26E
    :01FFE200B26C
    :01FFE400B26A
    :01FFE600B268
    :01FFE800B266
    :01FFEA00B264
    :01FFEC00B262
    :01FFEE00B260
    :01FFF000B25E
    :01FFF200B25C
    :01FFF400B25A
    :01FFF600B258
    :01FFF800B256
    :01FFFA00B254
    :01FFFC00B252
    :01FFFE00748E
    :00000001FF

    That is an Intel-format hex file. However it doesn't look right either. You have 32 bytes each at address x2100, x2140, and x2180 (which are 64-byte chunks) and what looks like the vector table (the vectors look wrong also).

    The MSP430F2410 has some FLASH at x2100, but the gaps do not make sense - unless you have something setup strange in your linker cmd file.

    I would recommend using the TI-TXT format.

  • Hi all,

    now I get a TI-TXT-file out of my Code, I don't know why exactly (I follow the Step in the Wiki, but first I hadn't any change, after some trys it does what i expected...)

  • And now flashing the MCU via the FlasPro works, too?

**Attention** This is a public forum