Skip to content

Session 1: Introduction & Development Pipeline

Project homework:

Install course toolchain (instructions provided) or set up VM/container Run hello world synthesis on a simple design Verify tools work end-to-end before Thursday

Site and Documentation Setup

As I just went through Fab Academy in 2025, I wanted to use the same documentation setup as I did when I took that class. So, I went ahead and setup my Git repo with MKDocs and VS Code. Details of that process can be found in my FA page here and are summarized below.

The bones are setup and will evolve as the class continues.

Git Setup

I installed Git Bash on my computer and logged into Fab Cloud with my credentials. I generated my SSH key and set it up in Fab Cloud. Then I cloned the repo into a local folder on my machine.

VS Code setup

Then I opend the folder in VS code and opened the sample pages. I added a picture and changed some text and did the initial commit to verify it was working. I was able to push the initial build and I was able to see the changes reflected on my public site.

Local Build

Then I installed Python and mkdocs so I could build the site locally to test before pushing it. I downloaded Python 3.14 as well as Pip. Then I downloaded MKdocs. Once this was setup I was able to run commands “mk docs build” and “mk docs serve” to build it and I was able to open it with a web browser using “http://127.0.0.1:8000/futures/microelectronics/2026/labs/unccharlotte/students/jeremy-losaw/”

Then I started to do some customization. I changed some themes and colors and icons. At one point I had a bad error as I tried to change my icon logo image from the stock .svg to a .jpg. However, I used ChatGPT to analyze the error and it provided syntax to fix it.

theme:
  name: material
  logo: images/monstera.jpg

Testing Tools

I explored the testing tools inside the environment. I started by exploring the sample programs and output before modifying an existing program.

Browser VNC and Fortune Teller Code

I started by firing up the browser based VNC at this link. I clicked on the browser based VNC and entered my credentials.

VNC Splash Screen

Then I right clicked in the destop area and opened the terminal window. I opened the directory with the sample programs using “cd /foss/examples” command and ran “make sim-fortune” to run the fortune teller sample. I could see the program running and observed the output from the program. It provided some messages back.

Fortune Test

Then I went and viewed the wave forms generated by the program. I ran “gtkwave fortune_teller/fortune_teller_rb.vcd”. This opened the wave viewer screen.

Wave zoomed out

Initially the viewer was too far zoomed to see anything, so I was able to zoom into the traces to see more detail. Once zoomed in I could see the traces more clearly. There are some interesting things going on on the RX and TX channels likely related to the string output from the program.

Wave zoomed in

Looking at the Code

Then I took a look at the fortune code. I ran “cat fortune_teller/fortune_teller.v | less”. The terminal displayed the output in a window to evaluate.

Fortune Code

Unfortunately the code was not pasteable outside of the terminal so I cannot paste it here. There were some definitions of inputs and outputs, a debounce routing for a physical button, definitions of each character corresponding to a letter, random number generator to pick the fortunes, and an LED output.

Modify Code

Next I did a modification to the code. I used the “cp -r…” command to copy and paste the program into my “foss/designs” folder.

Copy paste

Then I opened the file and navigated to the part of the code where the messages are coded.

Fortune letters

Then I decided to update the first message to “Why did you ask?”. I chose this as it is about the same length as the previous message and would not require any bulk rearrangement of the code. I had no idea what the letter references are, so I used Chat GPT to help. Since I could not directly copy the code from the virtual environment to my local machine, I took a screen shot and uploaded it to GPT and asked it to “can you give me the 8’h codes for “Why did you ask?”.” It output the following code:

// "Why did you ask?"
rom[x]  = 8'h57; // 'W'
rom[x+1] = 8'h68; // 'h'
rom[x+2] = 8'h79; // 'y'
rom[x+3] = 8'h20; // ' '
rom[x+4] = 8'h64; // 'd'
rom[x+5] = 8'h69; // 'i'
rom[x+6] = 8'h64; // 'd'
rom[x+7] = 8'h20; // ' '
rom[x+8] = 8'h79; // 'y'
rom[x+9] = 8'h6F; // 'o'
rom[x+10] = 8'h75; // 'u'
rom[x+11] = 8'h20; // ' '
rom[x+12] = 8'h61; // 'a'
rom[x+13] = 8'h73; // 's'
rom[x+14] = 8'h6B; // 'k'
rom[x+15] = 8'h3F; // '?'
rom[x+16] = 8'h0A; // '\n'  (optional newline)
rom[x+17] = 8'h00; // null terminator

Then I used this map to manually update the code in the VRC. Then I saved the file and ran the new program. Fortunately the random number generator hit the first message on the first try, and I was able to confirm that the new code is working.

/// caption Serial output while reading the button ///