GithubHelp home page GithubHelp logo

stm32-uart-dfu's Introduction

stm32-uart-dfu

Simple command-line program that works with stm32 microcontrollers uart bootloader.

Requirements:

pyserial

Usage:

Available dfu operations:

  • get id: prints mcu id (2 bytes)
  • run: MCU jumps at specified address
  • erase: erase specified size of memory at address
  • dump: dump specified size of memory from address to a file
  • load: load binary file to memory at address.

For available commands:

> python3 uart-dfu.py --help

For specific command help:

> python3 uart-dfu.py load --help

Example:

> python3 uart-dfu.py --port /dev/ttyUSB0 load --file firmware.bin --erase -m map.json

Memory map file:

Memory map file contains mcu's flash memory sectors information (address, size). Table with flash memory organization can be found in reference manual in 'embedded flash memory' section.
json file with memory map example for stm32f407 can be found in memory_map directory. Basically this file contains list of dicts like that:

[
  {
    "address": "0x8000000",
    "size": "0x4000"
  },
  {
    "address": "0x8004000",
    "size": "0x4000"
  },
  ...
]

Without memory map only mass erase is available.

stm32-uart-dfu's People

Contributors

abcdeath avatar

Watchers

 avatar

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.