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.

tm4c123gh6pm: TivaWare TARGET_IS_ defines

Part Number: TM4C123GH6PM
Other Parts Discussed in Thread: TM4C1294NCPDT, TM4C123AH6PM

When compiling a TivaWare project, it is necessary to specify the part using a project-level predefined preprocessor symbol, such as (in my case) PART_TM4C123GH6PM.

But to use the ROM_ functions defined in rom.h and rom_map.h, a 2nd define is needed, of the form TARGET_IS_TM4C12x_Rxx. There are a variety of possibilities: TARGET_IS_TM4C123_RA1, TARGET_IS_TM4C123_RA3, TARGET_IS_TM4C123_RB1, etc.

I have two questions about this:

1. Since I have #defined PART_TM4C123GH6PM (by means of the project settings), why aren't the TivaWare headers automatically defining the correct TARGET_IS_ symbol? As in:

#if defined (PART_TM4C123GH6PM)

#define THE_CORRECT_TARGET_IS_DEFINE_HERE

#endif

2. Since TivaWare is not doing this automatically, what is the correct TARGET_IS_ define to use for PART_TM4C123GH6PM?

I am using TivaWare 2.1.4.178.

  • This is what we use around here:

    Build-> ARM Compiler-> Advanced-> Predefined Symbols-> Pre-define NAME window
    TARGET_IS_TM4C129_RA0 or TARGET_IS_TM4C123_RB1
    PART_TM4C1294NCPDT or PART_TM4C123AH6PM (use actual p/n)

    Bruno