## Automatic Guides - Micromeccanica Motors *** ### Areas / Zones The areas were defined as: * Area 1: Right guides - 8 motors * Area 2: Left guides - 8 motors So at the change over the 2 Boxes divide the load, controlling 4 motors each. After the Right ( Area 1) guides finish the changeover the Left ( Area 2 ) start the changeover. ### The Panel has 2 connections with the PLC ![[Pasted image 20231002161035.png]] ![[Pasted image 20231002163806.png]] ![[Pasted image 20231002164144.png]] This connections work with differents DBs for the mailbox. For this reason there are some point on the FC1020 that we need to control the response on the two mailboxs. This is because if the command is sent by the PLC with: ```pascal "DB Collegamento HMI".OrdineControllo."Numero ordine" := 70; ``` The state used by the panel is the DB10, but if the command to read the recipe is started by the panel by the RecipeViewSetDataRecordToPLC function the status is sent to the connection HMI_Guide on DB1051 as defined on the Recipes 4..34. For this reason we created this in/out variables that are connected with the DB10 - HMI: ```pascal #HMIGlobal_SetDati_Stato <= "DB HMI".DBW_30 #HMIGlobal_SetDati_ActualSet <= "DB HMI".DBW_32 #HMIGlobal_SetDati_Stato <=> "DB HMI".DBW_36 ``` ### The 30 Recipes for the Guides This recipes are managed by the Panel as Recipes 4 to 34. So the Recipe 1 internally is the 4 and so on. For this was added 3 ( #NrFirst_FormatRecipe) to the actual selected RecipeNumber: ```pascal FC1020 - Line 17 "DB FormatPar".nRecipeToLoadManually := "DB FormatPar".nShowedRecipeNumber + #NrFirst_FormatRecipe; ``` ### For the change over Remote on the Guides we added: (not tested) ```pascal FC1004 - Line 33 IF (NOT "DB Remote Control DB".RD.CtrlWord."Bit_0 ChangeOverRequest") THEN "DB Remote Control DB".RD.CtrlWord."Bit_0 ChangeOverRequest":= "DB HMI Recipe Pack".Delay_Cambio; END_IF; ``` ```pascal FC1035 - line 17 IF "rtRemoteChangeOverRequest".Q THEN "DB Cycle".nAutoStat := 3; // Idle "DB Remote Control DB".RD.CtrlWord."Bit_0 ChangeOverRequest" := FALSE; END_IF; ``` So we simulate the Start signal after the Pack format changed. This signal is reset after the Start timer is done.