forked from xiaozhi/xiaozhi-esp32
remove system resets
This commit is contained in:
@@ -23,7 +23,6 @@ private:
|
||||
Button touch_button_;
|
||||
Button volume_up_button_;
|
||||
Button volume_down_button_;
|
||||
SystemReset system_reset_;
|
||||
|
||||
void InitializeDisplayI2c() {
|
||||
i2c_master_bus_config_t bus_config = {
|
||||
@@ -95,10 +94,7 @@ public:
|
||||
boot_button_(BOOT_BUTTON_GPIO),
|
||||
touch_button_(TOUCH_BUTTON_GPIO),
|
||||
volume_up_button_(VOLUME_UP_BUTTON_GPIO),
|
||||
volume_down_button_(VOLUME_DOWN_BUTTON_GPIO),
|
||||
system_reset_(RESET_NVS_BUTTON_GPIO, RESET_FACTORY_BUTTON_GPIO) {
|
||||
// Check if the reset button is pressed
|
||||
system_reset_.CheckButtons();
|
||||
volume_down_button_(VOLUME_DOWN_BUTTON_GPIO) {
|
||||
|
||||
InitializeDisplayI2c();
|
||||
InitializeButtons();
|
||||
|
||||
@@ -32,8 +32,6 @@
|
||||
#define TOUCH_BUTTON_GPIO GPIO_NUM_47
|
||||
#define VOLUME_UP_BUTTON_GPIO GPIO_NUM_40
|
||||
#define VOLUME_DOWN_BUTTON_GPIO GPIO_NUM_39
|
||||
#define RESET_NVS_BUTTON_GPIO GPIO_NUM_1
|
||||
#define RESET_FACTORY_BUTTON_GPIO GPIO_NUM_2
|
||||
|
||||
#define DISPLAY_SDA_PIN GPIO_NUM_41
|
||||
#define DISPLAY_SCL_PIN GPIO_NUM_42
|
||||
|
||||
@@ -33,8 +33,6 @@
|
||||
#define TOUCH_BUTTON_GPIO GPIO_NUM_NC
|
||||
#define VOLUME_UP_BUTTON_GPIO GPIO_NUM_NC
|
||||
#define VOLUME_DOWN_BUTTON_GPIO GPIO_NUM_NC
|
||||
#define RESET_NVS_BUTTON_GPIO GPIO_NUM_NC
|
||||
#define RESET_FACTORY_BUTTON_GPIO GPIO_NUM_NC
|
||||
|
||||
|
||||
#define DISPLAY_BACKLIGHT_PIN GPIO_NUM_42
|
||||
|
||||
@@ -24,7 +24,6 @@ private:
|
||||
Button touch_button_;
|
||||
Button volume_up_button_;
|
||||
Button volume_down_button_;
|
||||
SystemReset system_reset_;
|
||||
|
||||
void InitializeDisplayI2c() {
|
||||
i2c_master_bus_config_t bus_config = {
|
||||
@@ -100,11 +99,7 @@ public:
|
||||
boot_button_(BOOT_BUTTON_GPIO),
|
||||
touch_button_(TOUCH_BUTTON_GPIO),
|
||||
volume_up_button_(VOLUME_UP_BUTTON_GPIO),
|
||||
volume_down_button_(VOLUME_DOWN_BUTTON_GPIO),
|
||||
system_reset_(RESET_NVS_BUTTON_GPIO, RESET_FACTORY_BUTTON_GPIO) {
|
||||
// Check if the reset button is pressed
|
||||
system_reset_.CheckButtons();
|
||||
|
||||
volume_down_button_(VOLUME_DOWN_BUTTON_GPIO) {
|
||||
InitializeDisplayI2c();
|
||||
InitializeButtons();
|
||||
InitializeIot();
|
||||
|
||||
@@ -33,8 +33,6 @@
|
||||
#define TOUCH_BUTTON_GPIO GPIO_NUM_47
|
||||
#define VOLUME_UP_BUTTON_GPIO GPIO_NUM_40
|
||||
#define VOLUME_DOWN_BUTTON_GPIO GPIO_NUM_39
|
||||
#define RESET_NVS_BUTTON_GPIO GPIO_NUM_1
|
||||
#define RESET_FACTORY_BUTTON_GPIO GPIO_NUM_2
|
||||
|
||||
#define DISPLAY_SDA_PIN GPIO_NUM_41
|
||||
#define DISPLAY_SCL_PIN GPIO_NUM_42
|
||||
|
||||
Reference in New Issue
Block a user