Commit 87c7891c authored by Maxime Perrotin's avatar Maxime Perrotin
Browse files

Update observer test case

parent d0acf212
......@@ -3,7 +3,7 @@
--! File generated by asn2aadl v2.2-r90f76d6: DO NOT EDIT !
--------------------------------------------------------
--! MadeInFastMode:True:
--! InputASN1FileChecksum:ee8a7e01f29874c0d50f437d5abb9599:/home/taste/tool-inst/share/taste-types/taste-types.asn:
--! InputASN1FileChecksum:ee8a7e01f29874c0d50f437d5abb9599:/home/taste/tool-src/kazoo/test/common/taste-types.asn:
--! InputASN1FileChecksum:48c0a111d212af65abc8c413f15ad1d9:DataView.asn:
--------------------------------------------------------
......@@ -45,7 +45,7 @@ end Stream_Element_Buffer;
DATA T_Boolean
PROPERTIES
-- name of the ASN.1 source file:
Source_Text => ("/home/taste/tool-inst/share/taste-types/taste-types.asn");
Source_Text => ("/home/taste/tool-src/kazoo/test/common/taste-types.asn");
TASTE::Ada_Package_Name => "TASTE_BasicTypes";
Deployment::ASN1_Module_Name => "TASTE-BasicTypes";
Source_Language => (ASN1);
......@@ -123,7 +123,7 @@ END T_Int_Buffer.impl;
DATA T_Int32
PROPERTIES
-- name of the ASN.1 source file:
Source_Text => ("/home/taste/tool-inst/share/taste-types/taste-types.asn");
Source_Text => ("/home/taste/tool-src/kazoo/test/common/taste-types.asn");
TASTE::Ada_Package_Name => "TASTE_BasicTypes";
Deployment::ASN1_Module_Name => "TASTE-BasicTypes";
Source_Language => (ASN1);
......@@ -162,7 +162,7 @@ END T_Int32_Buffer.impl;
DATA T_Int8
PROPERTIES
-- name of the ASN.1 source file:
Source_Text => ("/home/taste/tool-inst/share/taste-types/taste-types.asn");
Source_Text => ("/home/taste/tool-src/kazoo/test/common/taste-types.asn");
TASTE::Ada_Package_Name => "TASTE_BasicTypes";
Deployment::ASN1_Module_Name => "TASTE-BasicTypes";
Source_Language => (ASN1);
......@@ -279,7 +279,7 @@ END T_SeqOf_Buffer.impl;
DATA T_UInt32
PROPERTIES
-- name of the ASN.1 source file:
Source_Text => ("/home/taste/tool-inst/share/taste-types/taste-types.asn");
Source_Text => ("/home/taste/tool-src/kazoo/test/common/taste-types.asn");
TASTE::Ada_Package_Name => "TASTE_BasicTypes";
Deployment::ASN1_Module_Name => "TASTE-BasicTypes";
Source_Language => (ASN1);
......@@ -318,7 +318,7 @@ END T_UInt32_Buffer.impl;
DATA T_UInt8
PROPERTIES
-- name of the ASN.1 source file:
Source_Text => ("/home/taste/tool-inst/share/taste-types/taste-types.asn");
Source_Text => ("/home/taste/tool-src/kazoo/test/common/taste-types.asn");
TASTE::Ada_Package_Name => "TASTE_BasicTypes";
Deployment::ASN1_Module_Name => "TASTE-BasicTypes";
Source_Language => (ASN1);
......
......@@ -27,7 +27,6 @@ PUBLIC
WITH interfaceview::IV::orchestrator;
WITH interfaceview::IV::simulator_gui;
WITH interfaceview::IV::another_function;
WITH ocarina_processors_x86;
WITH deploymentview::DV::Node1;
WITH Taste;
......@@ -45,9 +44,6 @@ SUBCOMPONENTS
IV_simulator_gui : SYSTEM interfaceview::IV::simulator_gui::simulator_gui.others {
Taste::FunctionName => "simulator_gui";
};
IV_another_function : SYSTEM interfaceview::IV::another_function::another_function.others {
Taste::FunctionName => "another_function";
};
demo : PROCESS deploymentview::DV::Node1::demo.others {
Taste::coordinates => "124694 58687 147018 75906";
Deployment::Port_Number => 0;
......@@ -58,7 +54,6 @@ SUBCOMPONENTS
PROPERTIES
Taste::APLC_Binding => (reference (demo)) APPLIES TO IV_orchestrator;
Taste::APLC_Binding => (reference (demo)) APPLIES TO IV_simulator_gui;
Taste::APLC_Binding => (reference (demo)) APPLIES TO IV_another_function;
Actual_Processor_Binding => (reference (x86_linux)) APPLIES TO demo;
END Node1.others;
......
......@@ -9,34 +9,9 @@ PACKAGE interfaceview::IV::orchestrator
PUBLIC
WITH interfaceview::IV::simulator_gui;
WITH interfaceview::IV::another_function;
WITH Taste;
WITH DataView;
WITH TASTE_IV_Properties;
SUBPROGRAM PI_arr
FEATURES
p1 : IN PARAMETER DataView::T_SeqOf {
Taste::encoding => NATIVE;
};
PROPERTIES
Taste::Associated_Queue_Size => 1;
END PI_arr;
SUBPROGRAM IMPLEMENTATION PI_arr.others
PROPERTIES
Compute_Execution_Time => 0 ms .. 0 ms;
END PI_arr.others;
SUBPROGRAM PI_paramless
PROPERTIES
Taste::Associated_Queue_Size => 1;
END PI_paramless;
SUBPROGRAM IMPLEMENTATION PI_paramless.others
PROPERTIES
Compute_Execution_Time => 0 ms .. 0 ms;
END PI_paramless.others;
SUBPROGRAM PI_pulse
FEATURES
p1 : IN PARAMETER DataView::T_Int {
......@@ -51,34 +26,14 @@ PROPERTIES
Compute_Execution_Time => 0 ms .. 0 ms;
END PI_pulse.others;
SUBPROGRAM RI_ParamlessToGui
END RI_ParamlessToGui;
SUBPROGRAM IMPLEMENTATION RI_ParamlessToGui.others
END RI_ParamlessToGui.others;
SUBPROGRAM RI_paramesstogui
END RI_paramesstogui;
SUBPROGRAM RI_do_something
END RI_do_something;
SUBPROGRAM IMPLEMENTATION RI_do_something.others
END RI_do_something.others;
SUBPROGRAM IMPLEMENTATION RI_paramesstogui.others
END RI_paramesstogui.others;
SYSTEM orchestrator
FEATURES
PI_arr : PROVIDES SUBPROGRAM ACCESS interfaceview::IV::orchestrator::PI_arr.others {
Taste::coordinates => "157343 56034";
Taste::RCMoperationKind => sporadic;
Taste::RCMperiod => 0 ms;
Taste::Deadline => 0 ms;
Taste::InterfaceName => "arr";
};
PI_paramless : PROVIDES SUBPROGRAM ACCESS interfaceview::IV::orchestrator::PI_paramless.others {
Taste::coordinates => "157343 93078";
Taste::RCMoperationKind => sporadic;
Taste::RCMperiod => 0 ms;
Taste::Deadline => 0 ms;
Taste::InterfaceName => "paramless";
};
PI_pulse : PROVIDES SUBPROGRAM ACCESS interfaceview::IV::orchestrator::PI_pulse.others {
Taste::coordinates => "157343 68382";
Taste::RCMoperationKind => sporadic;
......@@ -86,16 +41,10 @@ FEATURES
Taste::Deadline => 0 ms;
Taste::InterfaceName => "pulse";
};
RI_ParamlessToGui : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::simulator_gui::PI_ParamlessToGui.others {
Taste::coordinates => "157343 77223";
Taste::RCMoperationKind => any;
Taste::InterfaceName => "ParamlessToGui";
Taste::labelInheritance => "true";
};
RI_do_something : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::another_function::PI_do_something.others {
Taste::coordinates => "190366 115007";
RI_paramesstogui : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::simulator_gui::PI_paramesstogui.others {
Taste::coordinates => "157343 81798";
Taste::RCMoperationKind => any;
Taste::InterfaceName => "do_something";
Taste::InterfaceName => "paramesstogui";
Taste::labelInheritance => "true";
};
PROPERTIES
......@@ -115,22 +64,6 @@ WITH interfaceview::IV::orchestrator;
WITH Taste;
WITH DataView;
WITH TASTE_IV_Properties;
SUBPROGRAM RI_arr
FEATURES
p1 : IN PARAMETER DataView::T_SeqOf {
Taste::encoding => NATIVE;
};
END RI_arr;
SUBPROGRAM IMPLEMENTATION RI_arr.others
END RI_arr.others;
SUBPROGRAM RI_paramless
END RI_paramless;
SUBPROGRAM IMPLEMENTATION RI_paramless.others
END RI_paramless.others;
SUBPROGRAM RI_pulse
FEATURES
p1 : IN PARAMETER DataView::T_Int {
......@@ -141,38 +74,26 @@ END RI_pulse;
SUBPROGRAM IMPLEMENTATION RI_pulse.others
END RI_pulse.others;
SUBPROGRAM PI_ParamlessToGui
END PI_ParamlessToGui;
SUBPROGRAM PI_paramesstogui
END PI_paramesstogui;
SUBPROGRAM IMPLEMENTATION PI_ParamlessToGui.others
SUBPROGRAM IMPLEMENTATION PI_paramesstogui.others
PROPERTIES
Compute_Execution_Time => 0 ms .. 0 ms;
END PI_ParamlessToGui.others;
END PI_paramesstogui.others;
SYSTEM simulator_gui
FEATURES
RI_arr : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::orchestrator::PI_arr.others {
Taste::coordinates => "119740 57444";
Taste::RCMoperationKind => any;
Taste::InterfaceName => "arr";
Taste::labelInheritance => "true";
};
RI_paramless : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::orchestrator::PI_paramless.others {
Taste::coordinates => "119740 88314";
Taste::RCMoperationKind => any;
Taste::InterfaceName => "paramless";
Taste::labelInheritance => "true";
};
RI_pulse : REQUIRES SUBPROGRAM ACCESS interfaceview::IV::orchestrator::PI_pulse.others {
Taste::coordinates => "119740 66705";
Taste::RCMoperationKind => any;
Taste::InterfaceName => "pulse";
Taste::labelInheritance => "true";
};
PI_ParamlessToGui : PROVIDES SUBPROGRAM ACCESS interfaceview::IV::simulator_gui::PI_ParamlessToGui.others {
Taste::coordinates => "119740 77761";
PI_paramesstogui : PROVIDES SUBPROGRAM ACCESS interfaceview::IV::simulator_gui::PI_paramesstogui.others {
Taste::coordinates => "119740 83208";
Taste::RCMoperationKind => sporadic;
Taste::InterfaceName => "ParamlessToGui";
Taste::InterfaceName => "paramesstogui";
};
PROPERTIES
Source_Language => (GUI);
......@@ -184,43 +105,11 @@ END simulator_gui.others;
END interfaceview::IV::simulator_gui;
PACKAGE interfaceview::IV::another_function
PUBLIC
WITH Taste;
WITH DataView;
WITH TASTE_IV_Properties;
SUBPROGRAM PI_do_something
END PI_do_something;
SUBPROGRAM IMPLEMENTATION PI_do_something.others
PROPERTIES
Compute_Execution_Time => 0 ms .. 0 ms;
END PI_do_something.others;
SYSTEM another_function
FEATURES
PI_do_something : PROVIDES SUBPROGRAM ACCESS interfaceview::IV::another_function::PI_do_something.others {
Taste::coordinates => "190341 134560";
Taste::RCMoperationKind => sporadic;
Taste::InterfaceName => "do_something";
};
PROPERTIES
Source_Language => (SDL);
Taste::Active_Interfaces => any;
END another_function;
SYSTEM IMPLEMENTATION another_function.others
END another_function.others;
END interfaceview::IV::another_function;
PACKAGE interfaceview::IV
PUBLIC
WITH interfaceview::IV::orchestrator;
WITH interfaceview::IV::simulator_gui;
WITH interfaceview::IV::another_function;
WITH Taste;
WITH DataView;
WITH TASTE_IV_Properties;
......@@ -238,24 +127,12 @@ SUBCOMPONENTS
simulator_gui : SYSTEM interfaceview::IV::simulator_gui::simulator_gui.others {
Taste::coordinates => "33291 42009 119740 110860";
};
another_function : SYSTEM interfaceview::IV::another_function::another_function.others {
Taste::coordinates => "170406 134560 241930 171073";
};
CONNECTIONS
simulator_gui_RI_arr_orchestrator_PI_arr : SUBPROGRAM ACCESS orchestrator.PI_arr -> simulator_gui.RI_arr {
Taste::coordinates => "119740 57444 136103 57444 136103 56034 157343 56034";
};
simulator_gui_RI_paramless_orchestrator_PI_paramless : SUBPROGRAM ACCESS orchestrator.PI_paramless -> simulator_gui.RI_paramless {
Taste::coordinates => "119740 88314 136103 88314 136103 93078 157343 93078";
};
simulator_gui_RI_pulse_orchestrator_PI_pulse : SUBPROGRAM ACCESS orchestrator.PI_pulse -> simulator_gui.RI_pulse {
Taste::coordinates => "119740 66705 136103 66705 136103 68382 157343 68382";
};
orchestrator_RI_ParamlessToGui_simulator_gui_PI_ParamlessToGui : SUBPROGRAM ACCESS simulator_gui.PI_ParamlessToGui -> orchestrator.RI_ParamlessToGui {
Taste::coordinates => "157343 77223 136103 77223 136103 77761 119740 77761";
};
orchestrator_RI_do_something_another_function_PI_do_something : SUBPROGRAM ACCESS another_function.PI_do_something -> orchestrator.RI_do_something {
Taste::coordinates => "190366 115007 190366 125315 190341 125315 190341 134560";
orchestrator_RI_paramesstogui_simulator_gui_PI_paramesstogui : SUBPROGRAM ACCESS simulator_gui.PI_paramesstogui -> orchestrator.RI_paramesstogui {
Taste::coordinates => "157343 81798 138541 81798 138541 83208 119740 83208";
};
END interfaceview.others;
......
......@@ -4,18 +4,18 @@ process Another_Function;
START;
/* CIF NEXTSTATE (148, 60), (70, 35) */
NEXTSTATE one;
/* CIF state (456, 10), (70, 35) */
state two;
/* CIF input (436, 65), (107, 35) */
/* CIF state (148, 60), (70, 35) */
state one;
/* CIF input (127, 115), (107, 35) */
input do_something;
/* CIF NEXTSTATE (455, 120), (70, 35) */
/* CIF NEXTSTATE (146, 170), (70, 35) */
NEXTSTATE one;
endstate;
/* CIF state (148, 60), (70, 35) */
state one;
/* CIF input (128, 115), (107, 35) */
/* CIF state (456, 10), (70, 35) */
state two;
/* CIF input (435, 65), (107, 35) */
input do_something;
/* CIF NEXTSTATE (147, 170), (70, 35) */
NEXTSTATE two;
/* CIF NEXTSTATE (454, 120), (70, 35) */
NEXTSTATE one;
endstate;
endprocess Another_Function;
\ No newline at end of file
......@@ -7,76 +7,62 @@ process Orchestrator;
dcl counter t_int := 0;
dcl seqof t_seqof := {1};
dcl magic_number T_Int32:= 0;
/* CIF ENDTEXT */
/* CIF START (718, 52), (70, 34) */
START;
/* CIF PROCEDURECALL (643, 106), (220, 35) */
call writeln( 'Orchestrator startup');
/* CIF NEXTSTATE (720, 156), (67, 35) */
/* CIF NEXTSTATE (719, 156), (67, 35) */
NEXTSTATE wait;
/* CIF state (523, 254), (67, 35) */
state wait;
/* CIF input (112, 309), (71, 35) */
/* CIF state (496, 337), (70, 35) */
state Step_2;
/* CIF input (496, 392), (70, 35) */
input pulse(t);
/* CIF decision (113, 364), (70, 50) */
decision t;
/* CIF ANSWER (30, 434), (70, 25) */
(0):
/* CIF task (0, 479), (131, 59) */
task seqof := {1,1,1,1},
counter := 0,
t := 0;
/* CIF NEXTSTATE (30, 556), (70, 35) */
/* CIF decision (496, 447), (70, 50) */
decision t = 2;
/* CIF ANSWER (451, 517), (70, 24) */
(true):
/* CIF output (430, 561), (110, 35) */
output paramesstogui;
/* CIF NEXTSTATE (451, 616), (70, 35) */
NEXTSTATE wait;
/* CIF ANSWER (164, 434), (70, 25) */
else:
/* CIF task (134, 479), (131, 59) */
task seqof := {1,1,1,1},
counter := 0,
t := 0;
/* CIF NEXTSTATE (163, 556), (72, 35) */
NEXTSTATE running;
/* CIF ANSWER (552, 517), (70, 24) */
(false):
/* CIF NEXTSTATE (552, 561), (70, 35) */
NEXTSTATE step_2;
enddecision;
/* CIF input (498, 309), (86, 35) */
input arr(seqof);
/* CIF task (434, 364), (214, 35) */
task counter := (counter + 1) mod 4;
/* CIF decision (479, 419), (124, 50) */
decision seqof = {4,4,4,4}
and counter = 0;
/* CIF ANSWER (365, 489), (70, 25) */
endstate;
/* CIF state (999, 100), (67, 35) */
state wait;
/* CIF input (996, 155), (71, 35) */
input pulse(t);
/* CIF decision (986, 210), (89, 50) */
decision counter = 3;
/* CIF ANSWER (875, 280), (70, 24) */
(true):
/* CIF ANSWER (640, 489), (70, 25) */
/* CIF task (839, 324), (141, 35) */
task magic_number := 42;
/* CIF NEXTSTATE (875, 379), (70, 35) */
NEXTSTATE Step_2;
/* CIF ANSWER (1068, 280), (70, 24) */
(false):
/* CIF task (535, 534), (281, 35) */
task seqof := { 1 } // seqof (1, length(seqof)-1);
enddecision;
/* CIF NEXTSTATE (506, 585), (70, 35) */
NEXTSTATE -;
/* CIF input (898, 309), (87, 40) */
input paramless;
/* CIF output (883, 369), (116, 35) */
output ParamlessToGui;
/* CIF task (890, 419), (104, 42) */
task counter := 4,
t := 1;
/* CIF task (878, 481), (127, 38) */
task seqof := {1,1,1,1};
/* CIF NEXTSTATE (906, 534), (72, 35) */
NEXTSTATE running;
endstate;
/* CIF state (1173, 80), (72, 35) */
state running;
/* CIF input (1175, 135), (70, 35) */
input *;
/* CIF output (1156, 190), (107, 35) */
output do_something;
/* CIF task (1145, 245), (131, 59) */
task seqof := {1,1,1,1},
counter := 0,
t := 0;
/* CIF NEXTSTATE (1175, 319), (70, 35) */
/* CIF decision (996, 430), (70, 50) */
decision t;
/* CIF ANSWER (914, 500), (70, 25) */
(4):
/* CIF task (878, 545), (141, 59) */
task counter := 3;
/* CIF ANSWER (1061, 500), (70, 25) */
else:
/* CIF task (1025, 545), (141, 59) */
task counter := 0,
magic_number := 0;
enddecision;
/* CIF task (996, 620), (70, 35) */
task t := 0;
/* CIF NEXTSTATE (996, 675), (70, 35) */
NEXTSTATE wait;
endstate;
endprocess Orchestrator;
\ No newline at end of file
......@@ -9,10 +9,12 @@ observer/my_observer.adb: observer/observer.pr observer/observer.asn
cd observer && opengeode --toAda observer.pr && \
asn1.exe -Ada -typePrefix asn1scc -equal --target allboards observer.asn my_observer_datamodel.asn && \
mv src/my_observer_datamodel.ad? .
# generate Ada package to print asn1 values
taste-asn1-gser --raw -o observer --module gser observer/observer.asn observer/my_observer_datamodel.asn
# gather dataviews needed to build an observer
observer/observer.asn: ../dataview/dataview-uniq.asn ../build/simulation.asn ../orchestrator/SDL/code/orchestrator_datamodel.asn ../another_function/SDL/code/another_function_datamodel.asn
observer/observer.asn: ../dataview/dataview-uniq.asn ../build/simulation.asn ../orchestrator/SDL/code/orchestrator_datamodel.asn # ../another_function/SDL/code/another_function_datamodel.asn
cat $^ > $@
clean:
......
with Text_IO; use Text_IO;
-- with simulator;
with simulator_interface;
-- with simulation_dataview; use simulation_dataview;
-- with orchestrator_datamodel; use orchestrator_datamodel;
with Properties; -- user-defined properties
-- To Encode and MD5 the state:
......@@ -16,26 +13,22 @@ with Gnat.MD5,
adaasn1rtl.encoding;
use Ada.Streams;
procedure mc is
use Properties;
with My_Observer;
-- Pulse_Event : asn1SccEvent :=
-- (Kind => Orchestrator_PRESENT,
-- Orchestrator =>
-- (Kind => Msg_In_PRESENT,
-- Msg_In =>
-- (Kind => Pulse_PRESENT,
-- Pulse => (P1 => 2))));
procedure MC is
use Properties;
package Simulator_Pkg is new Simulator_Interface
(State_With_Observers => State_With_Observers,
Application_State => Application_State,
Update_State => Update_State,
Full_State_Init => Full_State_Init);
Full_State_Init => Full_State_Init,
State_As_String => State_To_String,
Run_Observers => Properties.My_Properties'Access);
use Simulator_Pkg;
My_Properties_Access : Check_Properties_Access :=
Properties.My_Properties'Access;
-- My_Properties_Access : Check_Properties_Access :=
-- Properties.My_Properties'Access;
-- procedure Encode_And_md5 (State: asn1SccSystem_State) is
-- uPER_Encoded : asn1SccSystem_State_uPER_Stream;
......@@ -49,21 +42,12 @@ procedure mc is
-- end Encode_And_md5;
begin
Simulator_Pkg.Simulation_Startup (My_Properties_Access);
-- Modify the system state:
-- Simulator.State.Orchestrator.SomeData := 3;
-- Simulator.Push_Event (Pulse_Event);
-- Pulse_Event.Orchestrator.Msg_In.Pulse.P1 := 3;
-- Simulator.Push_Event (Pulse_Event);
-- Simulator.Push_Event (Pulse_Event);
-- Set once for all a pointer to the current state in the observers
My_Observer.St := Simulator_Pkg.User_State'Unchecked_Access;
Simulator_Pkg.Simulation_Startup;
-- Encode_And_md5 (Simulator.State);
-- while Simulator.State.Events.Length > 0 loop
-- Simulator_Interface.Execute_Next_Event;
-- end loop;
Put_Line ("Now exhausting all interfaces...");
Simulator_Pkg.Run_Exhaustive_Simulation;
end mc;
end MC;
with Text_IO; use Text_IO;
with iterators_types;
use iterators_types;
with my_observer;
with My_Observer;
with My_Observer_Datamodel;
use My_Observer_Datamodel;
with GSER;
-- For the test of the stop condition...
package body Properties is
......@@ -20,18 +24,33 @@ package body Properties is
Full_State.User_State := Application_State;
end Update_State;
procedure My_Properties (Full_State : in out State_With_Observers;
Id : out Natural;
Success : out Boolean) is
begin
Id := 0;
procedure Print_Full_State (Full_State : State_With_Observers) is
begin
Put_Line (State_To_String (Full_State));
end Print_Full_State;
procedure My_Properties (Full_State : in out State_With_Observers;
Event : access asn1sccObservable_Event;
Id : out Natural;
Success : out Boolean) is
Local_Event : aliased asn1sccObservable_Event := Event.all;
begin
Id := 0;
-- Restore the state of the observer, and execute it
My_Observer.Ctxt := Full_State.My_Observer_State;
-- Put_Line ("[OBS] Context set to: " & GSER.Image (My_Observer.Ctxt));
-- Set the event in the observer's monitor
My_Observer.Event := Local_Event'Unchecked_access;
My_Observer.Observe;
Full_State.My_Observer_State := My_Observer.Ctxt;
-- Simple stop condition:
Success := (My_Observer.Ctxt.State = My_Observer_Datamodel.asn1SccEnd_Success);
if Success then
Put_Line ("Stop condition found");
end if;
-- Observer modelled in SDL:
-- Restore the state of the observer, and execute it
My_Observer.Ctxt := Full_State.My_Observer_State;
My_Observer.Observe (Global_State => Full_State.User_State);
end;
-- Simple stop condition:
Success := (My_Observer.Ctxt.State = My_Observer_Datamodel.asn1SccEnd_Success);
end;
end Properties;
-- Add the data model of all observers to form the full state
with My_Observer;
with My_Observer_Datamodel;
with simulation_dataview; use simulation_dataview;
with adaasn1rtl; use adaasn1rtl;
with GSER;
package Properties is
......@@ -22,16 +24,24 @@ package Properties is
procedure Update_State (Full_State : in out State_With_Observers;
Application_State : asn1SccSystem_State);
-- Return a GSER string of the state, useful to print or to compute hash
function State_To_String (Full_State : State_With_Observers) return String is
(GSER.Image (Full_State.User_State) & GSER.Image (Full_State.My_Observer_State));