Home
XpandNotes
Cancel

Using Uart on Stm32f407g

Environment: windows 10, STM32CubeIDE 1.8.0 In this tutorial we will use uart4 through PA0 and PA1 pins. Project Initialization First, add a new stm32f407g project in CubeIDE, and name the proje...

Send mail from Outlook using SmtpClient

From James’ comment: DO NOT USE SMTPCLIENT IN PRODUCTION. It doesn’t support modern protocols and is now obsolete. Use Mailkit or FluentEmail instead. Read the Remarks section of Microsoft’s docs f...

Single-Responsibility Principle (SRP)

If a class has too many responsibilities (High Cohesion), all classes that depend on this class have to be modified when we want to add a new feature to the class, which increases the difficulty of...

OpenCV Read Images and Separate RGB Channels

Install opencv-python. $ pip install opencv-python OpenCV Read File Name a image as image.jpg and place it in the same directory as the python script below. # showimg.py import cv2 img = cv2.i...

Using WeasyPrint to convert HTML to PDF

Environment: Tested and worked on Ubuntu 20.04 to Ubuntu 24.04. While maintaining the PDF renderer for the tldr-page project, I came across the handy library WeasyPrint. Here are three ways to use...

Implement factorial using MIPS

This was a computer organization class assignment. I implemented a factorial using the following algorithm: $ F(n) = \begin{cases} 1, & n = 0 \\ F(n - 1) * n, & n \in \mathbb{N} \end{case...

Getting Started

Prerequisites Follow the instructions in the Jekyll Docs to complete the installation of the basic environment. Git also needs to be installed. Installation Creating a New Site There are two wa...