diff --git a/esphome/components/shell/__init__.py b/esphome/components/shell/__init__.py deleted file mode 100644 index 89cf30c053..0000000000 --- a/esphome/components/shell/__init__.py +++ /dev/null @@ -1,31 +0,0 @@ -import esphome.codegen as cg -import esphome.config_validation as cv -from esphome.const import ( - CONF_ID, -) -from esphome.components.nrf52 import add_zephyr_prj_conf_option - -shell_ns = cg.esphome_ns.namespace("shell") -Shell = shell_ns.class_("Shell", cg.Component) - -CONFIG_SCHEMA = cv.All( - cv.Schema( - { - cv.GenerateID(): cv.declare_id(Shell), - } - ).extend(cv.COMPONENT_SCHEMA), - cv.only_with_zephyr, -) - - -async def to_code(config): - var = cg.new_Pvariable(config[CONF_ID]) - await cg.register_component(var, config) - add_zephyr_prj_conf_option("CONFIG_SHELL", True) - add_zephyr_prj_conf_option("CONFIG_SHELL_BACKENDS", True) - add_zephyr_prj_conf_option("CONFIG_SHELL_BACKEND_SERIAL", True) - add_zephyr_prj_conf_option("CONFIG_NET_SHELL_DYN_CMD_COMPLETION", True) - add_zephyr_prj_conf_option("CONFIG_NET_SHELL", True) - add_zephyr_prj_conf_option("CONFIG_GPIO_SHELL", True) - # add_zephyr_prj_conf_option("CONFIG_ADC_SHELL", True) - add_zephyr_prj_conf_option("CONFIG_NET_L2_BT_SHELL", True) diff --git a/esphome/components/shell/shell.cpp b/esphome/components/shell/shell.cpp deleted file mode 100644 index 3496cac396..0000000000 --- a/esphome/components/shell/shell.cpp +++ /dev/null @@ -1,21 +0,0 @@ -#include "shell.h" -#include - -struct device; - -namespace esphome { -namespace shell { - -void Shell::setup() { -#if DT_NODE_HAS_COMPAT(DT_CHOSEN(zephyr_shell_uart), zephyr_cdc_acm_uart) - const device *dev = DEVICE_DT_GET(DT_CHOSEN(zephyr_shell_uart)); - if (!device_is_ready(dev) || usb_enable(NULL)) { - return; - } -#else -#error "shell is not set in device tree" -#endif -} - -} // namespace shell -} // namespace esphome diff --git a/esphome/components/shell/shell.h b/esphome/components/shell/shell.h deleted file mode 100644 index 54db86dd30..0000000000 --- a/esphome/components/shell/shell.h +++ /dev/null @@ -1,10 +0,0 @@ -#pragma once -#include "esphome/core/component.h" - -namespace esphome { -namespace shell { -class Shell : public Component { - void setup() override; -}; -} -}