- Python 59.5%
- Rust 36.9%
- Shell 3.6%
| docs | ||
| modules | ||
| motarem@d9ad4666f0 | ||
| ngtu_1_1 | ||
| ngtu_1_2 | ||
| ngtu_1_4 | ||
| rust_devices@883fed7155 | ||
| tests | ||
| .gitignore | ||
| .gitmodules | ||
| README.md | ||
| requirements-py38.txt | ||
SKIF Beamline Control Software
Monorepo for the SKIF synchrotron beamline control system. Contains Sardana controllers, macros, helper GUIs, and Rust-based device servers for beamlines 1-2 and 1-4.
System Overview
The SKIF control software serves two active experimental stations. Each station runs a set of Rust services that talk directly to hardware over TCP, plus a Python Sardana layer that exposes those services to the control system through Unix domain sockets.
NGTU 1-2 — Non-cooled slit station
Controls three independent hardware subsystems:
| Subsystem | Rust service | What it drives |
|---|---|---|
| Slit | slit_controller |
4-axis non-cooled slit using Standa steppers, RF256 quadrature encoders, and TRID temperature sensors; hardware at 192.168.0.51, 192.168.0.200, 192.168.0.201 |
| Cooled slit | cooled_slit_controller |
4-axis water-cooled slit using EM2RS servo amplifiers with LIR linear encoders and ICPCON M7015 temperature acquisition; hardware at 192.168.0.61 |
| Filter | filter |
Single-axis beam filter using an EM2RS servo and LIR linear encoder; hardware at 192.168.0.60 |
Sardana controllers deployed: SlitController.py, EM2RSController.py,
LatchController.py. Macros: AllMacro.py. Shared modules: TRID.py,
motarem_client/.
NGTU 1-4 — XAFS station
Controls the XAFS (X-ray Absorption Fine Structure) beamline:
| Subsystem | Rust service | What it drives |
|---|---|---|
| XAFS | xafs |
4-axis cooled slit, 1-axis attenuator, collimator temperature readout, and water-inlet monitor; all hardware at 192.168.0.57 |
Sardana controllers deployed: CooledSlitController.py, Attenuator.py. Shared
modules: motarem_client/.
Repository Layout
skif/
├── motarem/ # Rust motion server + Python client (external submodule)
├── rust_devices/ # Rust device crates (external submodule)
├── ngtu_1_1/ # Sardana controllers and macros for beamline 1-1
├── ngtu_1_2/ # Sardana controllers, macros, and Rust services for beamline 1-2
│ ├── slit_controller/ # Rust crate: non-cooled slit
│ ├── cooled_slit_controller/ # Rust crate: cooled slit
│ ├── filter/ # Rust crate: beam filter
│ ├── services/ # systemd units for Tango/Sardana
│ └── scripts/ # deploy and init scripts
├── ngtu_1_4/ # Sardana controllers and Rust service for beamline 1-4
│ ├── xafs/ # Rust crate: XAFS station backend
│ ├── services/ # systemd units for Tango/Sardana
│ └── scripts/ # deploy and init scripts
├── docs/ # Block diagrams and documentation
└── requirements-py38.txt # Aggregated Python dependencies
External submodules
| Path | Repository | Description |
|---|---|---|
motarem/ |
github:Tombleron/motarem |
Rust motion server + Python client |
rust_devices/ |
github:Tombleron/slit_controller |
Rust crates for hardware devices |
Quick Start
For a complete installation walkthrough — prerequisites, first-time setup, hardware configuration, and troubleshooting — see docs/setup.md.
The short version for a routine update of an already-configured station:
git pull --recurse-submodules
./ngtu_1_2/scripts/deploy.sh # rebuild Rust + redeploy Python for 1-2
./ngtu_1_4/scripts/deploy.sh # same for 1-4
Updating Submodules
# Pull latest commits for all submodules
git submodule update --remote --merge
# Commit the new submodule pointers
git add motarem rust_devices
git commit -m "chore: bump submodules"