polar-bits#

Bluesky-based data acquisition for the POLAR beamline (4ID) at the Advanced Photon Source.

polar-bits is built on the BITS (Bluesky Instrument Toolkit Structure) framework and provides a shared device library, scan plans, and data output callbacks for three hutches and the Raman offline setup: 4IDB, 4IDG, 4IDH, and Raman.


What’s New

Headlines for the current APS run cycle. Returning users start here.

What’s New
Getting Started

Installation, first session, loading devices.

Getting Started
Scan Plans

lup, ascan, grid_scan, qxscan, DM workflow submission.

Scan Plans
Useful Functions

Per-session helpers: pr_setup, qxscan_setup, temperature_setup, undulator_setup, restore_session_state, device loaders.

Useful Functions
Device Reference

Lookup tables: all core, 4IDB, 4IDG, and 4IDH devices.

Device Reference
General Examples

experiment_setup, counters.plotselect, scans, data access.

General Examples
Writing Macros

Startup scripts, motor shortcuts, writing Bluesky plans.

Writing Macros
4IDG Examples

Diffractometer setup, HKL navigation, reciprocal-space scans.

4IDG: Diffractometer Usage
4IDH Examples

Magnet 9-1-1 field sweeps, XMCD spectroscopy, temperature series.

4IDH: Magnet 9-1-1 Usage
FAQ

Common questions: plots, baseline, pause/resume, peak finding.

Frequently Asked Questions

Advanced#

Architecture

Multi-beamline structure, startup flow, station labels.

Architecture
Configuration

iconfig.yml and devices.yml explained.

Configuration
Devices Guide

PV-agnostic pattern, deferred connection, factory classes.

Devices Guide
Callbacks

SPEC, NeXus/HDF5, and dichroism stream output.

Callbacks and Data Output
QueueServer

Start/restart the QueueServer per beamline.

QueueServer
API Reference

Full auto-generated API for all packages.

api/index