예제 #1
0
  virtual void put(const T& t) {

    cout << sc_time_stamp() << " SC consumer executing packet:" 
       << endl << "  " << t << endl;

    wait(10,SC_NS);

    ap.write(t);
  }
예제 #2
0
파일: sctop.cpp 프로젝트: funningboy/smtdv
 void run() {
   wait(50, SC_NS);
   for (int i = 17; i < 17+N; i++) {
     T pkt(i);
     cout << "[SC " << sc_time_stamp() << "] producer, writing on tlm_analysis_port: ";
     pkt.print(cout);
     aport.write(pkt);
     wait(10, SC_NS);
     cnt = i;
   }
   if(cnt == 16+N) 
     cout << "TEST PASSED" << endl;
   else
     cout << "TEST FAILED" << endl;
 }
예제 #3
0
파일: sctop.cpp 프로젝트: funningboy/smtdv
 producer(sc_module_name nm) : uvm_component(nm), aport("aport") {
   cout << "SC producer::producer name= " << this->name() << endl;
   cout << "SC producer::aport " << aport.name() << endl;
 }