MCCS Master Leaf Node

class tmcprototype.mccsmasterleafnode.src.mccsmasterleafnode.mccs_master_leaf_node.MccsMasterLeafNode(*args, **kwargs)

Properties:

  • MccsMasterFQDN - Property to provide FQDN of MCCS Master Device

Attributes:

  • mccsHealthState - Forwarded attribute to provide MCCS Master Health State
  • activityMessage - Attribute to provide activity message
AssignResources(argin)

Invokes AssignResources command on Mcccs Master

class AssignResourcesCommand(*args, **kwargs)

A class for MccsMasterLeafNode’s AssignResources() command.

allocate_ended(event)

Callback function immediately executed when the asynchronous invoked command returns.

Parameters:

event – a CmdDoneEvent object. This class is used to pass data to the callback method in asynchronous callback model for command execution.

Type:

CmdDoneEvent object It has the following members:

  • device : (DeviceProxy) The DeviceProxy object on which the call was executed.
  • cmd_name : (str) The command name
  • argout_raw : (DeviceData) The command argout
  • argout : The command argout
  • err : (bool) A boolean flag set to true if the command failed. False otherwise
  • errors : (sequence<DevError>) The error stack
  • ext
Returns:

none

Raises:

DevFailed if this command is not allowed to be run

in current device state

check_allowed()

Checks whether the command is allowed to be run in the current state

Returns:True if this command is allowed to be run in current device state
Return type:boolean
Raises:DevFailed if this command is not allowed to be run in current device state
do(argin)

It accepts stationiDList list, channels and stationBeamiDList in JSON string format and invokes allocate command on MccsMaster with JSON string as an input argument.

:param argin:StringType. The string in JSON format.

Example: {

“subarray_id”: 1, “station_ids”: [1,2], “channels”: [1,2,3,4,5,6,7,8], “station_beam_ids”: [1], “tile_ids”: [1,2,3,4]

}

Returns:None

Note: Enter the json string without spaces as an input.

Raises:ValueError if input argument json string contains invalid value KeyError if input argument json string contains invalid key DevFailed if the command execution is not successful
class InitCommand(*args, **kwargs)

A class for the TMC MCCS Master Leaf Node’s init_device() method.

do()

Initializes the attributes and properties of the MccsMasterLeafNode.

Returns:A tuple containing a return code and a string message indicating status. The message is for information purpose only.
Return type:(ResultCode, str)
Raises:DevFailed if error occurs while creating the device proxy for Mccs Master or subscribing the evennts.
MccsMasterFQDN

Used by autodoc_mock_imports.

class OffCommand(*args, **kwargs)

A class for MccsMasterLeafNode’s Off() command.

do()

Invokes Off command on the MCCS Element.

Parameters:argin – None.
Returns:A tuple containing a return code and a string message indicating status. The message is for information purpose only.
Return type:(ResultCode, str)
off_cmd_ended_cb(event)

Callback function immediately executed when the asynchronous invoked command returns.

Parameters:

event – a CmdDoneEvent object. This class is used to pass data to the callback method in asynchronous callback model for command execution.

Type:

CmdDoneEvent object It has the following members:

  • device : (DeviceProxy) The DeviceProxy object on which the call was executed.
  • cmd_name : (str) The command name
  • argout_raw : (DeviceData) The command argout
  • argout : The command argout
  • err : (bool) A boolean flag set to true if the command failed. False otherwise
  • errors : (sequence<DevError>) The error stack
  • ext
Returns:

none

class OnCommand(*args, **kwargs)

A class for MccsMasterLeafNode’s On() command.

do()

Invokes On command on the MCCS Element.

Parameters:argin – None
Returns:A tuple containing a return code and a string message indicating status. The message is for information purpose only.
Return type:(ResultCode, str)
on_cmd_ended_cb(event)

Callback function immediately executed when the asynchronous invoked command returns.

Parameters:

event – a CmdDoneEvent object. This class is used to pass data to the callback method in asynchronous callback model for command execution.

Type:

CmdDoneEvent object It has the following members:

  • device : (DeviceProxy) The DeviceProxy object on which the call was executed.
  • cmd_name : (str) The command name
  • argout_raw : (DeviceData) The command argout
  • argout : The command argout
  • err : (bool) A boolean flag set to true if the command failed. False otherwise
  • errors : (sequence<DevError>) The error stack
  • ext
Returns:

none

ReleaseResources()

Invokes ReleaseResources command on MccsMasterLeafNode

class ReleaseResourcesCommand(*args, **kwargs)

A class for MccsMasterLeafNode’s ReleaseResources() command.

check_allowed()

Checks whether the command is allowed to be run in the current state

Returns:True if this command is allowed to be run in current device state
Return type:boolean
Raises:DevFailed if this command is not allowed to be run in current device state
do()

It invokes ReleaseResources command on MccsMaster and releases all the resources assigned to MccsMaster.

Returns:None.
Raises:DevFailed if the command execution is not successful
releaseresources_cmd_ended_cb(event)

Callback function immediately executed when the asynchronous invoked command returns.

Parameters:

event – a CmdDoneEvent object. This class is used to pass data to the callback method in asynchronous callback model for command execution.

Type:

CmdDoneEvent object It has the following members:

  • device : (DeviceProxy) The DeviceProxy object on which the call was executed.
  • cmd_name : (str) The command name
  • argout_raw : (DeviceData) The command argout
  • argout : The command argout
  • err : (bool) A boolean flag set to true if the command failed. False otherwise
  • errors : (sequence<DevError>) The error stack
  • ext
Returns:

none

activityMessage

Used by autodoc_mock_imports.

always_executed_hook()

Internal construct of TANGO.

delete_device()

Internal construct of TANGO.

init_command_objects()

Initialises the command handlers for commands supported by this device.

is_AssignResources_allowed()

Checks whether the command is allowed to be run in the current state

Returns:True if this command is allowed to be run in current device state
Return type:boolean
is_ReleaseResources_allowed()

Checks whether the command is allowed to be run in the current state

Returns:True if this command is allowed to be run in current device state
Return type:boolean
mccsHealthState

Used by autodoc_mock_imports.

read_activityMessage()
validate_obs_state()
write_activityMessage(value)
tmcprototype.mccsmasterleafnode.src.mccsmasterleafnode.mccs_master_leaf_node.main(args=None, **kwargs)

Runs the MccsMasterLeafNode.

Parameters:
  • args – Arguments internal to TANGO
  • kwargs – Arguments internal to TANGO
Returns:

An object of CompletedProcess class returned by the subprocess.