Answered step by step
Verified Expert Solution
Question
1 Approved Answer
ASSEMBLY CODE: How to make leds on FPGA go back and Forth in ASSEMBLY lab1 1s- CAECE346LablLab1 1-Atom File Edit View Selection Find Packages Help
ASSEMBLY CODE: How to make leds on FPGA go back and Forth in ASSEMBLY
lab1 1s- CAECE346\Labl\Lab1 1-Atom File Edit View Selection Find Packages Help Lab1 1 lab1 1.s lab12.5 1 .equ LEDS, 0x10000010 # define LEDs 0x10000010 .text .global_start 4 start: movia r2, LEDS # base address of LEDs on DE0-Nano movi r3, obeeeeeee # left limit set up movi r4, 0x7FFF slli r4, r4, 3 add r4, r4, r4 # count to the number for delay 7 load : movi r5, 0b00000001 # the initial value set up or reset for LEDs # load the value to drive LEDs # set r6 to zero # r6++ # if(r61=r4) go to count # else if (r5-=r3) go to loop # else r5 rotate to left for 1 bit 10 loop: stw r5,(r2) mov r6, re count: addi r6, r6, 1 12 13 14 15 bne r6, r4, count beq r5, r3, load roli r5, r5,1 lab1 1s- CAECE346\Labl\Lab1 1-Atom File Edit View Selection Find Packages Help Lab1 1 lab1 1.s lab12.5 1 .equ LEDS, 0x10000010 # define LEDs 0x10000010 .text .global_start 4 start: movia r2, LEDS # base address of LEDs on DE0-Nano movi r3, obeeeeeee # left limit set up movi r4, 0x7FFF slli r4, r4, 3 add r4, r4, r4 # count to the number for delay 7 load : movi r5, 0b00000001 # the initial value set up or reset for LEDs # load the value to drive LEDs # set r6 to zero # r6++ # if(r61=r4) go to count # else if (r5-=r3) go to loop # else r5 rotate to left for 1 bit 10 loop: stw r5,(r2) mov r6, re count: addi r6, r6, 1 12 13 14 15 bne r6, r4, count beq r5, r3, load roli r5, r5,1Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started