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