PIC LED blinker (busy-wait)
Beyond all doubt, the #1 beginning program in microcontrollers is the LED blinker. It’s super simple, and teaches the concept of pin voltages and busy-waits. Here is a busy-wait LED blinker program, and a walkthrough building it in MPLab.
First, the delay. This is a busy-wait delay program, busy-wait means you just burn instruction cycles [...]