I am trying to set up a piece of equipment with a Horner HE-X4R. I'd like to use structured text and so far I'm just trying to get a basic On/off switch set up using this. The code is just several lines and assigned the variables to two buttons and the Motor_RUN to an indicator light on the screen.
IF PBMotor_ON = TRUE OR Motor_RUN = TRUE THEN
Motor_RUN := TRUE;
ELSIF PBMotor_ON = FALSE OR PBMotor_OFF = TRUE THEN
Motor_RUN := FALSE;
END_IF;
I'd like to test this without wiring it into the system but the simulation option is grayed out when I go into debug mode. Does anyone know what I need to do in order to do a simulation?
IF PBMotor_ON = TRUE OR Motor_RUN = TRUE THEN
Motor_RUN := TRUE;
ELSIF PBMotor_ON = FALSE OR PBMotor_OFF = TRUE THEN
Motor_RUN := FALSE;
END_IF;
I'd like to test this without wiring it into the system but the simulation option is grayed out when I go into debug mode. Does anyone know what I need to do in order to do a simulation?