Skip to main content
Filter by
Sorted by
Tagged with
0 votes
1 answer
68 views

Is it allowed to connect two modules using SV interface modports with different signals? interface chip_bus (); logic [31 :0] address; logic [63:0] data; logic [63:0] req; // The two ...
jel88's user avatar
  • 45
2 votes
2 answers
95 views

I usually work with Xilinx FPGA boards. Based on the documentation I've reviewed and the research I've done, I try to avoid using a global reset signal in my designs as much as possible. However, let'...
stackwryd's user avatar
2 votes
1 answer
87 views

My register doesn't work properly. The output changes simultaneously with the input. There should be a one-cycle delay, but I am not seeing it from the simulation in Modelsim. Does anyone know why? ...
user22714606's user avatar
2 votes
1 answer
89 views

I'm implementing a simple ARM7 in Verilog and am currently in the process of creating a simple data memory. I've come up with something like this: // very simple sdata implementation with 1mb~ memory ...
therepanic's user avatar
1 vote
1 answer
123 views

I have a simple example for random stability in QuestaSim. module sv_rand_stability; class dummy; rand int data; endclass initial begin dummy d; $display("%...
Sergey Chusov's user avatar
1 vote
1 answer
100 views

In SystemVerilog is the "property" construct: property <name> <body> endproperty This can then be instantiated as: assert property(<name>); In the language extension ...
Tharaqon's user avatar
-1 votes
1 answer
95 views

In UVM TLM1, there are three main interface types: port — the initiator of a transaction, export — a proxy that forwards port requests to an implementation, imp — the implementation, which contains ...
Andrei Solodovnikov's user avatar
0 votes
1 answer
64 views

Can someone help me with system verilog constraint for the below requirement.1) Fixed queue size of 10 and has four 6s in it at random position. I tried the below constraint to start with. class ...
User99's user avatar
  • 11
-1 votes
1 answer
85 views

I'm writing an FPGA state machine in System Verilog to read bytes from a SPI port and parse them into commands to the FPGA. The "RXSPIBITS" state is used to read SPI bytes by multiple other ...
Joe's user avatar
  • 9
4 votes
1 answer
127 views

I've been doing a finite state machine of an elevator using Verilog. The elevator contains four states: IDLE: When the elevator is stopped. ERROR: When the elevator's weight limit is exceeded. MOVING:...
Gr_10's user avatar
  • 71
-1 votes
1 answer
109 views

For context, please look at my attached diagram to see what I am trying to accomplish. Essentially, I want to swap inout wires using a contained hierarchy that will allow me to have more modular RTL ...
Mahmoud Maarouf's user avatar
2 votes
1 answer
82 views

I know a lot of people have asked about when to use assign inside always, but I'm wondering if you actually have to. Is it ok to have a module where you have assign statements, but they are not inside ...
dishcat15's user avatar
1 vote
1 answer
106 views

I’m working on an FPGA project and planning to use UVM (Universal Verification Methodology) for verification. I’m confused about the timing of when to apply UVM in the design flow. Should I develop my ...
Kerim Turak's user avatar
2 votes
2 answers
174 views

When I am doing some development with Verilog and Vivado, I wrote some Verilog code as follows: module min_rep_example_A(input clk, input rst_n, output reg[3:0] LED); always @(posedge clk or ...
Cu635's user avatar
  • 77
0 votes
0 answers
71 views

The instantiation module as below: module second_module( input [7:0] d, output reg [7:0] q ); initial q <= ~d; endmodule The top module as below: module top_module( input [7:0] ...
kittygirl's user avatar
  • 2,511
0 votes
1 answer
92 views

Refer to this question,I write a similar case. module n; reg [1:0]a, b; initial begin a=1; a<=a+1; $strobe("strobe",a); $display("display",a); end endmodule The ...
kittygirl's user avatar
  • 2,511
1 vote
1 answer
80 views

module n; reg [1:0]a, b; initial begin $monitor($time,," monitor ",a); a=1; a<=a+1; #1;//assignment should happen here end endmodule The expect output is: 1 monitor 2 but I got 0 ...
kittygirl's user avatar
  • 2,511
0 votes
1 answer
61 views

`timescale 1ns / 1ps module factorial( input i_n, output reg res, input i_clk ); integer j; initial begin:a for (j=1;j<=i_n;j=j+1)begin res<=res*j; end res<='d3; $display("res is ...
kittygirl's user avatar
  • 2,511
-1 votes
1 answer
110 views

I'm a complete beginner when it comes to Verilog. I have a block ROM which is as follows: module CDbram_2_0_32 (clk, en, addr, dout); input clk; input en; input [9:0] addr; output [9:0] dout [0:37]; (...
Dara Greyest's user avatar
1 vote
2 answers
126 views

I have Verilog code like this: module gen_bits(input clk, input clear, input ld, input in, output reg[7:0] out); always @(posedge clk) begin if (clear) out <= 8'b00000000; ...
qian li's user avatar
  • 53
0 votes
0 answers
41 views

I'm currently doing preliminary testing on a switch level transmission gate master latch. The design is adiabatic and is part of a flip flop circuit. The adiabatic operation is done through Bennett ...
Nguyen Nguyen's user avatar
-1 votes
1 answer
74 views

Consider the following example: // example.v module submod ( output logic sub_output ); assign sub_output = 1'b1; endmodule module top; logic out; submod gen_submod (); assign out ...
cryptobeginner's user avatar
0 votes
1 answer
147 views

I am hoping to define an SVA property that detects a zero-time (delta cycle) glitch on a signal. I have found a recipe that I expected to work for high-going glitches, but it turns out it also works ...
Craig's user avatar
  • 940
1 vote
1 answer
96 views

I'm looking for SV code that is equivalent to these lines in VHDL: process begin wait until rising_edge(mysig) for 1 us; if rising_edge(mysig) do_something() else do_something_else(); end if; ...
Craig's user avatar
  • 940
0 votes
1 answer
184 views

In SystemVerilog, to create a custom type based on another type I believe I can use either typedef or localparam type. For example, I believe the following are equivalent: typedef logic [31:0] T; ...
MattHusz's user avatar
  • 464
1 vote
1 answer
75 views

I currently need to read 128 8-bit data. After reading 128 data, they are combined into a 1024-bit RAM which is then assigned to dout. The ram_cnt will count from 0 to 65535. When it counts 128 (0~...
Vina's user avatar
  • 27
1 vote
2 answers
86 views

I wrote a module which used the writing method like: always_ff@(posedge clk)begin logic [WIDTH-1:0] signal1; ........ end When I compiled it in VCS, I drove the signal in testbench, and when I ...
genterminal's user avatar
1 vote
1 answer
807 views

Purpose: Input 128 data, store them in RAM, and output them to dout after collecting 128 data. di is an input variable. RAM is used to store 128 data. When RAM collects 128 numbers, dout will write ...
Ti Wize's user avatar
  • 13
3 votes
1 answer
125 views

This is the Verilog question. I have written the code according to the image, but I'm getting mismatch in the output, can I get some assistance? module add1 ( input a, input b, input cin, output ...
Subzee's user avatar
  • 73
1 vote
1 answer
108 views

I've been assigned to create a 4:1 multiplexer in Verilog, and then implement the function: F(X, Y, Z) = (X*Y') + (Y'*Z') + (X'*Z') If I did the everything right on paper, the s0 = Y, s1 = Z, I0 = 0, ...
Ahooey's user avatar
  • 11
-1 votes
1 answer
82 views

I have been working on my desktop using Quartus prime lite and ModelSim, but recently I got a weird error that I can't seem to fix. I have tried restarting my pc, uninstalling and reinstalling Quartus ...
youlexa's user avatar
0 votes
1 answer
1k views

I'm using Vivado 2024.1 with full-project synthesis (not out-of-context), and I’m getting this warning during synthesis: [Synth 8-7080] Parallel synthesis criteria is not met The design builds and ...
Bimo's user avatar
  • 6,769
1 vote
1 answer
87 views

I tried to reproduce loadable counter in Vivado 2023.1, but I cannot get expected result. My testbench file is below: `timescale 1ns / 1ps module behav_counter(); reg [7:0] d; reg clk; reg ...
kittygirl's user avatar
  • 2,511
1 vote
1 answer
130 views

Suppose I have a module that takes in two numbers and a signal telling either it is signed multiplication or unsigned. Module has to multiply. module signed_or_unsigned_mul # ( parameter n = 8 ) ( ...
Aleksandr Grigorev's user avatar
1 vote
1 answer
97 views

Let's say we're trying to write a Verilog/SystemVerilog testbench code named SC_TB for module sample_code. Is there a more practical way of seeing what reg B and wire Cw is doing in testbench, without ...
Mister Moron's user avatar
1 vote
1 answer
68 views

I'm working on a Verilog project for the DE10-Lite FPGA board that interfaces with a 3-axis accelerometer over SPI. I have separate SPI modules (spi_ee_config) for each axis: x_info, y_info, and ...
Mayank Neupane's user avatar
2 votes
1 answer
76 views

The SystemVerilog spec describes a scheduler model in Figure 4-1 (p. 67 of IEEE 1800-2023). It describes a number of regions, including an Active region set and a Re-Active region set. Orthogonally, ...
garethw's user avatar
  • 53
2 votes
2 answers
110 views

In Verilog, you can declare wires/registers as ports and connect them at instantiation (port_A in example) as ports and connect them "later"/"outside" using hierarchical names (...
Anedar's user avatar
  • 4,313
0 votes
1 answer
120 views

How should I add ignore_bin in child class for a coverpoint which is defiened in base class? I tried extending base covergroup but it shows compilation errors for keyword extend in this context ...
Sam's user avatar
  • 1
1 vote
1 answer
64 views

I need to write a property to check the divisor of a fast clock. I’ve tried the following options: property clk_frequency_P(logic pll_clk, logic destination_clk, logic clk_en, logic reset, int divisor)...
Sarti's user avatar
  • 153
1 vote
1 answer
343 views

module DCP_21( input a, input b, output w, output x, output y, output z ); assign w = ~(a & b); assign x = ~(a | b); assign y = a^b; assign z = ~(...
Anushka Nair's user avatar
1 vote
1 answer
101 views

For the code below, I utilized a predefined RAM module from Quartus to create the RAM. How do I determine the port order when instantiating it? I understand it must be compatible with the module from ...
mmm's user avatar
  • 11
0 votes
1 answer
59 views

In SystemVerilog LRM 1800-2017 , section 15.4.5., the declaration of the get task for mailbox is the following: task get( ref singular message ); Why is the direction type ref, not output?
Mo'men Sameh's user avatar
0 votes
1 answer
187 views

What is a good way to test the interaction between two (or more) modules using cocotb? For example, say we have a transmitter (TX) and receiver (RX) module, and we want to test them together (e.g., RX ...
pbandlead's user avatar
0 votes
1 answer
122 views

Are there major differences between using ##1 and |=> in System Verilog assertions A ##1 B and A => B. When do they behave similarly, and when do they differ? For example property p_a_then_b; ...
user2979872's user avatar
0 votes
1 answer
90 views

How to write a part select expression using shift operator in system Verilog? Given a memory word logic [0:8] memword; How to write the part select expression memword[i:j] in shift operator? If not ...
Subramanya Krishna's user avatar
1 vote
1 answer
92 views

I have the following code: logic [3:0] a = 4'1010; logic [3:0] b = 4'b0111; logic [3:0] f = 4'b1000; // ~b logic [4:0] c; logic [4:0] d; logic [4:0] e; assign c = a + b; // this gives a ...
Paulo's user avatar
  • 135
-2 votes
1 answer
147 views

I am developing an FSM to latch on to incoming data and compute its average in Verilog, but my FSM seems to be just stuck at one state. Although the simulation shows it shifted perfectly in previous ...
FPGAguru2015's user avatar
1 vote
1 answer
150 views

Here is my code on EDA Playground. `include "uvm_macros.svh" import uvm_pkg::*; //////////////////////transaction class////////////////////// class transaction extends uvm_sequence_item; `...
Dev Munvar's user avatar
-1 votes
1 answer
83 views

I have an input SystemVerilog RTL like this : typedef struct packed { logic [1:0][3:0] a; struct packed { logic [4:0] b; logic c; logic [1:0] d; } e; // anonymous packed struct ...
jel88's user avatar
  • 45

1
2 3 4 5
73