Untimed example

Let’s start with the first example…


We shall start with the include’s


using namespace sc_core;

#include "tlm.h"
#include "tlm_utils/simple_initiator_socket.h"

Firstly we include systemc and then tlm.h
Then we include the easiest socket for that example.
Now it’s time to declare the Initiator class

class Initiator: sc_module
  tlm_utils::simple_initiator_socket initiator_socket;
  Initiator(sc_module_name name_);

  void initiator_thread();

Continue reading »

Posted in Ejemplos | Tagged , , , , , | 1 Comment

Coding Styles

TLM-2 lists modeling 3 different modes (called Coding Styles in official documents): untimed, Loosely-timed and Approximately-timed. Each serves a specific purpose, and to model different types of systems. We must also take into account the cost of each simulation mode (untimed less expensive, Approximatelly-timed more expensive).

Continue reading »

Posted in General | Tagged , , , , | Leave a comment