Skip to content

Latest commit

 

History

History
88 lines (56 loc) · 2.58 KB

README.md

File metadata and controls

88 lines (56 loc) · 2.58 KB

Test Results & Proof of Success - Single Cycle

This page displays the test programmes used to verify our design and the resultant outputs seen on the waveform viewer that prooves the correctness of our CPU design implemnetation working as per the needs of this course work.

In addition, we have also added videos that show the outputs for the F1 Program driving the neopixel bar on VBuddy and the trace values for the Reference Program plotted on the VBuddy's TFT display.

F1 Program

The program developed and used by the team:

main:
	jal a1, iloop
    addi a2, zero, 0x0
    beq a2, zero, 0
    
iloop:
	lb a0, 0(zero)
    lb a0, 1(zero)
    lb a0, 2(zero)
    lb a0, 3(zero)
    lb a0, 4(zero)
    lb a0, 5(zero)
    lb a0, 6(zero)
    lb a0, 7(zero)
    nop
    nop
    nop
    lb a0, 8(zero)
    jalr a3, a1, 0
    
 mloop:
 	beq a2, zero, mloop
    

Resultant waveform view from the risc_v.vcd file:

Alt text Alt text

Outputs from a0 driving the neopixel bar on VBuddy:

F1_Light_VBuddy.2.3.mp4

Reference Program

To test, go to the rtl folder and run source doit.sh.

Resultant waveform view from the risc_v.vcd file:

Sine

Alt text

Noisy

Alt text

Triangle

Alt text

Gaussian

Alt text

Explanation of waveforms

Having entered _loop3, a0 will start taking the values at mem[base_pdf+a1). The next line of instruction increments a1 by 1, causing a0 to take the value at the next address. This loop will keep repeating itself until the end of the pdf array.

Video Results on Vbuddy

Gaussian

gaussian.mp4

Noisy

noisy.mp4

Triangle

triangle.mp4

Sine

sine.mp4

Conclusion from tests

The waveform views for all were displayed as expected. When testing on the Vbuddy, the Sine and Triangle did not seem like sine and triangle waves. However, since the Gaussian and Noisy was displayed perfectly, and the waveforms are displayed as it should, we believe the CPU is working correctly.