Git Product home page Git Product logo

cjmcu-ft232hq-programmer's Introduction

CJMCU-232H-based JTAG, SWD, and AVR Programmer

This is a very popular module based on the FT232H chip made by CJMCU. You can use this module as a high-speed programmer for your embedded projects. I discovered that this module can be used as a JTAG and SWD programmer for ESP32 and STM32 microcontrollers. It can also be used as an ISP programmer for AVR microcontrollers.

This module might be used to program other microcontrollers, but no information about them has been published yet.

CJMCU-232H

Any similar module/board based on FT233H/FT2232H which exposes AD0, AD1, AD1, and AD3 pins can be used for this purpose.

Note that voltage level of all I/Os is 3.3V but they are 5V-tolerant

OpenOCD (for JTAG & SWD)

Install WinUSB driver for FT232H using Zadig:

image

For SWD connection use -f interface/ftdi/ft232h-module-swd.cfg, and for JTAG connection use -f interface/ftdi/um232h.cfg -c "transport select jtag".

Example: Read STM32f103C8 (Blue-Pill board) flash:

For STM32f103C8 with 64KB of flash. Target is board/stm32f103c8_blue_pill.cfg. Size to read is 0x10000. Read firmware from MCU and store it in a file named firmware.bin on your computer.

openocd -f interface/ftdi/ft232h-module-swd.cfg -f board/stm32f103c8_blue_pill.cfg -c init -c "reset halt" -c "flash read_bank 0 firmware.bin 0 0x10000" -c "reset" -c shutdown

Example: Write STM32f103C8 (Blue-Pill board) flash:

For STM32f103C8 with 64KB of flash. Target is board/stm32f103c8_blue_pill.cfg. Write firmware from the file firmware.bin to the flash memory of the MCU.

openocd -f interface/ftdi/ft232h-module-swd.cfg -f board/stm32f103c8_blue_pill.cfg  -c init -c "reset halt" -c "flash write_image erase firmware.bin 0x08000000" -c "reset" -c shutdown

Using with PlatformIO:

[env:bluepill_f103c8_128k]
platform = ststm32
board = bluepill_f103c8_128k
framework = arduino
; Upload options for FT232H USB-JTAG adapter in SWD Mode
upload_protocol = custom
upload_command = ${platformio.packages_dir}/tool-openocd/bin/openocd -s ${platformio.packages_dir}/tool-openocd/scripts -f interface/ftdi/ft232h-module-swd.cfg -f board/stm32f103c8_blue_pill.cfg -c "init" -c "reset halt" -c "flash write_image erase {$SOURCE} 0x08000000" -c "reset" -c "shutdown"
; Debug options for FT232H USB-JTAG adapter in SWD Mode
debug_tool = custom
debug_server =
  ${platformio.packages_dir}/tool-openocd/bin/openocd
  -s
  ${platformio.packages_dir}/tool-openocd/scripts
  -f
  interface/ftdi/ft232h-module-swd.cfg
  -f
  board/stm32f103c8_blue_pill.cfg

AVRDUDE / AVRDUDESS (for AVR ISP)

Install default driver from FTDI. If you have installed WinUSB or libusb driver for FT232H, you should revert it to defalut driver:

image

image

image

image

image

image

Resources

cjmcu-ft232hq-programmer's People

Contributors

m3y54m avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  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.