This section introduces the main Sardana components and gives some related information.
The Pool command CreateController creates a controller instance. The parameters are controller type, library name (Python script name), class name (defined in the Python script), controller name and other items. Many controllers use RootDeviceName to select the Tango servers to be operated by a controller instance. Examples for controller names (aliases) are omsvme58_eh2a or omsvme58_eh2b. The controller name reflects the devices a controller is talking to, e.g.: omsvme58_eh2a speaks to all motors of the OmsVme58 EH2A instance, like p02/motor/eh2a.01, etc.. In this case the RootDeviceName is p02/motor/eh2a. This string matches all Tango servers to be controlled by a omsvme58_eh2a.
After a controller has been created it can be populated with Pool devices. This is done with the Pool command CreateElement. The parameters are the controller type, the controller name, a channel number and the alias for the Pool device. The channel number starts at 1. It is used as an index for the list that was created with the RootDeviceName. There is a one-to-one correspondance between Pool devices and Tango devices, e.g.: the Tango device p02/motor/eh2a.01 is connected to the Pool device eh2a_mot01. This is an alias which happens to be identical with the Online device names.
The word Macro starts with a capital letter because it refers to Python code which has a well-defined structure. A Sardana Macro defines a class which inherits from the Macro superclass. Tbe class name is used to refer to the Macro from Spock or from any other application.
Perhaps it is instructive to execute this litte exercise: Open a Door using 'Test device' and select the command RunMacro. Give it 'wa' as input and execute it. The attribute 'Output' contains the result.
At PETRA III the Sardana system is an additional layer on top of the Tango Servers which has the following consequences: