From 6bd2eda255d8323ef97e1cf9ca3c25e0e1f34d17 Mon Sep 17 00:00:00 2001 From: boccioli_m Date: Fri, 12 Jun 2015 11:46:18 +0200 Subject: [PATCH] Closedown --- plugins/TestingList.java | 12 ++++++------ script/Motor Test 3.py | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/plugins/TestingList.java b/plugins/TestingList.java index 3bf8d47..b0e0ed0 100644 --- a/plugins/TestingList.java +++ b/plugins/TestingList.java @@ -67,7 +67,7 @@ public class TestingList extends Panel { Object ret = eval("ret"); boolean status = (boolean) eval("status"); Object deviceName = eval("DEVICE"); - String sStatus = (status == true) ? "Success" : "Failed"; + String sStatus = (status == true) ? "Success" : "Failure"; if (ret != "" ) { @@ -81,7 +81,7 @@ public class TestingList extends Panel { } else{ // ret empty means that either the test script does not have variable ret, or that the script could not be started at all ret = "Could not start test script"; - sStatus = "Failed"; + sStatus = "Failure"; String[] dsDeviceName = testingList.getTestInProgress(); //SwingUtils.showException(getComponent(), ex ); //SwingUtils.showMessage(getComponent(), "", ex.toString() + deviceName[0]); @@ -96,7 +96,7 @@ public class TestingList extends Panel { } } catch (Exception ex) { String ret = "Could not start test script"; - String sStatus = "Failed"; + String sStatus = "Failure"; String[] dsDeviceName = testingList.getTestInProgress(); //SwingUtils.showException(getComponent(), ex ); SwingUtils.showMessage(getComponent(), "onExecutedFile()", ex.toString() + dsDeviceName[0]); @@ -379,7 +379,7 @@ public class TestingList extends Panel { iconSource = "/icons/button_ok-16px.png"; logger.log(Level.INFO, "Device: " + testName + "; Test: " + testName + " Result: " + res + " (" + status + ")"); break; - case "Failed": + case "Failure": iconSource = "/icons/button_close-16px.png"; logger.log(Level.SEVERE, "Device: " + testName + "; Test: " + testName + " Result: " + res + " (" + status + ")"); break; @@ -452,10 +452,10 @@ public class TestingList extends Panel { bSelected = (boolean) jTable1.getValueAt(row, COL_CHECK); if (bSelected) { sStatus = "Pending"; - iconSource = "/icons/button_pause-16px.png"; + iconSource = "/icons/button_stop-16px.png"; } else { sStatus = "Disabled"; - iconSource = "/icons/button_stop-16px.png"; + iconSource = null; } ImageIcon icon = new ImageIcon(getClass().getResource(iconSource)); jTable1.setValueAt(bSelected, row, COL_CHECK); diff --git a/script/Motor Test 3.py b/script/Motor Test 3.py index eae3f99..9afed57 100644 --- a/script/Motor Test 3.py +++ b/script/Motor Test 3.py @@ -6,7 +6,7 @@ ret = 'Test failed' status = False #TODO: Set the diplay names of positioners and detectors -scan = ManualScan(['idX', 'idInkr'], ['idMotorStatus', 'idLogicalPosition', 'idDiameter', 'idMotorPosition', 'idPotiRaw', 'idPotiProc', 'idBtvsRaw', 'idBtvsProc', 'idDiff01', 'idDiff02'] , [40.0, 0.0], [44.0, 10.0], [3000, 20]) +scan = ManualScan(['idX', 'idInkr'], ['idMotorStatus', 'idLogicalPosition', 'idDiameter', 'idMotorPosition', 'idPotiRaw', 'idPotiProc', 'idBtvsRaw', 'idBtvsProc', 'idDiff01', 'idDiff02'] , [-0.5, 0.0], [4.0, 11.0], [3000, 20]) scan.start() #Creating channels: dimension 1 @@ -51,7 +51,7 @@ for setpoint1 in range(0, 3): readback1 = setpoint1 sleep( 0.1 ) # Settling time #RegionPositioner idInkr - for setpoint2 in frange(40.0, 44.0, 1.0, True) + frange(11.0, 0.0, -1.0, True): + for setpoint2 in frange(40.0, 42.0, 1.0, True) + frange(11.0, 0.0, -1.0, True): idInkr.put(setpoint2, timeout=None) # TODO: Set appropriate timeout readback2 = idInkr.get() if abs(readback2 - setpoint2) > 0.5 : # TODO: Check accuracy