Programming Tool for PUYA PY32F0xx Microcontrollers
Project description
Programming Tool for PUYA PY32F0xx Microcontrollers
Description
With this tool, PUYA microcontrollers of the series PY32F0xx (and maybe other PY32) can be flashed via a simple USB-to-serial converter by utilizing the factory built-in embedded UART bootloader.
Preparations
If necessary, a driver for the USB-to-serial converter used must be installed.
Installation
Ensure that the prerequisites for installing Python packages are met. Then execute the following command in the command line:
pip install puyaisp
Usage
Connect your USB-to-serial converter to your PY32F0xx MCU as follows:
USB2SERIAL PY32F0xx
+--------+ +-------------------+
| RXD| <--- |PA2 or PA9 or PA14|
| TXD| ---> |PA3 or PA10 or PA15|
| VDD| ---> |VDD |
| GND| ---> |GND |
+--------+ +-------------------+
Set your MCU to bootloader mode by using ONE of the following methods:
- Disconnect your USB-to-serial converter, pull BOOT0 pin (PF4) to VCC (or press and hold the BOOT button, if your board has one), then connect the converter to your USB port. BOOT0 pin (or BOOT button) can be released now.
- Connect your USB-to-serial converter to your USB port. Pull BOOT0 pin (PF4) to VCC, then pull nRST (PF2) shortly to GND (or press and hold the BOOT button, then press and release the RESET button and then release the BOOT button, if your board has them).
Usage: puyaisp [-h] [-u] [-l] [-e] [-o] [-G] [-R] [-f FLASH]
Optional arguments:
-h, --help show this help message and exit
-u, --unlock unlock chip (remove read protection)
-l, --lock lock chip (set read protection)
-e, --erase perform chip erase (implied with -f)
-o, --rstoption reset option bytes
-G, --nrstgpio make nRST pin a GPIO pin
-R, --nrstreset make nRST pin a RESET pin
-f FLASH, --flash FLASH write BIN file to flash and verify
Example:
puyaisp -f firmware.bin
Links
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file puyaisp-1.4.1.tar.gz
.
File metadata
- Download URL: puyaisp-1.4.1.tar.gz
- Upload date:
- Size: 7.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.10.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a2abee5f593e6dbe05988c0047fe9cb9a9db69a6f44efb421046a984624ae5b7 |
|
MD5 | e3a8fd45d0c43e76293afa3ca1770a0f |
|
BLAKE2b-256 | 62f9dbd40264030b8bd113afbdd991015ee29bd8df0f8f8b7d87a4e0c933b857 |
File details
Details for the file puyaisp-1.4.1-py3-none-any.whl
.
File metadata
- Download URL: puyaisp-1.4.1-py3-none-any.whl
- Upload date:
- Size: 8.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.10.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4877e85202a3d1e1e6cba4ffedce5c7998755dad3a8f27d95b990b39f7b8028f |
|
MD5 | 1144232cc190cccaa2346934795bc3c6 |
|
BLAKE2b-256 | 6c75e845184eb7bbd964cd953f220c6b242e6df118c7f26b313201a8bbfa26f4 |