V4.5
This commit is contained in:
@@ -4,7 +4,7 @@ namespace AiQ_GUI
|
||||
internal class CameraModules
|
||||
{
|
||||
// Chack camera modules are in default state according to what the diagnostics API.
|
||||
public static void CheckCamModule(Module CamMod, Label Lbl)
|
||||
public static void CheckCamModule(Module CamMod, Label Lbl, Camera CamOnTest)
|
||||
{
|
||||
if (CamMod == null || Lbl == null)
|
||||
{
|
||||
@@ -17,7 +17,21 @@ namespace AiQ_GUI
|
||||
if (CamMod.zoom != 0) // Check camera module is at full wide
|
||||
errMssg += $"Zoom not at 0 - {CamMod.zoom} ";
|
||||
|
||||
if (CamMod.firmwareVer != UniversalData.WonwooFirmware) // Check camera module firmware version is up to date.
|
||||
bool LessTanOrEqualTo = false;
|
||||
|
||||
try
|
||||
{
|
||||
LessTanOrEqualTo = Convert.ToDouble(CamMod.firmwareVer) <= Convert.ToDouble(UniversalData.WonwooFirmware);
|
||||
}
|
||||
catch
|
||||
{
|
||||
MainForm.Instance.AddToActionsList($"{CamMod.firmwareVer} or {UniversalData.WonwooFirmware} could not be converted to a double");
|
||||
}
|
||||
|
||||
if (CamOnTest.RMANum > 0 && LessTanOrEqualTo)
|
||||
errMssg += $"Firmware: {CamMod.firmwareVer} should be less than or equal to {UniversalData.WonwooFirmware} for RMA {CamOnTest.RMANum}";
|
||||
|
||||
else if ((CamOnTest.RMANum == 0 || CamOnTest.RMANum == -1) && CamMod.firmwareVer != UniversalData.WonwooFirmware)
|
||||
errMssg += $"Firmware: {CamMod.firmwareVer} should be {UniversalData.WonwooFirmware} ";
|
||||
|
||||
if (CamMod.expMode != 0) // Auto 0=0x00
|
||||
|
||||
Reference in New Issue
Block a user