79125165

Date: 2024-10-25 10:04:23
Score: 2
Natty:
Report link

If you are inside an SC_METHOD or if you don't want to stop (in time) an SC_THREAD, then the following will work:

#define SC_INCLUDE_DYNAMIC_PROCESSES
#include <systemc>

  //...
  sc_signal<int, SC_MANY_WRITERS> sig;
  //...
  sc_spawn( [&](){ wait(DELAY); sig.write(VALUE); } );

This was taken from here: https://forums.accellera.org/topic/7010-how-to-model-output-delay-in-systemc-like-the-verilog-non-blocking-intra-assignment-delay/

Reasons:
  • Probably link only (1):
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Marco Breiling