diff --git a/Client/View/NcWindow.cs b/Client/View/NcWindow.cs index 18335853..f55d6477 100644 --- a/Client/View/NcWindow.cs +++ b/Client/View/NcWindow.cs @@ -207,7 +207,7 @@ namespace Active_Client.View //Add arguments if is Fanuc NC if (Config.VendorHmiConfig.Type == 1) - ncprocess.StartInfo.Arguments = "/H=" + Config.VendorHmiConfig.IpAddress + ":" + Config.VendorHmiConfig.Port + "/T=5"; + ncprocess.StartInfo.Arguments = "/H=" + Config.VendorHmiConfig.IpAddress + ":" + Config.VendorHmiConfig.Port + "/T=30"; //Start the Process ncprocess.Start(); diff --git a/Libs/CMS_CORE_Library.dll b/Libs/CMS_CORE_Library.dll index 6ff0fcc5..0e86a86a 100644 Binary files a/Libs/CMS_CORE_Library.dll and b/Libs/CMS_CORE_Library.dll differ diff --git a/Step.Config/Config/serverConfig.xml b/Step.Config/Config/serverConfig.xml index 899c45be..ec14f78a 100644 --- a/Step.Config/Config/serverConfig.xml +++ b/Step.Config/Config/serverConfig.xml @@ -11,6 +11,7 @@ 01/01/2019 false false + false false diff --git a/Step.Config/Config/serverConfigValidator.xsd b/Step.Config/Config/serverConfigValidator.xsd index 633994fc..3348c807 100644 --- a/Step.Config/Config/serverConfigValidator.xsd +++ b/Step.Config/Config/serverConfigValidator.xsd @@ -16,6 +16,7 @@ + diff --git a/Step.Config/ServerConfigController.cs b/Step.Config/ServerConfigController.cs index 70aefd4b..27588ee3 100644 --- a/Step.Config/ServerConfigController.cs +++ b/Step.Config/ServerConfigController.cs @@ -283,7 +283,8 @@ namespace Step.Config SharedName = x.Element("sharedName").Value, InstallationDate = x.Element("installationDate").Value, MgiOption = Convert.ToBoolean(x.Element("mgiOption").Value), - SiemensKeyboardOption = Convert.ToBoolean(x.Element("siemensKeyboardOption").Value) + SiemensKeyboardOption = Convert.ToBoolean(x.Element("siemensKeyboardOption").Value), + MachineNumberHasLetters = Convert.ToBoolean(x.Element("machineNumberHasLetters").Value) }).FirstOrDefault(); // Read Prod Software Config with LINQ diff --git a/Step.Model/ConfigModels/NcConfigModel.cs b/Step.Model/ConfigModels/NcConfigModel.cs index e8324679..8bc31a22 100644 --- a/Step.Model/ConfigModels/NcConfigModel.cs +++ b/Step.Model/ConfigModels/NcConfigModel.cs @@ -6,7 +6,7 @@ using System.Threading.Tasks; namespace Step.Model.ConfigModels { - public class NcConfigModel + public class NcConfigModel { public string NcVendor { get; set; } public bool ShowNcHMI { get; set; } @@ -19,5 +19,6 @@ namespace Step.Model.ConfigModels public string InstallationDate { get; set; } public bool MgiOption { get; set; } public bool SiemensKeyboardOption { get; set; } + public bool MachineNumberHasLetters { get; set; } } } diff --git a/Step.Model/ConfigModels/ServerConfigModel.cs b/Step.Model/ConfigModels/ServerConfigModel.cs index ca5f6c7b..ac5a3920 100644 --- a/Step.Model/ConfigModels/ServerConfigModel.cs +++ b/Step.Model/ConfigModels/ServerConfigModel.cs @@ -23,7 +23,5 @@ namespace Step.Model.ConfigModels public int MaxAlarmsRows { get; set; } public int AlarmToDelete { get; set; } - - public bool SiemensKeyboardOption { get; set; } } } \ No newline at end of file diff --git a/Step.Model/Constants.cs b/Step.Model/Constants.cs index 59beb2d6..27b044f9 100644 --- a/Step.Model/Constants.cs +++ b/Step.Model/Constants.cs @@ -21,9 +21,18 @@ namespace Step.Model { BUTTON = 0, IMAGE = 1, - INPUT = 2 + INPUT = 2, + PROGRESS_BAR = 3, + LABEL = 4, + NEGATE_IMAGE = 5 } + public struct SCADA_ACTION + { + public static string READ = "read"; + public static string WRITE = "write"; + } + public const int MIN_CMS_ROLE = 100; public const int MIN_ADMIN_ROLE = 30; diff --git a/Step.NC/NcAdapter.cs b/Step.NC/NcAdapter.cs index 4e56bc0d..5e970e30 100644 --- a/Step.NC/NcAdapter.cs +++ b/Step.NC/NcAdapter.cs @@ -218,7 +218,7 @@ namespace Step.NC genericData.NcModel = tmpInfo; // Get machine number - cmsError = numericalControl.NC_RMachineNumber(ref tmpInfo); + cmsError = numericalControl.NC_RMachineNumber(NcConfig.MachineNumberHasLetters, ref tmpInfo); if (cmsError.errorCode != 0) return cmsError; @@ -1005,8 +1005,11 @@ namespace Step.NC } public CmsError ReadScadaData(ScadaSchemaModel scadaSchema, out DTOScadaModel scadaValue) - { - CmsError cmsError = NO_ERROR; + { + ReadScadaDataSiemens(scadaSchema, out scadaValue); + + return NO_ERROR; + CmsError cmsError = NO_ERROR; scadaValue = new DTOScadaModel() { Id = scadaSchema.Id, @@ -1267,14 +1270,14 @@ namespace Step.NC // Read Machine ID string strMachNumber = "0"; - CmsError cmsError = numericalControl.NC_RMachineNumber(ref strMachNumber); + CmsError cmsError = numericalControl.NC_RMachineNumber(NcConfig.MachineNumberHasLetters, ref strMachNumber); if (cmsError.IsError()) return cmsError; SupportFunctions.ConvertStringMachineNumberIntoNumber(strMachNumber, out bool containsLetters, out int machNumber); // Read Data from NC & elaborate it - long NcCandy = 0; + long NcCandy = 0; cmsError = numericalControl.PLC_RCandy(ref NcCandy); if (cmsError.IsError()) return cmsError; @@ -1298,7 +1301,7 @@ namespace Step.NC return cmsError; // Manage Expired Lincense Bit - if(CandiesController.ElaborateExpiredBit(newDate, bNcCandy, out bool bNewCandy)) + if(CandiesController.ElaborateExpiredBit(newDate, bNcCandy, out bool bNewCandy)) { //Write Expired Lincense Bit on NC cmsError = numericalControl.PLC_WExpiredCandy(bNewCandy);