Instrument Neutral Distributed Interface INDI  1.9.5
vantage.h
Go to the documentation of this file.
1 /*******************************************************************************
2  Copyright(c) 2015 Jasem Mutlaq. All rights reserved.
3 
4  INDI Davis Vantage Pro/Pro2/Vue Weather Driver
5 
6  This program is free software; you can redistribute it and/or modify it
7  under the terms of the GNU General Public License as published by the Free
8  Software Foundation; either version 2 of the License, or (at your option)
9  any later version.
10 
11  This program is distributed in the hope that it will be useful, but WITHOUT
12  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14  more details.
15 
16  You should have received a copy of the GNU Library General Public License
17  along with this library; see the file COPYING.LIB. If not, write to
18  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
19  Boston, MA 02110-1301, USA.
20 
21  The full GNU General Public License is included in this distribution in the
22  file called LICENSE.
23 *******************************************************************************/
24 
25 #pragma once
26 
27 #include "indiweather.h"
28 
29 class Vantage : public INDI::Weather
30 {
31  public:
32  Vantage();
33  virtual ~Vantage() = default;
34 
35  // Generic indi device entries
36  virtual bool Handshake() override;
37  virtual const char *getDefaultName() override;
38 
39  virtual bool initProperties() override;
40 
41  protected:
42  virtual IPState updateWeather() override;
43 
44  private:
45  bool ack();
46  bool wakeup();
47 };
IPState
IPState
Property state.
Definition: indiapi.h:158
INDI::Weather
Definition: indiweather.h:68
Vantage::updateWeather
virtual IPState updateWeather() override
updateWeather Update weather conditions from device or service. The function should not change the st...
Definition: vantage.cpp:114
Vantage::Vantage
Vantage()
Definition: vantage.cpp:74
Vantage::~Vantage
virtual ~Vantage()=default
Vantage::getDefaultName
virtual const char * getDefaultName() override
Definition: vantage.cpp:79
Vantage
Definition: vantage.h:29
Vantage::Handshake
virtual bool Handshake() override
perform handshake with device to check communication
Definition: vantage.cpp:109
indiweather.h
Vantage::initProperties
virtual bool initProperties() override
Initilize properties initial state and value. The child class must implement this function.
Definition: vantage.cpp:84