Can an operation expression be used as the VPI callback obje

A

abc

Guest
I tried to write a VPI callback which was called when the value was
changed. It works when the callback object is not operation.

initial $monitor(a); // It works

initial $monitor(a !== 3'b010); // It can't register the callback

Can an operation expression be used as the callback object?

Thanks,
 
Swapnajit Mittra wrote:
abc <abc@yahoo.com> wrote in message news:<RAAUc.84$euc.23@news04.bloor.is.net.cable.rogers.com>...

I tried to write a VPI callback which was called when the value was
changed. It works when the callback object is not operation.

initial $monitor(a); // It works

initial $monitor(a !== 3'b010); // It can't register the callback

Can an operation expression be used as the callback object?

Thanks,


Have you tried the following?

wire flag;
assign flag = (a !== 3'b010);

initial $monitor(flag);
It works using a temporary variable. But it requires to define an
additional variable. Is it impossible to attach a value change callback
on an operational expression such as (a !== 3'b010)?

Thanks,

- Swapnajit.
--
SystemVerilog, DPI, Verilog PLI and all other good stuffs.
Project VeriPage: http://www.project-veripage.com
For subscribing to the mailing list:
URL: http://www.project-veripage.com/list/?p=subscribe&id=1
 

Welcome to EDABoard.com

Sponsor

Back
Top