source: trunk/IPs/systemC/processor/Morpheo/Behavioural/New_Component/src/New_Component_allocation.cpp @ 50

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

Changement dans le répertoire "New_Component" afin que les composants nouvellement crées peuvent compiler

File size: 1.2 KB
Line 
1#ifdef SYSTEMC
2/*
3 * $Id$
4 *
5 * [ Description ]
6 *
7 */
8
9#include "Behavioural/@DIRECTORY/include/@COMPONENT.h"
10
11namespace morpheo                    {
12namespace behavioural {
13@NAMESPACE_BEGIN
14
15  void @COMPONENT::allocation (void)
16  {
17    string rename;
18
19    log_printf(FUNC,@COMPONENT,"allocation","Begin");
20
21    _component   = new Component ();
22
23    Entity * entity = _component->set_entity (_name       
24                                              ,"@COMPONENT"
25#ifdef POSITION
26                                              ,COMBINATORY
27#endif
28                                              );
29
30    _interfaces = entity->set_interfaces();
31
32    // ~~~~~[ Interface : "" ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
33
34      Interface * interface = _interfaces->set_interface(""
35#ifdef POSITION
36                                                         ,IN
37                                                         ,SOUTH,
38                                                         "Generalist interface"
39#endif
40                                                         );
41
42     in_CLOCK        = interface->set_signal_clk              ("clock" ,1, CLOCK_VHDL_YES);
43     in_NRESET       = interface->set_signal_in  <Tcontrol_t> ("nreset",1, RESET_VHDL_YES);
44
45    // ~~~~~[ Component ]~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~   
46
47#ifdef POSITION
48    _component->generate_file();
49#endif
50
51    log_printf(FUNC,@COMPONENT,"allocation","End");
52  };
53
54@NAMESPACE_END
55}; // end namespace behavioural
56}; // end namespace morpheo             
57#endif
Note: See TracBrowser for help on using the repository browser.