Use Modelsim to debug and compile a repeat loop statement sy

Use Modelsim to debug and compile a repeat loop statement syntax: repeat () module repeat_example(); reg [3:0] opcode; reg [15:0] data; reg temp; always @ (opcode or data) begin if (opcode == 10) begin//Perform rotate repeat (8) begin #1 temp = data[15]; data = data

Solution

It will print statement TEMP DATA and statement repeat means it will repeat data it will work like a loop .\'repeat\' statement will print data for 8 times { syntax: repeat(8) begin}

 Use Modelsim to debug and compile a repeat loop statement syntax: repeat () module repeat_example(); reg [3:0] opcode; reg [15:0] data; reg temp; always @ (opc

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site