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.

CCS/TMS320F28335: CCS/TMS320F28335

Part Number: TMS320F28335
Other Parts Discussed in Thread: CONTROLSUITE

Tool/software: Code Composer Studio

We are using TMS320f28335 controller and CCS 6.01 version IDE. we have identified that we unable to set  GPIO-A data set register though it is configured as GPIO mode and output direction. I have tried to update the GPIO-A data set via watch window, nevertheless it remains at zero. herewith I have attached code snippet for your reference.

Sample code:

EALLOW;
GpioCtrlRegs.GPAMUX1.bit.GPIO15 = (BT_U16)0; /* GPIO15 as GPIO15 = 00 */

GpioCtrlRegs.GPADIR.bit.GPIO15 = (BT_U16)1; /* GPIO15 = output */

GpioDataRegs.GPASET.bit.GPIO15 = (BT_U16)1; /* Load output latch high */

EDIS;

  • Hi Subhash,

    Subash Sundaresan said:
    GpioCtrlRegs.GPAMUX1.bit.GPIO15 = (BT_U16)0; /* GPIO15 as GPIO15 = 00 */

    GpioCtrlRegs.GPADIR.bit.GPIO15 = (BT_U16)1; /* GPIO15 = output */

    Are these registers getting set? Also, what's the definition of 'BT_U16' ?

    Subash Sundaresan said:
    GpioDataRegs.GPASET.bit.GPIO15 = (BT_U16)1; /* Load output latch high */

    Let this line of code be in forever 'for' or 'while' loop at the later stage. Alternately do try the 'gpio_toggle' example code from controlSuite.

    Regards,

    Gautam

  • Hi Gautam,
    Thank you very much! Yes Direction register is set to 1 and MUX is default to 0. The "BT_U16" is typedef to "unsigned short int". But we unable to set Data Set register. I will check with GPIO code from TI sample project.

    Thanks,
    Subash