Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions mitdevices/l8212.c
Original file line number Diff line number Diff line change
Expand Up @@ -217,39 +217,39 @@ static int FreqToClock(int chans, int noc, int freq_nid, int *clock)
switch (*clock) {
case 4:
if (noc > 8)
status = L8212$_FREQ_TO_HIGH;
status = L8212$_FREQ_TOO_HIGH;
break;
case 5:
if (noc > 4)
status = L8212$_FREQ_TO_HIGH;
status = L8212$_FREQ_TOO_HIGH;
break;
case 6:
if (noc > 2)
status = L8212$_FREQ_TO_HIGH;
status = L8212$_FREQ_TOO_HIGH;
break;
case 7:
if (noc > 1)
status = L8212$_FREQ_TO_HIGH;
status = L8212$_FREQ_TOO_HIGH;
break;
}
break;
case 1:
switch (*clock) {
case 4:
if (noc > 32)
status = L8212$_FREQ_TO_HIGH;
status = L8212$_FREQ_TOO_HIGH;
break;
case 5:
if (noc > 16)
status = L8212$_FREQ_TO_HIGH;
status = L8212$_FREQ_TOO_HIGH;
break;
case 6:
if (noc > 8)
status = L8212$_FREQ_TO_HIGH;
status = L8212$_FREQ_TOO_HIGH;
break;
case 7:
if (noc > 4)
status = L8212$_FREQ_TO_HIGH;
status = L8212$_FREQ_TOO_HIGH;
break;
}
break;
Expand Down
4 changes: 2 additions & 2 deletions mitdevices/mds_gendevice.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ extern int GenDeviceHeadNid();
(MSG_MASK + 2015 * MSG_FACNUM_M + 11 * MSG_MSGNUM_M + MSG_ERROR)
#define DEV$_NOT_TRIGGERED \
(MSG_MASK + 2015 * MSG_FACNUM_M + 12 * MSG_MSGNUM_M + MSG_ERROR)
#define DEV$_FREQ_TO_HIGH \
#define DEV$_FREQ_TOO_HIGH \
(MSG_MASK + 2015 * MSG_FACNUM_M + 13 * MSG_MSGNUM_M + MSG_ERROR)
#define DEV$_INVALID_NOC \
(MSG_MASK + 2015 * MSG_FACNUM_M + 14 * MSG_MSGNUM_M + MSG_ERROR)
Expand Down Expand Up @@ -134,7 +134,7 @@ int getmsg(int sts, char **facnam, char **msgnam, char **msgtext)
"unable to read start index for channel"},
{DEV$_NOT_TRIGGERED, "DEV", "NOT_TRIGGERED",
"device was not triggered, check wires and triggering device"},
{DEV$_FREQ_TO_HIGH, "DEV", "FREQ_TO_HIGH",
{DEV$_FREQ_TOO_HIGH, "DEV", "FREQ_TOO_HIGH",
"the frequency is set to high for the requested number of channels"},
{DEV$_INVALID_NOC, "DEV", "INVALID_NOC",
"the NOC (number of channels) requested is greater than the physical "
Expand Down
6 changes: 3 additions & 3 deletions mitdevices/mitdevices_messages.xml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
<status name="NOT_TRIGGERED" value="4108" severity="Error"
text="device was not triggered, check wires and triggering device"
/>
<status name="FREQ_TO_HIGH" value="4109" severity="Error"
<status name="FREQ_TOO_HIGH" value="4109" severity="Error"
text="the frequency is set to high for the requested number of channels"
/>
<status name="INVALID_NOC" value="4110" severity="Error"
Expand Down Expand Up @@ -127,7 +127,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
<status name="IO_STUCK" value ="4130" severity="Error"
text="I/O to Device is stuck. Check network connection and board status."
/>
<status name="UNKOWN_STATE" value ="4131" severity="Error"
<status name="UNKNOWN_STATE" value ="4131" severity="Error"
text="Device returned unrecognized state string"
/>
<status name="WRONG_TREE" value="4132" severity="Error"
Expand Down Expand Up @@ -466,7 +466,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
<status name="BAD_PTS" value="5051" severity="Error"
text="Invalid pts code, must be 0 .. 7"
facnam="L8212$_" facabb="L8212"/>
<status name="FREQ_TO_HIGH" value="5052" severity="Error"
<status name="FREQ_TOO_HIGH" value="5052" severity="Error"
text="Frequency to high for selected number of channels"
facnam="L8212$_" facabb="L8212"/>
<status name="INVALID_NOC" value="5053" severity="Error"
Expand Down
8 changes: 4 additions & 4 deletions mitdevices/mitdevices_msg.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
(MSG_MASK + 2015 * MSG_FACNUM_M + 11 * MSG_MSGNUM_M + MSG_ERROR)
#define DEV$_NOT_TRIGGERED \
(MSG_MASK + 2015 * MSG_FACNUM_M + 12 * MSG_MSGNUM_M + MSG_ERROR)
#define DEV$_FREQ_TO_HIGH \
#define DEV$_FREQ_TOO_HIGH \
(MSG_MASK + 2015 * MSG_FACNUM_M + 13 * MSG_MSGNUM_M + MSG_ERROR)
#define DEV$_INVALID_NOC \
(MSG_MASK + 2015 * MSG_FACNUM_M + 14 * MSG_MSGNUM_M + MSG_ERROR)
Expand Down Expand Up @@ -270,7 +270,7 @@
(MSG_MASK + 2015 * MSG_FACNUM_M + 954 * MSG_MSGNUM_M + MSG_ERROR)
#define L8212$_BAD_PTS \
(MSG_MASK + 2015 * MSG_FACNUM_M + 955 * MSG_MSGNUM_M + MSG_ERROR)
#define L8212$_FREQ_TO_HIGH \
#define L8212$_FREQ_TOO_HIGH \
(MSG_MASK + 2015 * MSG_FACNUM_M + 956 * MSG_MSGNUM_M + MSG_ERROR)
#define L8212$_INVALID_NOC \
(MSG_MASK + 2015 * MSG_FACNUM_M + 957 * MSG_MSGNUM_M + MSG_ERROR)
Expand Down Expand Up @@ -362,7 +362,7 @@ EXPORT int getmsg(int sts, char **facnam, char **msgnam, char **msgtext)
"unable to read start index for channel"},
{DEV$_NOT_TRIGGERED, "DEV", "NOT_TRIGGERED",
"device was not triggered, check wires and triggering device"},
{DEV$_FREQ_TO_HIGH, "DEV", "FREQ_TO_HIGH",
{DEV$_FREQ_TOO_HIGH, "DEV", "FREQ_TOO_HIGH",
"the frequency is set to high for the requested number of channels"},
{DEV$_INVALID_NOC, "DEV", "INVALID_NOC",
"the NOC (number of channels) requested is greater than the physical "
Expand Down Expand Up @@ -562,7 +562,7 @@ EXPORT int getmsg(int sts, char **facnam, char **msgnam, char **msgtext)
{L8212$_BAD_OFFSET, "L8212", "BAD_OFFSET",
"Invalid offset must be one of (0, -2048, -4096)"},
{L8212$_BAD_PTS, "L8212", "BAD_PTS", "Invalid pts code, must be 0 .. 7"},
{L8212$_FREQ_TO_HIGH, "L8212", "FREQ_TO_HIGH",
{L8212$_FREQ_TOO_HIGH, "L8212", "FREQ_TOO_HIGH",
"Frequency to high for selected number of channels"},
{L8212$_INVALID_NOC, "L8212", "INVALID_NOC",
"Invalid number of active channels"},
Expand Down
4 changes: 2 additions & 2 deletions pydevices/MitDevices/acq.py
Original file line number Diff line number Diff line change
Expand Up @@ -629,7 +629,7 @@ def waitftp(self):
from MDSplus.mdsExceptions import DevNOT_TRIGGERED
from MDSplus.mdsExceptions import DevIO_STUCK
from MDSplus.mdsExceptions import DevTRIGGERED_NOT_STORED
from MDSplus.mdsExceptions import DevUNKOWN_STATE
from MDSplus.mdsExceptions import DevUNKNOWN_STATE

"""Wait for board to finish digitizing and storing the data"""
state = self.getBoardState()
Expand Down Expand Up @@ -659,7 +659,7 @@ def waitftp(self):
raise DevTRIGGERED_NOT_STORED()
else:
print("ACQxxx UNKNOWN BOARD state /%s/" % (state,))
raise DevUNKOWN_STATE()
raise DevUNKNOWN_STATE()

WAITFTP = waitftp

Expand Down
2 changes: 1 addition & 1 deletion pydevices/W7xDevices/acqfmc.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ def _get_board_site(self):

def _zclk(self, mbclk_min, mbclk_max, freq):
if freq > mbclk_max:
raise MDSplus.mdsExceptions.DevFREQ_TO_HIGH()
raise MDSplus.mdsExceptions.DevFREQ_TOO_HIGH()

clkdiv = int(math.ceil(mbclk_min/freq))
mbclk = int(freq * clkdiv)
Expand Down
2 changes: 1 addition & 1 deletion pydevices/phantomhighspeed/phantom.py
Original file line number Diff line number Diff line change
Expand Up @@ -985,7 +985,7 @@ def arm(self):
if pers is not None:
stream = pers.get('stream', None)
if stream is not None:
raise MDSplus.DevUNKOWN_STATE
raise MDSplus.DevUNKNOWN_STATE
try:
self.lib.arm()
pers['stream'] = stream = self.Stream(self)
Expand Down
8 changes: 4 additions & 4 deletions python/MDSplus/tests/dcl_case.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,13 +80,13 @@ def interface(self):
self._doTCLTest('do TESTDEVICE_S:TASK_TEST')
self._doTCLTest('do TESTDEVICE_S:ACTIONSERVER:MANUAL')
self._doExceptionTest('do TESTDEVICE_I:TASK_ERROR1',
Exc.DevUNKOWN_STATE) # w/o timeout
Exc.DevUNKNOWN_STATE) # w/o timeout
self._doExceptionTest('do TESTDEVICE_S:TASK_ERROR1',
Exc.DevUNKOWN_STATE) # w/o timeout
Exc.DevUNKNOWN_STATE) # w/o timeout
self._doExceptionTest('do TESTDEVICE_I:TASK_ERROR2',
Exc.DevUNKOWN_STATE) # w/ timeout
Exc.DevUNKNOWN_STATE) # w/ timeout
self._doExceptionTest('do TESTDEVICE_S:TASK_ERROR2',
Exc.DevUNKOWN_STATE) # w/ timeout
Exc.DevUNKNOWN_STATE) # w/ timeout
self._doExceptionTest('close', Exc.TreeWRITEFIRST)
self._doTCLTest('write')
self._doTCLTest('close')
Expand Down
6 changes: 3 additions & 3 deletions python/MDSplus/tests/devices/TestDevice.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

import time
import threading
from MDSplus import Device, DevUNKOWN_STATE, Int32Array
from MDSplus import Device, DevUNKNOWN_STATE, Int32Array
from MDSplus import with_mdsrecords, mdsrecord, cached_property


Expand Down Expand Up @@ -196,8 +196,8 @@ def test(self):
return 'TEST'

def error(self):
"""Raise an DevUNKOWN_STATE exception."""
raise DevUNKOWN_STATE
"""Raise an DevUNKNOWN_STATE exception."""
raise DevUNKNOWN_STATE

def timeout(self):
"""Simulate a long running process."""
Expand Down
4 changes: 2 additions & 2 deletions python/MDSplus/tests/task_case.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@ def do(self):
self._doTCLTest(
'do TESTDEVICE:TASK_TEST', tree=tree)
self._doExceptionTest(
'do TESTDEVICE:TASK_ERROR1', Exc.DevUNKOWN_STATE, tree)
'do TESTDEVICE:TASK_ERROR1', Exc.DevUNKNOWN_STATE, tree)
self._doExceptionTest(
'do TESTDEVICE:TASK_ERROR2', Exc.DevUNKOWN_STATE, tree)
'do TESTDEVICE:TASK_ERROR2', Exc.DevUNKNOWN_STATE, tree)
self._doExceptionTest(
'do TESTDEVICE:TASK_TIMEOUT', Exc.TdiTIMEOUT, tree)

Expand Down
4 changes: 2 additions & 2 deletions treeshr/RemoteAccess.c
Original file line number Diff line number Diff line change
Expand Up @@ -1848,7 +1848,7 @@ inline static int io_open_one_remote(char *host, char *filepath,
MDS_IO_LOCK_RD | MDS_IO_LOCK_NOWAIT,
0)))
{
status = TreeEDITTING;
status = TreeEDITING;
*fd = -2;
}
}
Expand Down Expand Up @@ -1979,7 +1979,7 @@ EXPORT int MDS_IO_OPEN_ONE(char *filepath_in, char const *treename_in, int shot,
if (IS_NOT_OK(io_lock_local((fdinfo_t){conid, fd, enhanced}, 1, 1,
MDS_IO_LOCK_RD | MDS_IO_LOCK_NOWAIT, 0)))
{
status = TreeEDITTING;
status = TreeEDITING;
fd = -2;
}
}
Expand Down
2 changes: 1 addition & 1 deletion treeshr/treeshr_messages.xml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
<status name="CONGLOM_NOT_FULL" value="4133" severity="Error" text="Current conglomerate is not yet full"/>
<status name="CONTINUING" value="4396" severity="Info" text="Operation continuing: note following error"/>
<status name="DUPTAG" value="4121" severity="Error" text="Tag name already in use"/>
<status name="EDITTING" value="4146" severity="Error" text="Tree file open for edit: operation not permitted"/>
<status name="EDITING" value="4146" severity="Error" text="Tree file open for edit: operation not permitted"/>
<status name="ILLEGAL_ITEM" value="4129" severity="Error" text="Invalid item code or part number specified"/>
<status name="ILLPAGCNT" value="4122" severity="Error" text="Illegal page count, error mapping tree file"/>
<status name="INVDFFCLASS" value="4135" severity="Error" text="Invalid data fmt: only CLASS_S can have data in NCI"/>
Expand Down