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/TMS570LS1224: The way to turn off USER LEDS

Expert 1660 points
Part Number: TMS570LS1224


Tool/software: Code Composer Studio

hello,

could anyone inform me how to  turn off USER LEDS (GIOB_1 &  GIOB_2  )

  • Hello,

    1. Enable GIO Driver from Driver Enable Tab;
    2. From PINMUX Tab check GIOB checkbox (clear all conflicts if available);
    3. From GIO-->Port B Tab set GIOB[1] as output;
    4. From GIO-->Port B Tab set GIOB[2] as output;
    4. Generate code

    5. In CCS sys_main.c: include gio.h
    6. In main(): call gioInit();
    7. In main():

    call gioToggleBit(gioPORTB, 1); to toggle LED2 
    call gioToggleBit(gioPORTB, 2); to toggle LED3

    call gioSetBit(gioPORTB,1, 0); to set LED2 OFF
    call gioSetBit(gioPORTB,2, 0); to set LED3 OFF