taurus is a library for connecting client side applications (CLIs and GUIs) to Tango device servers. It is built on top of PyTango which is a python binding for the Tango library. It provides an abstraction layer that allows Tango to be accessed in a pythonic, object oriented way. For the GUI part, taurus is built on top of the graphical library PyQt which is a python binding for Qt.
For example, to display the values of four attributes (state, position, velocity, acceleration) of a device (motor/icepap/01):
import sys from PyQt4 import Qt from taurus.qt.qtgui.panel import TaurusForm from taurus.qt.qtgui.application import TaurusApplication app = TaurusApplication(sys.argv) attrs = [ 'state', 'position', 'velocity', 'acceleration' ] model = [ 'motor/icepap/01/%s' % attr for attr in attrs ] w = TaurusForm() w.model = model w.show() sys.exit(app.exec_())
The above example can even be achieved even without typing any code:
% cd taurus/qt/qtgui/panel % python taurusform.py motor/icepap/01/state motor/icepap/01/position motor/icepap/01/velocity
taurus is designed with the philosophy that you should be able to create simple applications that are able to connect to tango servers with just a few lines of code or even with no code at all!
The concepts were not born from scratch. It is not our intention to reinvent the way applications are written. Many of the concepts were borrowed from the existing java tango library called ATK. If you have used ATK before you will find many concepts familiar.
The taurus library is divided into two parts: the core module which handles all interaction with PyTango (taurus core tutorial) and the widget module which provides a collection of widgets that can be used inside any PyQt based GUI (taurus widget tutorial).