Skip to content

Commit

Permalink
Rename mgos::ScopedTiemr to mgos::Timer
Browse files Browse the repository at this point in the history
  • Loading branch information
rojer committed Dec 30, 2020
1 parent 3bbbc47 commit 47e0c46
Show file tree
Hide file tree
Showing 8 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/ADE7953/shelly_pm_ade7953.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ class ADE7953PowerMeter : public PowerMeter {
struct mgos_ade7953 *const ade7953_;
const int channel_;
float aea_acc_ = 0; // Accumulated active energy.
mgos::ScopedTimer acc_timer_;
mgos::Timer acc_timer_;
};

} // namespace shelly
2 changes: 1 addition & 1 deletion src/BL0937/shelly_pm_bl0937.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class BL0937PowerMeter : public PowerMeter {
float apa_ = 0; // Last active power reading, W.
float aea_ = 0; // Accumulated active energy, Wh.

mgos::ScopedTimer meas_timer_;
mgos::Timer meas_timer_;
};

} // namespace shelly
2 changes: 1 addition & 1 deletion src/shelly_hap_garage_door_opener.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ class GarageDoorOpener : public Component, public mgos::hap::Service {
Output *out_close_, *out_open_;
struct mgos_config_gdo *cfg_;

mgos::ScopedTimer state_timer_;
mgos::Timer state_timer_;

mgos::hap::Characteristic *cur_state_char_ = nullptr;
mgos::hap::Characteristic *tgt_state_char_ = nullptr;
Expand Down
2 changes: 1 addition & 1 deletion src/shelly_hap_sensor_base.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ class SensorBase : public Component, public mgos::hap::Service {
Input::HandlerID handler_id_ = Input::kInvalidHandlerID;

double last_ev_ts_ = 0;
mgos::ScopedTimer auto_off_timer_;
mgos::Timer auto_off_timer_;

SensorBase(const SensorBase &other) = delete;
};
Expand Down
2 changes: 1 addition & 1 deletion src/shelly_hap_window_covering.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ class WindowCovering : public Component, public mgos::hap::Service {

Input::HandlerID in_open_handler_ = Input::kInvalidHandlerID;
Input::HandlerID in_close_handler_ = Input::kInvalidHandlerID;
mgos::ScopedTimer state_timer_;
mgos::Timer state_timer_;

mgos::hap::Characteristic *cur_pos_char_ = nullptr;
mgos::hap::Characteristic *tgt_pos_char_ = nullptr;
Expand Down
2 changes: 1 addition & 1 deletion src/shelly_input_pin.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ class InputPin : public Input {

State state_ = State::kIdle;
int timer_cnt_ = 0;
mgos::ScopedTimer timer_;
mgos::Timer timer_;

InputPin(const InputPin &other) = delete;
};
Expand Down
2 changes: 1 addition & 1 deletion src/shelly_output.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ class OutputPin : public Output {
const int on_value_;

bool pulse_active_ = false;
mgos::ScopedTimer pulse_timer_;
mgos::Timer pulse_timer_;

OutputPin(const OutputPin &other) = delete;
};
Expand Down
2 changes: 1 addition & 1 deletion src/shelly_switch.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ class ShellySwitch : public Component, public mgos::hap::Service {
Input::HandlerID handler_id_ = Input::kInvalidHandlerID;
std::vector<mgos::hap::Characteristic *> state_notify_chars_;

mgos::ScopedTimer auto_off_timer_;
mgos::Timer auto_off_timer_;
bool dirty_ = false;

ShellySwitch(const ShellySwitch &other) = delete;
Expand Down

0 comments on commit 47e0c46

Please sign in to comment.