M1M3 Support System
Loading...
Searching...
No Matches
RaisingLoweringInfo.h
1/*
2 * This file is part of LSST M1M3 support system package.
3 *
4 * Developed for the Vera C. Rubin Telescope and Site System.
5 * This product includes software developed by the LSST Project
6 * (https://www.lsst.org).
7 * See the COPYRIGHT file at the top-level directory of this distribution
8 * for details of code ownership.
9 *
10 * This program is free software: you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation, either version 3 of the License, or
13 * (at your option) any later version.
14 *
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
19 *
20 * You should have received a copy of the GNU General Public License
21 * along with this program. If not, see <https://www.gnu.org/licenses/>.
22 */
23#ifndef LSST_RAISINGLOWERINGINFO_H
24#define LSST_RAISINGLOWERINGINFO_H
25
26#include <SAL_MTM1M3.h>
27
28#include <cRIO/Singleton.h>
29
30namespace LSST {
31namespace M1M3 {
32namespace SS {
33
37class RaisingLoweringInfo : public MTM1M3_logevent_raisingLoweringInfoC,
38 public cRIO::Singleton<RaisingLoweringInfo> {
39public:
41
47 void sendUpdates(bool force = false);
48
55 float supportRatio() { return weightSupportedPercent / 100.0; }
56
57 void setTimeTimeout(double new_timeTimeout);
58
64
70
75
80
88
96
100 void setHPWait(size_t hpIndex, bool newWait);
101
102 void setFAXWait(size_t faXIndex, bool newWait);
103 void setFAYWait(size_t faYIndex, bool newWait);
104 void setFAZWait(size_t faZIndex, bool newWait);
105
111 void setWaitAirPressure(bool newWait);
112
113private:
114 bool _updated;
115};
116
117} // namespace SS
118} // namespace M1M3
119} // namespace LSST
120
121#endif // !LSST_RAISINGLOWERINGINFO_H
Manipulates RaisingLoweringInfo event fields.
Definition RaisingLoweringInfo.h:38
float supportRatio()
Returns ratio of mirror mass supported.
Definition RaisingLoweringInfo.h:55
void setWaitAirPressure(bool newWait)
Sets waitAirPressure field.
Definition RaisingLoweringInfo.cpp:124
void incSupportPercentage()
Increases mirrror support percentage by RaiseIncrementPercentage setting value.
Definition RaisingLoweringInfo.cpp:51
void fillSupportPercentage()
Sets support percentage to 100%.
Definition RaisingLoweringInfo.cpp:77
void setHPWait(size_t hpIndex, bool newWait)
Sets waitHardpoint field, triggers updates if needed.
Definition RaisingLoweringInfo.cpp:96
bool supportPercentageFilled()
Is mirror support percentage equal or more than 100%?
Definition RaisingLoweringInfo.cpp:85
void zeroSupportPercentage()
Sets support percentage to 0%.
Definition RaisingLoweringInfo.cpp:69
void decSupportPercentage()
Decrements mirror support percentage by LowerDecrementPercentage setting value.
Definition RaisingLoweringInfo.cpp:60
bool supportPercentageZeroed()
Is mirror support percentage less or equal to 0?
Definition RaisingLoweringInfo.cpp:87
void sendUpdates(bool force=false)
Sends updates to RaisingLoweringInfo structure.
Definition RaisingLoweringInfo.cpp:44