BECKHOFF CX210009x4 User Manual
Page 27
Product overview
ELSIF bReadLine1Req THEN
eModeRead := eCX2100_ReadLine1;
bExecuteRead := TRUE;
ELSIF bReadLine2Req THEN
eModeRead := eCX2100_ReadLine2;
bExecuteRead := TRUE;
ELSIF bReadLinesReq THEN
eModeRead := eCX2100_ReadLines;
bExecuteRead := TRUE;
END_IF
END_IF
(* get display *)
IF (eModeRead <> eCX2100_DisplayNoActionRd) AND (eModeWrite = eCX2100_DisplayNoActionWr) THEN
fbGetDisplayText(
bExecute := bExecuteRead,
sNetID := '',
nPort := 16#7100,
eMode := eModeRead,
bBusy => bBusy,
bError => bError,
nErrorID => nErrorID,
);
IF NOT fbGetDisplayText.bBusy THEN
fbGetDisplayText(bExecute := FALSE);
IF NOT fbGetDisplayText.bError THEN
CASE eModeRead OF
eCX2100_ReadCursorInfo:
nCursorPosX := fbGetDisplayText.nCursorPosX;
nCursorPosY := fbGetDisplayText.nCursorPosY;
nCursorMode := fbGetDisplayText.nCursorMode;
bReadCursorInfoReq := FALSE;
eCX2100_ReadBackLight:
nBacklight := fbGetDisplayText.nBacklight;
bReadBacklightReq := FALSE;
eCX2100_ReadLine1:
sLine1 := fbGetDisplayText.sLine1;
bReadLine1Req := FALSE;
eCX2100_ReadLine2:
‘ sLine2 := fbGetDisplayText.sLine2;
bReadLine2Req := FALSE;
eCX2100_ReadLines:
sLine1 := fbGetDisplayText.sLine1;
sLine2 := fbGetDisplayText.sLine2;
bReadLinesReq := FALSE;
END_CASE
END_IF
bExecuteRead := FALSE;
eModeRead := eCX2100_DisplayNoActionRd;
END_IF
END_IF
(* prepare set display mode *)
IF (eModeWrite = eCX2100_DisplayNoActionWr) AND (eModeRead = eCX2100_DisplayNoActionRd) THEN
IF bCursorOnReq THEN
eModeWrite := eCX2100_CursorOn;
bExecuteWrite := TRUE;
bReadCursorInfoReq := TRUE;
ELSIF bCursorOffReq THEN
eModeWrite := eCX2100_CursorOff;
bExecuteWrite := TRUE;
bReadCursorInfoReq := TRUE;
ELSIF bBlinkCursorOnReq THEN
eModeWrite := eCX2100_CursorBlinkOn;
bExecuteWrite := TRUE;
bReadCursorInfoReq := TRUE;
ELSIF bBlinkCursorOffReq THEN
eModeWrite := eCX2100_CursorBlinkOff;
bExecuteWrite := TRUE;
bReadCursorInfoReq := TRUE;
ELSIF bBacklightOnReq THEN
eModeWrite := eCX2100_BackLightOn;
bExecuteWrite := TRUE;
bReadBacklightReq := TRUE;
ELSIF bBacklightOffReq THEN
eModeWrite := eCX2100_BackLightOff;
bExecuteWrite := TRUE;
bReadBacklightReq := TRUE;
CX210009x4
27
Version 1.1