First working implementation
- Currently only with one sided gripper
This commit is contained in:
@@ -1,16 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TcPlcObject Version="1.1.0.1">
|
||||
<DUT Name="E_TransitCond" Id="{0c8e8042-17f8-4b76-ad0c-96d650245098}">
|
||||
<Declaration><![CDATA[{attribute 'qualified_only'}
|
||||
{attribute 'strict'}
|
||||
{attribute 'to_string'}
|
||||
TYPE E_TransitCond :
|
||||
(
|
||||
ALWAYS := 0,
|
||||
RESULT_OK,
|
||||
RESULT_NIO
|
||||
);
|
||||
END_TYPE
|
||||
]]></Declaration>
|
||||
</DUT>
|
||||
</TcPlcObject>
|
||||
31
PLC/POUs/Scheduler/DUTs/ST_FlowRecipe.TcDUT
Normal file
31
PLC/POUs/Scheduler/DUTs/ST_FlowRecipe.TcDUT
Normal file
@@ -0,0 +1,31 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TcPlcObject Version="1.1.0.1">
|
||||
<DUT Name="ST_FlowRecipe" Id="{3e2c2867-3147-4627-bf49-6255dbaf5310}">
|
||||
<Declaration><![CDATA[TYPE ST_FlowRecipe :
|
||||
STRUCT
|
||||
// Index in station recipe arrays
|
||||
// -1 is used to determin if the slot
|
||||
// in the product array is free.
|
||||
// The index number will automatically be
|
||||
// assigned by the FB_ProductHandler
|
||||
iProdIdx : INT := -1;
|
||||
|
||||
// Current node in flow graph
|
||||
iCurrNode : INT := 0;
|
||||
|
||||
// Next node in flow graph
|
||||
// will be set by the station after completed process
|
||||
// 0 means that there is no next node and the
|
||||
// flow recipe is finished
|
||||
iNextNode : INT := 0;
|
||||
|
||||
// Number of flow nodes
|
||||
uiNodeCnt : INT := 0;
|
||||
|
||||
// Flow nodes array
|
||||
astNodes : ARRAY[0..(GVL_Scheduler.MAX_RECIPE_NODES - 1)] OF ST_FlowRecipeNode;
|
||||
END_STRUCT
|
||||
END_TYPE
|
||||
]]></Declaration>
|
||||
</DUT>
|
||||
</TcPlcObject>
|
||||
34
PLC/POUs/Scheduler/DUTs/ST_FlowRecipeNode.TcDUT
Normal file
34
PLC/POUs/Scheduler/DUTs/ST_FlowRecipeNode.TcDUT
Normal file
@@ -0,0 +1,34 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TcPlcObject Version="1.1.0.1">
|
||||
<DUT Name="ST_FlowRecipeNode" Id="{ceb8b626-8a65-4e92-9344-14e330b6c8bd}">
|
||||
<Declaration><![CDATA[TYPE ST_FlowRecipeNode :
|
||||
STRUCT
|
||||
// Priority for transportation after completed node
|
||||
uiPriority : UINT := 100;
|
||||
|
||||
// Required capabilities
|
||||
dwReqCap : DWORD := 0;
|
||||
|
||||
// How many retries are allowed of this node
|
||||
uiMaxRetries : UINT := 0;
|
||||
|
||||
// Current numbers of retries of this node
|
||||
uiCurrRetries : UINT := 0;
|
||||
|
||||
// Was the current process successfull
|
||||
xSuccess : BOOL := FALSE;
|
||||
|
||||
// Transition to node when operation ok
|
||||
iNextNodeSuccess : INT := -1;
|
||||
|
||||
// Transition to node when retrying
|
||||
iNextNodeRetry : INT := -1;
|
||||
|
||||
// Transition to node when operation failed
|
||||
// or max retries reached
|
||||
iNextNodeFail : INT := -1;
|
||||
END_STRUCT
|
||||
END_TYPE
|
||||
]]></Declaration>
|
||||
</DUT>
|
||||
</TcPlcObject>
|
||||
@@ -1,14 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TcPlcObject Version="1.1.0.1">
|
||||
<DUT Name="ST_Recipe" Id="{3e2c2867-3147-4627-bf49-6255dbaf5310}">
|
||||
<Declaration><![CDATA[TYPE ST_Recipe :
|
||||
STRUCT
|
||||
uiRecipeID : UINT;
|
||||
uiStartNode : UINT := 0;
|
||||
uiNodeCnt : UINT := 0;
|
||||
astNodes : ARRAY[0..(GVL_Scheduler.MAX_RECIPE_NODES - 1)] OF ST_RecipeNode;
|
||||
END_STRUCT
|
||||
END_TYPE
|
||||
]]></Declaration>
|
||||
</DUT>
|
||||
</TcPlcObject>
|
||||
@@ -1,19 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TcPlcObject Version="1.1.0.1">
|
||||
<DUT Name="ST_RecipeNode" Id="{ceb8b626-8a65-4e92-9344-14e330b6c8bd}">
|
||||
<Declaration><![CDATA[TYPE ST_RecipeNode :
|
||||
STRUCT
|
||||
uiNodeID : UINT;
|
||||
// Required capabilities
|
||||
dwReqCap : DWORD;
|
||||
|
||||
// Transition count
|
||||
uiTransCnt : UINT;
|
||||
|
||||
// Transitions
|
||||
astTransitions : ARRAY[0..(GVL_Scheduler.MAX_STATIONS - 1)] OF ST_Transition;
|
||||
END_STRUCT
|
||||
END_TYPE
|
||||
]]></Declaration>
|
||||
</DUT>
|
||||
</TcPlcObject>
|
||||
@@ -4,21 +4,19 @@
|
||||
<Declaration><![CDATA[TYPE ST_TransJob :
|
||||
STRUCT
|
||||
// Station to pick from
|
||||
uiFromNodeID : UINT;
|
||||
// Station to put into
|
||||
uiToNodeID : UINT;
|
||||
// Static priority from recipe
|
||||
iStatPrio : INT;
|
||||
// Dynamic priority from process
|
||||
iDynPrio : INT;
|
||||
// Prio sum
|
||||
iSumPrio : INT;
|
||||
// Time this job was created
|
||||
// The older the job the higher the priority
|
||||
uliTimeCreated : ULINT;
|
||||
uiFromStation : UINT;
|
||||
|
||||
// Is this job in the queue still valid
|
||||
xValid : BOOL := TRUE;
|
||||
// Station to put into
|
||||
uiToStation : UINT;
|
||||
|
||||
// Handle from reserved source station
|
||||
uiFromStationHandle : UINT;
|
||||
|
||||
// Handle from reserved target station
|
||||
uiToStationHandle : UINT;
|
||||
|
||||
// Static priority from recipe
|
||||
uiPrio : UINT;
|
||||
END_STRUCT
|
||||
END_TYPE
|
||||
]]></Declaration>
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TcPlcObject Version="1.1.0.1">
|
||||
<DUT Name="ST_Transition" Id="{7b8c5232-d3a6-4d0b-b8ad-e54400018d53}">
|
||||
<Declaration><![CDATA[TYPE ST_Transition :
|
||||
STRUCT
|
||||
eCondition : E_TransitCond;
|
||||
uiNextNodeID : UINT;
|
||||
END_STRUCT
|
||||
END_TYPE
|
||||
]]></Declaration>
|
||||
</DUT>
|
||||
</TcPlcObject>
|
||||
Reference in New Issue
Block a user