Gateway Usage and Examples
In this paragraph, we will describe how users can interface with the evltgw for the following functionalities:
Forward commands from ELT INSSW to the telescope
Forward commands from VLT INSSW to an ELT component
Retrieval of telescope fits header and binary tables
Providing the TCS state either with PUB/SUB or REQ/REP
The following functionalities will not be addressed as they do not require any interaction between end users and evltgw:
Forward updates of the VLT OLDB telescope data point to its ELT OLDB counterpart
Forward updates of configurable ELT OLDB data points to their VLT OLDB counterparts
Instrument alarms forwarding
Telemetry data and log ingestion in datalab
Sending commands to the ELT gateway
A client sends commands to the ELT gateway using the MAL gateway interface as specified in MAL ICD. Commands can be sent either from the command line or from a python, C++ or java application. This requires to install the gateway project on the client machine as defined in build.
Commands are sent to a service whose location is specified with: zpb.rr://mal.container_uri/service_name
mal.container_uri will contain the host and port where services are running. It can be done by hard-coding the uri of the gateway mal interface or by querying consul to get the location of the consul service named evltgw-services-rep.
service name is the name of a service that will expose one of the interface defined in MAL ICD. It will be one of the following:
vlt: service to send client specified VLT commands. This service exposes the MalVLT interface.
async_vlt: same as before but for asynchronous requests.
elt: service for component registration. This service exposes the MalELT interface.
async_elt: same as before but for asynchronous requests.
presetting: service that exposes the MalTCSPresetting interface.
tracking: service that exposes the MalTCSTracking interface.
autoguiding: service that exposes the MalTCSAutoGuiding interface.
active_optics: service that exposes the MalTCSActiveOptics interface.
enclosure: service that exposes the MalTCSEnclosure interface.
optics_control: service that exposes the MalTCSOpticsControl interface.
mode_switching: service that exposes the MalTCSModeSwitching interface.
tcsmaintenance: service that exposes the MalTCSMaintenance interface.
Command line
One possibility to send commands from the command line is to use the msgsend utility:
msgsend -u zpb.rr://mal.container_uri/service_name service_method method_parameters
Components are:
mal.container_uri: it can be obtained with: geturi “evltgw-services-rep”
service name is one of the service defined in Sending commands to the ELT gateway.
service_method specifies the command to be executed. It will follow this pattern:
::eltgw::mal::interface name::method name,interface name and method name being one of the interface and methods specified in MAL ICD.
method_parameters will contain all the selected method parameters as specified in MAL ICD.
Below two examples:
sending a tcs command (Note: string are enclosed in ‘” “’):
msgsend -u zpb.rr://192.168.56.202:8081/vlt ::eltgw::mal::MalVLT::send ‘“wxxtcs”’ ‘“tifNA”’ ‘“STATUS”’ ‘“xxx”’ 10.0
sending an offset command:
msgsend -u zpb.rr://192.168.56.202:8081/tracking ::eltgw::mal::MalTCSTracking::offsaa 1.0 2.0
Python
The following conveniency classes have been implemented to instantiate gateway services clients that will send requests to services.
MalVLTSyncClientFactory to create client of the vlt service for custom commands,
MalTCSPresettingSyncClientFactory to create clients of the presetting service,
MalTCSTrackingSyncClientFactory to create clients of the tracking service,
MalTCSAutoGuidingSyncClientFactory to create clients of the autoguiding service,
MalTCSActiveOpticsSyncClientFactory to create clients of the active optics service,
MalTCSEnclosureSyncClientFactory to create clients of the enclosure service,
MalTCSOpticsControlSyncClientFactory to create clients of the optics control service,
MalTCSModeSwitchingSyncClientFactory to create clients of the mode switching service,
MalTCSMaintenanceSyncClientFactory to create clients of the maintenance service.
They are defined in the eltGW.eltgw_mal module and provide a method named create that takes as a parameter the location of the targeted mal service. It will return an instance of a class implemeting one of the interface as specified in MAL ICD. For instance, to send an offset command to the telescope, we proceed as follows:
import json
import requests
import socket
import sys
from eltGW.eltgw_mal import MalTCSTrackingSyncClientFactory
TIMEOUT_SEC = 10
if __name__ == "__main__":
# querying consul to get location of evltgw-services-rep
host_name = socket.gethostname()
response = requests.get("http://{}:8500/v1/catalog/service/evltgw-services-rep".format(host_name))
if response.status_code != 200:
print("Could not get data from consul")
sys.exit(-1)
service_dict = json.loads(response.content)
service_addr = service_dict[0]['ServiceTaggedAddresses']['lan_ipv4']['Address']
service_port = service_dict[0]['ServiceTaggedAddresses']['lan_ipv4']['Port']
# instantiate a tracking service client to send an offset command
tcs_tracking_service_uri = "zpb.rr://{}:{}/tracking".format(service_addr, service_port)
tracking_client = MalTCSTrackingSyncClientFactory.create(tcs_tracking_service_uri, TIMEOUT_SEC)
reply = tracking_client.offsaa(1.0, 2.0)
print(reply)
C++
The first step is to define dependencies to mal and the gateway project icd. At the project level, a waf script will look as follows
import os
from wtools import project
from wtools.project import declare_project
from waflib.Build import BuildContext
def configure(cnf):
cnf.check_wdep(wdep_name='evltgw.eltGW.icd-cxx', uselib_store='eltGW-icd', mandatory=True)
cnf.check_wdep(wdep_name='cii.mal.cpp.mal', uselib_store='cii-mal', mandatory=True)
project.declare_project(name='evltgw_client', version='1.0-dev', requires='cxx python java cii boost',
boost_libs='log log_setup thread system chrono program_options',
recurse="cpp-client python-client")
At the module model, we will have such a wscript
from wtools.module import declare_cprogram
declare_cprogram(target='cpp-client', use='BOOST eltGW-icd cii-mal cpp-netlib-uri ')
Finally, in the application, we will use the cii factory and the targeted service url to send commands. Below an example of an application sending altitude and azimuth offset commands to the tracking service:
#include <iostream> #include <mal/Cii.hpp> #include <mal/utility/LoadMal.hpp> #include <mal/rr/qos/ReplyTime.hpp> #include "MalVLTServices.hpp" int main() { std::string uriString = "zpb.rr://192.168.56.202:8081/tracking"; // load MAL mapping that matches provided uri, obtain reference to mal::CiiFactory auto &factory = elt::mal::loadMalForUri(uriString, {}); std::cout << "Client, uri: " << uriString << std::endl; elt::mal::Uri uri(uriString); auto tracking_client = factory.getClient<eltgw::mal::MalTCSTrackingSync>(uri, {std::make_shared<elt::mal::rr::qos::ReplyTime> (std::chrono::seconds(3))}, {}); for (int i=0; i < 1000; i++) { std::cout << "Sending offsad command to tracking service" << std::endl; std::string reply = tracking_client->offsaa(12.0, 5.0); std::cout << "Reply to offsad command is " << reply << std::endl; } return 0; }
Java
The first step is to define dependencies to mal and the gateway project icd. At the project level, a waf script will look as follows
import os from wtools import project from wtools.project import declare_project from waflib.Build import BuildContext def configure(cnf): cnf.check_wdep(wdep_name='evltgw.eltGW.icd-java', uselib_store='eltGW-icd-java', mandatory=True) cnf.check_wdep(wdep_name='cii.mal.java', uselib_store='cii-mal-java', mandatory=True) project.declare_project(name='evltgw_client', version='1.0-dev', requires='cxx python java cii boost', boost_libs='log log_setup thread system chrono program_options', recurse="cpp-client python-client")
At the module model, we will have such a wscript:
from wtools.module import declare_jar
declare_jar(target='java-client', use='eltGW-icd-java cii-mal-java')
Finally, in the application, we will use the cii factory and the targeted service url to send commands. Below an example of an application sending altitude and azimuth offset commands to the tracking service:
import java.net.URI; import java.util.List; import java.util.Properties; import java.util.concurrent.CompletableFuture; import java.util.concurrent.TimeUnit; import elt.mal.CiiFactory; import elt.mal.rr.Ami; import elt.mal.rr.qos.QoS; import elt.mal.rr.qos.ReplyTime; import eltgw.mal.MalTCSTrackingSync; public class ClientDemo { /** * Install MAL mapping according to given uri. * * @param uri mal uri */ static void loadMalForUri(String uri) { String malName = uri.substring(0, 3); if (malName.equals("opc")) { malName = "opcua"; } CiiFactory.installMal(malName); } public static void main(String[] args) { String uriString = "zpb.rr://192.168.56.202:8081/tracking"; // install Mal mapping loadMalForUri(uriString); try (CiiFactory factory = CiiFactory.getInstance()) { URI uri = URI.create(uriString); try (MalTCSTrackingSync tracking_client = factory.getClient(uri, new QoS[] { new ReplyTime(3, TimeUnit.SECONDS) }, new Properties(), MalTCSTrackingSync.class)) { System.out.println("Client, uri: " + uriString); System.out.println("Sending offset command \n"); String reply = tracking_client.offsaa(12.0f, 5.0f); System.out.println("Reply: Sending offset command: " + reply + "\n"); } } catch (Throwable th) { th.printStackTrace(); System.err.println("EXC: " + th.getMessage()); System.exit(5); } } }
To launch the application from the command line, we do:
java -cp "build/java-client/java-client.jar:$MAL_ROOT/lib/*:$INTROOT/lib/mal-zpb-malvltservices.jar:$INTROOT/lib/mal-icd-malvltservices.jar:/opt/protobuf/java/*:$MAL_ROOT/lib/opentracing/*:$MAL_ROOT/lib/mal-zpb/*:$MAL_ROOT/lib/log4j/*" ClientDemo
Sending commands from VLT INS to an ELT component
It is possible to send commands from a VLT instrument to a component running in an ELT development environment. This component shall have registered beforehand to the eltGW.
ELT Component registration
A ELT component is any process that implements the MalELTComponent interface defined in ELT component ICD. This interface features a method named execute that takes as input parameters two strings, command which is the command to be executed and args that is a comma separated list of parameters to be passed to the command. command and args are two serialized strings, there is no requirement on the format, each elt component will have its own format that clients shall comply with when sending commands.
The choice has been made not to define components in a configuration file but rather to have a more dynamic approach where components register to the eltGW using the MalELT interface defined in MAL ICD. This interface features a method named register_component that have two input parameters:
name: name of the component, e.g. COSMIC
uri: elt component URI, e.g. zpb.rr://127.0.0.1:8083/cosmic
timeout: timeout in seconds when executing a command.
The MalELT interface will be reachable through a uri complying with this pattern: zpb.rr://host:port/elt for the synchronous interface and zpb.rr://host:port/async_elt for the asynchronous interface.
Below a python example of a dummy component that registers to the gateway and implements the execute method:
import datetime
import signal
import sys
import time
import threading
import elt.pymal as mal
from eltGW.eltgw_mal import MalELTSyncClientFactory
from ModMalELTServices.Eltgw.Mal import MalELTComponent, ExecuteReply
from ModMalELTServices.Eltgw.Mal.MalELTComponent import MalELTComponentSync
# timeout for the elt component when communicating with the gateway
TIMEOUT_SEC = 20
# component timeout during command execution
COMPONENT_EXEC_TIMEOUT = 10
class MalELTComponentSyncImpl:
def __init__(self, data_entity_factory):
self._data_entity_factory = data_entity_factory
def execute(self, command, args)
# dummy implementation, displays command
# and args, waits and returns
print(f"{command} {args} being executed")
if command == "sleep":
time.sleep(int(args))
time.sleep(0.001)
print(f"{command} executed")
reply = self._data_entity_factory(ExecuteReply)
reply.setStatus_code(0);
reply.setMsg("Everything's fine")
return reply
class ELTMalServicesContainer:
def __init__(self, uri):
self._uri = uri
mal_name = self._uri.split(":")[0].split(".")[0]
print(f"Registering mal {mal_name}")
self._mal = mal.loadMal(mal_name, {})
self._factory = mal.CiiFactory.getInstance()
self._factory.registerMal(mal_name, self._mal)
def run(self, elt_component_service_name):
self._server = self._factory.createServer(self._uri, mal.rr.qos.DEFAULT, {})
qosList = [mal.ps.qos.Deadline(datetime.timedelta(seconds=1)),
mal.ps.qos.Latency(datetime.timedelta(milliseconds=100))]
self._server.registerService(elt_component_service_name, MalELTComponent.MalELTComponentSyncService,
MalELTComponentSyncImpl(self._mal.createDataEntity))
print(f"Running elt component on {self._uri}")
self._server.run()
def stop(self):
self._server.close()
def main(argv):
"""
@brief Entry point of elt_component_client
Register to the elt gateway as an elt component and waits for input commands
"""
elt_service_uri = argv[1]
elt_container_uri = argv[2]
elt_component_name = argv[3]
# we start the component
container = ELTMalServicesContainer(elt_container_uri)
signal.signal(signal.SIGINT, lambda control, signal: container.stop())
container_thread = threading.Thread(target=container.run, args=(elt_component_name,))
container_thread.start()
# and register it
client = MalELTSyncClientFactory.create(elt_service_uri, TIMEOUT_SEC)
client.register_component(elt_component_name, elt_container_uri + "/" + elt_component_name, COMPONENT_EXEC_TIMEOUT)
client.close()
# wait for component to stop
container_thread.join()
if __name__ == "__main__":
if len(sys.argv) < 4:
print("""Parameters: url of gateway elt sync service,
elt container uri, elt component name""")
sys.exit(-1)
main(sys.argv)
Sending command
On a VLTSW WS, a client sends a command aimed to a ELT component through the VLT gateway. The command is a ccs command with the usual parameters:
environment: wvgw which is the environment where the vltGW is running.
process: outMsgVGW which is the process responsible for forwarding commands to the eltGW.
command: EXEC which is the command that allows to send commands to the eltGW.
command parameters: it consists of three fields, component to specify the targeted ELT component, command to specify the command to be executed by the ELT component and args which is comma separated list of parameters to be passed to the command.
Here is a command line example of a command named Rtc.setTelemetryLevel taking ‘High’ as input parameter and to be executed by the ELT RTC platform COSMIC:
msgSend "wvgw" outMsgVGW EXEC "component=COSMIC,command=Rtc.setTelemetryLevel,args=High"
Getting metadata from the ELT gateway
A client can get fits keywords and binary tables through the metadaq interface that is implemented by the gateway. The command STARTDAQ shall be sent at the beginning of the acquisition. When the acquisition completes, the command STOPDAQ shall be sent. The fits keywords will be returned along with the location of the binary table files on the elt gateway machine. Again, commands can be sent from the command line or from a python, C++ or java application using synchronous clients generated from the metadaq interface. Like when sending commands, the location of the service shall be specified. It will consist as previously of the host name, port and service name which is metadataq.
Command line
Python
In python, a conveniency class named MetaDaqSyncClientFactory has been defined to instantiate gateway service clients. It is defined in the eltGW.eltgw_mal module and provide a method named create that takes as a parameter the url of the targeted mal service like in the following example:
import json
import requests
import socket
import sys
from eltGW.eltgw_mal import MetaDaqSyncClientFactory
TIMEOUT_SEC = 10
if __name__ == "__main__":
# we query consul to get the port of the gateway services server
host_name = socket.gethostname()
response = requests.get("http://{}:8500/v1/catalog/service/evltgw-services-rep".format(host_name))
if response.status_code != 200:
print("Could not get data from consul")
sys.exit(-1)
service_dict = json.loads(response.content)
service_addr = service_dict[0]['ServiceTaggedAddresses']['lan_ipv4']['Address']
service_port = service_dict[0]['ServiceTaggedAddresses']['lan_ipv4']['Port']
metadaq_service_uri = "zpb.rr://{}:{}/metadaq".format(service_addr, service_port)
metadaq_service_client = MetaDaqSyncClientFactory.create(metadaq_service_uri, TIMEOUT_SEC)
ACQ_ID = "acq_id"
reply = metadaq_service_client.StartDaq(ACQ_ID)
reply = metadaq_service_client.StopDaq(ACQ_ID)
print(reply.getKeywords())
print(reply.getFiles())
C++
The first step is to define dependencies to mal and the gateway project icd. At the project level, a waf script will look as follows:
import os
from wtools import project
from wtools.project import declare_project
from waflib.Build import BuildContext
def configure(cnf):
cnf.check_wdep(wdep_name='cii.mal.cpp.mal', uselib_store='cii-mal', mandatory=True)
cnf.check_wdep(wdep_name='metadaq.if-cxx', uselib_store='metadaq', mandatory=True)
project.declare_project(name='evltgw_client', version='1.0-dev', requires='cxx python java cii boost',
boost_libs='log log_setup thread system chrono program_options',
recurse="cpp-client python-client")
At the module level, we will have such a wscript:
from wtools.module import declare_cprogram
declare_cprogram(target='cpp-client', use='BOOST cii-mal cpp-netlib-uri metadaq')
Finally, in the application, we will use the cii factory and the metadaq service url to send commands. Below an example of an application requesting the fits binary files and keywords:
#include <iostream> #include <mal/Cii.hpp> #include <mal/utility/LoadMal.hpp> #include <mal/rr/qos/ReplyTime.hpp> #include "Metadaqif.hpp" int main() { const std::string ACQ_ID = "SomeAcqId"; std::string uriString = "zpb.rr://192.168.56.202:8081/metadaq"; // load MAL mapping that matches provided uri, obtain reference to mal::CiiFactory auto &factory = elt::mal::loadMalForUri(uriString, {}); elt::mal::Uri metadaq_uri(uriString); auto metadaq_client = factory.getClient<metadaqif::MetaDaqSync>(metadaq_uri, {std::make_shared<elt::mal::rr::qos::ReplyTime> (std::chrono::seconds(3))}, {}); for (int i=0; i < 1000; i++) { std::cout << "Sending startdaq command to metadaq service" << std::endl; auto startreply = metadaq_client->StartDaq(ACQ_ID); std::cout << "Reply to startdaq command is " << startreply->getId() << std::endl; std::cout << "Sending stopdaq command to metadaq service" << std::endl; auto stopreply = metadaq_client->StopDaq(ACQ_ID); std::string files = ""; for (auto file: stopreply->getFiles()) { files = files + " " + file; } std::cout << "Reply to stopdaq command is " << files << " " << stopreply->getKeywords() << std::endl; } return 0; }
JAVA
There is currently no java version of the metadaq interface client so it is not possible to request metadata from a java application.
Getting TCS State
Requesting TCS State
A client can get the current TCS state by requesting it explicitely from the gateway service named StdCmds that exposes the stdif::StdCmds interface (see metadaq interface). Two methods are available, GetState or GetStatus. Again, the status can be obtained from the command line with msgsend or from a python program like the following one:
import json
import requests
import socket
import sys
from eltGW.eltgw_mal import StdCmdsSyncClientFactory
if __name__ == "__main__":
host_name = socket.gethostname()
# we query consul to get the port of the gateway services server
response = requests.get('http://{}:8500/v1/catalog/service/evltgw-services-rep'.format(host_name))
if response.status_code != 200:
print("Could not get data from consul")
sys.exit(-1)
service_dict = json.loads(response.content)
service_addr = service_dict[0]['ServiceTaggedAddresses']['lan_ipv4']['Address']
service_port = service_dict[0]['ServiceTaggedAddresses']['lan_ipv4']['Port']
stdcmds_uri = "zpb.rr://{}:{}/StdCmds".format(service_addr, service_port)
std_client = StdCmdsSyncClientFactory.create(stdcmds_uri, 10)
print(std_client.GetState())
Subscribing to TCS Status
A client can be notified of TCS status changes published by the gateway. It will subscribe to the status topic by using a uri such as:
zpb.ps://host:port/std/status.
It will get the host and port by querying from consul the value of the service evltgw-status-pub. Below an example of a subscriber application:
import json
import elt.pymal as mal
import requests
import socket
from ModStdif.Stdif import (StdCmds, State, Status)
if __name__ == "__main__":
global is_running
is_running = True
# we query consult to get the publisher host and port
host_name = socket.gethostname()
response = requests.get('http://{}:8500/v1/catalog/service/evltgw-status-pub'.format(host_name))
if response.status_code != 200:
print("Could not get data from consul")
sys.exit(-1)
service_dict = json.loads(response.content)
service_addr = service_dict[0]['ServiceTaggedAddresses']['lan_ipv4']['Address']
service_port = service_dict[0]['ServiceTaggedAddresses']['lan_ipv4']['Port']
uri = "zpb.ps://{}:{}/std/status".format(service_addr, service_port)
scheme = uri[0:3]
malName = scheme
mapping = mal.loadMal(malName, {})
factory = mal.CiiFactory.getInstance()
factory.registerMal(scheme, mapping)
with factory.getSubscriber(uri, Status, qos=mal.ps.qos.DEFAULT) as subscriber:
# Asynchronous data subscription, no filtering,
# Terminate when RETURN/CTRL-D entered on standard input
def dataEventFunction(subscription, dataEvent):
# Data event processing method
try:
global is_running
if not is_running:
# subscription should not be closed within the callback
return
print('INSTANCE EVENT: %s, INSTANCE STATE: %s, TIMESTAMP: %s, VALID DATA: %s' %
(dataEvent.event, dataEvent.state, dataEvent.sourceTimestamp, dataEvent.hasValidData()))
if dataEvent.hasValidData():
state = dataEvent.getData()
global is_tracing_enabled
print('... sample, daqId: %s, value: %s' % (state.getSource(), state.getStatus()))
except Exception as e:
print('Exception in dataEventFunction: ', e)
print('Subscriber started, terminate by pressing RETURN')
with subscriber.subscribeAsync(mal.ps.DataEventFilter.all(Status), dataEventFunction) as subscription:
# Suspend main thread, wait on user input
try:
_ = input()
except (EOFError, KeyboardInterrupt):
# Done
pass
is_running = False
print('BYE')
MAL ICD
The gateway ICD for commands forwarding look as follows:
<?xml version="1.0" encoding="UTF-8"?>
<types xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="schemas/icd_type_definition.xsd">
<package name="eltgw">
<package name="mal">
<enum name="FlagType">
<enumerator name="REF"/>
<enumerator name="STAR"/>
</enum>
<enum name="MotionType">
<enumerator name="REL" />
<enumerator name="ABS" />
<enumerator name="DIFF" />
</enum>
<enum name="Switch" >
<enumerator name="On" />
<enumerator name="Off" />
</enum>
<enum name="EpochSystem" >
<enumerator name="J" />
<enumerator name="B" />
</enum>
<enum name="CoordinateType" >
<enumerator name="A" />
<enumerator name="M" />
</enum>
<enum name="GsMode" >
<enumerator name="AG" />
<enumerator name="FS" />
<enumerator name="SF" />
</enum>
<enum name="VignettingLimit" >
<enumerator name="NONE" />
<enumerator name="INSTRUMENT" />
</enum>
<enum name="RotMode" >
<enumerator name="NORMAL" />
<enumerator name="NO_TRACKING" />
<enumerator name="ALTAZ" />
</enum>
<enum name="OperationalMode" >
<enumerator name="AUTO" />
<enumerator name="SEMI" />
<enumerator name="COMMAND" />
</enum>
<enum name="BaffleMode" >
<enumerator name="RETRACTED" />
<enumerator name="DEPLOYED" />
</enum>
<enum name="FocusStation" >
<enumerator name="UNDEFINED" />
<enumerator name="NA" />
<enumerator name="NB" />
<enumerator name="CA" />
<enumerator name="CO" />
<enumerator name="IM" />
</enum>
<interface name="MalVLT">
<method name="send" returnType="string" >
<argument name="environment" type="string"/>
<argument name="process" type="string"/>
<argument name="cmd" type="string"/>
<argument name="parameters" type="string"/>
<argument name="timeout" type="float" />
</method>
</interface>
<interface name="MalELT">
<method name="register_component" returnType="int8_t">
<argument name="name" type="string" />
<argument name="uri" type="string" />
<argument name="timeout" type="float" />
</method>
</interface>
<interface name="MalTCSPresetting">
<method name="clrstp" returnType="string" />
<method name="prsalaz" returnType="string">
<argument name="alt" type="float"/>
<argument name="az" type="float"/>
</method>
<method name="prscoor" returnType="string">
<argument name="alpha" type="float"/>
<argument name="delta" type="float"/>
<argument name="epoch_system" type="nonBasic" nonBasicTypeName="EpochSystem" />
<argument name="epoch" type="float"/>
<argument name="equinox" type="float"/>
<argument name="pma" type="float"/>
<argument name="pmd" type="float"/>
<argument name="rad_vel" type="float"/>
<argument name="parallax" type="float"/>
<argument name="coordinate_type" type="nonBasic" nonBasicTypeName="CoordinateType" />
<argument name="wavelength" type="float"/>
<argument name="offset_alpha" type="float"/>
<argument name="offset_delta" type="float"/>
<argument name="offset_rot" type="float"/>
</method>
<method name="prsname" returnType="string">
<argument name="pos_name" type="string"/>
</method>
<method name="savcstp" returnType="string">
<argument name="file" type="string"/>
</method>
<method name="savrstp" returnType="string">
<argument name="file" type="string"/>
</method>
<method name="setup" returnType="string" >
<argument name="expo_id" type="int32_t"/>
<argument name="file" type="string"/>
<argument name="function" type="string"/>
<argument name="value" type="float"/>
<argument name="no_move" type="boolean"/>
<argument name="check" type="boolean"/>
</method>
<method name="stoptrk" returnType="string">
<argument name="function" type="string"/>
</method>
</interface>
<interface name="MalTCSTracking">
<method name="adc_min" returnType="string" >
<argument name="lamda_red" type="float"/>
</method>
<method name="obj_rot" returnType="string" >
<argument name="offset_rot" type="float"/>
</method>
<method name="offsaa" returnType="string" >
<argument name="offset_alt" type="float"/>
<argument name="offset_az" type="float"/>
</method>
<method name="offsad" returnType="string" >
<argument name="offset_alpha" type="float"/>
<argument name="offset_delta" type="float"/>
</method>
<method name="offsadg" returnType="string" >
<argument name="offset_alpha" type="float"/>
<argument name="offset_delta" type="float"/>
</method>
<method name="offsgp" returnType="string" >
<argument name="offset_alpha" type="float"/>
<argument name="offset_delta" type="float"/>
</method>
<method name="offsxy" returnType="string" >
<argument name="offset_x" type="float"/>
<argument name="offset_y" type="float"/>
</method>
<method name="offsrot" returnType="string" >
<argument name="offset_rot" type="float"/>
</method>
<method name="set_adc" returnType="string" >
<argument name="adc_sep" type="float"/>
</method>
<method name="set_av" returnType="string" >
<argument name="offset_alpha" type="float"/>
<argument name="offset_delta" type="float"/>
</method>
<method name="set_lam" returnType="string" >
<argument name="wavelength" type="float"/>
</method>
<method name="set_rlim" returnType="string" >
<argument name="limit" type="float"/>
</method>
</interface>
<interface name="MalTCSAutoGuiding" >
<method name="box_2_gs" returnType="string" >
<argument name="error_max" type="float"/>
<argument name="rep_freq" type="float"/>
<argument name="at" type="string"/>
<argument name="mode" type="nonBasic" nonBasicTypeName="GsMode"/>
</method>
<method name="find_gs" returnType="string" >
<argument name="no_def_criteria" type="boolean"/>
<argument name="min_mag" type="float"/>
<argument name="max_mag" type="float"/>
<argument name="vignetting_limit" type="nonBasic" nonBasicTypeName="VignettingLimit"/>
</method>
<method name="fs_req" returnType="string" />
<method name="fs_rel" returnType="string" />
<method name="pr_gs" returnType="string" />
<method name="pr_park" returnType="string" />
<method name="pr_cnt" returnType="string" />
<method name="rot_fix" returnType="string" >
<argument name="motion_type" type="nonBasic" nonBasicTypeName="MotionType" />
<argument name="angle" type="float" />
<argument name="timeout" type="int32_t" />
</method>
<method name="rot_trk" returnType="string" >
<argument name="rot_mode" type="nonBasic" nonBasicTypeName="RotMode" />
</method>
<method name="start_ag" returnType="string" >
<argument name="rep_freq" type="float" />
<argument name="at" type="string" />
<argument name="mode" type="nonBasic" nonBasicTypeName="GsMode" />
</method>
<method name="stop_ag" returnType="string" >
<argument name="force" type="boolean" />
</method>
</interface>
<interface name="MalTCSActiveOptics">
<method name="get_m2_zfocus" returnType="string" />
<method name="set_m2_zpos" returnType="string" >
<argument name="offset" type="float" />
<argument name="motion_type" type="nonBasic" nonBasicTypeName="MotionType" />
</method>
<method name="start_ao" returnType="string">
<argument name="flag" type="nonBasic" nonBasicTypeName="FlagType"/>
</method>
<method name="stop_ao" returnType="string" />
</interface>
<interface name="MalTCSEnclosure">
<method name="set_dome_op_mode" returnType="string" >
<argument name="mode" type="nonBasic" nonBasicTypeName="OperationalMode" />
</method>
<method name="set_windscreen_op_mode" returnType="string" >
<argument name="mode" type="nonBasic" nonBasicTypeName="OperationalMode" />
</method>
</interface>
<interface name="MalTCSOpticsControl" >
<method name="move_ffs_in" returnType="string" />
<method name="move_ffs_out" returnType="string" />
<method name="move_m4_in_light_beam" returnType="string" />
<method name="move_m4_out_light_beam" returnType="string" />
<method name="set_baffles" returnType="string" >
<argument name="mode" type="nonBasic" nonBasicTypeName="BaffleMode" />
</method>
<method name="stop_chopping" returnType="string" />
<method name="start_chopping" returnType="string" />
</interface>
<interface name="MalTCSModeSwitching" >
<method name="get_ins" returnType="string" />
<method name="get_ins_cfg" returnType="string" >
<argument name="ins_id" type="string" />
</method>
<method name="set_ins" returnType="string" >
<argument name="ins_id" type="string" />
</method>
<method name="set_ins_cfg" returnType="string">
<argument name="ins_id" type="string" />
<argument name="ins_mode" type="string" />
<argument name="focus_station" type="nonBasic" nonBasicTypeName="FocusStation" />
<argument name="offset_rot" type="float" />
<argument name="offset_focus" type="float" />
<argument name="pixel_size_x" type="float" />
<argument name="pixel_size_y" type="float" />
<argument name="vig_area_size_x" type="float" />
<argument name="vig_area_size_y" type="float" />
<argument name="vig_area_cnt_x" type="float" />
<argument name="vig_area_cnt_y" type="float" />
<argument name="point_axis_off_x" type="float" />
<argument name="point_axis_off_y" type="float" />
<argument name="detector_lcu" type="string" />
<argument name="ref_X" type="float" />
<argument name="ref_Y" type="float" />
<argument name="adapter_focus" type="float" />
</method>
</interface>
<interface name="MalTCSMaintenance">
<method name="stop_action" returnType="string" />
<method name="cyclao" returnType="string" >
<argument name="flag" type="nonBasic" nonBasicTypeName="FlagType"/>
</method>
<method name="exit" returnType="string" >
<argument name="dev_name" type="string" />
</method>
<method name="get_pend" returnType="string" />
<method name="init" returnType="string" >
<argument name="devName" type="string" />
</method>
<method name="kill" returnType="string" />
<method name="off" returnType="string" >
<argument name="dev_name" type="string" />
</method>
<method name="offsfad" returnType="string" >
<argument name="type_settings" type="nonBasic" nonBasicTypeName="MotionType" />
<argument name="offset" type="float"/>
</method>
<method name="onecal" returnType="string" >
<argument name="type_settings" type="int32_t" />
</method>
<method name="online" returnType="string" >
<argument name="dev_name" type="string" />
</method>
<method name="ping" returnType="string" />
<method name="prncmd" returnType="string" />
<method name="selftst" returnType="string" >
<argument name="dev_name" type="string" />
</method>
<method name="seqao" returnType="string" >
<argument name="flag" type="nonBasic" nonBasicTypeName="FlagType"/>
</method>
<method name="simulat" returnType="string" >
<argument name="dev_name" type="string" />
</method>
<method name="standby" returnType="string" >
<argument name="dev_name" type="string" />
</method>
<method name="state" returnType="string" />
<method name="status" returnType="string" />
<method name="stopsim" returnType="string" >
<argument name="dev_name" type="string" />
</method>
<method name="test" returnType="string" >
<argument name="function" type="string" />
</method>
<method name="verbose" returnType="string" >
<argument name="on" type="nonBasic" nonBasicTypeName="Switch" />
</method>
<method name="version" returnType="string" />
</interface>
</package>
</package>
</types>
ELT component ICD
Any ELT component that waits for commands coming from the EVLTGW shall implement this interface:
<?xml version="1.0" encoding="UTF-8"?>
<types xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="schemas/icd_type_definition.xsd">
<package name="eltgw">
<package name="mal">
<struct name="ExecuteReply">
<member name="status_code" type="int8_t" />
<member name="msg" type="string" />
</struct>
<interface name="MalELTComponent">
<method name="execute" returnType="nonBasic" nonBasicReturnTypeName="ExecuteReply">
<argument name="command" type="string" />
<argument name="args" type="string" />
</method>
</interface>
</package>
</package>
</types>