Roofs (pyobs.modules.roof)

Modules for roofs. TODO: write doc

BaseDome

class BaseDome(**kwargs: Any)

Bases: IDome, BaseRoof

Base class for domes.

Initialize a new base dome.

async get_fits_header_before(namespaces: Optional[List[str]] = None, **kwargs: Any) Dict[str, Tuple[Any, str]][source]

Returns FITS header for the current status of this module.

Parameters:

namespaces – If given, only return FITS headers for the given namespaces.

Returns:

Dictionary containing FITS headers.

BaseRoof

class BaseRoof(**kwargs: Any)

Bases: WeatherAwareMixin, MotionStatusMixin, IRoof, IFitsHeaderBefore, Module

Base class for roofs.

Initialize a new base roof.

async get_fits_header_before(namespaces: Optional[List[str]] = None, **kwargs: Any) Dict[str, Tuple[Any, str]][source]

Returns FITS header for the current status of this module.

Parameters:

namespaces – If given, only return FITS headers for the given namespaces.

Returns:

Dictionary containing FITS headers.

async is_ready(**kwargs: Any) bool[source]

Returns the device is “ready”, whatever that means for the specific device.

Returns:

True, if roof is open.

async open() None[source]

Open module.

DummyRoof

class DummyRoof(**kwargs: Any)

Bases: BaseRoof, IRoof

A dummy camera for testing.

Creates a new dummy root.

get_percent_open() float[source]

Get the percentage the roof is open.

async init(**kwargs: Any) None[source]

Open the roof.

Raises:

AcquireLockFailed – If current motion could not be aborted.

async open() None[source]

Open module.

async park(**kwargs: Any) None[source]

Close the roof.

Raises:

AcquireLockFailed – If current motion could not be aborted.

async stop_motion(device: Optional[str] = None, **kwargs: Any) None[source]

Stop the motion.

Parameters:

device – Name of device to stop, or None for all.

Raises:

AcquireLockFailed – If current motion could not be aborted.