1
0
mirror of https://github.com/peterantypas/maiana.git synced 2025-05-27 21:00:24 -07:00

Fixed GPIO handling

This commit is contained in:
Peter Antypas 2023-03-11 08:42:28 -08:00
parent d820455b4a
commit 1bd06b3b2d
3 changed files with 6 additions and 5 deletions

View File

@ -122,9 +122,9 @@ void bsp_hw_init()
config_gpio(GPIO_STM32_TX_EN, GPIO_MODE_OUTPUT_OD, false, false);
gpio_set_level(GPIO_STM32_TX_EN, 1);
//gpio_set_level(GPIO_STM32_RESET_N, 0);
//usleep(2000);
//gpio_set_level(GPIO_STM32_RESET_N, 1);
gpio_set_level(GPIO_STM32_RESET_N, 0);
usleep(2000);
gpio_set_level(GPIO_STM32_RESET_N, 1);
#if 0
gpio_set_direction(GPIO_RED_LED, GPIO_MODE_OUTPUT);

View File

@ -105,6 +105,7 @@ esp_err_t http_wifi_post_handler(httpd_req_t *req)
return ESP_FAIL;
}
ESP_LOGI(TAG, "Setting WiFi mode to %d, with SSID %s and password %s", wifi_mode, ssid, pwd);
config_wifi(wifi_mode, ssid, pwd);
httpd_resp_send(req, NULL, 0);
esp_event_post(MAIANA_EVENT, REBOOT_EVENT, NULL, 0, 0);

View File

@ -54,8 +54,8 @@ CONFIG_BOOTLOADER_LOG_LEVEL=3
CONFIG_BOOTLOADER_VDDSDIO_BOOST_1_9V=y
CONFIG_BOOTLOADER_FACTORY_RESET=y
CONFIG_BOOTLOADER_NUM_PIN_FACTORY_RESET=20
CONFIG_BOOTLOADER_FACTORY_RESET_PIN_LOW=y
# CONFIG_BOOTLOADER_FACTORY_RESET_PIN_HIGH is not set
# CONFIG_BOOTLOADER_FACTORY_RESET_PIN_LOW is not set
CONFIG_BOOTLOADER_FACTORY_RESET_PIN_HIGH=y
CONFIG_BOOTLOADER_OTA_DATA_ERASE=y
CONFIG_BOOTLOADER_DATA_FACTORY_RESET="nvs"
# CONFIG_BOOTLOADER_APP_TEST is not set