Tamir Vardi Lab B Description: Cout A& B& Cin + A& BC& N + A & Cin Sum Cin & (Ab+ab) +cin & (Ab+ab)
Tamir Vardi Lab B Description: Cout A& B& Cin + A& BC& N + A & Cin Sum Cin & (Ab+ab) +cin & (Ab+ab)
Lab B
Description
The topic learned in Lab 2 is how to create a 7 segment display using the BASYS3 board. The
overview of this project is having a full adder that connects to a seven segment display.
Methods: The first step is to make a full adder, by using the truth table we are able to
create the logic of having 3 values, a, b, and c_in. I had to figure out the logic of having c_out
and sum. Essentially a,b, and c_in. I programmed a 1 bit adder and I stacked them together to
make a 4 bit adder.
I found out the formula’s for C_out and sum in terms of a,b,c_in,
cout = a& b& cin + a& bc& n + a & cin
sum=cin &(ab+ab)+cin &(ab+ab)
Once that was done I worked on creating a truth table for the 7 segment using
CA,CB,CC,CD,CE,CF,CG, display which I then implemented a top level.
There was some tricky things that I had to research about the board, using the BASYS3
manual I was able to overcome logical errors in my program. Once I got that working, I
debugged my program with a simulator, and was able to succeed debugging my code,
smoothly. Working on mapping out the FPGA pins, first having the input, then going to starting
with the adder, I combined three full adders(total 9 gates three for each adder) then pass into
three more gates for the seven segment display, and used an inverter because of how the
board is programmed on low, then to the output, having 13 gates.
The most number of gates to pass for a full adder is n ∗ 3 + 4, having 3 adders combined hence the
multiplication by three, and then adding 4 gates for the 4 bit values.
The value of 7 bit vector is 128. I tested 16 cases, therefore testing 12.5%.
Conclusion: Overall Lab two had fundamentals that helped build a 7 bit segment display
adder. The multiple modules having separate modules for specific tasks, helped
improve my projects organization. I was able to successfully debug my program using
the simulation. When all my logic was programmed it was definitely hard to debug it
through the board itself, so I definitely relied on the simulator. Learning the 7 segment
display adder helped me understand how complicated something so small to program
is, and I’m looking into the future labs.