|
Instrument Neutral Distributed Interface INDI 2.2.5
|
The following INDI properties are used to manage math plugins. More...
#include <MathPluginManagement.h>
Public Types | |
| enum | MountType { EQUATORIAL , ALTAZ } |
| Describes the basic type of the mount. More... | |
| typedef enum INDI::AlignmentSubsystem::MathPluginManagement::MountType | MountType_t |
Public Member Functions | |
| MathPluginManagement () | |
| Default constructor. | |
| virtual | ~MathPluginManagement () |
| Virtual destructor. | |
| void | InitProperties (Telescope *pTelescope) |
| Initialize alignment math plugin properties. It is recommended to call this function within initProperties() of your primary device. | |
| void | ProcessSwitchProperties (Telescope *pTelescope, const char *name, ISState *states, char *names[], int n) |
| Call this function from within the ISNewSwitch processing path. The function will handle any math plugin switch properties. | |
| void | ProcessTextProperties (Telescope *pTelescope, const char *name, char *texts[], char *names[], int n) |
| Call this function from within the ISNewText processing path. The function will handle any math plugin text properties. This text property is at the moment only contained in the config file so this will normally only have work to do when the config file is loaded. | |
| void | SaveConfigProperties (FILE *fp) |
| Call this function to save persistent math plugin properties. This function should be called from within the saveConfigItems function of your driver. | |
| void | SetApproximateMountAlignmentFromMountType (MountType_t Type) |
| Call this function to set the ApproximateMountAlignment property of the current Math Plugin. The alignment database should be initialised before this function is called so that it can use the DatabaseReferencePosition to determine which hemisphere the current observing site is in. For equatorial the ApproximateMountAlignment property will set to NORTH_CELESTIAL_POLE for sites in the northern hemisphere and SOUTH_CELESTIAL_POLE for sites in the southern hemisphere. For altaz mounts the ApproximateMountAlignment will be set to ZENITH. | |
| void | SetCurrentInMemoryDatabase (InMemoryDatabase *pDatabase) |
| Set the current in memory database. | |
| void | SetAlignmentSubsystemActive (bool enable) |
| SetAlignmentSubsystemActive Enable or Disable alignment subsystem. | |
| bool | IsAlignmentSubsystemActive () const |
| Return status of alignment subsystem. | |
| MountAlignment_t | GetApproximateMountAlignment () |
| Get the approximate alignment of the mount. | |
| bool | Initialise (InMemoryDatabase *pInMemoryDatabase) |
| Initialise or re-initialise the math plugin. Re-reading the in memory database as necessary. | |
| void | SetApproximateMountAlignment (MountAlignment_t ApproximateAlignment) |
| Set the approximate alignment of the mount. | |
| bool | TransformCelestialToTelescopeJD (double RightAscension, double Declination, double JulianDate, TelescopeDirectionVector &ApparentTelescopeDirectionVector) |
| TransformCelestialToTelescopeJD Transforms Celestial (Sky) Coords to Mount Coordinates. | |
| bool | TransformTelescopeToCelestialJD (const TelescopeDirectionVector &ApparentTelescopeDirectionVector, double &RightAscension, double &Declination, double JulianDate) |
| TransformTelescopeToCelestialJD Transforms Mount Coords to Celestial (Sky) Coordinates. | |
| bool | TransformCelestialToTelescope (const double RightAscension, const double Declination, double JulianOffset, TelescopeDirectionVector &ApparentTelescopeDirectionVector) |
| TransformCelestialToTelescope Compat shim - resolves JD and delegates to TransformCelestialToTelescopeJD. | |
| bool | TransformTelescopeToCelestial (const TelescopeDirectionVector &ApparentTelescopeDirectionVector, double &RightAscension, double &Declination, double JulianOffset=0) |
| TransformTelescopeToCelestial Compat shim - resolves JD and delegates to TransformTelescopeToCelestialJD. | |
The following INDI properties are used to manage math plugins.
This class also provides function links to the currently selected math plugin
Definition at line 34 of file MathPluginManagement.h.
| typedef enum INDI::AlignmentSubsystem::MathPluginManagement::MountType INDI::AlignmentSubsystem::MathPluginManagement::MountType_t |
Describes the basic type of the mount.
| Enumerator | |
|---|---|
| EQUATORIAL | |
| ALTAZ | |
Definition at line 40 of file MathPluginManagement.h.
| INDI::AlignmentSubsystem::MathPluginManagement::MathPluginManagement | ( | ) |
Default constructor.
Definition at line 20 of file MathPluginManagement.cpp.
|
inlinevirtual |
Virtual destructor.
Definition at line 46 of file MathPluginManagement.h.
|
virtual |
Get the approximate alignment of the mount.
Reimplemented from INDI::AlignmentSubsystem::MathPlugin.
Definition at line 373 of file MathPluginManagement.cpp.
|
virtual |
Initialise or re-initialise the math plugin. Re-reading the in memory database as necessary.
Reimplemented from INDI::AlignmentSubsystem::MathPlugin.
Definition at line 378 of file MathPluginManagement.cpp.
| void INDI::AlignmentSubsystem::MathPluginManagement::InitProperties | ( | Telescope * | pTelescope | ) |
Initialize alignment math plugin properties. It is recommended to call this function within initProperties() of your primary device.
| [in] | pTelescope | Pointer to the child INDI::Telecope class |
Definition at line 29 of file MathPluginManagement.cpp.
|
inline |
Return status of alignment subsystem.
Definition at line 106 of file MathPluginManagement.h.
| void INDI::AlignmentSubsystem::MathPluginManagement::ProcessSwitchProperties | ( | Telescope * | pTelescope, |
| const char * | name, | ||
| ISState * | states, | ||
| char * | names[], | ||
| int | n | ||
| ) |
Call this function from within the ISNewSwitch processing path. The function will handle any math plugin switch properties.
| [in] | pTelescope | Pointer to the child INDI::Telecope class |
| [in] | name | vector property name |
| [in] | states | states as passed by the client |
| [in] | names | names as passed by the client |
| [in] | n | number of values and names pair to process. |
Definition at line 233 of file MathPluginManagement.cpp.
| void INDI::AlignmentSubsystem::MathPluginManagement::ProcessTextProperties | ( | Telescope * | pTelescope, |
| const char * | name, | ||
| char * | texts[], | ||
| char * | names[], | ||
| int | n | ||
| ) |
Call this function from within the ISNewText processing path. The function will handle any math plugin text properties. This text property is at the moment only contained in the config file so this will normally only have work to do when the config file is loaded.
| [in] | pTelescope | Pointer to the child INDI::Telecope class |
| [in] | name | vector property name |
| [in] | texts | texts as passed by the client |
| [in] | names | names as passed by the client |
| [in] | n | number of values and names pair to process. |
Definition at line 94 of file MathPluginManagement.cpp.
| void INDI::AlignmentSubsystem::MathPluginManagement::SaveConfigProperties | ( | FILE * | fp | ) |
Call this function to save persistent math plugin properties. This function should be called from within the saveConfigItems function of your driver.
| [in] | fp | File pointer passed into saveConfigItems |
Definition at line 344 of file MathPluginManagement.cpp.
| void INDI::AlignmentSubsystem::MathPluginManagement::SetAlignmentSubsystemActive | ( | bool | enable | ) |
SetAlignmentSubsystemActive Enable or Disable alignment subsystem.
Definition at line 337 of file MathPluginManagement.cpp.
|
virtual |
Set the approximate alignment of the mount.
| [in] | ApproximateAlignment | - the approximate alignment of the mount |
Reimplemented from INDI::AlignmentSubsystem::MathPlugin.
Definition at line 383 of file MathPluginManagement.cpp.
| void INDI::AlignmentSubsystem::MathPluginManagement::SetApproximateMountAlignmentFromMountType | ( | MountType_t | Type | ) |
Call this function to set the ApproximateMountAlignment property of the current Math Plugin. The alignment database should be initialised before this function is called so that it can use the DatabaseReferencePosition to determine which hemisphere the current observing site is in. For equatorial the ApproximateMountAlignment property will set to NORTH_CELESTIAL_POLE for sites in the northern hemisphere and SOUTH_CELESTIAL_POLE for sites in the southern hemisphere. For altaz mounts the ApproximateMountAlignment will be set to ZENITH.
| [in] | Type | the mount type either EQUATORIAL or ALTAZ |
Definition at line 351 of file MathPluginManagement.cpp.
|
inline |
Set the current in memory database.
| [in] | pDatabase | A pointer to the current in memory database |
Definition at line 93 of file MathPluginManagement.h.
|
virtual |
TransformCelestialToTelescope Compat shim - resolves JD and delegates to TransformCelestialToTelescopeJD.
| RightAscension | Sky Right Ascension in hours. |
| Declination | Sky Declination in degrees |
| JulianOffset | Julian time Offset in days added to ln_get_julian_from_sys() |
| ApparentTelescopeDirectionVector | Output Apparent Telescope Direction Vector |
Implements INDI::AlignmentSubsystem::MathPlugin.
Definition at line 410 of file MathPluginManagement.cpp.
|
virtual |
TransformCelestialToTelescopeJD Transforms Celestial (Sky) Coords to Mount Coordinates.
| RightAscension | Sky Right Ascension in hours. |
| Declination | Sky Declination in degrees |
| JulianDate | Absolute Julian Date (days) |
| ApparentTelescopeDirectionVector | Output Apparent Telescope Direction Vector |
Reimplemented from INDI::AlignmentSubsystem::MathPlugin.
Definition at line 388 of file MathPluginManagement.cpp.
|
virtual |
TransformTelescopeToCelestial Compat shim - resolves JD and delegates to TransformTelescopeToCelestialJD.
| ApparentTelescopeDirectionVector | Input Apparent Telescope Direction Vector |
| RightAscension | Output Celestial Right Ascension |
| Declination | Output Celestial Declination |
| JulianOffset | Julian time Offset in days added to ln_get_julian_from_sys() (default 0) |
Implements INDI::AlignmentSubsystem::MathPlugin.
Definition at line 419 of file MathPluginManagement.cpp.
|
virtual |
TransformTelescopeToCelestialJD Transforms Mount Coords to Celestial (Sky) Coordinates.
| ApparentTelescopeDirectionVector | Input Apparent Telescope Direction Vector |
| RightAscension | Output Celestial Right Ascension |
| Declination | Output Celestial Declination |
| JulianDate | Absolute Julian Date (days) |
Reimplemented from INDI::AlignmentSubsystem::MathPlugin.
Definition at line 399 of file MathPluginManagement.cpp.