Editor Version ×
Standard

1.Easy to use and quick to get started

2.The process supports design scales of 300 devices or 1000 pads

3.Supports simple circuit simulation

4.For students, teachers, creators

Profession

1.Brand new interactions and interfaces

2.Smooth support for design sizes of over 5,000 devices or 10,000 pads

3.More rigorous design constraints, more standardized processes

4.For enterprises, more professional users

Completed

STD CH32X033 F8P6 Development Board

License: CC BY-SA 3.0

Mode: Editors' pick

  • 534
  • 0
  • 0
Update time: 2024-02-01 16:45:24
Creation time: 2024-01-02 15:43:28
Description
# CH32X033 F8P6 Development Board Development board for the CH32X033F8P6 low-cost 32-bit RISC-V microcontroller with native USB2.0 and Arduino IDE support. - Project files (Github): https://github.com/wagiminator/Development-Boards/tree/main/CH32X033F8P6_DevBoard ![CH32X033F8P6_DevBoard_pic1.jpg](https://raw.githubusercontent.com/wagiminator/Development-Boards/main/CH32X033F8P6_DevBoard/documentation/CH32X033F8P6_DevBoard_pic1.jpg) # Pinout ![CH32X033F8P6_DevBoard_pinout.png](https://raw.githubusercontent.com/wagiminator/Development-Boards/main/CH32X033F8P6_DevBoard/documentation/CH32X033F8P6_DevBoard_pinout.png) # The CH32X033 32-bit RISC-V USB Microcontroller ## Overview CH32X033 is a low-cost microcontroller that utilizes the QingKe 32-bit RISC-V4C core, supporting the RV32IMAC instruction set along with self-extending instructions. This microcontroller comes with a built-in USB PHY and supports USB2.0 full-speed device functions. It features a programmable protocol I/O controller (PIOC), 2 groups of operational amplifiers (OPA), 2 groups of analog comparators (CMP), 4 groups of USART, I2C, SPI, multiple timers, a 12-bit ADC, a 10-channel Touchkey, and various other peripheral resources. The device can operate at clock frequencies of up to 48MHz and is compatible with a supply voltage range of 2.0V to 5.5V. The CH32X033 includes 62KB of flash, 20KB of SRAM, and an embedded USB bootloader. ## Features - Qingke 32-bit RISC-V4C processor, RV32IMAC instruction set - Up to 48MHz system clock frequency - Single-cycle hardware multiplication, hardware division - 20KB SRAM, 62KB Flash - Operating voltage: 2.0V - 5.5V - Multiple low-power modes: sleep/stop/standby - Power-on/power-down reset (POR/PDR), programmable voltage detector (PVD) - 1x Programmable Protocol I/O Controller (PIOC), supports wide range of 1-wire and 2-wire interfaces - 1x 8-channel general-purpose direct memory access (DMA) controller - 2x operational amplifier (OPA) with programmable gain (PGA) - 2x analog comparator (CMP) - 1x 11-channel 12-bit analog-to-digital converter (ADC) - 1x 10-channel Touch-Key detection - 2x 16-bit advanced-control timer with complementary output and dead time control - 1x 16-bit general-purpose timer with input capture - 2x watchdog timers (independent and window) - 1x 64-bit SysTick counter - 1x USB2.0 full-speed device interface, 7 two-way endpoints with 64 bytes packet length - 4x USART interface, supports LIN and ISO7816 - 1x I²C interface, supports SMBus/PMBus - 1x SPI interface - 18x general-purpose I/O (GPIO) ports, external interrupts - 96-bit unique chip ID - Serial 2-wire debug interface - Factory built-in USB bootloader # Programming and Debugging There are two ways to program the microcontroller: via USB using the built-in bootloader and via the serial 2-wire debug interface using a WCH-LinkE programming device. ## Built-in USB Bootloader ### Installing Drivers for the Bootloader On Linux you do not need to install a driver. However, by default Linux will not expose enough permission to upload your code with the USB bootloader. In order to fix this, open a terminal and run the following commands: ``` echo 'SUBSYSTEM=="usb", ATTR{idVendor}=="4348", ATTR{idProduct}=="55e0", MODE="666"' | sudo tee /etc/udev/rules.d/99-ch55x.rules echo 'SUBSYSTEM=="usb", ATTR{idVendor}=="1a86", ATTR{idProduct}=="55e0", MODE="666"' | sudo tee -a /etc/udev/rules.d/99-ch55x.rules sudo udevadm control --reload-rules ``` For Windows, you need the [CH372 driver](http://www.wch-ic.com/downloads/CH372DRV_EXE.html). Alternatively, you can also use the [Zadig Tool](https://zadig.akeo.ie/) to install the correct driver. Here, click "Options" -> "List All Devices" and select the USB module. Then install the libusb-win32 driver. To do this, the board must be connected and the microcontroller must be in bootloader mode. ### Entering Bootloader Mode The bootloader must be started manually for new uploads. To do this, the board must first be disconnected from the USB port and all voltage sources. Now press the BOOT button and keep it pressed while reconnecting the board to the USB port of your PC. The chip now starts in bootloader mode, the BOOT button can be released and new firmware can be uploaded via USB within the next couple of seconds. ### WCHISPTool WCH offers the free but closed-source software [WCHISPTool](https://www.wch.cn/downloads/WCHISPTool_Setup_exe.html) to upload firmware with Windows via the USB bootloader. ### chprog.py You can also use chprog.py, a simple Python command line tool provided with the example software in this repo, to flash the microcontroller via the built-in USB bootloader. In order for this tool to work, Python3 must be installed on your system. To do this, follow these [instructions](https://www.pythontutorial.net/getting-started/install-python/). In addition [PyUSB](https://github.com/pyusb/pyusb) must be installed. On Linux (Debian-based), all of this can be done with the following commands: ``` sudo apt install python3 python3-pip python3 -m pip install pyusb ``` ``` Usage example: python3 chprog.py firmware.bin ``` ### Alternative Software Tools - [isp55e0](https://github.com/frank-zago/isp55e0) - [wchisp](https://github.com/ch32-rs/wchisp) ## Serial 2-Wire Debug Interface ### WCH-LinkE To program the microcontroller via the serial debug interface, you will need a special programming device. The [WCH-LinkE](http://www.wch-ic.com/products/WCH-Link.html) (pay attention to the "E" in the name) is a suitable option for this purpose and can be purchased commercially for around $4. This debugging tool is compatible with most WCH RISC-V and ARM-based microcontrollers. ![CH32V003_wch-linke.jpg](https://raw.githubusercontent.com/wagiminator/Development-Boards/main/CH32V003F4P6_DevBoard/documentation/CH32V003_wch-linke.jpg) To use the WCH-Link on Linux, you need to grant access permissions beforehand by executing the following commands: ``` echo 'SUBSYSTEM=="usb", ATTR{idVendor}=="1a86", ATTR{idProduct}=="8010", MODE="666"' | sudo tee /etc/udev/rules.d/99-WCH-LinkE.rules echo 'SUBSYSTEM=="usb", ATTR{idVendor}=="1a86", ATTR{idProduct}=="8012", MODE="666"' | sudo tee -a /etc/udev/rules.d/99-WCH-LinkE.rules sudo udevadm control --reload-rules ``` To upload firmware, you should disconnect the board from USB and then make the following connections to the WCH-LinkE: ``` WCH-LinkE MCU Board +-------+ +------+ | SWCLK| ---> |CLK | | SWDIO| |DIO | | GND| ---> |GND | | 3V3| ---> |VCC | +-------+ +------+ ``` If the blue LED on the WCH-LinkE remains illuminated once it is connected to the USB port, it means that the device is currently in ARM mode and must be switched to RISC-V mode initially. There are a few ways to accomplish this: - You can utilize the rvprog.py tool with the -v option (see below). - Alternatively, you can select "WCH-LinkRV" in the software provided by WCH, such as MounRiver Studio or WCH-LinkUtility. - Another option is to hold down the ModeS button on the device while plugging it into the USB port. More information can be found in the [WCH-Link User Manual](http://www.wch-ic.com/downloads/WCH-LinkUserManual_PDF.html). ### WCH-LinkUtility WCH offers the free but closed-source software [WCH-LinkUtility](https://www.wch.cn/downloads/WCH-LinkUtility_ZIP.html) to upload firmware with Windows using the WCH-LinkE. ### rvprog.py You can also use rvprog.py, a simple Python command line tool provided with the example software in this repo, to flash the microcontroller via the WCH-LinkE or compatible programmers/debuggers. In order for this tool to work, Python3 must be installed on your system (see chprog.py above for details). ``` Usage: rvprog.py [-h] [-a] [-v] [-u] [-l] [-e] [-f FLASH] Optional arguments: -h, --help show help message and exit -a, --armmode switch WCH-LinkE to ARM mode -v, --rvmode switch WCH-LinkE to RISC-V mode -u, --unlock unlock chip (remove read protection) -l, --lock lock chip (set read protection) -e, --erase perform a whole chip erase -f FLASH, --flash FLASH write BIN file to flash Example: python3 rvprog.py -f firmware.bin ``` ### Alternative Software Tools - [minichlink](https://github.com/cnlohr/ch32v003fun/tree/master/minichlink) - [wlink](https://github.com/ch32-rs/wlink) # Software Development Tools ## MounRiver Studio IDE The Eclipse-based closed-source [MounRiver Studio IDE](http://www.mounriver.com/) is the official development environment provided by WCH. It supports Windows, Linux, and Mac. MounRiver Studio can be downloaded for free. ## Open-Source GCC Toolchain You can download a complete toolchain (GCC and OpenOCD) for Linux and Mac from the MounRiver Studio website. However, on Linux you can also install a GCC-based toolchain by running the following command: ``` sudo apt install build-essential libnewlib-dev gcc-riscv64-unknown-elf ``` ## Arduino IDE and PlatformIO Support There are projects around to make the CH32X033 compatible with the Arduino IDE ([arduino_core_ch32](https://github.com/openwch/arduino_core_ch32)) and PlatformIO ([platform-ch32v](https://github.com/Community-PIO-CH32V/platform-ch32v)). # References, Links and Notes - [EasyEDA Design Files](https://oshwlab.com/wagiminator) - [MCU Templates](https://github.com/wagiminator/MCU-Templates) - [MCU Flash Tools](https://github.com/wagiminator/MCU-Flash-Tools) - [MounRiver Studio](http://www.mounriver.com/) - [CH32X033 with Arduino IDE](https://github.com/openwch/arduino_core_ch32) - [CH32X033 with PlatformIO](https://github.com/Community-PIO-CH32V/platform-ch32v) - [CH32X033 on openwch](https://github.com/openwch/ch32x035) - [CH32X033 datasheets](http://www.wch-ic.com/products/CH32X035.html) - [WCH-Link user manual](http://www.wch-ic.com/downloads/WCH-LinkUserManual_PDF.html) - [WCH Official Store on AliExpress](https://wchofficialstore.aliexpress.com) ![CH32X033F8P6_DevBoard_pic2.jpg](https://raw.githubusercontent.com/wagiminator/Development-Boards/main/CH32X033F8P6_DevBoard/documentation/CH32X033F8P6_DevBoard_pic2.jpg) ![CH32X033F8P6_DevBoard_pic3.jpg](https://raw.githubusercontent.com/wagiminator/Development-Boards/main/CH32X033F8P6_DevBoard/documentation/CH32X033F8P6_DevBoard_pic3.jpg) # License ![license.png](https://i.creativecommons.org/l/by-sa/3.0/88x31.png) This work is licensed under Creative Commons Attribution-ShareAlike 3.0 Unported License. (http://creativecommons.org/licenses/by-sa/3.0/)
Design Drawing
schematic diagram
1 /
PCB
1 /
The preview image was not generated, please save it again in the editor.
ID Name Designator Footprint Quantity Supplier Contributor
1 100n C1,C3 C_0603 2 LCSC CC0603KRX7R9BB104
2 10u C2 C_0603 1 LCSC CC0603KRX7R9BB104
3 HDR-M-2.54_1x10 H1,H2 210S-10X1/2.54 2 LCSC HDR-M-2.54_1x10
4 PWR LED1 LED0603 1 LCSC LED-0603-GREEN
5 PB1 LED2 LED0603 1 LCSC LED-0603-RED
6 1k R1,R2 0603 2 LCSC Res_0603(1/10W)_EU
7 4k7 R3 0603 1 LCSC Res_0603(1/10W)_EU
8 BOOT SW1 SW-SMD_L4.0-W2.9-LS5.0 1 LCSC SW-4.0x2.9
9 RESET SW2 SW-SMD_L4.0-W2.9-LS5.0 1 LCSC SW-4.0x2.9
10 CH32X033F8P6 U1 TSSOP-20 1 LCSC CH32X033F8P6
11 Micro Input USB1 MINI-USB-SMD_U254-051T-4BH23-S2B 1 LCSC U254-051T-4BH23-S2B

Unfold

Project Attachments
Empty
Project Members
Target complaint
Related Projects
Change a batch
Loading...
Add to album ×

Loading...

reminder ×

Do you need to add this project to the album?

服务时间

周一至周五 9:00~18:00
  • 0755 - 2382 4495
  • 153 6159 2675

服务时间

周一至周五 9:00~18:00
  • 立创EDA微信号

    easyeda

  • QQ交流群

    664186054

  • 立创EDA公众号

    lceda-cn