Jump to content


  • Content Count

  • Joined

  • Last visited

Everything posted by gyro

  1. Thanks, waiting for both edges of clock work fine. I have a another question, Let's say i have one SC_THREAD and one SC_METHOD(my_run) in SC_THREAD i set out port Vld to true run() { // do some stuff Vld.write(true); // do some stuff // wait // check condition if true notify method } my_run() { Vld.write(false); } I get a multiple driver error. Can't i access same port from two different process. Is this beacuse of non-deterministic scheduling of process within the same cycle, Vld can be overwrriten with different values ?
  2. I can't put the exact code here, but will try to put the basic idea that i intend to do. I have testbench, something like : class tb : public sc_module { sc_in<bool> Rdy; sc_out<bool> vld; sc_clock m_clk; SC_THREAD(run); sensitive << m_clk; }; void run() { if vld = false // do some stuff // no the next rising edge of clk check if rdy is high // if yes de-assert vld // else wait for rdy to become high } I have component say mod to which all these port are tied
  3. Kindly bear with me if the question is too naive. I have a SystemC module, and i want to introduce a delay of 1 cycle, how can i do that ? As per my understanding , something like wait(1, SC_NS) is delay of 1 NS not really a delay of 1 cycle. Thanks
  • Create New...