HDTutorial
EN

Playback starts YouTube’s embedded player (privacy-enhanced mode).

STM32 Programming Tutorial for Custom Hardware | SWD, PWM, USB, SPI

381,498 views October 25, 2020 39:58

Watch on YouTube
ChannelPhil’s Lab

Chapters

Description from the creator

(AD: This video includes a paid promotion for JLCPCB.)

Overview of how to write test firmware for a custom STM32-based PCB, in particular for a variant of one made using the hardware design tutorial videos (including various sensors, flash memory, USB, etc.).
Visit jlcpcb.com/RHS for $2 for five 2-layer PCBs and $5 for five 4-layer PCBs. (AD)



Includes topics such as: STM32CubeIDE, SWD and ST-Link, Timers and PWM (RGB LED), USB (Virtual COM Port), SPI (driver for inertial measurement unit).
By no means a complete tutorial but rather a guide on how to approach writing firmware when you first get your custom boards!

If you're enjoying my content, please consider becoming a patron:
patreon.com/phils94

github.com/pms67/LittleBrain-STM32F4-Sensorboard

[TIMESTAMPS]

00:00 Assembled Boards
02:53 Hand-Soldered Components
03:26 Initial Testing Suggestions and ST-Link/USB Connections
04:45 How to Order (JLCPCB) (Ad)

06:36 STM32CubeIDE Overview
07:43 CubeIDE Project Creation
08:44 Pin and Peripheral Assignment
12:40 Clock Configuration
13:43 USB CDC Config
14:28 SPI Baud Rate Config
15:10 Timer PWM Config

18:23 RGB LED Firmware (Timers and PWM)
21:38 Debugging via ST-Link and SWD
24:11 USB Virtual COM Port Firmware (USB CDC)
29:05 Inertial Measurement Unit (IMU) (SPI in Polling Mode)

37:28 Final Testing

ID: QIBvbJtYjWuHiTG0uCoK

About this tutorial

Phil’s Lab published this 39:58 video tutorial on October 25, 2020. It has been watched 381,498 times on YouTube.

Duration
39:58
Published
October 25, 2020
Views
381,498
Likes
8,119

Share

Further reading

This tutorial in other languages