Skip to content

Commit

Permalink
Merge branch 'release/V1.4.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
wesleybuchanan committed Jun 19, 2023
2 parents 06c5508 + c6c3421 commit 46a08fc
Show file tree
Hide file tree
Showing 1,253 changed files with 124,326 additions and 3,644 deletions.
22 changes: 0 additions & 22 deletions mappFramework/Diagnosis/Simulation/PC/BackupMgr.PVM

This file was deleted.

120 changes: 120 additions & 0 deletions mappFramework/Diagnosis/Simulation/PC/PackMLMgr.PVM

Large diffs are not rendered by default.

143 changes: 50 additions & 93 deletions mappFramework/Diagnosis/Simulation/PC/RecipeMgr.PVM

Large diffs are not rendered by default.

782 changes: 0 additions & 782 deletions mappFramework/Diagnosis/Simulation/PC/ReportMgr.PVM

This file was deleted.

Binary file added mappFramework/Diagnosis/Simulation/PC/UserXMgr.tc
Binary file not shown.
144 changes: 144 additions & 0 deletions mappFramework/Diagnosis/UnitTest/PC_any/FileTest.PVM

Large diffs are not rendered by default.

Binary file modified mappFramework/Logical/ChineseHelp/mappFramework.chm
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -50,16 +50,14 @@ PROGRAM _CYCLIC
MpAlarmXListUIConnect.AcknowledgeAll := TRUE;
END_IF

IF (HmiAlarmX.Commands.ExportAlarms = TRUE) THEN
MpAlarmXHistory_0.Export := TRUE;
END_IF

// Call all cyclic actions
AlarmHandling;
GetBacktraceInformation;
ExecuteQuery;
QueryTableConfig;
AlarmSampleFub;
ExportAlarms;

// Check if any reactions are active.
// Typically the MpAlarmXCheckReaction() function is called from other tasks within the application.
Expand All @@ -73,11 +71,6 @@ PROGRAM _CYCLIC
// Info is active. Add code here to resond to info situation.
END_IF

IF ((MpAlarmXHistory_0.Export = TRUE) AND (MpAlarmXHistory_0.CommandDone = TRUE)) THEN
HmiAlarmX.Commands.ExportAlarms := FALSE;
MpAlarmXHistory_0.Export := FALSE;
END_IF

// Error reset
IF NOT MpAlarmXCore_0.Error THEN
MpAlarmXCore_0.ErrorReset := FALSE;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ TYPE
Parameters : AlarmParametersType; (*HMI parameters*)
END_STRUCT;
AlarmCommandsType : STRUCT (*Structure to hold the commands from the HMI*)
ExportAlarms : BOOL; (*Triggers an alarm export of the alarm history. Connected to a button on the HMI. *)
ExportAlarms : BOOL; (*Triggers an alarm export of the alarm history. Connected to a button on the HMI.*)
RunQuery : BOOL; (*Triggers the query to run. Connected to a button on the HMI. *)
END_STRUCT;
AlarmParametersType : STRUCT (*Structure to hold the parameters from the HMI*)
Expand All @@ -19,6 +19,8 @@ TYPE
AlarmSortCfg : STRING[1000]; (*Sort configuration for the AlarmList widget*)
AlarmFilterCfg : STRING[1000]; (*Filter configuration for the AlarmList widget*)
TableConfig : ARRAY[0..1]OF STRING[120]; (*Table configuration for the alarm query Table*)
AlarmExportDone : BOOL; (*Alarm export of alarm history is completed. Connected to a button on the HMI. *)
AlarmExportDisplayed : BOOL; (*Alarm export of alarm history is displayed. Connected to a button on the HMI. *)
Query : AlarmQueryHMIType; (*Structure which rearranges the query data from AlarmQuery into a structure of arrays for easy connection to the Table widget*)
END_STRUCT;
AlarmQueryType : STRUCT (*Structure for query results and status*)
Expand Down
19 changes: 19 additions & 0 deletions mappFramework/Logical/Infrastructure/AlarmX/AlarmMgr/HMIActions.st
Original file line number Diff line number Diff line change
Expand Up @@ -43,3 +43,22 @@ ACTION QueryTableConfig:
brsstrcat(ADR(HmiAlarmX.Status.TableConfig[0]), ADR(',"to":19, "visible":false}]}'));

END_ACTION

ACTION ExportAlarms:

IF (HmiAlarmX.Commands.ExportAlarms = TRUE) THEN
MpAlarmXHistory_0.Export := TRUE;
END_IF

IF ((MpAlarmXHistory_0.Export = TRUE) AND (MpAlarmXHistory_0.CommandDone = TRUE)) THEN
MpAlarmXHistory_0.Export := FALSE;
HmiAlarmX.Commands.ExportAlarms := FALSE;
HmiAlarmX.Status.AlarmExportDone := TRUE;
END_IF

IF HmiAlarmX.Status.AlarmExportDisplayed THEN
HmiAlarmX.Status.AlarmExportDisplayed := FALSE;
HmiAlarmX.Status.AlarmExportDone := FALSE;
END_IF

END_ACTION
4 changes: 2 additions & 2 deletions mappFramework/Logical/Infrastructure/AlarmX/Alarms.tmx
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@
<seg>Mon unité</seg>
</tuv>
</tu>
<tu tuid="Alarm.9">
<tu tuid="Alarm.8">
<tuv xml:lang="de">
<seg>Alarm 8</seg>
</tuv>
Expand All @@ -329,7 +329,7 @@
<seg>Mon unité</seg>
</tuv>
</tu>
<tu tuid="Alarm.8">
<tu tuid="Alarm.9">
<tuv xml:lang="de">
<seg>Alarm 9</seg>
</tuv>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,9 @@ ACTION QueryTableConfig:

// Hide operator column for the recipe query
IF (HmiAudit.Status.Query.Option = 0) THEN
brsstrcat(ADR(HmiAudit.Status.TableConfig[0]), ADR(', "specColumns": [ {"from":1, "to":1, "visible":true}]'));
brsstrcat(ADR(HmiAudit.Status.TableConfig[0]), ADR(', "specColumns": [ {"from":2, "to":2, "visible":true}]'));
ELSIF (HmiAudit.Status.Query.Option = 1) THEN
brsstrcat(ADR(HmiAudit.Status.TableConfig[0]), ADR(', "specColumns": [ {"from":1, "to":1, "visible":false}]'));
brsstrcat(ADR(HmiAudit.Status.TableConfig[0]), ADR(', "specColumns": [ {"from":2, "to":2, "visible":false}]'));
END_IF

brsstrcat(ADR(HmiAudit.Status.TableConfig[0]), ADR('}'));
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<?AutomationStudio Version=4.8.6.30 SP?>
<?AutomationStudio FileVersion="4.9"?>
<Package xmlns="http://br-automation.co.at/AS/Package">
<Objects>
<Object Type="File" Description="mapp UserX audit event texts">TxtUserF.tmx</Object>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<?AutomationStudio Version=4.8.6.30 SP?>
<?AutomationStudio FileVersion="4.9"?>
<Package xmlns="http://br-automation.co.at/AS/Package">
<Objects>
<Object Type="File" Description="mapp Services audit event texts">TxtEventF.tmx</Object>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<?AutomationStudio Version=4.8.6.30 SP?>
<?AutomationStudio FileVersion="4.9"?>
<Package xmlns="http://br-automation.co.at/AS/Package">
<Objects>
<Object Type="File" Description="mapp Services audit event texts">TxtEventF.tmx</Object>
Expand Down
2 changes: 1 addition & 1 deletion mappFramework/Logical/Infrastructure/Audit/Package.pkg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<?AutomationStudio Version=4.8.6.30 SP?>
<?AutomationStudio FileVersion="4.9"?>
<Package xmlns="http://br-automation.co.at/AS/Package">
<Objects>
<Object Type="Program" Language="IEC" Description="Audit manager">AuditMgr</Object>
Expand Down
30 changes: 16 additions & 14 deletions mappFramework/Logical/Infrastructure/File/FileMgr/FileMgr.st
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,14 @@
PROGRAM _INIT

// Inititialize mapp function block
MpFileManagerUIConnect.DeviceList.DeviceNames[0] := 'mappRecipeFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[1] := 'mappAuditFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[2] := 'mappReportFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[3] := 'mappDataFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[4] := 'mappBackupFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[5] := 'mappAlarmXFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[6] := 'mappUserXFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[0] := 'USER';
MpFileManagerUIConnect.DeviceList.DeviceNames[1] := 'mappRecipeFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[2] := 'mappAuditFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[3] := 'mappReportFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[4] := 'mappDataFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[5] := 'mappBackupFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[6] := 'mappAlarmXFiles';
MpFileManagerUIConnect.DeviceList.DeviceNames[7] := 'mappUserXFiles';
MpFileManagerUI_0.Enable := TRUE;
MpFileManagerUI_0.MpLink := ADR(gMpLinkFileManagerUIFile);
MpFileManagerUI_0.UIConnect := ADR(MpFileManagerUIConnect);
Expand Down Expand Up @@ -65,13 +66,14 @@ PROGRAM _INIT
PathCheck.Folder[5] := 'AlarmX';
PathCheck.Folder[6] := 'UserX';

HmiFile.Status.DeviceDataProvider[0] := '{"value":"mappRecipeFiles","text":"mappRecipeFiles"}';
HmiFile.Status.DeviceDataProvider[1] := '{"value":"mappAuditFiles","text":"mappAuditFiles"}';
HmiFile.Status.DeviceDataProvider[2] := '{"value":"mappReportFiles","text":"mappReportFiles"}';
HmiFile.Status.DeviceDataProvider[3] := '{"value":"mappDataFiles","text":"mappDataFiles"}';
HmiFile.Status.DeviceDataProvider[4] := '{"value":"mappBackupFiles","text":"mappBackupFiles"}';
HmiFile.Status.DeviceDataProvider[5] := '{"value":"mappAlarmXFiles","text":"mappAlarmXFiles"}';
HmiFile.Status.DeviceDataProvider[6] := '{"value":"mappUserXFiles","text":"mappUserXFiles"}';
HmiFile.Status.DeviceDataProvider[0] := '{"value":"USER","text":"UserPath"}';
HmiFile.Status.DeviceDataProvider[1] := '{"value":"mappRecipeFiles","text":"mappRecipeFiles"}';
HmiFile.Status.DeviceDataProvider[2] := '{"value":"mappAuditFiles","text":"mappAuditFiles"}';
HmiFile.Status.DeviceDataProvider[3] := '{"value":"mappReportFiles","text":"mappReportFiles"}';
HmiFile.Status.DeviceDataProvider[4] := '{"value":"mappDataFiles","text":"mappDataFiles"}';
HmiFile.Status.DeviceDataProvider[5] := '{"value":"mappBackupFiles","text":"mappBackupFiles"}';
HmiFile.Status.DeviceDataProvider[6] := '{"value":"mappAlarmXFiles","text":"mappAlarmXFiles"}';
HmiFile.Status.DeviceDataProvider[7] := '{"value":"mappUserXFiles","text":"mappUserXFiles"}';

// Calculate offset for potential additional USB devices
FOR i := 0 TO ((SIZEOF(MpFileManagerUIConnect.DeviceList.DeviceNames) / SIZEOF(MpFileManagerUIConnect.DeviceList.DeviceNames[0])) - 1) DO
Expand Down
83 changes: 42 additions & 41 deletions mappFramework/Logical/Infrastructure/File/FileMgr/FileMgr.var
Original file line number Diff line number Diff line change
@@ -1,41 +1,42 @@
(*Function Blocks*)
VAR
MpFileManagerUI_0 : MpFileManagerUI; (*MpFileManagerUI instance*)
MpFileManagerUI_FIFO : MpFileManagerUI; (*MpFileManagerUI instance*)
R_TRIG_CheckStatus : R_TRIG; (*Trigger function block*)
TON_Wait : TON; (*FIFO handling support*)
TON_ScanFolder : TON; (*Timer to scan for folder*)
CurrentIndex : UDINT; (*FIFO handling support deleting more then 50 files*)
DirRead_FolderSize : DirRead; (*FIFO handling support reading current folder size*)
END_VAR
(*Constants*)
VAR CONSTANT
MAX_IDX_FILE_DEV : USINT := MAX_IDX_USB_DEV_LIST + 7; (*Maximum number of file devices *)
END_VAR
(*Structure Types*)
VAR
MpFileManagerUIConnect : MpFileManagerUIConnectType; (*File manager connection to the HMI*)
MpFileManagerUIConnect_FIFO : {REDUND_UNREPLICABLE} MpFileManagerUIConnectType; (*File manager connection to the HMI*)
HmiFile : FileHmiInterfaceType; (*HMI interface structure*)
PathCheck : FilePathCheckType; (*Parameter structure controlling the visible file device based on available folders*)
DirectoryData : fiDIR_READ_DATA; (*FIFO handling support reading current folder size*)
END_VAR
(*Variables*)
VAR
i : USINT; (*Index for FOR loops*)
DeviceListCount : USINT; (*Counter for accessible file devices*)
DeviceCount : USINT; (*Counter for available file devices*)
Ident : UDINT; (*Ident of a program on target*)
IdentStatus : UINT; (*Status variable if a program exists on target*)
Index : USINT; (*Index for avaliable devices*)
FolderDepthCount : USINT; (*Keeps track of the folder depth location to determine whether or not the back button should be shown*)
USBOffset : USINT := 0; (*Device list offset where to add USB device*)
MaxDeviceNameIndex : USINT; (*How many devices are configured*)
tempIdx : USINT; (*FIFO handling support index variable*)
FileNameArraySize : USINT; (*FIFO handling support size of the array*)
StartIndex : USINT; (*FIFO handling support *)
Fifo_Count : USINT; (*FIFO handling support current file count*)
END_VAR
VAR RETAIN
FifoSettingsRetain : {REDUND_UNREPLICABLE} FileHmiParaFifoType; (*Store FIFO settings in retain memory to be applied after boot*)
END_VAR
(*Function Blocks*)
VAR
MpFileManagerUI_0 : MpFileManagerUI; (*MpFileManagerUI instance*)
MpFileManagerUI_FIFO : MpFileManagerUI; (*MpFileManagerUI instance*)
R_TRIG_CheckStatus : R_TRIG; (*Trigger function block*)
TON_Wait : TON; (*FIFO handling support*)
TON_ScanFolder : TON; (*Timer to scan for folder*)
CurrentIndex : UDINT; (*FIFO handling support deleting more then 50 files*)
DirRead_FolderSize : DirRead; (*FIFO handling support reading current folder size*)
END_VAR
(*Constants*)
VAR CONSTANT
MAX_IDX_FILE_DEV : USINT := MAX_IDX_USB_DEV_LIST + 7; (*Maximum number of file devices *)
END_VAR
(*Structure Types*)
VAR
MpFileManagerUIConnect : MpFileManagerUIConnectType; (*File manager connection to the HMI*)
MpFileManagerUIConnect_FIFO : {REDUND_UNREPLICABLE} MpFileManagerUIConnectType; (*File manager connection to the HMI*)
HmiFile : FileHmiInterfaceType; (*HMI interface structure*)
PathCheck : FilePathCheckType; (*Parameter structure controlling the visible file device based on available folders*)
DirectoryData : fiDIR_READ_DATA; (*FIFO handling support reading current folder size*)
END_VAR
(*Variables*)
VAR
i : USINT; (*Index for FOR loops*)
DeviceCount : USINT; (*Counter for available file devices*)
Ident : UDINT; (*Ident of a program on target*)
IdentStatus : UINT; (*Status variable if a program exists on target*)
FolderDepthCount : USINT; (*Keeps track of the folder depth location to determine whether or not the back button should be shown*)
USBOffset : USINT := 0; (*Device list offset where to add USB device*)
MaxDeviceNameIndex : USINT; (*How many devices are configured*)
TempIdx : USINT; (*FIFO handling support index variable*)
FileNameArraySize : USINT; (*FIFO handling support size of the array*)
StartIndex : USINT; (*FIFO handling support *)
Fifo_Count : USINT; (*FIFO handling support current file count*)
END_VAR
VAR RETAIN
FifoSettingsRetain : {REDUND_UNREPLICABLE} FileHmiParaFifoType; (*Store FIFO settings in retain memory to be applied after boot*)
END_VAR
VAR
NextOpenIndex : USINT; (*Index for the next open slot in mpFileManagerUICOnnect device list which populates table*)
END_VAR
Loading

0 comments on commit 46a08fc

Please sign in to comment.