We prepared these guides on various topics relevant to CS107E students. Hope you find them useful.
Review
- Electricity basics
- Binary and hexadecimal number representations
- Intro to bitmasking
- Using the unix command line
Kit and Tools
- Bill of Materials (BOM) for course parts kit
- Recommendations for hand tools
- Soldering guide for soldering pins onto the MangoPi
Installation
- Setup WSL (only on Windows)
- Install developer tools (riscv toolchain and xfel)
- Setup git and mycode repo
- Install tio for USB-serial device
Mango Pi
- Powering the Mango Pi
- Using
xfel
as a bootloader - Reference card with pinout (printed copy in your kit)
- Serial communication over uart
- Meet your GPIO pins
- Program your GPIO pins
Risc-V
Development tools/process
- The git workflow used for labs and assignments in CS107e
- Using
git
for version control - Bare metal programming using
gcc
make
andMakefiles
- Using
gdb
in simulation mode - Binary utilities (
binutils
) - Advice on software testing
Extras
These resources are not fully fleshed out, but could be helpful starting points to use for projects
- Info on the vector unit of Mango Pi
- Sensors lecture code examples (includes bit bang version of i2c and spi)
- Code to use spi peripheral of Mango Pi
- Implementation of math library of Mango Pi
- Sample code for Neopixel/WS8212