This document describes how a PIC16F684 microcontroller can implement proportional-integral-derivative (PID) feedback control of an inverted pendulum system. The inverted pendulum consists of a base platform that rotates in a circle, a pendulum attached to a potentiometer on the base, and a controller board. The controller board measures the pendulum angle using the potentiometer and an analog-to-digital converter. It then uses a PID algorithm to determine the necessary motor output to drive the base and balance the pendulum at the vertical position. The document explains modeling considerations for the inverted pendulum system and approximations used to implement the PID control in software on the microcontroller.