From 7eb84626f3410e7c413d0cb40c1d75da2ff2540d Mon Sep 17 00:00:00 2001 From: Jasem Mutlaq Date: Mon, 9 Oct 2023 18:31:50 +0300 Subject: [PATCH] Set park type per dome type --- drivers/dome/dome_script.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/dome/dome_script.cpp b/drivers/dome/dome_script.cpp index cadf47249a..55b893ac9f 100644 --- a/drivers/dome/dome_script.cpp +++ b/drivers/dome/dome_script.cpp @@ -60,7 +60,6 @@ const char *DomeScript::getDefaultName() bool DomeScript::initProperties() { INDI::Dome::initProperties(); - SetParkDataType(PARK_AZ); #if defined(__APPLE__) ScriptsTP[SCRIPT_FOLDER].fill("SCRIPT_FOLDER", "Folder", "/usr/local/share/indi/scripts"); #else @@ -88,9 +87,15 @@ bool DomeScript::initProperties() TypeSP.load(); if (TypeSP[Dome].getState() == ISS_ON) + { + SetParkDataType(PARK_AZ); SetDomeCapability(DOME_CAN_PARK | DOME_CAN_ABORT | DOME_CAN_ABS_MOVE | DOME_HAS_SHUTTER); + } else + { + SetParkDataType(PARK_NONE); SetDomeCapability(DOME_CAN_PARK | DOME_CAN_ABORT); + } setDefaultPollingPeriod(2000); return true;