Download this file
1 2 3 4 5 6 7 8 9 10 11
METHOD CommunicationStateMachine : BOOL VAR //Task-Handle CASE wCommunicationState OF 0: //SysTask.SysTaskGetCurrent(ADR(hTask)); //SysTaskGetInterval(hTask, pulInterval); //sc.udiMasterCycleTime := pulInterval; sc.udiMasterCycleTime := TO_UDINT(fTaskCycle*1E6); controller.fDeltaTime := fTaskCycle; CommunicationStateMachine := SUPER^.CommunicationStateMachine();