{ "info": { "author": "Floris Lambrechts", "author_email": "florisla@gmail.com", "bugtrack_url": null, "classifiers": [ "License :: OSI Approved :: GNU General Public License v3 (GPLv3)", "Natural Language :: English", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Programming Language :: Python :: Implementation :: CPython", "Programming Language :: Python :: Implementation :: PyPy" ], "description": "\nSTM32Loader\n=========== \n\n[![PyPI package](https://badge.fury.io/py/stm32loader.svg)](https://badge.fury.io/py/stm32loader)\n[![Build Status](https://travis-ci.org/florisla/stm32loader.svg?branch=master)](https://travis-ci.org/florisla/stm32loader)\n[![License](https://img.shields.io/pypi/l/stm32loader.svg)](https://pypi.org/project/stm32loader/)\n[![Downloads](https://pepy.tech/badge/stm32loader)](https://pepy.tech/project/stm32loader)\n\nPython script to upload or download firmware to / from\nST Microelectronics STM32 microcontrollers over UART.\n\nAlso supports ST BlueNRG devices, and the SweetPeas bootloader\nfor Wiznet W7500.\n\nCompatible with Python version 3.4 to 3.7 or 2.7.\n\n\nUsage\n-----\n\n```\n./stm32loader.py [-hqVewvrsRB] [-l length] [-p port] [-b baud] [-P parity] [-a address] [-g address] [-f family] [file.bin]\n -e Erase (note: this is required on previously written memory)\n -u Readout unprotect\n -w Write file content to flash\n -v Verify flash content versus local file (recommended)\n -r Read from flash and store in local file\n -l length Length of read\n -p port Serial port (default: /dev/tty.usbserial-ftCYPMYJ)\n -b baud Baud speed (default: 115200)\n -a address Target address (default: 0x08000000)\n -g address Start executing from address (0x08000000, usually)\n -f family Device family to read out device UID and flash size; e.g F1 for STM32F1xx\n\n -h Print this help text\n -q Quiet mode\n -V Verbose mode\n\n -s Swap RTS and DTR: use RTS for reset and DTR for boot0\n -R Make reset active high\n -B Make boot0 active high\n -u Readout unprotect\n -n No progress: don't show progress bar\n -P parity Parity: \"even\" for STM32 (default), \"none\" for BlueNRG\n```\n\n\nExample\n-------\n\n```\nstm32loader.py -p /dev/tty.usbserial-ftCYPMYJ -e -w -v somefile.bin\n```\n\nThis will pre-erase flash, write `somefile.bin` to the flash on the device, and then perform a verification after writing is finished.\n\nYou can skip the `-p` option by configuring environment variable\n`STM32LOADER_SERIAL_PORT`.\nSimilarly, `-f` may be supplied through `STM32LOADER_FAMILY`.\n\n\nReference documents\n-------------------\n\n* ST AN2606: STM32 microcontroller system memory boot mode\n* ST AN3155: USART protocol used in the STM32 bootloader\n* ST AN4872: BlueNRG-1 and BlueNRG-2 UART bootloader protocol\n\n\nAcknowledgement\n---------------\n\nOriginal Version by Ivan A-R (tuxotronic.org).\nContributions by Domen Puncer, James Snyder, Floris Lambrechts,\nAtokulus, sam-bristow, NINI1988, Omer Kilic.\n\nInspiration for features from:\n\n* Configurable RTS/DTR and polarity, extended erase with pages:\n https://github.com/pazzarpj/stm32loader\n\n* Memory unprotect\n https://github.com/3drobotics/stm32loader\n\n* Correct checksum calculation for paged erase:\n https://github.com/jsnyder/stm32loader/pull/4\n\n* ST BlueNRG chip support\n https://github.com/lchish/stm32loader\n\n* Wiznet W7500 chip / SweetPeas custom bootloader support\n https://github.com/Sweet-Peas/WiznetLoader\n\n\nElectrically\n------------\n\nThe below assumes you are connecting an STM32F10x.\nFor other chips, the serial pins and/or the BOOT0 / BOOT1 values\nmay differ.\n\nMake the following connections:\n\n- Serial adapter GND to MCU GND.\n- Serial adapter power to MCU power or vice versa (either 3.3 or 5 Volt).\n- Note if you're using 5 Volt signaling or 3V3 on the serial adapter.\n- Serial TX to MCU RX (PA10).\n- Serial RX to MCU TX (PA9).\n- Serial DTR to MCU RESET.\n- Serial RTS to MCU BOOT0 (or BOOT0 to 3.3V).\n- MCU BOOT1 to GND.\n\nIf either RTS or DTR are not available on your serial adapter, you'll have to\nmanually push buttons or work with jumpers.\nWhen given a choice, set BOOT0 manually high and drive reset through the serial\nadepter (it needs to toggle, whereas BOOT0 does not).\n\n\nNot currently supported\n-----------------------\n\n* Command-line argument for readout protection\n* Command-line argument for write protection/unprotection\n* STM8 devices (ST UM0560)\n* Paged flash erase for devices with page size <> 1 KiB\n* Other bootloader protocols (e.g. I2C, HEX -> implemented in stm32flash)\n\n\nFuture work\n-----------\n* Use proper logging instead of print statements\n* Try Azure pipelines for CI\n* Support PyPy, PyPy3\n* Drop Python2 support; start using intenum for commands and replies\n* Determine flash page size or make this configurable\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/florisla/stm32loader", "keywords": "", "license": "GPL3", "maintainer": "", "maintainer_email": "", "name": "stm32loader", "package_url": "https://pypi.org/project/stm32loader/", "platform": "", "project_url": "https://pypi.org/project/stm32loader/", "project_urls": { "Bug Tracker": "https://github.com/florisla/stm32loader/issues", "Homepage": "https://github.com/florisla/stm32loader", "Source Code": "https://github.com/florisla/stm32loader" }, "release_url": "https://pypi.org/project/stm32loader/0.5.0/", "requires_dist": [ "pyserial", "progress", "setuptools ; extra == 'dev'", "wheel ; extra == 'dev'", "twine ; extra == 'dev'", "pylint ; extra == 'dev'", "flake8 ; extra == 'dev'", "flake8-isort ; extra == 'dev'", "black ; extra == 'dev'" ], "requires_python": ">=2.7.0", "summary": "Flash firmware to STM32 microcontrollers using Python.", "version": "0.5.0" }, "last_serial": 5219719, "releases": { "0.3.1": [ { "comment_text": "", "digests": { "md5": "0bcbaf4be14f0b2b6d4a2eec38dc54e8", "sha256": "2a2c325597231b080145a4c5ad8559bb32400520895a13c627402d66cd6ce1e1" }, "downloads": -1, "filename": "stm32loader-0.3.1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "0bcbaf4be14f0b2b6d4a2eec38dc54e8", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": ">=2.6.0", "size": 9795, "upload_time": "2018-07-31T07:54:43", "url": "https://files.pythonhosted.org/packages/d8/25/bc5f888f9b1d9e9179ea00e61f5c4b04f5bd19d7c12742db506e88c9c780/stm32loader-0.3.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "be82164d48e1672a34a4e726a3d934b6", "sha256": "5217a5f4f5190d32210370026392c92a46f86bc10533449a69288e40b9f9ba72" }, "downloads": -1, "filename": "stm32loader-0.3.1.tar.gz", "has_sig": false, "md5_digest": "be82164d48e1672a34a4e726a3d934b6", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.6.0", "size": 24263, "upload_time": "2018-07-31T07:54:45", "url": "https://files.pythonhosted.org/packages/a8/64/472b0fd8b9b308dc51fa4239d6adebda55eab4eddc253ccd0def06800c46/stm32loader-0.3.1.tar.gz" } ], "0.3.2": [ { "comment_text": "", "digests": { "md5": "0649121a17c4c8d0f84a6f306eaf9398", "sha256": "7611984f3ef1e90069c0dcca0fd7fa3ad1397858f3567c3e67145b7dc4aaef2d" }, "downloads": -1, "filename": "stm32loader-0.3.2-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "0649121a17c4c8d0f84a6f306eaf9398", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": ">=2.7.0", "size": 23029, "upload_time": "2018-07-31T20:57:27", "url": "https://files.pythonhosted.org/packages/2d/b9/5fab78f55033e0712cd3053a559bf658c9172551b93dad24bc87b0792605/stm32loader-0.3.2-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "8de2b0a89f2f1e8727cd8011dc29d68e", "sha256": "0c23866358096353771e966e25d43ff35f6e30096399f8c1663de6740dd8fc07" }, "downloads": -1, "filename": "stm32loader-0.3.2.tar.gz", "has_sig": false, "md5_digest": "8de2b0a89f2f1e8727cd8011dc29d68e", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7.0", "size": 24724, "upload_time": "2018-07-31T20:57:29", "url": "https://files.pythonhosted.org/packages/78/45/f3552b3c918712cb0e94107424fd85e7a190d36a6d785339182b7163fe34/stm32loader-0.3.2.tar.gz" } ], "0.3.3": [ { "comment_text": "", "digests": { "md5": "d0a5c72b6e0d4cbbbf0a0d34f515283e", "sha256": "530c298d6f7219e45c01bbe598810a8978ce2cefd5416b7b347be27d89715914" }, "downloads": -1, "filename": "stm32loader-0.3.3-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "d0a5c72b6e0d4cbbbf0a0d34f515283e", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": ">=2.7.0", "size": 23028, "upload_time": "2018-08-08T13:25:31", "url": "https://files.pythonhosted.org/packages/12/31/4c819c0102abbae8a7b924af3a45ee291ac7bfd1efbf82037e52c024565b/stm32loader-0.3.3-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "35d9de080dade42cdadf1be6e7bb72e9", "sha256": "2c91b03525465d2e4a5d256a529cfde54fbb9954d491d8426bc0001dc4728585" }, "downloads": -1, "filename": "stm32loader-0.3.3.tar.gz", "has_sig": false, "md5_digest": "35d9de080dade42cdadf1be6e7bb72e9", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7.0", "size": 24745, "upload_time": "2018-08-08T13:25:33", "url": "https://files.pythonhosted.org/packages/70/ad/85355454a8826876115901cc605180186803aad8176947f0212bb1e02de5/stm32loader-0.3.3.tar.gz" } ], "0.4.0": [ { "comment_text": "", "digests": { "md5": "37f79ce0d11e9039959f6077ac4f2e8a", "sha256": "8773ee8ddb64cd8d82f81aefa115194f4ff5b0f896749f3bb62855759722cbbe" }, "downloads": -1, "filename": "stm32loader-0.4.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "37f79ce0d11e9039959f6077ac4f2e8a", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": ">=2.7.0", "size": 29119, "upload_time": "2019-04-19T20:17:32", "url": "https://files.pythonhosted.org/packages/9d/ac/58a9c1b27a06bd8107bfb61d3914988e210a6defc7be8d2d071c811141e6/stm32loader-0.4.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "e2b6157bed28b660a022dec3418db15f", "sha256": "1dded82e4cd0a264e56e386b2e8991ff59bf2193b70c56bcc835606f86b5f104" }, "downloads": -1, "filename": "stm32loader-0.4.0.tar.gz", "has_sig": false, "md5_digest": "e2b6157bed28b660a022dec3418db15f", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7.0", "size": 33633, "upload_time": "2019-04-19T20:17:34", "url": "https://files.pythonhosted.org/packages/d4/3e/b103d5074979d58f80987d77c4a245a0abc1bb662678e32deb13e3b2a0a6/stm32loader-0.4.0.tar.gz" } ], "0.5.0": [ { "comment_text": "", "digests": { "md5": "601ec07b951274b39bc424403c9fb982", "sha256": "3e43a118ea91aac01fc5966fa38d437a61d6e59d4813d069dc11aadb8fcb6b3a" }, "downloads": -1, "filename": "stm32loader-0.5.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "601ec07b951274b39bc424403c9fb982", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": ">=2.7.0", "size": 29544, "upload_time": "2019-05-02T23:07:35", "url": "https://files.pythonhosted.org/packages/cb/4a/221b0191486f7e9bce251d7c1fc5ebd1c43ec31b3618122b51f4f3b9364d/stm32loader-0.5.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "d6fb9486d6f6cce2192ce89bc1c7b3d7", "sha256": "5cca887cd00609ae2be671f68424a0969713bb3ee274cf9a89da7ccf1a79d2f0" }, "downloads": -1, "filename": "stm32loader-0.5.0.tar.gz", "has_sig": false, "md5_digest": "d6fb9486d6f6cce2192ce89bc1c7b3d7", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7.0", "size": 34570, "upload_time": "2019-05-02T23:07:36", "url": "https://files.pythonhosted.org/packages/e0/5c/0ca59371adce8150313d1e195a98e3fb26203b36d6ef65a087cbb9488b2c/stm32loader-0.5.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "601ec07b951274b39bc424403c9fb982", "sha256": "3e43a118ea91aac01fc5966fa38d437a61d6e59d4813d069dc11aadb8fcb6b3a" }, "downloads": -1, "filename": "stm32loader-0.5.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "601ec07b951274b39bc424403c9fb982", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": ">=2.7.0", "size": 29544, "upload_time": "2019-05-02T23:07:35", "url": "https://files.pythonhosted.org/packages/cb/4a/221b0191486f7e9bce251d7c1fc5ebd1c43ec31b3618122b51f4f3b9364d/stm32loader-0.5.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "d6fb9486d6f6cce2192ce89bc1c7b3d7", "sha256": "5cca887cd00609ae2be671f68424a0969713bb3ee274cf9a89da7ccf1a79d2f0" }, "downloads": -1, "filename": "stm32loader-0.5.0.tar.gz", "has_sig": false, "md5_digest": "d6fb9486d6f6cce2192ce89bc1c7b3d7", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7.0", "size": 34570, "upload_time": "2019-05-02T23:07:36", "url": "https://files.pythonhosted.org/packages/e0/5c/0ca59371adce8150313d1e195a98e3fb26203b36d6ef65a087cbb9488b2c/stm32loader-0.5.0.tar.gz" } ] }