Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
Ocarina
Commits
a7224455
Commit
a7224455
authored
Apr 20, 2015
by
Julien
Browse files
Update VxWorks653 configuration - errors with schedule
parent
0125f887
Changes
7
Hide whitespace changes
Inline
Side-by-side
src/backends/ocarina-backends-vxworks653_conf-connections.adb
View file @
a7224455
...
@@ -228,6 +228,8 @@ package body Ocarina.Backends.Vxworks653_Conf.Connections is
...
@@ -228,6 +228,8 @@ package body Ocarina.Backends.Vxworks653_Conf.Connections is
XTN
.
Subitems
(
Channel_Node
));
XTN
.
Subitems
(
Channel_Node
));
Append_Node_To_List
(
Channel_Node
,
Append_Node_To_List
(
Channel_Node
,
XTN
.
Subitems
(
Connections_Node
));
XTN
.
Subitems
(
Connections_Node
));
Channel_Identifier
:=
Channel_Identifier
+
1
;
end
if
;
end
if
;
Feature
:=
Next_Node
(
Feature
);
Feature
:=
Next_Node
(
Feature
);
end
loop
;
end
loop
;
...
...
src/backends/ocarina-backends-vxworks653_conf-hm.adb
View file @
a7224455
...
@@ -315,7 +315,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Hm is
...
@@ -315,7 +315,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Hm is
Add_Error_Action
(
System_State_Node
,
Add_Error_Action
(
System_State_Node
,
"HME_HM_DEADLINE_MISSED"
,
"hmDefaultHandler"
);
"HME_HM_DEADLINE_MISSED"
,
"hmDefaultHandler"
);
Add_Error_Action
(
System_State_Node
,
Add_Error_Action
(
System_State_Node
,
"
HME_
HM_MSG"
,
"hmDH_EventLog"
);
"HM_MSG"
,
"hmDH_EventLog"
);
Add_Error_Action
(
System_State_Node
,
Add_Error_Action
(
System_State_Node
,
"HME_DEFAULT"
,
"hmDefaultHandler"
);
"HME_DEFAULT"
,
"hmDefaultHandler"
);
...
@@ -385,7 +385,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Hm is
...
@@ -385,7 +385,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Hm is
XTU
.
Add_Attribute
(
"Name"
,
XTU
.
Add_Attribute
(
"Name"
,
Get_Name_String
Get_Name_String
(
Map_Partition_Name
(
Virtual_Processor
))
(
Map_Partition_Name
(
Virtual_Processor
))
&
"_hm"
,
&
"_hm
table
"
,
Partition_HM_Table_Node
);
Partition_HM_Table_Node
);
System_State_Node
:=
Make_XML_Node
(
"SystemState"
);
System_State_Node
:=
Make_XML_Node
(
"SystemState"
);
...
@@ -425,7 +425,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Hm is
...
@@ -425,7 +425,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Hm is
Add_Error_Action
(
System_State_Node
,
Add_Error_Action
(
System_State_Node
,
"HME_HM_DEADLINE_MISSED"
,
"hmDefaultHandler"
);
"HME_HM_DEADLINE_MISSED"
,
"hmDefaultHandler"
);
Add_Error_Action
(
System_State_Node
,
Add_Error_Action
(
System_State_Node
,
"
HME_
HM_MSG"
,
"hmDH_EventLog"
);
"HM_MSG"
,
"hmDH_EventLog"
);
Add_Error_Action
(
System_State_Node
,
Add_Error_Action
(
System_State_Node
,
"HME_DEFAULT"
,
"hmDefaultHandler"
);
"HME_DEFAULT"
,
"hmDefaultHandler"
);
...
...
src/backends/ocarina-backends-vxworks653_conf-mapping.adb
View file @
a7224455
...
@@ -11,7 +11,7 @@ with Ocarina.ME_AADL.AADL_Instances.Entities;
...
@@ -11,7 +11,7 @@ with Ocarina.ME_AADL.AADL_Instances.Entities;
with
Ocarina
.
Backends
.
Utils
;
with
Ocarina
.
Backends
.
Utils
;
with
Ocarina
.
Backends
.
Messages
;
with
Ocarina
.
Backends
.
Messages
;
with
Ocarina
.
Backends
.
XML_Common
.
Mapping
;
--
with Ocarina.Backends.XML_Common.Mapping;
with
Ocarina
.
Backends
.
XML_Values
;
with
Ocarina
.
Backends
.
XML_Values
;
with
Ocarina
.
Backends
.
XML_Tree
.
Nodes
;
with
Ocarina
.
Backends
.
XML_Tree
.
Nodes
;
with
Ocarina
.
Backends
.
XML_Tree
.
Nutils
;
with
Ocarina
.
Backends
.
XML_Tree
.
Nutils
;
...
@@ -23,7 +23,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Mapping is
...
@@ -23,7 +23,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Mapping is
use
Ocarina
.
ME_AADL
.
AADL_Instances
.
Entities
;
use
Ocarina
.
ME_AADL
.
AADL_Instances
.
Entities
;
use
Ocarina
.
Backends
.
Utils
;
use
Ocarina
.
Backends
.
Utils
;
use
Ocarina
.
Backends
.
Messages
;
use
Ocarina
.
Backends
.
Messages
;
use
Ocarina
.
Backends
.
XML_Common
.
Mapping
;
--
use Ocarina.Backends.XML_Common.Mapping;
use
Ocarina
.
Backends
.
XML_Tree
.
Nodes
;
use
Ocarina
.
Backends
.
XML_Tree
.
Nodes
;
use
Ocarina
.
Backends
.
XML_Tree
.
Nutils
;
use
Ocarina
.
Backends
.
XML_Tree
.
Nutils
;
...
@@ -845,99 +845,6 @@ package body Ocarina.Backends.Vxworks653_Conf.Mapping is
...
@@ -845,99 +845,6 @@ package body Ocarina.Backends.Vxworks653_Conf.Mapping is
end
Map_Process_Scheduling
;
end
Map_Process_Scheduling
;
--------------
-- Map_Port --
--------------
function
Map_Port
(
F
:
Node_Id
)
return
Node_Id
is
N
:
Node_Id
;
P
:
Node_Id
;
Q
:
Node_Id
;
R
:
Node_Id
;
begin
if
AIN
.
Is_Event
(
F
)
and
then
AIN
.
Is_Data
(
F
)
then
N
:=
Make_XML_Node
(
"Queueing_Port"
);
elsif
AIN
.
Is_Data
(
F
)
and
then
not
AIN
.
Is_Event
(
F
)
then
N
:=
Make_XML_Node
(
"Sampling_Port"
);
else
return
No_Node
;
end
if
;
-- Add the direction of the port as attribute
Set_Str_To_Name_Buffer
(
"Direction"
);
P
:=
Make_Defining_Identifier
(
Name_Find
);
if
AIN
.
Is_In
(
F
)
and
then
not
AIN
.
Is_Out
(
F
)
then
Set_Str_To_Name_Buffer
(
"DESTINATION"
);
elsif
AIN
.
Is_Out
(
F
)
and
then
not
AIN
.
Is_In
(
F
)
then
Set_Str_To_Name_Buffer
(
"SOURCE"
);
else
return
No_Node
;
end
if
;
Q
:=
Make_Defining_Identifier
(
Name_Find
);
Append_Node_To_List
(
Make_Assignement
(
P
,
Q
),
XTN
.
Items
(
N
));
-- Add the name of the port as an attribute
Set_Str_To_Name_Buffer
(
"Name"
);
R
:=
Make_Defining_Identifier
(
Name_Find
);
Q
:=
Make_Defining_Identifier
(
To_XML_Name
(
Display_Name
(
Identifier
(
F
))));
Append_Node_To_List
(
Make_Assignement
(
R
,
Q
),
XTN
.
Items
(
N
));
if
AIN
.
Is_Data
(
F
)
and
then
not
AIN
.
Is_Event
(
F
)
then
Set_Str_To_Name_Buffer
(
"RefreshRateSeconds"
);
R
:=
Make_Defining_Identifier
(
Name_Find
);
if
Get_POK_Refresh_Time
(
F
)
/=
Null_Time
then
Q
:=
Make_Literal
(
XV
.
New_Floating_Point_Value
(
To_Seconds
(
Get_POK_Refresh_Time
(
F
))));
else
Q
:=
Map_Time
(
Null_Time
);
end
if
;
Append_Node_To_List
(
Make_Assignement
(
R
,
Q
),
XTN
.
Items
(
N
));
elsif
AIN
.
Is_Data
(
F
)
and
then
AIN
.
Is_Event
(
F
)
then
Set_Str_To_Name_Buffer
(
"MaxNbMessages"
);
P
:=
Make_Defining_Identifier
(
Name_Find
);
if
Get_Queue_Size
(
F
)
/=
-
1
then
Q
:=
Make_Literal
(
XV
.
New_Numeric_Value
(
Unsigned_Long_Long
(
Get_Queue_Size
(
F
)),
1
,
10
));
else
Q
:=
Make_Literal
(
XV
.
New_Numeric_Value
(
1
,
1
,
10
));
end
if
;
Append_Node_To_List
(
Make_Assignement
(
P
,
Q
),
XTN
.
Items
(
N
));
end
if
;
if
AIN
.
Is_Data
(
F
)
then
Set_Str_To_Name_Buffer
(
"MaxMessageSize"
);
P
:=
Make_Defining_Identifier
(
Name_Find
);
if
Get_Data_Size
(
Corresponding_Instance
(
F
))
/=
Null_Size
then
Q
:=
Make_Literal
(
XV
.
New_Numeric_Value
(
To_Bytes
(
Get_Data_Size
(
Corresponding_Instance
(
F
))),
1
,
10
));
else
Q
:=
Make_Literal
(
XV
.
New_Numeric_Value
(
1
,
1
,
10
));
end
if
;
Append_Node_To_List
(
Make_Assignement
(
P
,
Q
),
XTN
.
Items
(
N
));
end
if
;
return
N
;
end
Map_Port
;
-------------------
-------------------
-- Map_Data_Size --
-- Map_Data_Size --
-------------------
-------------------
...
@@ -1122,7 +1029,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Mapping is
...
@@ -1122,7 +1029,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Mapping is
Application_Node
:=
Make_XML_Node
(
"Application"
);
Application_Node
:=
Make_XML_Node
(
"Application"
);
XTU
.
Add_Attribute
(
"NameRef"
,
XTU
.
Add_Attribute
(
"NameRef"
,
Get_Name_String
Get_Name_String
(
Map_
Parti
tion_Name
(
Runtime
,
True
)),
(
Map_
Applica
tion_Name
(
Runtime
,
True
)),
Application_Node
);
Application_Node
);
Append_Node_To_List
(
Application_Node
,
Append_Node_To_List
(
Application_Node
,
XTN
.
Subitems
(
Partition_Description_Node
));
XTN
.
Subitems
(
Partition_Description_Node
));
...
@@ -1141,7 +1048,8 @@ package body Ocarina.Backends.Vxworks653_Conf.Mapping is
...
@@ -1141,7 +1048,8 @@ package body Ocarina.Backends.Vxworks653_Conf.Mapping is
XTN
.
Subitems
(
Partition_Description_Node
));
XTN
.
Subitems
(
Partition_Description_Node
));
XTU
.
Add_Attribute
(
"RequiredMemorySize"
,
"0x300000"
,
Settings_Node
);
XTU
.
Add_Attribute
(
"RequiredMemorySize"
,
"0x300000"
,
Settings_Node
);
XTU
.
Add_Attribute
(
"PartitionHMTable"
,
XTU
.
Add_Attribute
(
"PartitionHMTable"
,
Get_Name_String
(
Map_Partition_Name
(
Runtime
))
&
"_hm"
,
Get_Name_String
(
Map_Partition_Name
(
Runtime
))
&
"_hmtable"
,
Settings_Node
);
Settings_Node
);
XTU
.
Add_Attribute
(
"watchDogDuration"
,
"0"
,
Settings_Node
);
XTU
.
Add_Attribute
(
"watchDogDuration"
,
"0"
,
Settings_Node
);
XTU
.
Add_Attribute
(
"allocDisable"
,
"0"
,
Settings_Node
);
XTU
.
Add_Attribute
(
"allocDisable"
,
"0"
,
Settings_Node
);
...
@@ -1162,7 +1070,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Mapping is
...
@@ -1162,7 +1070,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Mapping is
end
Map_Partition
;
end
Map_Partition
;
function
Map_Partition_Name
(
Runtime
:
Node_Id
;
function
Map_Partition_Name
(
Runtime
:
Node_Id
;
Use_Source_Name
:
Boolean
:=
Fals
e
)
Use_Source_Name
:
Boolean
:=
Tru
e
)
return
Name_Id
is
return
Name_Id
is
Result
:
Name_Id
;
Result
:
Name_Id
;
begin
begin
...
@@ -1177,4 +1085,16 @@ package body Ocarina.Backends.Vxworks653_Conf.Mapping is
...
@@ -1177,4 +1085,16 @@ package body Ocarina.Backends.Vxworks653_Conf.Mapping is
return
Result
;
return
Result
;
end
Map_Partition_Name
;
end
Map_Partition_Name
;
function
Map_Application_Name
(
Runtime
:
Node_Id
;
Use_Source_Name
:
Boolean
:=
True
)
return
Name_Id
is
Result
:
Name_Id
;
begin
Result
:=
Map_Partition_Name
(
Runtime
,
Use_Source_Name
);
Get_Name_String
(
Result
);
Add_Str_To_Name_Buffer
(
"_app"
);
Result
:=
Name_Find
;
return
Result
;
end
Map_Application_Name
;
end
Ocarina
.
Backends
.
Vxworks653_Conf
.
Mapping
;
end
Ocarina
.
Backends
.
Vxworks653_Conf
.
Mapping
;
src/backends/ocarina-backends-vxworks653_conf-mapping.ads
View file @
a7224455
...
@@ -5,7 +5,6 @@ package Ocarina.Backends.Vxworks653_Conf.Mapping is
...
@@ -5,7 +5,6 @@ package Ocarina.Backends.Vxworks653_Conf.Mapping is
function
Map_Distributed_Application
(
E
:
Node_Id
)
return
Node_Id
;
function
Map_Distributed_Application
(
E
:
Node_Id
)
return
Node_Id
;
function
Map_HI_Node
(
E
:
Node_Id
)
return
Node_Id
;
function
Map_HI_Node
(
E
:
Node_Id
)
return
Node_Id
;
function
Map_HI_Unit
(
E
:
Node_Id
)
return
Node_Id
;
function
Map_HI_Unit
(
E
:
Node_Id
)
return
Node_Id
;
function
Map_Port
(
F
:
Node_Id
)
return
Node_Id
;
function
Map_Data
(
E
:
Node_Id
)
return
Node_Id
;
function
Map_Data
(
E
:
Node_Id
)
return
Node_Id
;
function
Map_Data_Access
(
E
:
Node_Id
)
return
Node_Id
;
function
Map_Data_Access
(
E
:
Node_Id
)
return
Node_Id
;
function
Map_Bus_Access
(
E
:
Node_Id
)
return
Node_Id
;
function
Map_Bus_Access
(
E
:
Node_Id
)
return
Node_Id
;
...
@@ -48,7 +47,11 @@ package Ocarina.Backends.Vxworks653_Conf.Mapping is
...
@@ -48,7 +47,11 @@ package Ocarina.Backends.Vxworks653_Conf.Mapping is
function
Map_Queuing_Port
(
Port
:
Node_Id
)
return
Node_Id
;
function
Map_Queuing_Port
(
Port
:
Node_Id
)
return
Node_Id
;
function
Map_Partition_Name
(
Runtime
:
Node_Id
;
function
Map_Partition_Name
(
Runtime
:
Node_Id
;
Use_Source_Name
:
Boolean
:=
False
)
Use_Source_Name
:
Boolean
:=
True
)
return
Name_Id
;
function
Map_Application_Name
(
Runtime
:
Node_Id
;
Use_Source_Name
:
Boolean
:=
True
)
return
Name_Id
;
return
Name_Id
;
end
Ocarina
.
Backends
.
Vxworks653_Conf
.
Mapping
;
end
Ocarina
.
Backends
.
Vxworks653_Conf
.
Mapping
;
src/backends/ocarina-backends-vxworks653_conf-naming.adb
View file @
a7224455
...
@@ -13,6 +13,7 @@ with Ocarina.Backends.Utils;
...
@@ -13,6 +13,7 @@ with Ocarina.Backends.Utils;
with
Ocarina
.
Backends
.
XML_Tree
.
Nodes
;
with
Ocarina
.
Backends
.
XML_Tree
.
Nodes
;
with
Ocarina
.
Backends
.
XML_Tree
.
Nutils
;
with
Ocarina
.
Backends
.
XML_Tree
.
Nutils
;
with
Ocarina
.
Backends
.
Vxworks653_Conf
.
Mapping
;
with
Ocarina
.
Backends
.
Vxworks653_Conf
.
Mapping
;
with
Ocarina
.
Backends
.
XML_Values
;
with
Ocarina
.
Namet
;
use
Ocarina
.
Namet
;
with
Ocarina
.
Namet
;
use
Ocarina
.
Namet
;
package
body
Ocarina
.
Backends
.
Vxworks653_Conf
.
Naming
is
package
body
Ocarina
.
Backends
.
Vxworks653_Conf
.
Naming
is
...
@@ -30,6 +31,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Naming is
...
@@ -30,6 +31,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Naming is
package
AIN
renames
Ocarina
.
ME_AADL
.
AADL_Instances
.
Nodes
;
package
AIN
renames
Ocarina
.
ME_AADL
.
AADL_Instances
.
Nodes
;
package
XTN
renames
Ocarina
.
Backends
.
XML_Tree
.
Nodes
;
package
XTN
renames
Ocarina
.
Backends
.
XML_Tree
.
Nodes
;
package
XTU
renames
Ocarina
.
Backends
.
XML_Tree
.
Nutils
;
package
XTU
renames
Ocarina
.
Backends
.
XML_Tree
.
Nutils
;
package
XV
renames
Ocarina
.
Backends
.
XML_Values
;
procedure
Visit_Component
(
E
:
Node_Id
);
procedure
Visit_Component
(
E
:
Node_Id
);
procedure
Visit_System
(
E
:
Node_Id
);
procedure
Visit_System
(
E
:
Node_Id
);
...
@@ -227,7 +229,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Naming is
...
@@ -227,7 +229,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Naming is
Size
:
Unsigned_Long_Long
;
Size
:
Unsigned_Long_Long
;
Queue_Size
:
Long_Long
;
Queue_Size
:
Long_Long
;
Refresh_Period
:
Time_Type
;
Refresh_Period
:
Time_Type
;
Refresh_Period_Second
:
Float
;
Refresh_Period_Second
:
Long_Double
;
begin
begin
-- Application Node that is the child of Applications
-- Application Node that is the child of Applications
...
@@ -237,7 +239,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Naming is
...
@@ -237,7 +239,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Naming is
Application_Node
:=
Make_XML_Node
(
"Application"
);
Application_Node
:=
Make_XML_Node
(
"Application"
);
XTU
.
Add_Attribute
(
"Name"
,
XTU
.
Add_Attribute
(
"Name"
,
Get_Name_String
Get_Name_String
(
Map_
Parti
tion_Name
(
Map_
Applica
tion_Name
(
AADL_Virtual_Processor
,
True
)),
(
AADL_Virtual_Processor
,
True
)),
Application_Node
);
Application_Node
);
Append_Node_To_List
(
Application_Node
,
Append_Node_To_List
(
Application_Node
,
...
@@ -344,18 +346,17 @@ package body Ocarina.Backends.Vxworks653_Conf.Naming is
...
@@ -344,18 +346,17 @@ package body Ocarina.Backends.Vxworks653_Conf.Naming is
not
Is_Out
(
Feature
)
not
Is_Out
(
Feature
)
then
then
Refresh_Period
:=
Get_POK_Refresh_Time
(
Feature
);
Refresh_Period
:=
Get_POK_Refresh_Time
(
Feature
);
Refresh_Period_Second
:=
1000.0
/
Refresh_Period_Second
:=
(
Float
(
To_Milliseconds
(
Refresh_Period
))
*
(
Long_Double
(
To_Milliseconds
(
Refresh_Period
))
/
Float
(
100.0
));
Long_Double
(
100
0
.0
));
XTU
.
Add_Attribute
(
"Direction"
,
XTU
.
Add_Attribute
(
"Direction"
,
"DESTINATION"
,
"DESTINATION"
,
Port_Node
);
Port_Node
);
XTU
.
Add_Attribute
(
"RefreshRate"
,
XTU
.
Add_Attribute
(
"RefreshRate"
,
Trim
(
Float
'
Image
XV
.
New_Floating_Point_Value
(
Refresh_Period_Second
),
(
Refresh_Period_Second
),
Left
),
Port_Node
);
Port_Node
);
end
if
;
end
if
;
if
not
Is_In
(
Feature
)
and
then
if
not
Is_In
(
Feature
)
and
then
...
...
src/backends/ocarina-backends-vxworks653_conf-schedule.adb
View file @
a7224455
-- with Locations;
-- with Locations;
with
Ada
.
Strings
;
use
Ada
.
Strings
;
with
Ada
.
Strings
.
Fixed
;
use
Ada
.
Strings
.
Fixed
;
with
Ocarina
.
Namet
;
use
Ocarina
.
Namet
;
with
Ocarina
.
Namet
;
use
Ocarina
.
Namet
;
with
Ocarina
.
ME_AADL
;
with
Ocarina
.
ME_AADL
;
with
Ocarina
.
ME_AADL
.
AADL_Instances
.
Nodes
;
with
Ocarina
.
ME_AADL
.
AADL_Instances
.
Nodes
;
...
@@ -12,6 +9,7 @@ with Ocarina.Instances.Queries;
...
@@ -12,6 +9,7 @@ with Ocarina.Instances.Queries;
with
Ocarina
.
Backends
.
Properties
.
ARINC653
;
with
Ocarina
.
Backends
.
Properties
.
ARINC653
;
-- with Ocarina.Backends.Properties;
-- with Ocarina.Backends.Properties;
with
Ocarina
.
Backends
.
XML_Values
;
with
Ocarina
.
Backends
.
Utils
;
with
Ocarina
.
Backends
.
Utils
;
with
Ocarina
.
Backends
.
XML_Tree
.
Nodes
;
with
Ocarina
.
Backends
.
XML_Tree
.
Nodes
;
with
Ocarina
.
Backends
.
XML_Tree
.
Nutils
;
with
Ocarina
.
Backends
.
XML_Tree
.
Nutils
;
...
@@ -29,12 +27,14 @@ package body Ocarina.Backends.Vxworks653_Conf.Schedule is
...
@@ -29,12 +27,14 @@ package body Ocarina.Backends.Vxworks653_Conf.Schedule is
use
Ocarina
.
Backends
.
Utils
;
use
Ocarina
.
Backends
.
Utils
;
use
Ocarina
.
Backends
.
Properties
.
ARINC653
;
use
Ocarina
.
Backends
.
Properties
.
ARINC653
;
use
Ocarina
.
Backends
.
XML_Values
;
-- use Ocarina.Backends.Properties;
-- use Ocarina.Backends.Properties;
-- use Ocarina.Backends.Vxworks653_Conf.Mapping;
-- use Ocarina.Backends.Vxworks653_Conf.Mapping;
package
AINU
renames
Ocarina
.
ME_AADL
.
AADL_Instances
.
Nutils
;
package
AINU
renames
Ocarina
.
ME_AADL
.
AADL_Instances
.
Nutils
;
package
XTN
renames
Ocarina
.
Backends
.
XML_Tree
.
Nodes
;
package
XTN
renames
Ocarina
.
Backends
.
XML_Tree
.
Nodes
;
package
XTU
renames
Ocarina
.
Backends
.
XML_Tree
.
Nutils
;
package
XTU
renames
Ocarina
.
Backends
.
XML_Tree
.
Nutils
;
package
XV
renames
Ocarina
.
Backends
.
XML_Values
;
Root_Node
:
Node_Id
:=
No_Node
;
Root_Node
:
Node_Id
:=
No_Node
;
Schedules_Node
:
Node_Id
:=
No_Node
;
Schedules_Node
:
Node_Id
:=
No_Node
;
...
@@ -161,7 +161,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Schedule is
...
@@ -161,7 +161,7 @@ package body Ocarina.Backends.Vxworks653_Conf.Schedule is
Schedule_Node
:
Node_Id
;
Schedule_Node
:
Node_Id
;
Module_Schedule
:
constant
Schedule_Window_Record_Term_Array
Module_Schedule
:
constant
Schedule_Window_Record_Term_Array
:=
Get_Module_Schedule_Property
(
Processor
);
:=
Get_Module_Schedule_Property
(
Processor
);
Partition_Duration
:
Float
;
Partition_Duration
:
Long_Double
;
begin
begin
Schedule_Node
:=
Make_XML_Node
(
"Schedule"
);
Schedule_Node
:=
Make_XML_Node
(
"Schedule"
);
XTU
.
Add_Attribute
(
"Id"
,
"0"
,
Schedule_Node
);
XTU
.
Add_Attribute
(
"Id"
,
"0"
,
Schedule_Node
);
...
@@ -179,13 +179,12 @@ package body Ocarina.Backends.Vxworks653_Conf.Schedule is
...
@@ -179,13 +179,12 @@ package body Ocarina.Backends.Vxworks653_Conf.Schedule is
-- For now, we assume the partition duration
-- For now, we assume the partition duration
-- is in milliseconds.
-- is in milliseconds.
--
--
Partition_Duration
:=
1000.0
/
Partition_Duration
:=
(
Float
(
Long_Double
(
To_Milliseconds
(
To_Milliseconds
(
Module_Schedule
(
J
).
Duration
))
*
Float
(
100.0
));
(
Module_Schedule
(
J
).
Duration
))
/
Long_Double
(
100
0
.0
));
XTU
.
Add_Attribute
(
"Duration"
,
XTU
.
Add_Attribute
(
"Duration"
,
Trim
(
Float
'
Image
XV
.
New_Floating_Point_Value
(
Partition_Duration
),
(
Partition_Duration
),
Left
),
Partition_Window_Node
);
Partition_Window_Node
);
XTU
.
Add_Attribute
(
"ReleasePoint"
,
XTU
.
Add_Attribute
(
"ReleasePoint"
,
"1"
,
Partition_Window_Node
);
"1"
,
Partition_Window_Node
);
...
...
src/backends/ocarina-backends-xml_values.adb
View file @
a7224455
...
@@ -353,11 +353,13 @@ package body Ocarina.Backends.XML_Values is
...
@@ -353,11 +353,13 @@ package body Ocarina.Backends.XML_Values is
Index
:
Integer
;
Index
:
Integer
;
begin
begin
FLT_IO
.
Put
(
S
,
Float
(
V
.
FVal
),
Aft
=>
4
,
Exp
=>
0
);
FLT_IO
.
Put
(
S
,
Float
(
V
.
FVal
),
Aft
=>
4
,
Exp
=>
0
);
Tmp
:=
Get_String_Name
(
S
);
Tmp
:=
Get_String_Name
(
S
);
Get_Name_String
(
Tmp
);
Get_Name_String
(
Tmp
);
Index
:=
2
;
Index
:=
1
;
while
Name_Buffer
(
Index
)
=
' '
loop
while
Name_Buffer
(
Index
)
=
' '
loop
Index
:=
Index
+
1
;
Index
:=
Index
+
1
;
...
@@ -366,7 +368,7 @@ package body Ocarina.Backends.XML_Values is
...
@@ -366,7 +368,7 @@ package body Ocarina.Backends.XML_Values is
-- Temporary fix
-- Temporary fix
-- FIXME: Need to find better solution later.
-- FIXME: Need to find better solution later.
return
Name_Buffer
(
Name_Len
-
6
..
Name_Len
);
return
Name_Buffer
(
Name_Len
-
5
..
Name_Len
);
end
;
end
;
when
K_String
=>
when
K_String
=>
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment