ska_tmc_cspmasterleafnode.manager package
Submodules
ska_tmc_cspmasterleafnode.manager.component_manager module
This module implements ComponentManager class for the CSP Controller leaf node.
- class ska_tmc_cspmasterleafnode.manager.component_manager.CspMLNComponentManager(*args: Any, **kwargs: Any)
Bases:
TmcLeafNodeComponentManager
A component manager for The CSP Controller leaf node component.
It supports in controlling the behaviour of CSP Master.
- check_if_csp_master_is_responsive() None
Checks if Csp Master device is responsive.
- property csp_master_device_name: str
Returns device name for the CSP Master Device.
- get_attribute_dict() dict
Returns the common attribute dictionary for all component types.
- Returns:
Dictionary of common attributes to be handled by the EventReceiver.
- get_device() ska_tmc_common.DeviceInfo
- handle_admin_mode_event(event: tango.EventType.CHANGE_EVENT) None
Handle CSP controller change event
- is_command_allowed(command_name: str) bool
Checks whether this command is allowed. It checks that the device is in the right state to execute this command and that all the components needed for the operation are not unresponsive.
- Returns:
True if this command is allowed
- Return type:
boolean
- is_event_failed(event) bool
Check if event failed
- off(task_callback)
Empty method for resolving lint issue
- off_command(task_callback: ska_tango_base.base.TaskCallbackType) Tuple[ska_tango_base.executor.TaskStatus, str]
Submits the Off command for execution.
- Return type:
tuple
- on(task_callback)
Empty method for resolving lint issue
- on_command(task_callback: ska_tango_base.base.TaskCallbackType) Tuple[ska_tango_base.executor.TaskStatus, str]
Submits the On command for execution.
- Return type:
tuple
- standby(task_callback)
Empty method for resolving lint issue
- standby_command(task_callback: ska_tango_base.base.TaskCallbackType) Tuple[ska_tango_base.executor.TaskStatus, str]
Submits the Standby command for execution.
- Return type:
tuple
- start_communicating()
Empty method for resolving lint issue
- stop_communicating()
Empty method for resolving lint issue
- update_device_admin_mode(device_name: str, admin_mode: ska_control_model.AdminMode) None
Update a monitored device admin mode, and call the relative callbacks if available :param device_name: Name of the device on which admin mode is updated :type device_name: str :param admin_state: admin mode of the device :type admin_mode: AdminMode
- update_exception_for_unresponsiveness(device_info: ska_tmc_common.DeviceInfo, exception: str) None
Set a device to failed and call the relative callback if available :param device_info: a device info :type device_info: DeviceInfo :param exception: an exception :type: Exception
- update_responsiveness_info(device_name: str) None
Update a device with the correct availability information.
- Parameters:
dev_name (str) – name of the device
Module contents
Init file for CSP Controller leaf node Manager.
- class ska_tmc_cspmasterleafnode.manager.CspMLNComponentManager(*args: Any, **kwargs: Any)
Bases:
TmcLeafNodeComponentManager
A component manager for The CSP Controller leaf node component.
It supports in controlling the behaviour of CSP Master.
- check_if_csp_master_is_responsive() None
Checks if Csp Master device is responsive.
- property csp_master_device_name: str
Returns device name for the CSP Master Device.
- get_attribute_dict() dict
Returns the common attribute dictionary for all component types.
- Returns:
Dictionary of common attributes to be handled by the EventReceiver.
- get_device() ska_tmc_common.DeviceInfo
- handle_admin_mode_event(event: tango.EventType.CHANGE_EVENT) None
Handle CSP controller change event
- is_command_allowed(command_name: str) bool
Checks whether this command is allowed. It checks that the device is in the right state to execute this command and that all the components needed for the operation are not unresponsive.
- Returns:
True if this command is allowed
- Return type:
boolean
- is_event_failed(event) bool
Check if event failed
- off(task_callback)
Empty method for resolving lint issue
- off_command(task_callback: ska_tango_base.base.TaskCallbackType) Tuple[ska_tango_base.executor.TaskStatus, str]
Submits the Off command for execution.
- Return type:
tuple
- on(task_callback)
Empty method for resolving lint issue
- on_command(task_callback: ska_tango_base.base.TaskCallbackType) Tuple[ska_tango_base.executor.TaskStatus, str]
Submits the On command for execution.
- Return type:
tuple
- standby(task_callback)
Empty method for resolving lint issue
- standby_command(task_callback: ska_tango_base.base.TaskCallbackType) Tuple[ska_tango_base.executor.TaskStatus, str]
Submits the Standby command for execution.
- Return type:
tuple
- start_communicating()
Empty method for resolving lint issue
- stop_communicating()
Empty method for resolving lint issue
- update_device_admin_mode(device_name: str, admin_mode: ska_control_model.AdminMode) None
Update a monitored device admin mode, and call the relative callbacks if available :param device_name: Name of the device on which admin mode is updated :type device_name: str :param admin_state: admin mode of the device :type admin_mode: AdminMode
- update_exception_for_unresponsiveness(device_info: ska_tmc_common.DeviceInfo, exception: str) None
Set a device to failed and call the relative callback if available :param device_info: a device info :type device_info: DeviceInfo :param exception: an exception :type: Exception
- update_responsiveness_info(device_name: str) None
Update a device with the correct availability information.
- Parameters:
dev_name (str) – name of the device
- class ska_tmc_cspmasterleafnode.manager.CspMLNComponentManagerMid(*args: Any, **kwargs: Any)
Bases:
CspMLNComponentManager
A component manager for The CSP Controller leaf node Mid component.
- clear_load_dish_cfg_attributes()
Clear all load dish cfg attribute after command completes
- get_attribute_dict() dict
Extends the common attribute dictionary with mid-specific attributes.
- Returns:
Dictionary of attributes to be handled by the EventReceiver.
- get_load_dish_cfg_result() None
Return Load Dish Cfg command result
- handle_dish_vcc_config_callback(event) None
Handle dish vcc config attribute change event
- handle_lrcr_callback(event) None
Event for LongRunning Command Result
- handle_source_dish_vcc_config_callback(event) None
Handle source dish vcc config attribute change event
- is_dish_vcc_config_valid() Tuple[bool, str]
Validate the sent dish VCC config and source dish VCC config match with received dish VCC config and source dish VCC config.
- Returns:
A tuple of boolean indicating validation success and an error message if any
- load_dish_cfg_command(argin: str, task_callback: Optional[Callable[[ska_tango_base.executor.TaskStatus, str], None]] = None) Tuple[ska_tango_base.executor.TaskStatus, str]
Submits the LoadDishCfg command for execution.
- Parameters:
argin – JSON string containing dish VCC configuration parameters
task_callback – Optional. Callback function for task completion
- Returns:
A tuple of TaskStatus and a response message
- start_dish_vcc_validation() None
Create Dish Vcc validation manager object and call validate method.
- update_command_result(dev_name: str, value: Tuple[str, str]) None
Updates the long running command result callback
- update_dish_vcc_map_validation_result(value: ska_tango_base.commands.ResultCode) None
Update dish vcc map validation result :param value: ResultCode value to be updated :param type: ResultCode Enum