Logo

Background

  • Overview

Interfaces

  • LMC to MCS
  • MCS to HPS
  • Subscription Points

Developer Guide

  • Getting Started
  • Design Notes

ska-mid-cbf-tdc-mcs API

  • Code
    • CbfComponentManager
    • CbfController
    • CbfSubarray
    • Fsp
    • PowerSwitch
    • Slim
      • Slim
      • SlimComponentManager
      • SlimLink
        • SlimLink
      • SlimLinkComponentManager
    • TalonDxLogConsumer
    • TalonBoard
    • TalonLRU
    • Vcc
ska-mid-cbf-tdc-mcs Software
  • Code
  • SLIM
  • SlimLink Class
  • Edit on GitHub

SlimLink Class

class ska_mid_cbf_tdc_mcs.slim.slim_link_device.SlimLink(cl, name)[source]

Bases: CbfDevice

TANGO device class for SLIM link device.

LRCTimeout

TANGO property

txDeviceName

Read the txDeviceName of the device.

Returns:

txDeviceName of the device.

rxDeviceName

Read the rxDeviceName of the device.

Returns:

rxDeviceName of the device.

linkName

Read the linkName of the device.

Returns:

linkName of the device.

txIdleCtrlWord

Read the txIdleCtrlWord of the device.

Returns:

txIdleCtrlWord of the device.

rxIdleCtrlWord

Read the rxIdleCtrlWord of the device.

Returns:

rxIdleCtrlWord of the device.

bitErrorRate

Read the bitErrorRate of the device.

Returns:

bitErrorRate of the device.

counters

Read the counters attribute.

Returns:

the counters array.

Return type:

list[int]

healthState

Read the Health State of the device. This overrides the ska-tango-base implementation.

Returns:

Health State of the device.

Return type:

HealthState

rxDebugAlignmentAndLockStatus

Alignment and lock status rollup attribute for debug

[0]: 66b block alignment lost. Read ‘1’ = alignment lost. Write ‘1’ to clear. [1]: 66b block aligned. Read ‘1’ = aligned. Read only. [2]: Clock data recovery lock lost. Read ‘1’ = CDR lock lost. Write ‘1’ to clear. [3]: Clock data recovery locked. Read ‘1’ = CDR locked. Read only.

:return Alignment and lock status rollup attribute of the Rx Device :rtype list[bool]

rxLinkOccupancy

Read the Link Occupancy of the Rx Device

Returns:

The Rx Link Occupancy as a percentage (0-1)

Return type:

float

txLinkOccupancy

Read the Link Occupancy of the Tx Device

Returns:

The Tx Link Occupancy as a percentage (0-1)

Return type:

float

simulationMode

Read the Simulation Mode of the device.

Returns:

Simulation Mode of the device.

create_component_manager() → SlimLinkComponentManager[source]

Create and return a component manager for this device.

Returns:

a component manager for this device

Return type:

SlimLinkComponentManager

init_command_objects() → None[source]

Sets up the command objects

class VerifyConnectionCommand(*args, component_manager: BaseComponentManager, **kwargs)[source]

Bases: CbfFastCommand

The command class for the VerifyConnection command.

Run several health checks on the SLIM Link.

is_allowed() → bool[source]
do() → tuple[ska_control_model.result_code.ResultCode, str][source]

Implement VerifyConnection command functionality.

Returns:

The HealthState enum describing the link’s status.

Return type:

(ResultCode, str)

VerifyConnection() → tuple[list[ska_control_model.result_code.ResultCode], list[str]][source]

‘VerifyConnection’ TANGO command

Parameters:

arg (DevVoid) – (not documented)

Returns:

Tuple containing a return code and a string message indicating the status of the command.

Return type:

DevVarLongStringArray

class ClearCountersCommand(*args, component_manager: BaseComponentManager, **kwargs)[source]

Bases: CbfFastCommand

The command class for the ClearCounters command.

Clear the read counters array on Tx and Rx sides of the SLIM Link.

is_allowed() → bool[source]
do() → tuple[ska_control_model.result_code.ResultCode, str][source]

Implement ClearCounters command functionality.

Returns:

A tuple containing a return code and a string message indicating status. The message is for information purpose only.

Return type:

(ResultCode, str)

ClearCounters() → tuple[list[ska_control_model.result_code.ResultCode], list[str]][source]

‘ClearCounters’ TANGO command

Parameters:

arg (DevVoid) – (not documented)

Returns:

Tuple containing a return code and a string message indicating the status of the command.

Return type:

DevVarLongStringArray

Abort() → tuple[list[ska_control_model.result_code.ResultCode], list[str]]

Abort any executing long running command(s) and empty the queue.

Returns:

A tuple containing a result code and the unique ID of the command

AbortCommands() → tuple[list[ska_control_model.result_code.ResultCode], list[str]]

Empty out long running commands in queue.

Returns:

A tuple containing a return code and a string message indicating status. The message is for information purpose only.

CheckLongRunningCommandStatus(argin: str) → str

Check the status of a long running command by ID.

Parameters:

argin – the command id

Returns:

command status

ConnectTxRx() → tuple[list[ska_control_model.result_code.ResultCode], list[str]][source]

‘ConnectTxRx’ TANGO command

Parameters:

arg (DevVoid) – (not documented)

Returns:

Tuple containing a return code and a string message indicating the status of the command.

Return type:

DevVarLongStringArray

DebugDevice() → int

Enable remote debugging of this device.

To modify behaviour for this command, modify the do() method of the command class: DebugDeviceCommand.

Returns:

the port the debugger is listening on

DeviceID

TANGO property

ExecutePendingOperations() → None

Execute any Tango operations that have been pushed on the queue.

The poll time is initially 5ms, to circumvent the problem of device initialisation, but is reset to 100ms after the first pass.

GetVersionInfo() → list[str]

Return the version information of the device.

To modify behaviour for this command, modify the do() method of the command class.

Returns:

The result code and the command unique ID

GroupDefinitions

Device property.

Each string in the list is a JSON serialised dict defining the group_name, devices and subgroups in the group. A Tango Group object is created for each item in the list, according to the hierarchy defined. This provides easy access to the managed devices in bulk, or individually.

The general format of the list is as follows, with optional devices and subgroups keys:

[ {"group_name": "<name>",
   "devices": ["<dev name>", ...]},
  {"group_name": "<name>",
   "devices": ["<dev name>", "<dev name>", ...],
   "subgroups" : [{<nested group>},
                    {<nested group>}, ...]},
  ...
  ]

For example, a hierarchy of racks, servers and switches:

[ {"group_name": "servers",
   "devices": ["elt/server/1", "elt/server/2",
                 "elt/server/3", "elt/server/4"]},
  {"group_name": "switches",
   "devices": ["elt/switch/A", "elt/switch/B"]},
  {"group_name": "pdus",
   "devices": ["elt/pdu/rackA", "elt/pdu/rackB"]},
  {"group_name": "racks",
   "subgroups": [
        {"group_name": "rackA",
         "devices": ["elt/server/1", "elt/server/2",
                       "elt/switch/A", "elt/pdu/rackA"]},
        {"group_name": "rackB",
         "devices": ["elt/server/3", "elt/server/4",
                       "elt/switch/B", "elt/pdu/rackB"],
         "subgroups": []}
   ]} ]
LoggingLevelDefault

Device property.

Default logging level at device startup. See LoggingLevel

LoggingTargetsDefault

Device property.

Default logging targets at device startup. See the project readme for details.

Off() → tuple[list[ska_control_model.result_code.ResultCode], list[str]]

Turn device off.

Returns:

A tuple containing a return code and a string message indicating status. The message is for information purpose only.

On() → tuple[list[ska_control_model.result_code.ResultCode], list[str]]

Turn device on.

Returns:

A tuple containing a return code and a string message indicating status. The message is for information purpose only.

Reset() → tuple[list[ska_control_model.result_code.ResultCode], list[str]]

Reset the device; currently unimplemented in Mid.CBF

Returns:

A tuple containing a return code and a string message indicating status. The message is for information purpose only.

SkaLevel

Device property.

Indication of importance of the device in the SKA hierarchy to support drill-down navigation: 1..6, with 1 highest.

Standby() → tuple[list[ska_control_model.result_code.ResultCode], list[str]]

Put the device into standby mode; currently unimplemented in Mid.CBF

Returns:

A tuple containing a return code and a string message indicating status. The message is for information purpose only.

TangoClassClass

alias of SlimLinkClass

TangoClassName = 'SlimLink'
adminMode

Read the Admin Mode of the device.

It may interpret the current device condition and condition of all managed

devices to set this. Most possibly an aggregate attribute.

Returns:

Admin Mode of the device

buildState

Read the Build State of the device.

Returns:

the build state of the device

commandedState

Read the last commanded operating state of the device.

Initial string is “None”. Only other strings it can change to is “OFF”, “STANDBY” or “ON”, following the start of the Off(), Standby(), On() or Reset() long running commands.

Returns:

commanded operating state string.

controlMode

Read the Control Mode of the device.

The control mode of the device are REMOTE, LOCAL Tango Device accepts only from a ‘local’ client and ignores commands and queries received from TM or any other ‘remote’ clients. The Local clients has to release LOCAL control before REMOTE clients can take control again.

Returns:

Control Mode of the device

loggingLevel

Read the logging level of the device.

Initialises to LoggingLevelDefault on startup. See LoggingLevel

Returns:

Logging level of the device.

loggingTargets

Read the additional logging targets of the device.

Note that this excludes the handlers provided by the ska_ser_logging library defaults - initialises to LoggingTargetsDefault on startup.

Returns:

Logging level of the device.

longRunningCommandResult

Read the result of the completed long running command.

Reports unique_id, json-encoded result. Clients can subscribe to on_change event and wait for the ID they are interested in.

Returns:

ID, result.

lrcFinished

Read info of the finished long running commands.

Returns:

a list of info JSON blobs of the finished long running commands.

lrcProtocolVersions

Return supported protocol versions.

Returns:

A tuple containing the lower and upper bounds of supported long running command protocol versions.

testMode

Read the Test Mode of the device.

Either no test mode or an indication of the test mode.

Returns:

Test Mode of the device

versionId

Read the Version Id of the device.

Returns:

the version id of the device

DisconnectTxRx() → tuple[list[ska_control_model.result_code.ResultCode], list[str]][source]

‘DisconnectTxRx’ TANGO command

Parameters:

arg (DevVoid) – (not documented)

Returns:

Tuple containing a return code and a string message indicating the status of the command.

Return type:

DevVarLongStringArray

Previous Next

© Copyright 2026, NRC - SKA Organization.

Built with Sphinx using a custom SKA theme based on a theme provided by Read the Docs. Creative Commons Licence
SKA developer documentation by SKA Observatory is licensed under a Creative Commons Attribution 4.0 International License .
Based on a work at github.com/ska-telescope/developer.skatelescope.org .

This work is inspired by the LSST developer guide © Copyright 2016-2018 Association of Universities for Research in Astronomy, licensed under a Creative Commons Attribution 4.0 International License .

This work is inspired by the Apache developer information Copyright © 2018 The Apache Software Foundation, Licensed under the Apache License, Version 2.0 .