Just rotate a led turned on trough the pins P00_5 to P00_12
#include "Ifx_Types.h"
#include "IfxCpu.h"
#include "IfxScuWdt.h"
#include "IfxPort_Io.h"
#include "Bsp.h"
IFX_ALIGN(4) IfxCpu_syncEvent g_cpuSyncEvent = 0;
void core0_main(void)
{
IfxCpu_enableInterrupts();
/* !!WATCHDOG0 AND SAFETY WATCHDOG ARE DISABLED HERE!!
* Enable the watchdogs and service them periodically if it is required */
IfxScuWdt_disableCpuWatchdog( IfxScuWdt_getCpuWatchdogPassword() );
IfxScuWdt_disableSafetyWatchdog( IfxScuWdt_getSafetyWatchdogPassword() );
/* Wait for CPU sync event */
IfxCpu_emitEvent( &g_cpuSyncEvent );
IfxCpu_waitEvent( &g_cpuSyncEvent, 1 );
/*configure the pin from 5 to 12 on port 00 as output pushpull and cmos speed of 1 */
IfxPort_setGroupModeOutput( &MODULE_P00, 5, 0xff, IfxPort_Mode_outputPushPullGeneral, IfxPort_OutputIdx_general );
IfxPort_setGroupPadDriver( &MODULE_P00, 5, 0xff, IfxPort_PadDriver_cmosAutomotiveSpeed1 );
/*on port 00 turn off leds on bits from 5 to 12*/
IfxPort_setGroupState( &MODULE_P00, 5, 0xff, 0x00 );
while(1)
{
/*Loop though all 8 pins one at the time every 500ms*/
for( uint8 i=0 ; i < 8u ; i++ )
{
/*turn on led in turn*/
IfxPort_setGroupState( &MODULE_P00, 5, 0xff, ( 1u << i ) );
/*crude delay in milliseconds*/
waitTime( IfxStm_getTicksFromMilliseconds( BSP_DEFAULT_TIMER, 500u ) );
}
}
}