[W8BH] attended a talk by another ham, [W8TEE] that showed a microcontroller sending and receiving Morse code. He decided to build his own, and documented his results in an 8 part tutorial. He’s using the Blue Pill board and the resulting device sends code with paddles, sends canned text, provides an LCD with a rotary knob menu interface, and even has an SD card for data storage.
All the code is on GitHub. If you are interested in Morse code or in learning how to write a pretty substantial application using the Blue Pill and the Arduino IDE (or any other similar processor), this is a great exposition that is also a practical tool.
[W8BH] takes good advantage of breakout boards with things such as the displays and jacks on them. Of course, you don’t absolutely have to use those, but it does make life easier. You can see [W8TEE’s] version posted in an online forum.
The parts of the tutorial all build on each other, so you start out simple and get deeper and deeper. The tutorials are PDF files, but they are well organized and easy to read.
Blue Pill header pic: Popolon [CC BY-SA 4.0]