Skip to content

Commit 5013e57

Browse files
MBP-247: Add the homing status as persistent
1 parent 943176f commit 5013e57

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

solution/tc_project_app/POUs/MAIN.TcPOU

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -310,12 +310,15 @@ END_IF
310310
<Action Name="STORE_PERSISTENT" Id="{cb5c9254-2e5f-47b1-9baa-10e728a961b0}" FolderPath="POSITION_RECOVERY\">
311311
<Implementation>
312312
<ST><![CDATA[FOR iAxes := 1 TO GVL_APP.nAXIS_NUM DO
313-
//Store Position at shutdown
313+
//Store actual position at shutdown
314314
astAxesPersistent[iAxes].fPositionAtShutdown := GVL.astAxes[iAxes].Axis.NcToPlc.ActPos;
315315
316316
//Store encoder position BIAS at shutdown
317317
astAxesPersistent[iAxes].fEncoderBiasAtShutdown := afbReadPositionBias[iAxes].Value;
318318
319+
//Store homing status at shutdown
320+
astAxesPersistent[iAxes].bHomedAtShutdown := GVL.astAxes[iAxes].stStatus.bHomed;
321+
319322
//Store value of moving at shutdown
320323
IF GVL.astAxes[iAxes].Axis.Status.StandStill OR GVL.astAxes[iAxes].Axis.Status.Disabled THEN
321324
astAxesPersistent[iAxes].bMovingAtShutdown := FALSE;

0 commit comments

Comments
 (0)