Astrolive
Asynchronous ASCOM integration for Home Assistant
Install / Use
/learn @mawinkler/AstroliveREADME
AstroLive<!-- omit in toc -->
Connector for the ASCOM Alpaca REST API designed to work with Home Assistant via MQTT.

The integration with Home Assistant is implemented via MQTT for sensor and camera entities and supports autodiscovery of Home Assistant for the devices.

AstroLive uses the nice ALPACA client implementation of the OCA Box classes which is used by the Araucaria Project.
Table of Content<!-- omit in toc -->
- How It Works
- Breaking Changes when upgrading from Version 0.3
- Requirements
- My Personal Setup
- Usage
- Integrate with Home Assistant
How It Works
- AstroLive connects via the ASCOM Alpaca API to your observatory.
- For each configured and connected component a MQTT device configuration for sensors, binary_sensors, switches and if applicable camera is created below
homeassistant/. - As of now the following components are supported:
- Telescope
- Camera
- Camera via File
- Focuser
- Switch
- FilterWheel
- Dome
- Rotator
- SafetyMonitor
- These configurations allow MQTT auto discovery in Home Assistant.
- AstroLive then starts a seperate thread for each device which queries the compenent status interval according to the configuration and publishes the device state to MQTT.
- If the component is of the type Camera the last captured FITS image is autostretched, downsized and published as a .jpg. This is the same for Camera via file where AstroLive watches a directory for new FITS images.
Slewing the telescope using the equatorial coordinate system, parking and unparking the scope, moving the focuser and some more commands are possible directly from Home Assistant.
AstroLive is designed to run as a container to be deployed on a dedicated host or next to Home Assistant. It does not require any custom integration for Home Assistant since communication is solely via MQTT.
Breaking Changes when upgrading from Version 0.3
With version 0.3 AstroLive did only use Home Assistant sensors and camera entities. This simplified the initial implementations but using a sensor might not always be the appropriate entity type. An on/off switch in the Pegasus UPB2 should either be represented as a binary_sensor or even better as an actual switch.
For this reason some of the entities in your Home Assistant will automatically change from sensor to switch or binary_sensor when using AstroLive 0.4+. This likely results in missing entities in your Lovelace configuration or automations which should easily be fixed by changing the type there as well.
See chapter Devices and Sensors, Binary Sensors, Switches and Cameras for details.
Requirements
- A windows (mini) pc/notebook controlling your scope
- ASCOM Platform
- ASCOMRemote.
- Container runtime engine (e.g. Docker).
- MQTT Broker (e.g. Mosquitto).
- A recent version of Home Assistant with MQTT autodiscovery enabled.
My Personal Setup
To give you an idea how I did setup my observatory together with AstroLive and AstroWeather here's my setup:
- Hardware
- Telescopes: Skywatcher Esprit 120ED, William Optics AP 71
- Mounts: Skywatcher EQ6-R, iOptron GEM45
- Camera: QHY268c
- Guide Camera: QHY5III462c
- Off Axis Guider: OAG-M
- Filter Wheel: QHY CFW3M-US
- Switch: PegasusAstro Ultimate Powerbox v2
- Focuser: PegasusAstro Focus Cube, ZWO EAF
- Mini PC: MeLE Quieter2 8GB 256GB Windows 11
- Software:
- NINA, PHD2, ASCOM Platform, EQASCOM, QHYCCD Win AllInOne, Polemaster, iPolar, PegasusAstro Unity, Dropbox, HASS.Agent, Libre Hardware Monitor

All off the software is running on the MeLE Quieter2 mini pc which I mounted on top of the scope. I configured NINA to store image files within a dedicated directory which is synced by Dropbox. This directory is then monitored by AstroLive to enable the image processing.
Since NINA does provide it's own drivers to interact with the QHY camera I did not connect the cameras to ASCOMRemote. During my tests with AstroLive I encountered problems while imaging if AstroLive uses the Camera API of ASCOMRemote. I need to investigate this further, but processing the resulting image stored on disk is working nicely for me and lowers the load on the mini pc anyways.
Usage
Ensure to have the ASCOM Platform deployed on your astro imaging server.
Installation and Configuration of ASCOM Remote Server
Download and install the latest version from here: ASCOMRemote
<details><summary><b>Show instructions</b></summary>Add the devices you want to use in conjunction of AstroLive. The following screenshot show a connected Focuser, Telescope and Switch.

You need to press [Setup] for each configured device to connect it to the ASCOM Remote Server Configuration.

Set a name for the servers location (e.g. Backyard) and specify the Server IP Address. This is the IP the Remote Server is running on. Choose a port (default is 11111) and leave the rest to the defaults.

Press [OK]
</details>Links:
Get and Configure AstroLive
Clone AstroLive
git clone https://github.com/mawinkler/astrolive
Now, create a default.cfg.yaml based on the supplied default.cfg.yaml.sample and modify it to your needs. The yaml should be pretty self explanatory :-)
cp astrolive/default.cfg.yaml.sample astrolive/default.cfg.yaml
<details><summary><b>Show YAML</b></summary>Note: If you are using drivers provided with the sequencer software, using ASCOM remote in parallel will mess up the imaging session when accessing the camera API. Tested with QHY and N.I.N.A./PHD2. For that reason, I'm always using the
camera_filecomponent witch checks for the latest FITS-file published within a given directory tree.
default:
include: backyard
backyard:
observatory:
# Name of the observatory
comment: Backyard Scope
# Longitude
lon: <LONGITUDE>
# Lattitude
lat: <LATTITUDE>
# Elevation
elev: <ELEVATION>
# Communication protocol
protocol: alpaca
# Address of the ASCOM Remote server
address: http://<IP OF ASCOMRemote>:11111/api/v1
components:
telescope:
# Kind of the device
kind: telescope
comment: <NAME OF YOUR SCOPE>
# Device number as configured in ASCOM Remote
device_number: 0
# Name prefix of the created sensor in MQTT
friendly_name: <NAME OF YOUR SCOPE>
# Update interval in seconds
update_interval: 15
# List of components belonging to the telescope
components:
# Note to ASCOM:
# If you are using drivers provided with the sequencer software,
# using ASCOM remote in parallel will mess up the imaging session.
# Tested with QHY and N.I.N.A./PHD2.
# Valid device kinds are
# telescope: Telescope
# dome: Dome
# camera: Camera
# filterwheel: Filter Wheel
# focuser: Focuser
# rotator: Rotator
# switch: Switch
# safetymonitor: SafetyMonitor
# camera_file: Camera File, reads and processes the latest image within
# from a configured location.
# camera:
# # Kind of the device
# kind: camera
# # Device number as configured in ASCOM Remote
# device_number: 0
# # Name prefix of the created sensor in MQTT
# friendly_name: <NAME OF YOUR IMAGING CAMERA>
# # Get image via ASCOM remote. If false, process sensors only
# image: true
# # Update interval in seconds
# update_interval: 60
# guiding_camera:
# kind: camera
# device_number: 1
# friendly_name: <NAME OF YOUR GUIDING CAMERA>
# image: true
# update_interval: 60
camera_file:
kind: file
friendly_name: <NAME OF YOUR IMAGING CAMERA>
# Monitoring directory for new image files
# Only FITS files are supported
monitor: '/fits'
update_interval: 60
focuser:
kind: focuser
friendly_name: <NAME OF YOUR FOCUSER>
update_interval: 15
switch:
kind: switch
friendly_name: <NAME OF YOUR SWITCH>
update_interval: 30
# Optionally define the number of available switches.
# If not set astrolive will query the switch which is NOT
# su
Related Skills
node-connect
347.0kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
107.8kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
347.0kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
347.0kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
