Posts

Lab 4 Building GCC on My Linux VM

  Lab 4 Building GCC on My Linux VM (ft. My M2 MacBook Air) For this lab, I took a dive into the world of large software builds, specifically building the GCC compiler from source. The goal was to get hands-on experience using tools like make and autotools , since we’ll be working with GCC during our course project. Instead of using the SPO600 servers (x86-001 and aarch64-002), I decided to try something a little different and ran everything inside a Linux VM on my M2 MacBook Air (which is arm64 under the hood). Spoiler alert: it actually worked out great! Step 1: Cloning the Source Code First things first, I needed the latest development version of GCC. I SSH’d into my Linux VM and cloned the official GCC Git repo: git clone git://gcc.gnu.org/git/gcc.git gcc-source This gave me a folder full of source code, ready to be built. Step 2: Configuring the Build I’ve learned it's a bad idea to build inside the source directory, so I created a separate directory for building: mkdir gcc-b...

Lab 3 The Worm Game

  Lab 3 - 6502 Assembly: The Worm Game Adventure For this lab, I decided to take a leap into creating a simple but super fun Worm Game in 6502 Assembly language. And let me tell you – this was by far the most fun lab I've worked on so far! Not only did I get to learn more about how Assembly interacts with both text and graphic screens, but I also had to dig into game mechanics like collision detection, random fruit generation, and managing user input, all with very low-level code. The Game Plan The goal was to create a basic version of the classic "Worm" game, which starts with a small worm moving around the screen. The player controls the worm with the keyboard (W, A, S, D to move up, left, down, and right) and tries to eat randomly appearing fruits, which makes the worm grow longer. The challenge? Avoiding crashing into walls or its own body! Key Features: Moving the Worm : Control the worm's movement using the keyboard (WASD keys). Growing the Worm : Every time the...

Lab 2 Adventures in 6502 Assembly

  Bouncing Pixels and Going Solo: Lab 2 Adventures in 6502 Assembly Introduction Lab 2 was originally meant to be a mob programming session, think pair programming, but with a full group, all sharing one screen and collaborating on every line of code. Unfortunately, I couldn’t make it to the in-class session, so I ended up taking on the lab solo. While I missed out on the live collaboration part, I still got a chance to dive deep into the code, experiment with the animation logic, and get creative with bouncing a graphic around the screen using 6502 Assembly. This post walks through my solo journey with Lab 2: animating a graphic diagonally, making it bounce off the edges of the screen, and exploring some fun optional challenges along the way. Setting Up the Animation We were given a base program that moves a 5×5 pixel graphic diagonally across the emulator screen. The starting point was a neat little subroutine called DRAW , which takes an image, its position, and then places it o...