Firmware Tutorial

Module 1: Analog and Digital I/O

Now that we have a grasp of fundamental concepts in firmware, we can begin writing code! 

To start let's take a look at the firmware tutorial project in the firmware repository. If you have not already completed the Software 101 Module 1, go ahead and do so as it allows you to setup our development environment and begin writing code! Ideally, you would have completed all 5 modules but the Module 1 is mandatory. Navigate under projects and look at fw_tutorial. For this module, we will write firmware for the hardware tutorial board which can be found here. The goal is to be able to toggle an LED using the green and yellow push-buttons found on the board.

If you take a look at the inc folder, you can see we have already predefined the headers in a structured format. button.h is the header for the push button module and defines enums, structures and functions associated with controlling push-buttons. config.h is the header for the configuration file. We utilize a separate configuration file so that we can easily change settings such as pin mappings or threshold values from a single file rather than looking through numerous files. Our goal is to now implement the associated .c source files for these headers.