1

I have the following member in transaction:

bit [31:0] data [$];

The interface has the following input:

 logic [31:0] WDATA

In the driver, I want to assign the concatenation of the transaction data to itself. For example if the data contains FFFFFFFF, I have to concatenate FFFFFFFF to FFFFFFFF, and then assign it to the virtual interface

pseudo code:

vif.DATA <= trx.data[i] (concatenation) trx.tata[i]

How can I do it?

1 Answer 1

1

Use the concatenation operator {} (refer to IEEE Std 1800-2012, section 11.4.12 Concatenation operators):

vif.DATA <= {trx.data[i], trx.tata[i]}
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.