- General Client
- Mission Database
- TM/TC Processing
- Archive
- Link Management
- Object Storage
- File Transfer
- Time Correlation (TCO)
- Timeline
- Examples
Client¶
Note
MDBClient
instances are usually created via
YamcsClient.get_mdb()
:
from yamcs.client import YamcsClient
client = YamcsClient('localhost:8090')
mdb = client.get_mdb(instance='simulator')
# ...
- class yamcs.client.MDBClient(ctx: Context, instance: str)¶
- create_parameter(name: str, data_source: str, short_description: Optional[str] = None, long_description: Optional[str] = None, aliases: Optional[Mapping[str, str]] = None, parameter_type: Optional[str] = None) → Parameter¶
Create a parameter.
New in version 1.9.1: Compatible with Yamcs 5.8.8 onwards
- Parameters:
name –
Fully qualified name of the parameter.
Space systems that do not yet exist, will be added automatically.
data_source – Where this parameter originated. One of
TELEMETERED
,GROUND
,DERIVED
,CONSTANT
,LOCAL
,SYSTEM
,COMMAND
,COMMAND_HISTORY
.short_description – Short description (one line)
long_description – Long description (Markdown)
aliases – Aliases, keyed by namespace.
parameter_type – Qualified name of a parameter type. This is optional, but recommended. It allows specifying units, alarms and so on.
- create_parameter_type(name: str, eng_type: str, short_description: Optional[str] = None, long_description: Optional[str] = None, aliases: Optional[Mapping[str, str]] = None, unit: Optional[str] = None, signed: Optional[bool] = None, enum_values: Optional[Mapping[int, str]] = None, one_string_value: Optional[str] = None, zero_string_value: Optional[str] = None, default_alarm: Optional[RangeSet] = None, context_alarms: Optional[Mapping[str, RangeSet]] = None) → ParameterType¶
Create a parameter type.
New in version 1.9.1: Compatible with Yamcs 5.8.8 onwards
- Parameters:
name –
Fully qualified name of the parameter type.
Space systems that do not yet exist, will be added automatically.
eng_type – Engineering type. One of
float
,integer
,boolean
,binary
,string
orenumeration
.short_description – Short description (one line)
long_description – Long description (Markdown)
aliases – Aliases, keyed by namespace.
unit – Engineering unit
signed – Whether the engineering type supports signed representation. (only used with
integer
parameter types)enum_values – Enumeration labels, keyed by integer value (only used with
enumeration
parameter types)one_string_value – String representation of a boolean one. (only used with
boolean
parameter types)zero_string_value – String representation of a boolean zero. (only used with
boolean
parameter types)default_alarm – Default alarm, effective when no contextual alarm takes precedence.
context_alarms – Contextual alarms, keyed by condition.
- export_space_system(name: str) → str¶
Exports an XTCE description of a space system (XML format).
New in version 1.9.0: Compatible with Yamcs 5.8.0 onwards
- Parameters:
name – A fully-qualified XTCE name. Use
/
for root.
- get_algorithm(name: str) → Algorithm¶
Gets a single algorithm by its unique name.
- Parameters:
name – Either a fully-qualified XTCE name or an alias in the format
NAMESPACE/NAME
.
- get_command(name: str) → Command¶
Gets a single command by its unique name.
- Parameters:
name – Either a fully-qualified XTCE name or an alias in the format
NAMESPACE/NAME
.
- get_container(name: str) → Container¶
Gets a single container by its unique name.
- Parameters:
name – Either a fully-qualified XTCE name or an alias in the format
NAMESPACE/NAME
.
- get_parameter(name: str) → Parameter¶
Gets a single parameter by its name.
- Parameters:
name – Either a fully-qualified XTCE name or an alias in the format
NAMESPACE/NAME
.
- get_parameter_type(name: str) → ParameterType¶
Gets a single parameter type by its name.
New in version 1.9.1: Compatible with Yamcs 5.8.8 onwards
- Parameters:
name – Either a fully-qualified XTCE name or an alias in the format
NAMESPACE/NAME
.
- get_space_system(name: str) → SpaceSystem¶
Gets a single space system by its unique name.
- Parameters:
name – A fully-qualified XTCE name. Use
/
for root.
- list_algorithms(page_size: Optional[int] = None) → Iterable[Algorithm]¶
Lists the algorithms visible to this client.
Algorithms are returned in lexicographical order.
- list_commands(page_size: Optional[int] = None) → Iterable[Command]¶
Lists the commands visible to this client.
Commands are returned in lexicographical order.
- list_containers(page_size: Optional[int] = None) → Iterable[Container]¶
Lists the containers visible to this client.
Containers are returned in lexicographical order.
- list_parameter_types(page_size: Optional[int] = None) → Iterable[ParameterType]¶
Lists the parameter types visible to this client.
Parameter types are returned in lexicographical order.
New in version 1.9.1: Compatible with Yamcs 5.8.8 onwards
- list_parameters(parameter_type: Optional[str] = None, page_size: Optional[int] = None) → Iterable[Parameter]¶
Lists the parameters visible to this client.
Parameters are returned in lexicographical order.
- Parameters:
parameter_type – The type of parameter
- list_space_systems(page_size: Optional[int] = None) → Iterable[SpaceSystem]¶
Lists the space systems visible to this client.
Space systems are returned in lexicographical order.