Station Component Manager
This module implements component management for stations.
- class SpsStationComponentManager(station_id, subrack_fqdns, tile_fqdns, daq_trl, sdn_first_interface, sdn_gateway, antenna_config_uri, logger, max_workers, communication_state_changed_callback, component_state_changed_callback, tile_health_changed_callback, subrack_health_changed_callback)
A component manager for a station.
- __init__(station_id, subrack_fqdns, tile_fqdns, daq_trl, sdn_first_interface, sdn_gateway, antenna_config_uri, logger, max_workers, communication_state_changed_callback, component_state_changed_callback, tile_health_changed_callback, subrack_health_changed_callback)
Initialise a new instance.
- Parameters:
station_id (
int
) – the id of this stationsubrack_fqdns (
Sequence
[str
]) – FQDNs of the Tango devices which manage this station’s subrackstile_fqdns (
Sequence
[str
]) – FQDNs of the Tango devices which manage this station’s TPMsdaq_trl (
str
) – The TRL of this Station’s DAQ Receiver.sdn_first_interface (
str
) – CIDR-style IP address with mask, for the first interface in the block assigned for science data For example, “10.130.0.1/25” means “address 10.130.0.1 on network 10.130.0.0/25”.sdn_gateway (
str
) – IP address of the SDN gateway, or None if the network has no gateway.antenna_config_uri (
Optional
[list
[str
]]) – location of the antenna mapping filelogger (
Logger
) – the logger to be used by this object.max_workers (
int
) – the maximum worker threads for the slow commands associated with this component manager.communication_state_changed_callback (
Callable
[[CommunicationStatus
],None
]) – callback to be called when the status of the communications channel between the component manager and its component changescomponent_state_changed_callback (
Callable
[...
,None
]) – callback to be called when the component state changestile_health_changed_callback (
Callable
[[str
,Optional
[HealthState
]],None
]) – callback to be called when a tile’s health changedsubrack_health_changed_callback (
Callable
[[str
,Optional
[HealthState
]],None
]) – callback to be called when a subrack’s health changed
- adc_power()
Get input RMS levels.
- apply_calibration(switch_time)
Switch the calibration bank.
(i.e. apply the calibration coefficients previously loaded by
load_calibration_coefficients()
).
- apply_pointing_delays(load_time)
Load the pointing delay at a specified time.
- property beamformer_table: list[list[int]]
Get beamformer region table.
Bidimensional array of one row for each 8 channels, with elements: 0. start physical channel 1. beam number 2. subarray ID 3. subarray_logical_channel 4. subarray_beam_id 5. substation_id 6. aperture_id
Each row is a set of 7 consecutive elements in the list.
- Returns:
list of up to 7*48 values
- board_temperature_summary()
Get summary of board temperatures.
- property channeliser_rounding: numpy.ndarray
Channeliser rounding.
Number of LS bits dropped in each channeliser frequency channel. Valid values 0-7 Same value applies to all antennas and polarizations
- Returns:
list of 512 values for each Tile, one per channel.
- clock_present_summary()
Get summary of 10 MHz clock presence.
- Return type:
- Returns:
TRUE if 10 MHz clock is present in all tiles
- configure_integrated_beam_data(integration_time, first_channel, last_channel)
Configure and start the transmission of integrated channel data.
Configure with the provided integration time, first channel and last channel. Data are sent continuously until the StopIntegratedData command is run.
- configure_integrated_channel_data(integration_time, first_channel, last_channel)
Configure and start the transmission of integrated channel data.
Configure with the provided integration time, first channel and last channel. Data are sent continuously until the StopIntegratedData command is run.
- configure_test_generator(argin)
Distribute to tiles command configure_test_generator.
- property csp_rounding: list[int] | None
CSP formatter rounding.
Rounding from 16 to 8 bits in final stage of the station beamformer, before sending data to CSP. Array of (up to) 384 values, one for each logical channel. Range 0 to 7, as number of discarded LS bits.
- Returns:
CSP formatter rounding for each logical channel.
- property forty_gb_network_address: str
Get 40Gb network address.
- Returns:
IP network address for station network
- forty_gb_network_errors()
Get summary of network errors.
- fpga_temperature_summary()
Get summary of FPGAs temperatures.
- initialise(task_callback=None)
Submit the _initialise method.
This method returns immediately after it submitted self._initialise for execution.
- property is_beamformer_running: bool
Get station beamformer state.
- Returns:
Get station beamformer state
- property is_configured: bool
Return whether this station component manager is configured.
- Returns:
whether this station component manager is configured.
- load_calibration_coefficients(calibration_coefficients)
Load calibration coefficients.
These may include any rotation matrix (e.g. the parallactic angle), but do not include the geometric delay.
- load_pointing_delays(delay_list)
Specify the delay in seconds and the delay rate in seconds/second.
The delay_array specifies the delay and delay rate for each antenna. beam_index specifies which beam is desired (range 0-47, limited to 7 in the current firmware)
- off(task_callback=None)
Submit the _off method.
This method returns immediately after it submitted self._off for execution.
- on(task_callback=None)
Submit the _on method.
This method returns immediately after it submitted self._on for execution.
- pll_locked_summary()
Get summary of PLL lock state.
- Return type:
- Returns:
TRUE if PLL locked in all tiles
- property pps_delay_corrections: list[int]
Get the PPS delay correction.
- Returns:
Array of pps delay corrections, one value per tile, in nanoseconds
- pps_delay_summary()
Get summary of PPS delays.
- property pps_delays: list[int]
Get PPS delay.
Array of one value per tile. Returns the PPS delay, Values are internally rounded to 1.25 ns steps
- Returns:
Array of one value per tile, in nanoseconds
- pps_present_summary()
Get summary of PPS presence.
- Return type:
- Returns:
TRUE if PPS is present in all tiles
- property preadu_levels: list[float]
Get attenuator level of preADU channels, one per input channel.
- Returns:
Array of one value per antenna/polarization (32 per tile)
- run_test(task_callback=None, *, count=1, test_name)
Submit the _run_test method.
This method returns immediately after it submitted self._run_test for execution.
- self_check(task_callback=None)
Submit the _self_check method.
This method returns immediately after it submitted self._self_check for execution.
- send_data_samples(argin)
Front end for send_xxx_data methods.
- set_beamformer_table(beamformer_table)
Set the frequency regions to be beamformed into a single beam.
- set_channeliser_rounding(channeliser_rounding, task_callback=None)
Set the channeliserRounding in all Tiles.
- set_csp_ingest(dst_ip, src_port, dst_port)
Configure link for CSP ingest channel.
- set_lmc_download(mode, payload_length, dst_ip, src_port=61648, dst_port=4660)
Configure link and size of LMC channel.
- set_lmc_integrated_download(mode, channel_payload_length, beam_payload_length, dst_ip='', src_port=61648, dst_port=4660)
Configure link and size of integrated LMC channel.
- Parameters:
mode (
str
) – ‘1G’ or ‘10G’channel_payload_length (
int
) – SPEAD payload length for integrated channel databeam_payload_length (
int
) – SPEAD payload length for integrated beam datadst_ip (
str
) – Destination IP, defaults to Nonesrc_port (
int
) – source port, defaults to 0xF0D0dst_port (
int
) – destination port, defaults to 4660
- Return type:
- set_power_state(power_state, fqdn=None)
Set the power_state of the component.
- TODO:
Power state should be set in the component mananger and then the device updated. Current design sets the component power state from the device component_state_changed callback. This should be corrected
- Parameters:
power_state (
PowerState
) – the value of PowerState to be set.
- Raises:
ValueError – fqdn not found
- Return type:
- standby(task_callback=None)
Submit the _standby method.
This method returns immediately after it submitted self._standby for execution.
- start_acquisition(argin, task_callback=None)
Submit the start acquisition method.
This method returns immediately after it submitted self._on for execution.
- Parameters:
argin (
str
) – json dictionary with optional keywords
start_time - (str) start time
delay - (int) delay start
- start_beamformer(start_time, duration, subarray_beam_id, scan_id)
Start the beamformer at the specified time.
- Parameters:
- Return type:
- property static_delays: list[float]
Get static time delay correction.
Array of one value per antenna/polarization (32 per tile), in range +/-124. Delay in samples (positive = increase the signal delay) to correct for static delay mismathces, e.g. cable length.
- Returns:
Array of one value per antenna/polarization (32 per tile)
- stop_data_transmission()
Stop data transmission for send_channelised_data_continuous.
- Return type:
- subscribe_to_attributes(task_callback=None, task_abort_event=None)
Subscribe to attributes of interest.
This will form subscriptions to attributes on subdevices MccsTile and MccsSubrack if attribute not already subscribed.
- sysref_present_summary()
Get summary of SYSREF presence.
- Return type:
- Returns:
TRUE if SYSREF is present in all tiles
- property test_generator_active: bool
Get test generator state.
- Returns:
True if at least one TPM uses test generator
- property test_list: list[str]
Get list of self-check tests available.
- Returns:
list of self-check tests available.
- property test_logs: str
Get logs of most recently run self-check test set.
- Returns:
logs of most recently run self-check test set.
- property test_report: str
Get report of most recently run self-check test set.
- Returns:
report of most recently run self-check test set.
- tile_programming_state()
Get TPM programming state.
- trigger_adc_equalisation(task_callback=None)
Submit the trigger adc equalisation method.
This method returns immediately after it submitted self._trigger_adc_equalisation for execution.