Adding any Tango Attribute as a IORegister

Any Tango attribute can be added as IORegister in Sardana using the TangoAttrIORController class.

The entry in the online.xml has to be:

<device>
 <name>ior1</name>
 <type>input_register</type>
 <module>tangoattributeiorctrl</module>
 <device>p09/motor/exp.01/Position</device>
 <control>tango</control>
 <hostname>haso111n:10000</hostname>
</device>

where <module> has to be tangoattributeiorctrl and <device> has to contain not only the name of the device the device the attribute belongs to but also the name of the attribute itself. The Labels and Calibration extra attributes of the TangoAttrIORController can also be set in the online.xml adding the tags ior_labels and/or ior_calibration to this entry, ex.

<device>
 <name>ior1</name>
 <type>input_register</type>
 <module>tangoattributeiorctrl</module>
 <device>p09/motor/exp.01/Position</device>
 <ior_labels>16.66%:16 33.33%:33 50%:50 66.66%:66 83.33%:83 100%:100</ior_labels>
 <ior_calibration>[[0.4,0.5,0.6],[1.4,1.5,1.6],[2.4,2.5,2.6],[3.4,3.5,3.6],[4.4,4.5,4.6],[5.4,5.5,5.6]]</ior_calibration>
 <control>tango</control>
 <hostname>haso111n:10000</hostname>
</device>

Read the documentation of the TangoAttrIORController class for setting correctly the Labels and Calibration attributes.



2019-12-04