(* === DECLARATION === *) TYPE struct_boiler_status : STRUCT // State state: BOOL; // Current boiler state (ON/OFF) relay_output: BOOL; // Actual relay output state // Runtime Info on_time_minutes: INT; // Current ON time in minutes remaining_minutes: INT; // Remaining time before auto-shutoff // Safety Status emergency_active: BOOL; // Emergency stop is active time_limit_reached: BOOL; // Max time limit was reached // Error Handling error_state: BOOL; // Error detected error_code: INT; // Error code (0=none, 1=emergency, 2=time limit) END_STRUCT END_TYPE (* === IMPLEMENTATION === *)