1
\$\begingroup\$

How does assignment through a contribution statement (statements with <+ operator) works in verilog-a?

I read in the language reference manual of verilog-a the following about the branch contribution statement:

The simulator adds the value of the right-hand side (of contribution statement) to any previously retained value for the branch for later assignment to the branch. If there are no previously retained values, the value of the right-hand side itself is retained.

Could anyone explain to me how this method assigns proper values for the branch current or voltage?

Ricardo
6,22420 gold badges56 silver badges90 bronze badges
asked Jul 4, 2014 at 9:30
\$\endgroup\$

1 Answer 1

2
\$\begingroup\$

This can be explained with the help of the following example:
analog begin V(in) <+ 2; V(in) <+ 3; end
Initially the simulator sees the value 2 and assigns it as a voltage of port in. Then it sees the value 3, but the simulator will add the previously stored value for in i.e., 2 to the present value so final value assigned will be 5V.

answered Aug 2, 2014 at 14:01
\$\endgroup\$

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

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.