Add servo missing restore option to codegen (#829)

See also https://github.com/esphome/issues/issues/609
This commit is contained in:
Otto Winter
2019-11-02 20:56:42 +01:00
committed by GitHub
parent 75275c4e93
commit dc2279b74f
3 changed files with 5 additions and 1 deletions
+1
View File
@@ -47,6 +47,7 @@ class Servo : public Component {
void set_min_level(float min_level) { min_level_ = min_level; }
void set_idle_level(float idle_level) { idle_level_ = idle_level; }
void set_max_level(float max_level) { max_level_ = max_level; }
void set_restore(bool restore) { restore_ = restore; }
protected:
void save_level_(float v) { this->rtc_.save(&v); }