I was wondering if there was a way of modelling bidir switch.
Using code, I always have a problem of propagating signal.
For instance:
module bidir_sw( a, b, ctrl);
inout a;
inout b;
inout ctrl
wreal a;
wreal b;
logic ctrl;
// this will only work from b -> a
assign a = (ctrl == 1'b1) ? b : `wrealZState;
// this will only work from a -> b
assign b = (ctrl == 1'b1) ? a : `wrealZState;
endmodule
Is there an easy way to make it work both ways, using XCELIUM ?