Git Product home page Git Product logo

esp-stm8-flasher's Introduction

esp-stm8-flasher

ESP8266 application for flashing STM8S microcontrollers via stm8-bootloader.

Features

  • Remote terminal - UART<->WiFi bridge
  • File storage - store multiple firmware images in flash
  • Web GUI - manage remote file storage and perform drag-and-drop uploads directly from browser

Build instructions

Precompiled binaries for ESP8266 and STM8S003 are located inside esp-stm8-flasher/firmware.

git clone --recursive https://github.com/lujji/esp-stm8-flasher

Create ./esp-stm8-flasher/esp-open-rtos/include/private_ssid_config.h with two macro definitions:

#define WIFI_SSID "mywifissid"
#define WIFI_PASS "my secret password"

Build and flash the firmware

make html && make -j4 flash

Configuration

You may want to change a few things inside config.h:

  • BLOCK_SIZE - STM8 flash block size. This should match bootloader configuration
  • TELNET_PORT - remote terminal port
  • RST_PIN - GPIO pin for resetting STM8

FLASH_SIZE and SPIFFS_SIZE are set in Makefile according to the flash size of the ESP8266 module.

STM8 bootloader should be compiled with BOOT_PIN set to PD6 - this way RX pin will be used to detect entry condition.

Wiring

ESP8266 STM8
GPIO1 (TX) PD6 (RX)
GPIO3 (RX) PD5 (TX)
GPIO5 nRST

Uploading the firmware

Uploading and flashing the firmware can be done either from Web GUI or the command-line utility:

python esfutil.py -p firmware.bin 192.168.100.6

This performs three operations: upload file to remote storage, flash the firmware, delete file from storage. Utility supports other commands for manipulating remote file system, see --help for more details. This utility requires websocket module, which can be installed via pip.

Remote terminal

This project provides a buffered serial bridge. Default port is 23.

telnet 192.168.100.6 23

esp-stm8-flasher's People

Contributors

lujji avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

esp-stm8-flasher's Issues

ESP-14

Is it possible to both flash the esp8266 of the ESP-14 and also flash the bootloader to the STM8S003. The Module has ESP_GPIO0 pin and RX/TX pins on the STM8S, that are also connected with the esp8266 RX/TX pins.

Seems to me the ESP-14 is the perfect module for this project.

IMG_20220920_012706
IMG_20220920_012630

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.