21 #ifndef TEENASTRO_FOCUSER_H
22 #define TEENASTRO_FOCUSER_H
35 virtual bool ISNewNumber (
const char *dev,
const char *name,
double values[],
char *names[],
int n);
36 virtual bool ISNewSwitch (
const char *dev,
const char *name,
ISState *states,
char *names[],
int n);
70 bool send(
const char *
const msg);
73 bool sendAndReceive(
const char *
const msg,
char *resp,
int bufsize);
111 bool goTo(uint32_t position);
ISwitchVectorProperty RebootDeviceSP
bool setManualSpeed(uint32_t value)
void deleteOtherProperties()
ISwitchVectorProperty CfgMotorMicrostepsSP
INumberVectorProperty CfgMotorResolutionNP
bool setMotorCurrent(uint32_t value)
bool setManualAcc(uint32_t value)
virtual bool ISNewSwitch(const char *dev, const char *name, ISState *states, char *names[], int n)
Process the client newSwitch command.
bool sendAndReceiveBool(const char *const msg)
bool setConfigItem(char item, uint32_t deviceValue)
void deleteMainControlProperties()
void defineOtherProperties()
virtual bool AbortFocuser()
AbortFocuser all focus motion.
virtual void TimerHit()
Callback function to be called once SetTimer duration elapses.
bool saveConfigItems(FILE *fp)
saveConfigItems Saves the Device Port and Focuser Presets in the configuration file
virtual bool ISNewNumber(const char *dev, const char *name, double values[], char *names[], int n)
Process the client newNumber command.
bool setMotorStepsPerRevolution(uint32_t value)
bool send(const char *const msg)
INumberVectorProperty TempNP
void initPositionPropertiesRanges(uint32_t maxPos)
bool ReverseFocuser(bool enable)
ReverseFocuser Reverse focuser motion direction.
virtual bool SyncFocuser(uint32_t value)
SyncFocuser Set current position to ticks without moving the focuser.
void defineMainControlProperties()
INumberVectorProperty CfgManualSpeedNP
bool setMotorMicrosteps(uint32_t value)
INumberVectorProperty CfgGoToAccNP
bool setMotorResolution(uint32_t value)
ITextVectorProperty DeviceVersionTP
ISwitchVectorProperty GoToParkSP
const char * getDefaultName()
bool SetFocuserMaxPosition(uint32_t value)
SetFocuserMaxPosition Update focuser maximum position. It only updates the PresetNP property limits.
bool sendAndReceive(const char *const msg, char *resp, int bufsize)
ISwitchVectorProperty EraseEEPROMSP
bool updateDeviceVersion()
bool sendAndExpectTimeout(const char *const msg, char *resp, int bufsize)
INumberVectorProperty CfgMotorStepsPerRevolutionNP
INumber CfgMotorStepsPerRevolutionN[1]
INumber CfgMotorCurrentN[1]
ISwitch CfgMotorMicrostepsS[TAF_MICROS_N]
virtual IPState MoveRelFocuser(FocusDirection dir, uint32_t ticks)
MoveFocuser the focuser to an relative position.
bool ISNewNumberHelper(INumberVectorProperty *NP, double values[], char *names[], int n, bool res)
virtual bool updateProperties()
updateProperties is called whenever there is a change in the CONNECTION status of the driver....
INumberVectorProperty CfgManualDecNP
bool SetFocuserSpeed(int value)
SetFocuserSpeed Set Focuser speed.
bool setParkPos(uint32_t value)
INumberVectorProperty CfgParkPosNP
bool setManualDec(uint32_t value)
INumber CfgMotorResolutionN[1]
INumberVectorProperty CurSpeedNP
virtual IPState MoveAbsFocuser(uint32_t ticks)
MoveFocuser the focuser to an absolute position.
virtual bool initProperties()
Initilize properties initial state and value. The child class must implement this function.
virtual bool Handshake()
perform handshake with device to check communication
INumber CfgManualSpeedN[1]
bool updateMotionConfig()
INumberVectorProperty CfgMotorCurrentNP
INumberVectorProperty CfgManualAccNP
bool goTo(uint32_t position)
bool setGoToAcc(uint32_t value)
Number vector property descriptor.
Switch vector property descriptor.
Text vector property descriptor.