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.

RTOS/MSP432P4111: How to migrate TI-RTOS projects form MSP432P401R to MSP432P4111

Part Number: MSP432P4111

Tool/software: TI-RTOS

I need to migrate an existing project from the MSP432P401R to the MSP432P4111.

I am working on the MSP432P401R (Red) launchpad and trying to run it on the MSP432P4111 Launchpad.

  • SimpleLink MSP432P4SDK 2.10.0.14
  • CCS V7.3.0
  • XDCTools 3.50.5.12
  • Compiler TI v17.9.0.STS

If I tried to use the existing P401R project configuration with the P4111 target, I get an exception when the processor tries to run the simplelink drivers Power_init() function. Is this expected?

Since I was hitting that excpetion, i attempted to move over to a P4111 target configuration instead.  

These are the changes I've made so far:

  1. I changed my platform to: ti.platforms.msp432:MSP432P4111
  2. I changed my device variant to: MSP432P4111
  3. I changed my predfined symbol in the ARM Compiler->Prefefind Symbosl: to have __MSP432P4111___
  4. I changed my linker file to the example from the mailbox TI RTOS project... MSP432_EXP432P4111_TIRTOS.cmd

I'm using regular register accesses to configure the part, but the register names are undefined:

Description	Resource	Path	Location	Type
#20 identifier "P10DIR" is undefined	Msp432Gpio.c	
#20 identifier "P10DS" is undefined	Msp432Gpio.c	
#20 identifier "P10IN" is undefined	Msp432Gpio.c	
#20 identifier "P10OUT" is undefined	Msp432Gpio.c	
#20 identifier "P10REN" is undefined	Msp432Gpio.c	
#20 identifier "P10SEL0" is undefined	Msp432Gpio.c	
#20 identifier "P10SEL1" is undefined	Msp432Gpio.c	
#20 identifier "P1DIR" is undefined	Msp432Gpio.c	
#20 identifier "P1DS" is undefined	Msp432Gpio.c	
#20 identifier "P1OUT" is undefined	Msp432Gpio.c	
#20 identifier "P1REN" is undefined	Msp432Gpio.c	
#20 identifier "P1SEL0" is undefined	Msp432Gpio.c	
#20 identifier "P1SEL1" is undefined	Msp432Gpio.c	
#20 identifier "P2DIR" is undefined	Msp432Gpio.c	
#20 identifier "P2DS" is undefined	Msp432Gpio.c	
#20 identifier "P2IN" is undefined	Msp432Gpio.c	
#20 identifier "P2IN" is undefined	Msp432Gpio.c	
#20 identifier "P2IN" is undefined	Msp432Gpio.c	
#20 identifier "P2IN" is undefined	Msp432Gpio.c	
#20 identifier "P2OUT" is undefined	Msp432Gpio.c	
#20 identifier "P2OUT" is undefined	Msp432Gpio.c	
#20 identifier "P2OUT" is undefined	Msp432Gpio.c	
#20 identifier "P2REN" is undefined	Msp432Gpio.c	
#20 identifier "P2SEL0" is undefined	Msp432Gpio.c	
#20 identifier "P2SEL1" is undefined	Msp432Gpio.c	
#20 identifier "UCA0IE" is undefined	Msp432Spi.c	
#20 identifier "UCA1IE" is undefined	Msp432Spi.c	
#20 identifier "UCA2IE" is undefined	Msp432Spi.c	
#20 identifier "UCA3IE" is undefined	Msp432Spi.c	
#20 identifier "UCB0BRW" is undefined	MspI2c.c	
#20 identifier "UCB0CTLW0" is undefined	MspI2c.c	
#20 identifier "UCB0CTLW0" is undefined	MspI2c.c	
#20 identifier "UCB0CTLW0" is undefined	MspI2c.c	
#20 identifier "UCB0CTLW0" is undefined	MspI2c.c	
#20 identifier "UCB0CTLW0" is undefined	MspI2c.c	
#20 identifier "UCB0CTLW0" is undefined	MspI2c.c	
#20 identifier "UCB0CTLW0" is undefined	MspI2c.c	
#20 identifier "UCB0CTLW0" is undefined	MspI2c.c	
#20 identifier "UCB0CTLW1" is undefined	MspI2c.c	
#20 identifier "UCB0I2CSA" is undefined	MspI2c.c	
#20 identifier "UCB0I2CSA" is undefined	MspI2c.c	
#20 identifier "UCB0I2CSA" is undefined	MspI2c.c	
#20 identifier "UCB0IE" is undefined	Msp432Spi.c	
#20 identifier "UCB0IE" is undefined	MspI2c.c	
#20 identifier "UCB0IE" is undefined	MspI2c.c	

It appears that the MSP432P401R has a msp432p401r_classic.h, while the msp432p4111 does not have an equivalant header file.  is there a work around for this, other than rolling my own?  

Thanks,
Mark

  • I would recommend moving the current MSP432P401R code that you have over to the most recent driverLib and replace and 'classic' register manipulations with the CMSIS style. Once you have made that transition, then you can more easily make the port to the P4111.

    www.ti.com/.../slaa771.pdf

    Regards,
    Chris
  • Thanks Chris,

    I'm trying to follow those instructions (form the app note)
    1. Import the driverlib Empty project for MSP432P4111.
    2. Rename the project as needed.
    3. Copy source code to the new project.
    4. Rename FlashCtl and SysCtl APIs to FlashCtl_A and SysCtl_A.
    5. Compile the project.
    6. No other code changes needed across the MSP432P4x family.

    However, the only empty driverlib project I have is the NO-RTOS variant.
    How do I enable XDCUtils and Sybios configuration for the empty driverlib project?
  • Never mind...I found copying my other .cfg file to the new project enabled it.
  • I'm trying to use the driver lib to initialize the system clocks and i'm getting an exception.  

    It's occurring when I step into CS_initClockSignal(CS_ACLK, CS_REFOCLK_SELECT, CS_CLOCK_DIVIDER_1);

    Here's the mixed c/assembly that calls the fucntion.  

     89           CS_initClockSignal(CS_ACLK, CS_REFOCLK_SELECT, CS_CLOCK_DIVIDER_1);
    00007986:   2001                movs       r0, #1
    00007988:   2102                movs       r1, #2
    0000798a:   2200                movs       r2, #0
    0000798c:   F002FCA6            bl         #0xa2dc

    Now Here's the mixed c/assembly:

              CS_initClockSignal():
    0000589c:   4B31                ldr        r3, [pc, #0xc4]
    0000589e:   B5D0                push       {r4, r6, r7, lr}
    214       {
    000058a0:   460F                mov        r7, r1
    218           CS->KEY = CS_KEY;
    000058a2:   F646FF99            bl         #0xffe4c7d8
    000058a6:   2001                movs       r0, #1
    000058a8:   F7400000            sbfx       r0, r0, #0, #1

    The code makes it through: 000058a2: F646FF99 bl #0xffe4c7d8

    An exception is generated when it tries to do the next instruction:  000058a6: 2001 movs r0, #1

    I find the bl instruction suspcious with the #0xffe4c7d8.

    I don't get any Exception debug in ROV, however I have not made it to BIOS_start() yet.  So that may not be surprising.  

    Any idea why this may be occuring?

    THanks,
    Mark

  • Next problem i'm running into is my CS driverlib calls are generating an exception.

    I'm stepping through this C Source code:
    PCM_setCoreVoltageLevel(PCM_VCORE1);
    CS_setDCOCenteredFrequency(CS_DCO_FREQUENCY_48);
    CS_setReferenceOscillatorFrequency(CS_REFO_128KHZ);
    CS_initClockSignal(CS_ACLK, CS_REFOCLK_SELECT, CS_CLOCK_DIVIDER_1);
    CS_initClockSignal(CS_SMCLK, CS_MODOSC_SELECT, CS_CLOCK_DIVIDER_1);
    Interrupt_disableSleepOnIsrExit(); // MDR_DEBUG: Disable sleep for now.

    Scenario 1)
    If i set a breakpoint at CS_initClockSignal(CS_ACLK, CS_REFOCLK_SELECT, CS_CLOCK_DIVIDER_1);
    Run
    I get an exception

    Scenario 2)
    If i set a breakpoint at CS_setReferenceOscillatorFrequency(CS_REFO_128KHZ);
    Step over that call
    Step over CS_initClockSignal(CS_ACLK, CS_REFOCLK_SELECT, CS_CLOCK_DIVIDER_1);
    I get an exception

    .Secnario 3)
    If i set a breakpoint at CS_setReferenceOscillatorFrequency(CS_REFO_128KHZ);
    Step over that call
    Assembly step into CS_initClockSignal(CS_ACLK, CS_REFOCLK_SELECT, CS_CLOCK_DIVIDER_1);
    ---- Assembly code for fucntion call ----
    89 CS_initClockSignal(CS_ACLK, CS_REFOCLK_SELECT, CS_CLOCK_DIVIDER_1);
    00007988: 2102 movs r1, #2
    0000798a: 2200 movs r2, #0
    0000798c: F7FDFF86 bl #0x589c

    As I step through the CS_initClockSignal function, an exception occurs
    I don't get any useful exception information from ROV or the console.
  • Mark,
    Regrets for the drop of this thread. The TIDRIVERS (RTOS) version controls the clocks and core level through the power performance levels. If possible, then I would recommend using those.

    One of the differences between the P4111 and P401 devices is the flash. At 48Mhz the P401 device must use flash waitstates of 1 while the P4111 must use 3. Perhaps this is addressed somewhere else in your code, but if not, then it might explain the exceptions.

    Regards,
    Chris

**Attention** This is a public forum