source: trunk/IPs/systemC/processor/Morpheo/Behavioural/include/Interfaces.h @ 62

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

Modification en profondeur de Component-port_map.
Compilation ok pour Register_unit ... a tester (systemC et vhdl)

File size: 3.1 KB
Line 
1#ifndef morpheo_behavioural_Interfaces_h
2#define morpheo_behavioural_Interfaces_h
3
4/*
5 * $Id$
6 *
7 * [ Description ]
8 *
9 */
10
11#include <stdint.h>
12#include <iostream>
13#include <list>
14#include "Behavioural/include/Interface_fifo.h"
15#include "Common/include/ToString.h"
16#include "Common/include/Debug.h"
17#ifdef VHDL
18#include "Behavioural/include/Vhdl.h"
19#endif
20#include "Behavioural/include/Usage.h"
21
22using namespace std;
23
24namespace morpheo              {
25namespace behavioural          {
26
27  class Interfaces
28  {
29    // -----[ fields ]----------------------------------------------------
30  private   : const string               _name;
31  private   : const Tusage_t             _usage;
32  private   : list<Interface_fifo*>    * _list_interface;
33
34    // -----[ methods ]---------------------------------------------------
35  public    :                       Interfaces            (string name, 
36                                                           Tusage_t usage=USE_ALL);
37  public    :                       Interfaces            (const Interfaces & interfaces);
38  public    :                       ~Interfaces           ();
39
40  public    : Interface_fifo *      set_interface         (string         name       
41#ifdef POSITION
42                                                           ,direction_t    direction   
43                                                           ,localisation_t localisation
44#endif
45                                                           );
46#ifdef POSITION
47  public    : Interface_fifo *      set_interface         (string         name        ,
48                                                           direction_t    direction   ,
49                                                           localisation_t localisation,
50                                                           string         comment     );
51#endif
52  private   : string                get_interface         (void);
53  public    :list<Interface_fifo*>* get_interface_list    (void);
54
55#ifdef VHDL
56  public    : void                  set_port              (Vhdl           * & vhdl          );
57#  ifdef VHDL_TESTBENCH
58  private   : void                  get_signal            (list<string>   * & list_signal   );
59  private   : void                  set_signal            (Vhdl           * & vhdl          );
60#  endif
61#endif
62#ifdef VHDL_TESTBENCH
63  private   : uint32_t              get_cycle             (void);
64  private   : Signal *              get_clock             (void);
65  private   : Signal *              get_reset             (void);
66
67  private   : void                  testbench_generate_file (void);
68  public    : void                  testbench             (void);
69  private   : string                testbench_body        (Vhdl           * & vhdl          ,
70                                                           string             counter_name  ,
71                                                           string             reset_name    );
72#endif
73
74  public    : Interface_fifo  *     find_interface        (string name);
75  public    : Signal          *     find_signal           (string name);
76  public    : bool                  find_signal           (Signal * signal);
77
78#ifdef POSITION
79  public    : XML                   toXML                 (void);
80  public    : XML                   toXML_mapping         (void);
81#endif
82
83  public    : bool                  test_map              (bool top_level);
84
85  public    : friend ostream&       operator<<            (ostream& output_stream,
86                                                           morpheo::behavioural::Interfaces & x);
87
88  };
89
90}; // end namespace behavioural         
91}; // end namespace morpheo             
92
93#endif
Note: See TracBrowser for help on using the repository browser.