Python scripting
Teaching example library
Run from the OBS checkout with normal student Python; OBS remains in its own
visible console. The same files are staged under the compiled distribution's
isolated student_python directory. No package build or installation is needed.
For each command-line example, --help prints parameters without a connection.
Common flags are --port, --userid and --camera. Numeric units are explicit:
RA hours, declination degrees, sky offsets arcseconds, focus device steps,
exposure/cadence seconds, detector temperatures Celsius, and raw image values ADU.
All examples except inspect_observatory perform real equipment operations when
connected to real OBS. Replace illustrative coordinates, filters, temperatures,
positions and pixel coordinates for your experiment. Statistics/photometry examples
need NumPy and astropy.io.fits in student Python. CSV outputs go to the current
working directory unless --output is specified, and overwrite that named CSV.
These examples collect and explain diagnostics; they do not impose quality gates.
| Example | Purpose |
|---|---|
| inspect_observatory | Read telemetry and discover equipment |
| single_exposure | Acquire a first target |
| colour_sequence | Observe through multiple filters |
| variable_star_series | Measure a time series |
| target_list | Observe an explicit CSV target list |
| exposure_ladder | Explore signal and saturation |
| dark_current_study | Study dark signal at a selected temperature |
| photon_transfer_curve | Estimate conversion gain from image pairs |
| focus_curve | Sample image width against focus position |
| adaptive_flats | Use measurements to choose the next exposure |
| dithered_sequence | Acquire a cross-shaped dither sequence |
| native_capture | Capture video, planets or paired speckle |
| rotator_flats | Acquire the original rotator calibration sequence |
See the API reference for processing acknowledgements, error/result recovery, explicit image analysis, native capture semantics, and capability gaps.