|TUBL05||Pysmlib: A Python Finite State Machine Library for EPICS||330|
In the field of Experimental Physics and Industrial Control Systems (EPICS)*, the traditional tool to implement high level procedures is the Sequencer*. While this is a mature, fast, and well-proven software, it comes with some drawbacks. For example, it’s based on a custom C-like programming language which may be unfamiliar to new users and it often results in complex, hard to read code. This paper presents pysmlib, a free and open source Python library developed as a simpler alternative to the EPICS Sequencer. The library exposes a simple interface to develop event-driven Finite State Machines (FSM), where the inputs are connected to Channel Access Process Variables (PV) thanks to the PyEpics** integration. Other features include parallel FSM with multi-threading support and input sharing, timers, and an integrated watchdog logic. The library offers a lower barrier to enter and greater extensibility thanks to the large ecosystem of scientific and engineering python libraries, making it a perfect fit for modern control system requirements. Pysmlib has been deployed in multiple projects at INFN Legnaro National Laboratories (LNL), proving its robustness and flexibility.
* L. R. Dalesio, M. R. Kraimer, and A. J. Kozubal. "EPICS architecture." ICALEPCS. Vol. 91. 1991.
** M. Newville, et al., pyepics/pyepics Zenodo. http://doi.org/10.5281/zenodo.592027
|Slides TUBL05 [1.705 MB]|
|DOI •||reference for this paper ※ https://doi.org/10.18429/JACoW-ICALEPCS2021-TUBL05|
|About •||Received ※ 08 October 2021 Revised ※ 22 October 2021 Accepted ※ 22 December 2021 Issue date ※ 10 February 2022|
|Cite •||reference for this paper using ※ BibTeX, ※ LaTeX, ※ Text/Word, ※ RIS, ※ EndNote (xml)|