#include "Bsp.h"
#include "IfxCpu.h"
#include "IfxPort_Io.h"
#include "IfxPort_PinMap.h"
#include "IfxScuWdt.h"
#include "Ifx_Types.h"
IfxCpu_syncEvent cpuSyncEvent = 0;
const IfxPort_Io_ConfigPin configPin[] = {
{&IfxPort_P10_2,
IfxPort_Mode_outputPushPullGeneral,
IfxPort_PadDriver_cmosAutomotiveSpeed1},
};
const IfxPort_Io_Config conf
= {sizeof(configPin) / sizeof(IfxPort_Io_ConfigPin),
(IfxPort_Io_ConfigPin *)configPin};
int core0_main(void) {
IfxCpu_enableInterrupts();
IfxScuWdt_disableCpuWatchdog(IfxScuWdt_getCpuWatchdogPassword());
IfxScuWdt_disableSafetyWatchdog(IfxScuWdt_getSafetyWatchdogPassword());
IfxCpu_emitEvent(&cpuSyncEvent);
IfxCpu_waitEvent(&cpuSyncEvent, 1);
initTime();
IfxPort_Io_initModule(&conf);
while(1) {
IfxPort_setPinState(&MODULE_P10, 2, IfxPort_State_toggled);
Ifx_TickTime time = now();
while(now() - time < TimeConst_100ms * 5) {}
}
return 1;
}