#ifndef ESP_SERIAL_FLASHER_H #define ESP_SERIAL_FLASHER_H #ifdef __cplusplus extern "C" { #endif #include "serial_io.h" #include "osi_api.h" uint8_t bootloader_uart_init(int new_baudrate); uint8_t bootloader_uart_deinit(void); uint8_t esp32_enter_bootloader(void); uint8_t esp32_exit_bootloader(void); esp_loader_error_t loader_port_serial_write(const uint8_t *data, uint16_t size, uint32_t timeout); esp_loader_error_t loader_port_serial_read(uint8_t *data, uint16_t size, uint32_t timeout); void loader_port_delay_ms(uint32_t ms); void loader_port_start_timer(uint32_t ms); uint32_t loader_port_remaining_time(void); uint8_t loader_port_change_baudrate(uint32_t baudrate); void loader_port_debug_print(const char *str); #ifdef __cplusplus } /*"C" */ #endif #endif