Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
kazoo
Commits
ae2eb78e
Commit
ae2eb78e
authored
Sep 05, 2019
by
Maxime Perrotin
Browse files
Use Opengeode in Demo_ABB
parent
20021542
Changes
43
Hide whitespace changes
Inline
Side-by-side
templates/concurrency_view/aadl_4_makefile/block.tmplt
View file @
ae2eb78e
...
...
@@ -8,7 +8,7 @@
@@-- @_Unprotected_PIs_@ : Unprotected Provided interfaces (from pi.tmplt)
@@-- @_Required_@ : Required interfaces (from ri.tmplt)
@_LOWER:Name_@ :
@@IF@@ @_
LOWER:
Language_@ =
"sdl"
@@IF@@ @_Language_@ =
SDL
# Call opengeode to generate the functional code
make -j -C ../@_LOWER:Name_@/SDL generate-code
@@ELSE@@
...
...
templates/skeletons/ada-source/trigger.tmplt
View file @
ae2eb78e
...
...
@@ -15,6 +15,6 @@
@@-- @_Filename_Is_Present_@ : True if target function output already exists
@@-- @_Makefile_Is_Present_@ : True if target build script already exists
@@-- @_C_Middleware_@ : True if middleware is in C (e.g. PO-HI-C)
@@IF@@ @_Language_@ =
"
Ada
"
@@IF@@ @_Language_@ = Ada
TRUE
@@END_IF@@
templates/skeletons/opengeode-structure/interface.tmplt
View file @
ae2eb78e
...
...
@@ -14,12 +14,12 @@
@@IF@@ @_LOWER:Kind_@ = "cyclic_operation" or @_LOWER:Kind_@ = "sporadic_operation"
@@IF@@ @_Param_Names'Length_@ > 0
/* CIF Keep Specific Geode PARAMNAMES @_Param_Names_@ */
signal @_
CAPITALIZE:
Name_@ (@_REPLACE_ALL((-)/_):Param_Types_@)
signal @_Name_@ (@_REPLACE_ALL((-)/_):Param_Types_@)
@@ELSE@@
signal @_
CAPITALIZE:
Name_@
signal @_Name_@
@@END_IF@@
@@ELSE@@
procedure @_
CAPITALIZE:
Name_@;
procedure @_Name_@;
@@IF@@ @_EXIST:Param_Names_@
fpar
@@INLINE( )(,\n )(;\n external)@@
...
...
test/Demo_ABB/DataView.aadl
View file @
ae2eb78e
--------------------------------------------------------
--
! File generated by asn2aadl v2.1.
39
: DO NOT EDIT !
--
! File generated by asn2aadl v2.1.
41
: DO NOT EDIT !
--------------------------------------------------------
--
! InputASN1FileChecksum:
e4dd89bba248a6086ac359f24f27783b
:/home/taste/tool-src/kazoo/test/Demo_ABB/DataView.asn:
--
! InputASN1FileChecksum:
fc58a72b84447d6bd771ef41e6b1cb1f
:/home/taste/tool-src/kazoo/test/Demo_ABB/DataView.asn:
--
! InputASN1FileChecksum:ee8a7e01f29874c0d50f437d5abb9599:/home/taste/tool-inst/share/taste-types/taste-types.asn:
--------------------------------------------------------
...
...
@@ -48,11 +48,11 @@ PROPERTIES
Deployment
::
ASN1_Module_Name
=>
"Lift-dataview"
;
Source_Language
=>
(
ASN1
);
--
Size
of
a
buffer
to
cover
all
forms
of
message
representation
:
--
Real
message
size
is
8
;
suggested
aligned
message
buffer
is
...
Source_Data_Size
=>
8
Bytes
;
--
Real
message
size
is
16
;
suggested
aligned
message
buffer
is
...
Source_Data_Size
=>
16
Bytes
;
--
name
of
the
corresponding
data
type
in
the
source
file
:
Type_Source_Name
=>
"Cabin-button"
;
TASTE
::
Position_In_File
=>
[
line
=>
4
1
;
column
=>
1
;
];
TASTE
::
Position_In_File
=>
[
line
=>
4
0
;
column
=>
1
;
];
--
what
kind
of
type
is
this
?
TASTE
::
ASN1_Basic_Type
=>
aCHOICE
;
END
Cabin_button
;
...
...
@@ -67,8 +67,8 @@ DATA IMPLEMENTATION Cabin_button_Buffer_Max.impl
--
Buffer
to
hold
a
marshalled
data
of
type
Cabin_button
PROPERTIES
Data_Model
::
Data_Representation
=>
array
;
Data_Model
::
Dimension
=>
(
8
);
--
Size
of
the
buffer
Source_Data_Size
=>
8
Bytes
;
--
Size
of
the
buffer
in
bytes
Data_Model
::
Dimension
=>
(
16
);
--
Size
of
the
buffer
Source_Data_Size
=>
16
Bytes
;
--
Size
of
the
buffer
in
bytes
Data_Model
::
Base_Type
=>
(
classifier
(
DataView
::
Stream_Element_Buffer
));
END
Cabin_button_Buffer_Max
.
impl
;
...
...
@@ -82,7 +82,7 @@ SUBCOMPONENTS
Length
:
data
Base_Types
::
Unsigned_32
;
PROPERTIES
Data_Model
::
Data_Representation
=>
Struct
;
Source_Data_Size
=>
2
4
Bytes
;
--
Size
of
the
buffer
in
bytes
Source_Data_Size
=>
3
2
Bytes
;
--
Size
of
the
buffer
in
bytes
END
Cabin_button_Buffer
.
impl
;
DATA
Floor_button
...
...
@@ -93,11 +93,11 @@ PROPERTIES
Deployment
::
ASN1_Module_Name
=>
"Lift-dataview"
;
Source_Language
=>
(
ASN1
);
--
Size
of
a
buffer
to
cover
all
forms
of
message
representation
:
--
Real
message
size
is
8
;
suggested
aligned
message
buffer
is
...
Source_Data_Size
=>
8
Bytes
;
--
Real
message
size
is
16
;
suggested
aligned
message
buffer
is
...
Source_Data_Size
=>
16
Bytes
;
--
name
of
the
corresponding
data
type
in
the
source
file
:
Type_Source_Name
=>
"Floor-button"
;
TASTE
::
Position_In_File
=>
[
line
=>
3
6
;
column
=>
1
;
];
TASTE
::
Position_In_File
=>
[
line
=>
3
5
;
column
=>
1
;
];
--
what
kind
of
type
is
this
?
TASTE
::
ASN1_Basic_Type
=>
aSEQUENCE
;
END
Floor_button
;
...
...
@@ -112,8 +112,8 @@ DATA IMPLEMENTATION Floor_button_Buffer_Max.impl
--
Buffer
to
hold
a
marshalled
data
of
type
Floor_button
PROPERTIES
Data_Model
::
Data_Representation
=>
array
;
Data_Model
::
Dimension
=>
(
8
);
--
Size
of
the
buffer
Source_Data_Size
=>
8
Bytes
;
--
Size
of
the
buffer
in
bytes
Data_Model
::
Dimension
=>
(
16
);
--
Size
of
the
buffer
Source_Data_Size
=>
16
Bytes
;
--
Size
of
the
buffer
in
bytes
Data_Model
::
Base_Type
=>
(
classifier
(
DataView
::
Stream_Element_Buffer
));
END
Floor_button_Buffer_Max
.
impl
;
...
...
@@ -127,7 +127,7 @@ SUBCOMPONENTS
Length
:
data
Base_Types
::
Unsigned_32
;
PROPERTIES
Data_Model
::
Data_Representation
=>
Struct
;
Source_Data_Size
=>
2
4
Bytes
;
--
Size
of
the
buffer
in
bytes
Source_Data_Size
=>
3
2
Bytes
;
--
Size
of
the
buffer
in
bytes
END
Floor_button_Buffer
.
impl
;
DATA
Floors
...
...
@@ -138,13 +138,13 @@ PROPERTIES
Deployment
::
ASN1_Module_Name
=>
"Lift-dataview"
;
Source_Language
=>
(
ASN1
);
--
Size
of
a
buffer
to
cover
all
forms
of
message
representation
:
--
Real
message
size
is
4
;
suggested
aligned
message
buffer
is
...
--
Real
message
size
is
8
;
suggested
aligned
message
buffer
is
...
Source_Data_Size
=>
8
Bytes
;
--
name
of
the
corresponding
data
type
in
the
source
file
:
Type_Source_Name
=>
"Floors"
;
TASTE
::
Position_In_File
=>
[
line
=>
9
;
column
=>
1
;
];
TASTE
::
Position_In_File
=>
[
line
=>
8
;
column
=>
1
;
];
--
what
kind
of
type
is
this
?
TASTE
::
ASN1_Basic_Type
=>
a
ENUMERATED
;
TASTE
::
ASN1_Basic_Type
=>
a
INTEGER
;
END
Floors
;
DATA
IMPLEMENTATION
Floors
.
impl
...
...
@@ -187,7 +187,7 @@ PROPERTIES
Source_Data_Size
=>
24
Bytes
;
--
name
of
the
corresponding
data
type
in
the
source
file
:
Type_Source_Name
=>
"Lift-control"
;
TASTE
::
Position_In_File
=>
[
line
=>
20
;
column
=>
1
;
];
TASTE
::
Position_In_File
=>
[
line
=>
19
;
column
=>
1
;
];
--
what
kind
of
type
is
this
?
TASTE
::
ASN1_Basic_Type
=>
aSEQUENCE
;
END
Lift_control
;
...
...
@@ -232,7 +232,7 @@ PROPERTIES
Source_Data_Size
=>
16
Bytes
;
--
name
of
the
corresponding
data
type
in
the
source
file
:
Type_Source_Name
=>
"Lift-sensor"
;
TASTE
::
Position_In_File
=>
[
line
=>
2
7
;
column
=>
1
;
];
TASTE
::
Position_In_File
=>
[
line
=>
2
6
;
column
=>
1
;
];
--
what
kind
of
type
is
this
?
TASTE
::
ASN1_Basic_Type
=>
aSEQUENCE
;
END
Lift_sensor
;
...
...
@@ -412,7 +412,7 @@ PROPERTIES
Source_Data_Size
=>
16
Bytes
;
--
name
of
the
corresponding
data
type
in
the
source
file
:
Type_Source_Name
=>
"Start-condition"
;
TASTE
::
Position_In_File
=>
[
line
=>
4
6
;
column
=>
1
;
];
TASTE
::
Position_In_File
=>
[
line
=>
4
5
;
column
=>
1
;
];
--
what
kind
of
type
is
this
?
TASTE
::
ASN1_Basic_Type
=>
aCHOICE
;
END
Start_condition
;
...
...
@@ -445,6 +445,51 @@ PROPERTIES
Source_Data_Size
=>
32
Bytes
;
--
Size
of
the
buffer
in
bytes
END
Start_condition_Buffer
.
impl
;
DATA
Status
PROPERTIES
--
name
of
the
ASN
.1
source
file
:
Source_Text
=>
(
"/home/taste/tool-src/kazoo/test/Demo_ABB/DataView.asn"
);
TASTE
::
Ada_Package_Name
=>
"Lift_dataview"
;
Deployment
::
ASN1_Module_Name
=>
"Lift-dataview"
;
Source_Language
=>
(
ASN1
);
--
Size
of
a
buffer
to
cover
all
forms
of
message
representation
:
--
Real
message
size
is
24
;
suggested
aligned
message
buffer
is
...
Source_Data_Size
=>
24
Bytes
;
--
name
of
the
corresponding
data
type
in
the
source
file
:
Type_Source_Name
=>
"Status"
;
TASTE
::
Position_In_File
=>
[
line
=>
50
;
column
=>
1
;
];
--
what
kind
of
type
is
this
?
TASTE
::
ASN1_Basic_Type
=>
aSEQUENCE
;
END
Status
;
DATA
IMPLEMENTATION
Status
.
impl
END
Status
.
impl
;
DATA
Status_Buffer_Max
END
Status_Buffer_Max
;
DATA
IMPLEMENTATION
Status_Buffer_Max
.
impl
--
Buffer
to
hold
a
marshalled
data
of
type
Status
PROPERTIES
Data_Model
::
Data_Representation
=>
array
;
Data_Model
::
Dimension
=>
(
24
);
--
Size
of
the
buffer
Source_Data_Size
=>
24
Bytes
;
--
Size
of
the
buffer
in
bytes
Data_Model
::
Base_Type
=>
(
classifier
(
DataView
::
Stream_Element_Buffer
));
END
Status_Buffer_Max
.
impl
;
DATA
Status_Buffer
END
Status_Buffer
;
DATA
IMPLEMENTATION
Status_Buffer
.
impl
--
Buffer
to
hold
a
marshalled
data
of
type
Status
SUBCOMPONENTS
Buffer
:
data
Status_Buffer_Max
.
impl
;
Length
:
data
Base_Types
::
Unsigned_32
;
PROPERTIES
Data_Model
::
Data_Representation
=>
Struct
;
Source_Data_Size
=>
40
Bytes
;
--
Size
of
the
buffer
in
bytes
END
Status_Buffer
.
impl
;
DATA
T_Boolean
PROPERTIES
--
name
of
the
ASN
.1
source
file
:
...
...
@@ -729,6 +774,7 @@ SUBCOMPONENTS
OpenClose
:
DATA
OpenClose
.
impl
;
Position
:
DATA
Position
.
impl
;
Start_condition
:
DATA
Start_condition
.
impl
;
Status
:
DATA
Status
.
impl
;
T_Boolean
:
DATA
T_Boolean
.
impl
;
T_Int32
:
DATA
T_Int32
.
impl
;
T_Int8
:
DATA
T_Int8
.
impl
;
...
...
test/Demo_ABB/DataView.asn
View file @
ae2eb78e
...
...
@@ -5,15 +5,14 @@ UpDown ::= ENUMERATED { up (1), down (0) }
OnOff ::= ENUMERATED { on (1), off (0) }
OpenClose ::= ENUMERATED { door-open (1), door-close (0) }
Position ::= REAL (0.0 .. 100.0)
--Flag ::= BOOLEAN
Floors ::= ENUMERATED {
Floors ::= INTEGER {
floor-0 (10),
floor-1 (20),
floor-2 (30),
floor-3 (40),
floor-4 (50),
floor-5 (60)
}
}
(10 | 20 | 30 | 40 | 50 | 60)
-- Types used for the interfacing with the Simulink model
...
...
@@ -48,6 +47,11 @@ Start-condition ::= CHOICE {
nb-of-cycle INTEGER (50 .. 255)
}
Status ::= SEQUENCE {
lift Lift-sensor,
door OpenClose
}
END
...
...
test/Demo_ABB/DeploymentView.aadl
View file @
ae2eb78e
...
...
@@ -74,6 +74,6 @@ PROPERTIES
Taste::coordinates => "0 0 2970 2100";
Taste::version => "2.2";
Taste::interfaceView => "InterfaceView.aadl";
Taste::HWLibraries => ("
../../../..
/tool-inst/share/ocarina/AADLv2/ocarina_components.aadl");
Taste::HWLibraries => ("
/home/taste
/tool-inst/share/ocarina/AADLv2/ocarina_components.aadl");
END deploymentview::DV;
test/Demo_ABB/InterfaceView.aadl
View file @
ae2eb78e
...
...
@@ -65,19 +65,19 @@ PROPERTIES
Compute_Execution_Time => 0 ms .. 0 ms;
END PI_Manual_Control.others;
SUBPROGRAM PI_Start
SUBPROGRAM PI_Start
_Controller
FEATURES
start_param : IN PARAMETER DataView::Start_condition {
Taste::encoding => NATIVE;
};
PROPERTIES
Taste::Associated_Queue_Size => 1;
END PI_Start;
END PI_Start
_Controller
;
SUBPROGRAM IMPLEMENTATION PI_Start.others
SUBPROGRAM IMPLEMENTATION PI_Start
_Controller
.others
PROPERTIES
Compute_Execution_Time => 0 ms .. 0 ms;
END PI_Start.others;
END PI_Start
_Controller
.others;
SUBPROGRAM RI_Operate_lift
FEATURES
...
...
@@ -92,35 +92,15 @@ END RI_Operate_lift;
SUBPROGRAM IMPLEMENTATION RI_Operate_lift.others
END RI_Operate_lift.others;
SUBPROGRAM RI_
door_status
SUBPROGRAM RI_
Housekeeping
FEATURES
status
: IN PARAMETER DataView::
OpenClose
{
Taste::encoding =>
NATIVE
;
housekeeping
: IN PARAMETER DataView::
Status
{
Taste::encoding =>
UPER
;
};
END RI_
door_status
;
END RI_
Housekeeping
;
SUBPROGRAM IMPLEMENTATION RI_door_status.others
END RI_door_status.others;
SUBPROGRAM RI_floor_detected
FEATURES
floor : IN PARAMETER DataView::Floors {
Taste::encoding => NATIVE;
};
END RI_floor_detected;
SUBPROGRAM IMPLEMENTATION RI_floor_detected.others
END RI_floor_detected.others;
SUBPROGRAM RI_position
FEATURES
pos : IN PARAMETER DataView::Position {
Taste::encoding => NATIVE;
};
END RI_position;
SUBPROGRAM IMPLEMENTATION RI_position.others
END RI_position.others;
SUBPROGRAM IMPLEMENTATION RI_Housekeeping.others
END RI_Housekeeping.others;
SYSTEM Controller
FEATURES
...
...
@@ -152,12 +132,12 @@ FEATURES
Taste::Deadline => 0 ms;
Taste::InterfaceName => "Manual_Control";
};
PI_Start : PROVIDES SUBPROGRAM ACCESS interfaceview::IV::Controller::PI_Start.others {
PI_Start
_Controller
: PROVIDES SUBPROGRAM ACCESS interfaceview::IV::Controller::PI_Start
_Controller
.others {
Taste::coordinates => "1519 1467";
Taste::RCMoperationKind => sporadic;
Taste::RCMperiod => 0 ms;
Taste::Deadline => 0 ms;
Taste::InterfaceName => "Start";
Taste::InterfaceName => "Start
_Controller
";
};
RI_Operate_lift : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::Lift_Model::PI_Operate_lift.others {
Taste::coordinates => "2027 859";
...
...
@@ -165,34 +145,18 @@ FEATURES
Taste::InterfaceName => "Operate_lift";
Taste::labelInheritance => "true";
};
RI_door_status : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::User::PI_door_status.others {
Taste::coordinates => "1519 1128";
Taste::RCMoperationKind => sporadic;
Taste::InterfaceName => "door_status";
Taste::labelInheritance => "true";
};
RI_floor_detected : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::User::PI_floor_detected.others {
Taste::coordinates => "1519 1237";
Taste::RCMoperationKind => sporadic;
Taste::InterfaceName => "floor_detected";
Taste::labelInheritance => "true";
};
RI_position : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::User::PI_position.others {
Taste::coordinates => "1519 1338";
Taste::RCMoperationKind => sporadic;
Taste::InterfaceName => "position";
RI_Housekeeping : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::User::PI_Housekeeping.others {
Taste::coordinates => "1519 1247";
Taste::RCMoperationKind => any;
Taste::InterfaceName => "Housekeeping";
Taste::labelInheritance => "true";
};
PROPERTIES
Source_Language => (
RTDS
);
Source_Language => (
SDL
);
Taste::Active_Interfaces => enabled;
END Controller;
SYSTEM IMPLEMENTATION Controller.others
SUBCOMPONENTS
starting_floor : DATA DataView::Floors {
Taste::FS_Default_Value => "floor_0";
};
END Controller.others;
END interfaceview::IV::Controller;
...
...
@@ -246,47 +210,19 @@ WITH interfaceview::IV::Controller;
WITH Taste;
WITH DataView;
WITH TASTE_IV_Properties;
SUBPROGRAM PI_
door_status
SUBPROGRAM PI_
Housekeeping
FEATURES
status
: IN PARAMETER DataView::
OpenClose
{
Taste::encoding =>
NATIVE
;
housekeeping
: IN PARAMETER DataView::
Status
{
Taste::encoding =>
UPER
;
};
PROPERTIES
Taste::Associated_Queue_Size => 1;
END PI_
door_status
;
END PI_
Housekeeping
;
SUBPROGRAM IMPLEMENTATION PI_
door_status
.others
SUBPROGRAM IMPLEMENTATION PI_
Housekeeping
.others
PROPERTIES
Compute_Execution_Time => 0 ms .. 0 ms;
END PI_door_status.others;
SUBPROGRAM PI_floor_detected
FEATURES
floor : IN PARAMETER DataView::Floors {
Taste::encoding => NATIVE;
};
PROPERTIES
Taste::Associated_Queue_Size => 1;
END PI_floor_detected;
SUBPROGRAM IMPLEMENTATION PI_floor_detected.others
PROPERTIES
Compute_Execution_Time => 0 ms .. 0 ms;
END PI_floor_detected.others;
SUBPROGRAM PI_position
FEATURES
pos : IN PARAMETER DataView::Position {
Taste::encoding => NATIVE;
};
PROPERTIES
Taste::Associated_Queue_Size => 1;
END PI_position;
SUBPROGRAM IMPLEMENTATION PI_position.others
PROPERTIES
Compute_Execution_Time => 0 ms .. 0 ms;
END PI_position.others;
END PI_Housekeeping.others;
SUBPROGRAM RI_Floor_Command
FEATURES
...
...
@@ -318,38 +254,24 @@ END RI_Manual_Control;
SUBPROGRAM IMPLEMENTATION RI_Manual_Control.others
END RI_Manual_Control.others;
SUBPROGRAM RI_Start
SUBPROGRAM RI_Start
_Controller
FEATURES
start_param : IN PARAMETER DataView::Start_condition {
Taste::encoding => NATIVE;
};
END RI_Start;
END RI_Start
_Controller
;
SUBPROGRAM IMPLEMENTATION RI_Start.others
END RI_Start.others;
SUBPROGRAM IMPLEMENTATION RI_Start
_Controller
.others
END RI_Start
_Controller
.others;
SYSTEM User
FEATURES
PI_door_status : PROVIDES SUBPROGRAM ACCESS interfaceview::IV::User::PI_door_status.others {
Taste::coordinates => "907 1128";
Taste::RCMoperationKind => sporadic;
Taste::RCMperiod => 0 ms;
Taste::Deadline => 0 ms;
Taste::InterfaceName => "door_status";
};
PI_floor_detected : PROVIDES SUBPROGRAM ACCESS interfaceview::IV::User::PI_floor_detected.others {
Taste::coordinates => "907 1237";
PI_Housekeeping : PROVIDES SUBPROGRAM ACCESS interfaceview::IV::User::PI_Housekeeping.others {
Taste::coordinates => "907 1251";
Taste::RCMoperationKind => sporadic;
Taste::RCMperiod => 0 ms;
Taste::Deadline => 0 ms;
Taste::InterfaceName => "floor_detected";
};
PI_position : PROVIDES SUBPROGRAM ACCESS interfaceview::IV::User::PI_position.others {
Taste::coordinates => "907 1338";
Taste::RCMoperationKind => sporadic;
Taste::RCMperiod => 0 ms;
Taste::Deadline => 0 ms;
Taste::InterfaceName => "position";
Taste::InterfaceName => "Housekeeping";
};
RI_Floor_Command : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::Controller::PI_Floor_Command.others {
Taste::coordinates => "907 816";
...
...
@@ -369,10 +291,10 @@ FEATURES
Taste::InterfaceName => "Manual_Control";
Taste::labelInheritance => "true";
};
RI_Start : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::Controller::PI_Start.others {
RI_Start
_Controller
: REQUIRES SUBPROGRAM ACCESS interfaceview::IV::Controller::PI_Start
_Controller
.others {
Taste::coordinates => "907 1467";
Taste::RCMoperationKind => sporadic;
Taste::InterfaceName => "Start";
Taste::InterfaceName => "Start
_Controller
";
Taste::labelInheritance => "true";
};
PROPERTIES
...
...
@@ -406,7 +328,7 @@ SUBCOMPONENTS
Taste::coordinates => "1519 671 2027 1599";
};
Lift_Model : SYSTEM interfaceview::IV::Lift_Model::Lift_Model.others {
Taste::coordinates => "2306
631
2835
1403
";
Taste::coordinates => "2306
728
2835
931
";
};
User : SYSTEM interfaceview::IV::User::User.others {
Taste::coordinates => "261 606 907 1587";
...
...
@@ -421,20 +343,14 @@ CONNECTIONS
Controller_PI_Manual_Control_User_RI_Manual_Control : SUBPROGRAM ACCESS Controller.PI_Manual_Control -> User.RI_Manual_Control {
Taste::coordinates => "907 1017 1207 1017 1207 1017 1519 1017";
};
Controller_PI_Start_User_RI_Start : SUBPROGRAM ACCESS Controller.PI_Start -> User.RI_Start {
Controller_PI_Start_
Controller_
User_RI_Start
_Controller
: SUBPROGRAM ACCESS Controller.PI_Start
_Controller
-> User.RI_Start
_Controller
{
Taste::coordinates => "907 1467 1207 1467 1207 1467 1519 1467";
};
Lift_Model_PI_Operate_lift_Controller_RI_Operate_lift : SUBPROGRAM ACCESS Lift_Model.PI_Operate_lift -> Controller.RI_Operate_lift {
Taste::coordinates => "2027 859 2166 859 2166 859 2306 859";
};
User_PI_door_status_Controller_RI_door_status : SUBPROGRAM ACCESS User.PI_door_status -> Controller.RI_door_status {
Taste::coordinates => "1519 1128 1207 1128 1207 1128 907 1128";
};
User_PI_floor_detected_Controller_RI_floor_detected : SUBPROGRAM ACCESS User.PI_floor_detected -> Controller.RI_floor_detected {
Taste::coordinates => "1519 1237 1207 1237 1207 1237 907 1237";
};
User_PI_position_Controller_RI_position : SUBPROGRAM ACCESS User.PI_position -> Controller.RI_position {
Taste::coordinates => "1519 1338 1207 1338 1207 1338 907 1338";
User_PI_Housekeeping_Controller_RI_Housekeeping : SUBPROGRAM ACCESS User.PI_Housekeeping -> Controller.RI_Housekeeping {
Taste::coordinates => "1519 1247 1213 1247 1213 1251 907 1251";
};
END interfaceview.others;
...
...
test/Demo_ABB/Makefile
View file @
ae2eb78e
...
...
@@ -3,7 +3,7 @@ KAZOO=../../kazoo
all
:
c
c
:
test-parse-c
#
Polyorb_HI_C output
cp
controller/controller
/
*
output.pohic/controller/
RTDS
/src
cp
controller/controller
.pr
output.pohic/controller/
SDL
/src
cp
lift_model/
*
output.pohic/lift_model/SIMULINK/src
make
-C
output.pohic
...
...
test/Demo_ABB/controller/RTDSdataView.asn
deleted
100644 → 0
View file @
20021542
Lift-dataview DEFINITIONS ::=
BEGIN
UpDown ::= ENUMERATED { up (1), down (0) }
OnOff ::= ENUMERATED { on (1), off (0) }
OpenClose ::= ENUMERATED { door-open (1), door-close (0) }
Position ::= REAL (0.0 .. 100.0)
Flag ::= BOOLEAN
Floors ::= ENUMERATED {
floor-0 (10),
floor-1 (20),
floor-2 (30),
floor-3 (40),
floor-4 (50),
floor-5 (60),
floor-above (70)
}
-- Types used for the interfacing with the Simulink model
Lift-control ::= SEQUENCE {
direction UpDown,
motor OnOff,
brake OnOff,
door OpenClose
}
Lift-sensor ::= SEQUENCE {
door-open Flag,
door-closed Flag,
floor-detected Flag,
pos-x Position
}
-- Types used for the user interaction
Floor-button ::= SEQUENCE {
floor Floors,
direction UpDown
}
Cabin-button ::= CHOICE {
emergency-stop Flag,
floor Floors
}
Start-condition ::= CHOICE {
forever BOOLEAN,
nb-of-cycle INTEGER (1..255)
}
END
test/Demo_ABB/controller/controller.pr
0 → 100644
View file @
ae2eb78e
/*
CIF
PROCESS
(
250
,
150
),
(
150
,
75
)
*/
process
Controller
;
/*
CIF
TEXT
(
0
,
100
),
(
278
,
184
)
*/
dcl
cmd
Lift_control
,
counter
Start_condition
,
sensors
Lift_sensor
,
door
OpenClose
:=
door_close
,
floor_cmd
Floor_button
,
cabin_cmd
Cabin_button
,
target_pos
Position
;
dcl
hk
Status
;
/*
CIF
ENDTEXT
*/
/*
CIF
START
(
456
,
71
),
(
70
,
35
)
*/
START
;
/*
CIF
task
(
385
,
126
),
(
212
,
184
)
*/
task
sensors
.
pos_x
:=
60.0
,
cmd
:=
{
direction
down
,
motor
off
,
door
door_close
,
brake
on
},
counter
:=
forever
:
false
/*
CIF
comment
(
617
,
200
),
(
145
,
35
)
*/
comment
'Set initial conditions'
;
/*
CIF
NEXTSTATE
(
445
,
341
),
(
90
,
35
)
*/
NEXTSTATE
Power_Off
;
/*
CIF
label
(
2921
,
85
),
(
102
,
57
)
*/
connection
move
:
/*
CIF
decision
(
2859
,
159
),
(
226
,
75
)
*/
decision
target_pos
=
round
(
sensors
.
pos_x
);
/*
CIF
ANSWER
(
2813
,
254
),
(
70
,
24
)
*/
(
true
):
/*
CIF
task
(
2767
,
298
),
(
161
,
120
)
*/