source: trunk/IPs/systemC/processor/Morpheo/Behavioural/New_Component/include/New_Component.h @ 40

Last change on this file since 40 was 40, checked in by rosiere, 17 years ago

Interface et Signal, c'est deux classes enregistres la valeurs des signaux à chaque cycle ... étape préparatoire avan le changement de la classe Vhdl_Testbench

File size: 3.4 KB
Line 
1#ifndef morpheo_behavioural_@DEFINE_@COMPONENT_h
2#define morpheo_behavioural_@DEFINE_@COMPONENT_h
3
4/*
5 * $Id$
6 *
7 * [ Description ]
8 *
9 */
10
11#ifdef SYSTEMC
12#include "systemc.h"
13#endif
14
15#include <iostream>
16#include "Include/ToString.h"
17#include "Include/Debug.h"
18
19#include "Behavioural/@DIRECTORY/include/Parameters.h"
20#include "Behavioural/@DIRECTORY/include/Types.h"
21#ifdef STATISTICS
22#include "Behavioural/@DIRECTORY/include/Statistics.h"
23#endif
24#ifdef POSITION
25#include "Behavioural/include/Position.h"
26#else
27#include "Behavioural/include/Interfaces.h"
28#endif
29#ifdef VHDL
30#include "Behavioural/include/Vhdl.h"
31#endif
32#ifdef VHDL_TESTBENCH
33#include "Behavioural/include/Vhdl_Testbench.h"
34#endif
35
36using namespace std;
37
38namespace morpheo {
39namespace behavioural {
40@NAMESPACE_BEGIN
41
42  class @COMPONENT
43#if SYSTEMC
44    : public sc_module
45#endif
46  {
47    // -----[ fields ]----------------------------------------------------
48    // Parameters
49  protected : const string     _name;
50
51  protected : const Parameters _param;
52//#ifdef STATISTICS
53//  protected : const morpheo::behavioural::Parameters_Statistics _param_statistics;
54//#endif
55
56#ifdef STATISTICS
57  private   : Statistics                     * _stat;
58#endif
59
60#ifdef VHDL_TESTBENCH
61  private   : Vhdl_Testbench                 * _vhdl_testbench;
62#endif
63
64#ifdef POSITION
65  private   : Position                       * _position;
66#endif
67
68  private   : Interfaces                     * _interfaces;
69
70#ifdef SYSTEMC
71    // ~~~~~[ Interface ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
72    // Interface
73  public    : SC_CLOCK                      *  in_CLOCK        ;
74  public    : SC_IN (Tcontrol_t)            *  in_NRESET       ;
75
76    // ~~~~~[ Component ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~   
77
78    // ~~~~~[ Register ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~   
79
80    // ~~~~~[ Internal ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
81#endif
82
83    // -----[ methods ]---------------------------------------------------
84
85#ifdef SYSTEMC
86    SC_HAS_PROCESS (@COMPONENT);
87#endif
88  public  :          @COMPONENT              (
89#ifdef SYSTEMC
90                                              sc_module_name                              name,
91#else                                         
92                                              string                                      name,
93#endif                                         
94#ifdef STATISTICS
95                                              morpheo::behavioural::Parameters_Statistics param_statistics,
96#endif
97                                              Parameters                                  param );
98                                               
99  public  :          @COMPONENT              (Parameters param );
100  public  :          ~@COMPONENT             (void);
101                                               
102#ifdef SYSTEMC                                 
103  private : void     allocation                (void);
104  private : void     deallocation              (void);
105                                               
106//#if defined(STATISTICS) or defined(VHDL_TESTBENCH)
107  public  : void     transition                (void);
108//#endif
109#endif                                         
110#ifdef STATISTICS
111  public  : string   statistics                (uint32_t depth);
112#endif
113                                               
114#if VHDL                                       
115  public  : void     vhdl                      (void);
116  private : void     vhdl_port                 (Vhdl & vhdl);
117  private : void     vhdl_declaration          (Vhdl & vhdl);
118  private : void     vhdl_body                 (Vhdl & vhdl);
119#endif                                         
120                                               
121#ifdef VHDL_TESTBENCH                         
122  private : void     vhdl_testbench_transition (void);
123#endif
124  public  : void     vhdl_testbench_label      (string label);
125  };
126
127@NAMESPACE_END
128}; // end namespace behavioural
129}; // end namespace morpheo             
130
131#endif
Note: See TracBrowser for help on using the repository browser.