mirror of
https://github.com/esphome/esphome.git
synced 2024-11-27 17:27:59 +01:00
lint
This commit is contained in:
parent
4ec62a2be6
commit
28dd222283
6 changed files with 9 additions and 10 deletions
|
@ -51,6 +51,8 @@ ModemComponent::ModemComponent() {
|
|||
global_modem_component = this;
|
||||
}
|
||||
|
||||
void ModemComponent::enable_debug() { esp_log_level_set("command_lib", ESP_LOG_VERBOSE); }
|
||||
|
||||
std::string ModemComponent::send_at(const std::string &cmd) {
|
||||
std::string result = "ERROR";
|
||||
command_result status = command_result::FAIL;
|
||||
|
|
|
@ -61,7 +61,7 @@ class ModemComponent : public Component {
|
|||
void set_gnss_power_command(const std::string &at_command) { this->gnss_power_command_ = at_command; }
|
||||
void set_not_responding_cb(Trigger<> *not_responding_cb) { this->not_responding_cb_ = not_responding_cb; }
|
||||
void enable_cmux() { this->cmux_ = true; }
|
||||
void enable_debug() { esp_log_level_set("command_lib", ESP_LOG_VERBOSE); }
|
||||
void enable_debug();
|
||||
void add_init_at_command(const std::string &cmd) { this->init_at_commands_.push_back(cmd); }
|
||||
bool is_connected() { return this->component_state_ == ModemComponentState::CONNECTED; }
|
||||
bool is_disabled() { return this->component_state_ == ModemComponentState::DISABLED; }
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
import esphome.codegen as cg
|
||||
from esphome.components import sensor
|
||||
from esphome.components.modem import (
|
||||
CONF_ENABLE_GNSS,
|
||||
CONF_MODEM,
|
||||
final_validate_platform,
|
||||
)
|
||||
import esphome.config_validation as cv
|
||||
from esphome.const import (
|
||||
CONF_ALTITUDE,
|
||||
|
@ -20,6 +15,8 @@ from esphome.const import (
|
|||
)
|
||||
import esphome.final_validate as fv
|
||||
|
||||
from .. import CONF_ENABLE_GNSS, CONF_MODEM, final_validate_platform
|
||||
|
||||
CODEOWNERS = ["@oarcher"]
|
||||
|
||||
AUTO_LOAD = []
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
#include "esphome/core/log.h"
|
||||
#include "esphome/core/application.h"
|
||||
|
||||
#include "esphome/components/modem/modem_component.h"
|
||||
#include "../modem_component.h"
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
|
|
@ -1,9 +1,10 @@
|
|||
import esphome.codegen as cg
|
||||
from esphome.components import text_sensor
|
||||
from esphome.components.modem import final_validate_platform
|
||||
import esphome.config_validation as cv
|
||||
from esphome.const import CONF_ID, DEVICE_CLASS_EMPTY
|
||||
|
||||
from .. import final_validate_platform
|
||||
|
||||
CODEOWNERS = ["@oarcher"]
|
||||
|
||||
AUTO_LOAD = []
|
||||
|
|
|
@ -10,8 +10,7 @@
|
|||
#include "esphome/core/log.h"
|
||||
#include "esphome/core/application.h"
|
||||
|
||||
// #include "esphome/components/watchdog/watchdog.h"
|
||||
#include "esphome/components/modem/modem_component.h"
|
||||
#include "../modem_component.h"
|
||||
|
||||
#define ESPHL_ERROR_CHECK(err, message) \
|
||||
if ((err) != ESP_OK) { \
|
||||
|
|
Loading…
Reference in a new issue