mountcontrol/mcc/mcc_moving_model_common.h
2025-09-01 18:25:47 +03:00

64 lines
1.9 KiB
C++

#pragma once
/* MOUNT CONTROL COMPONENTS LIBRARY */
/* COMMON DEFINITIONS FOR SIMPLE SLEWING, TRACKING AND GUIDING MODEL IMPLEMENTATIONS */
#include <chrono>
#include "mcc_angle.h"
namespace mcc
{
struct MccSimpleMovingModelParams {
// ******* common for all modes *******
// mean celestial rate
static constexpr double sideralRate = 15.0410686_arcsecs; // in radians per second
// timeout to telemetry updating
std::chrono::seconds telemetryTimeout{3};
// minimal time to prohibited zone (at current speed in slewing mode). if it is lesser then exit with error
std::chrono::seconds minTimeToPZone{10};
// ******* slewing mode *******
bool slewAndStop{false}; // slew to target and stop mount
// coordinates difference to stop slewing (in radians)
double slewToleranceRadius{5.0_arcsecs};
// target-mount coordinate difference to start adjusting of slewing (in radians)
double adjustCoordDiff{slewToleranceRadius * 10.0};
// slew process timeout
std::chrono::seconds slewTimeout{3600};
double slewXRate{0.0}; // maximal slewing rate (0 means move with maximal allowed rate)
double slewYRate{0.0}; // maximal slewing rate (0 means move with maximal allowed rate)
std::chrono::milliseconds adjustCycleInterval{500}; // minimum time between two successive adjustments
double adjustXRate{5.0_arcmins}; // maximal adjusting rate (a rate at the final slewing stage)
double adjustYRate{5.0_arcmins}; // maximal adjusting rate (a rate at the final slewing stage)
// ******* tracking mode *******
double trackSpeedX{};
double trackSpeedY{};
// ******* guiding mode *******
double correctionRange[2]{0.3_arcsecs, 3.0_arcsecs};
bool dualAxisGuiding{true}; // mount must be of an equatorial type: false means guiding along only HA-axis
};
} // namespace mcc