1. The sequence to generate Ip_transaction are as follows:
2. The corresponding sequencer are as follows:
3. This sequencer is to be instantiated in My_agent, at this time, there are two sequencer in my_agent:
4. To use layer sequence, the most important thing is how to give ip_transaction to the sequence that produces my_transaction. Add a port to the My_sequencer and instantiate:
5. Connect in My_agent:
6. In the sequence that produce my_transaction:
1) because you want to use the variable ip_tr_port in sequencer, you use the DECLARE_P_SEQUENCER macro to declare sequencer.
2) wireless cycle, because the time to get new ip_transaction from Ip_tr_port. An infinite loop like driver. So you can't objection in it.
3) Objection to be controlled in ip_sequence.
7. Start these two sequence:
8. Default_sequence can be used, provided that the member variable in VSQR points to the corresponding sequencer:
1) When establishing CRC error, only need to establish crc_sequence and start on My_sequencer.
2) When building checksum, just build cks_err_seq and start on Ip_sequencer.
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.
Example of uvm:10.2.2 layer sequence