Station calibrator subpackage
This subpackage implements station calibrator functionality for MCCS.
- class MccsStationCalibrator(*args, **kwargs)
An implementation of a station calibrator Tango device for MCCS.
- GetCalibration(argin)
Get a calibration from the calibration store.
- class GetCalibrationCommand(component_manager, logger=None)
Class for handling the GetCalibration() command.
This command takes as input a JSON string that conforms to the following schema:
{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://skao.int/MccsStationCalibrator_GetCalibration.json", "title": "MccsStationCalibrator GetCalibration schema", "description": "Schema for MccsStationCalibrator's GetCalibration command", "type": "object", "properties": { "frequency_channel": { "description": "Freqency channel to calibrate for", "type": "integer", "minimum": 0, "maximum": 511 } }, "required": ["frequency_channel"] }
- __init__(component_manager, logger=None)
Initialise a new instance.
- Parameters:
component_manager (
StationCalibratorComponentManager
) – the device’s component managerlogger (
Optional
[Logger
]) – a logger for this command to log with.
- do(*args, **kwargs)
Implement
MccsStationCalibrator.GetCalibration()
command.
- class InitCommand(*args, **kwargs)
A class for
MccsStationCalibrator
’s Init command.The
do()
method below is called uponMccsStationCalibrator
’s initialisation.- do(*args, **kwargs)
Initialise the attributes and properties of the MccsStationCalibrator.
- Parameters:
- Return type:
- Returns:
A tuple containing a return code and a string message indicating status. The message is for information purpose only.
- __init__(*args, **kwargs)
Initialise this device object.
- create_component_manager()
Create and return a component manager for this device.
- Return type:
- Returns:
a component manager for this device.
- class StationCalibratorComponentManager(logger, station_name, calibration_store_name, communication_state_callback, component_state_callback)
A component manager for a station calibrator.
- __init__(logger, station_name, calibration_store_name, communication_state_callback, component_state_callback)
Initialise a new instance.
- Parameters:
logger (
Logger
) – the logger to be used by this object.station_name (
str
) – the name of this calibrator’s stationcalibration_store_name (
str
) – the name of this calibrator’s calibration storecommunication_state_callback (
Callable
[[CommunicationStatus
],None
]) – callback to be called when the status of the communications channel between the component manager and its component changes.component_state_callback (
Callable
[...
,None
]) – callback to be called when the component state changes.
- get_calibration(channel)
Get a calibration from the calibration store.
- Parameters:
channel (
int
) – the frequency channel to calibrate for- Raises:
ValueError – if the outside temperature has not been read yet
- Return type:
- Returns:
A list of calibration values
- start_communicating()
Establish communication with the StationCalibrator components.
- Return type:
- class StationCalibratorHealthModel(*args, **kwargs)
A health model for a station calibrator.
At present this uses the base health model; this is a placeholder for a future, better implementation.
- Station calibrator component manager
- Station calibrator device
- Station calibrator health model