#include pins.h #include vars.h portset(OUTPUT_FUEL); //turn ON fuel valve portset(OUTPUT_IGNITION); //turn ON sparkle relay proc=plc_proc_ignition; timer=timeout_ignition; do{ timer--; }while(timer>0); //delay for ignition portclr(OUTPUT_IGNITION); //turn OFF sparkle relay portset(OUTPUT_OXY_HEAT); //turn ON Preheat Oxygen valve proc=plc_proc_preheat; break_heating=1; //set break_heating variable timer=timeout_heating; do{ timer--; if (break_heating==0) { timer=0; }; //If break_heating was cleared outside of PLC, clear timer to exit from the loop }while(timer>0); //pre-heating loop portset(OUTPUT_OXY_CUT); //turn ON Cutting Oxygen valve proc=plc_proc_cutting; exit(99); };