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.

TMS320F28P550SJ: How to deal with uint32_t in F28P55?

Part Number: TMS320F28P550SJ

Tool/software:

Hi,

I have a question about uint32_t.

I use: chip TMS320F28P550SJ, CCS version 20.0.1.4__1.6.1, and Spectrum Digital XDS2XX USB Debug Probe.

My main function is as show as below, and I should get value1=0x0000AA00, value2=0x000AA000, value3=0x00AA0000. However, the value I obtained were: value1=0x0000AA00, value2=0x0000A000, value3=0x00000000. How could I get the right uint32_t data? Thanks.

#include "f28p55x_device.h"
#include "f28x_project.h"
#include "C:\TI\ccs2001\ccs\tools\compiler\ti-cgt-c2000_22.6.1.LTS\include\stdint.h"
void main(void)
{
    uint16_t data = 0xAA;
    uint32_t value1 = 0U;
    uint32_t value2 = 0U;
    uint32_t value3 = 0U;

    //
    // Initialize System Control:
    // PLL, WatchDog, enable Peripheral Clocks
    //
    InitSysCtrl();

    value1 = data <<8;
    value2 = data <<12;
    value3 = data <<16;
    while(1)
    {
        ;
    }
}