Commit 8ee4e813 authored by Maxime Perrotin's avatar Maxime Perrotin
Browse files

Delete garbage

parent c9d97504
export ASN1SCC=$(shell which asn1.exe)
all:
gprbuild -p -P function1.gpr # generate Ada code from the SDL model
gprbuild -p -P dataview_ada.gpr # generate Ada code from the ASN.1 model
gprbuild -p -P code/function1_ada.gpr # build the Ada code
clean:
rm -rf obj code
\ No newline at end of file
SYNC-SDL-DATAVIEW DEFINITIONS ::=
BEGIN
MyInteger ::= INTEGER (0 .. 10000)
-- ASN.1 Type definitions must start with an uppercase
-- Field names in records (SEQUENCE) must start with a lowercase
-- Underscores are not allowed: use dash (hyphen)
-- For integers do not assume that small ranges will be translated to small
-- types in C or Ada (expect unsigned or signed 64 bits types with subtypes
-- for the range in Ada)
-- Simple types:
-- TASTE-Boolean ::= BOOLEAN
-- MyInteger ::= INTEGER (0..255)
-- MyReal ::= REAL (0.0 .. 1000.0)
-- MyBool ::= BOOLEAN
-- MyEnum ::= ENUMERATED { hello, world, how-are-you }
-- Complex types:
-- MySeq ::= SEQUENCE {
-- input-data MyInteger,
-- output-data MyInteger,
-- validity ENUMERATED { valid, invalid }
-- }
--
-- MyChoice ::= CHOICE {
-- a BOOLEAN,
-- b MySeq
-- }
--
-- MySeqOf ::= SEQUENCE (SIZE (2)) OF MyEnum
--
-- MyOctStr ::= OCTET STRING (SIZE (3))
--
-- -- You can also declare constants
-- myVar MySeqOf ::= { hello, world }
END
TASTE-BasicTypes DEFINITIONS ::=
BEGIN
-- Set of TASTE predefined basic types
T-Int32 ::= INTEGER (-2147483648 .. 2147483647)
T-UInt32 ::= INTEGER (0 .. 4294967295)
T-Int8 ::= INTEGER (-128 .. 127)
T-UInt8 ::= INTEGER (0 .. 255)
T-Boolean ::= BOOLEAN
T-Null-Record ::= SEQUENCE {}
END
project DataView_Ada is
for Languages use ("ASN1");
for Source_Dirs use (".");
for Source_Files use ("dataview-uniq.asn");
for Object_Dir use "code";
package Naming is
for Body_Suffix ("ASN1") use ".asn";
end Naming;
package Compiler is
for Driver ("ASN1") use "mono";
for Leading_Required_Switches ("ASN1") use
(external("ASN1SCC"),
"-Ada",
"-typePrefix",
"Asn1Scc");
end Compiler;
end DataView_Ada;
\ No newline at end of file
project DataView_c is
for Languages use ("ASN1");
for Source_Dirs use (".");
for Source_Files use ("dataview-uniq.asn");
for Object_Dir use "code";
package Naming is
for Body_Suffix ("ASN1") use ".asn";
end Naming;
package Compiler is
for Driver ("ASN1") use "mono";
for Leading_Required_Switches ("ASN1") use
(external("ASN1SCC"),
"-c",
"-typePrefix",
"Asn1Scc");
end Compiler;
end DataView_c;
\ No newline at end of file
project function1 is
for Languages use ("SDL");
for Source_Dirs use (".");
for Object_Dir use "code";
for Source_Files use ("system_structure.pr");
package Naming is
for Body_Suffix ("SDL") use ".pr";
end Naming;
package Compiler is
for Driver ("SDL") use "opengeode";
for Object_File_Suffix ("SDL") use ".adb";
for Leading_Required_Switches ("SDL") use ("--toAda", "../function1.pr");
end Compiler;
end function1;
\ No newline at end of file
/* CIF PROCESS (250, 150), (150, 75) */
process Function1;
/* CIF TEXT (664, 67), (267, 167) */
-- Text area for declarations and comments
dcl i MyInteger := 42;
/* CIF ENDTEXT */
/* CIF START (320, 10), (70, 35) */
START;
/* CIF PROCEDURECALL (299, 65), (111, 35) */
call setData(i, true);
/* CIF NEXTSTATE (320, 115), (70, 35) */
NEXTSTATE Wait;
/* CIF state (451, 10), (68, 35) */
state Wait;
/* CIF input (450, 65), (70, 35) */
input pulse;
/* CIF PROCEDURECALL (443, 120), (82, 35) */
call getData(i);
/* CIF PROCEDURECALL (445, 170), (78, 35) */
call writeln(i);
/* CIF task (450, 225), (70, 35) */
task i := i + 1;
/* CIF PROCEDURECALL (425, 275), (118, 35) */
call setData (i, false);
/* CIF NEXTSTATE (450, 330), (70, 35) */
NEXTSTATE wait;
endstate;
endprocess Function1;
\ No newline at end of file
[General]
geometry=@ByteArray(\x1\xd9\xd0\xcb\0\x2\0\0\0\0\x5\xd8\0\0\0\xf5\0\0\ta\0\0\x3\xee\0\0\x5\xdb\0\0\x1\x12\0\0\t^\0\0\x3\xeb\0\0\0\0\0\0\0\0\rp)
windowState=@ByteArray(\0\0\0\xff\0\0\0\0\xfd\0\0\0\x2\0\0\0\x1\0\0\x1\x12\0\0\x1\xef\xfc\x2\0\0\0\x1\xfc\0\0\0<\0\0\x1\xef\0\0\0\x87\x1\0\0\x1b\xfa\0\0\0\0\x2\0\0\0\x2\xfb\0\0\0\x1c\0\x64\0\x61\0t\0\x61\0t\0y\0p\0\x65\0s\0_\0\x64\0o\0\x63\0k\x1\0\0\0\0\xff\xff\xff\xff\0\0\0k\0\xff\xff\xff\xfb\0\0\0\x1a\0\x64\0\x61\0t\0\x61\0\x64\0i\0\x63\0t\0_\0\x64\0o\0\x63\0k\x1\0\0\0\0\xff\xff\xff\xff\0\0\0k\0\xff\xff\xff\0\0\0\x3\0\0\x3Q\0\0\0\x8c\xfc\x1\0\0\0\x1\xfb\0\0\0\xe\0m\0s\0g\0\x44\0o\0\x63\0k\x1\0\0\0\x33\0\0\x3Q\0\0\0\x46\0\a\xff\xff\0\0\x2\x39\0\0\x1\xef\0\0\0\x4\0\0\0\x4\0\0\0\b\0\0\0\b\xfc\0\0\0\x2\0\0\0\0\0\0\0\x1\0\0\0\x16\0S\0\x44\0L\0 \0T\0o\0o\0l\0\x62\0\x61\0r\x3\0\0\0\0\xff\xff\xff\xff\0\0\0\0\0\0\0\0\0\0\0\x2\0\0\0\x1\0\0\0\x18\0\x46\0i\0l\0\x65\0 \0T\0o\0o\0l\0\x62\0\x61\0r\x1\0\0\0\0\xff\xff\xff\xff\0\0\0\0\0\0\0\0)
-- Header file for function Function1 in SDL language
-- Component type : FALSE
-- Instance of :
-- Generated by TASTE on 2021-03-29 10:24:09
-- Context Parameters present : NO
-- Provided interfaces : pulse
-- Required interfaces : getData, setData
-- User-defined properties for this function:
-- * Taste::Active_Interfaces = any
-- * Taste::coordinates = 89902 45955 111963 60081
-- DO NOT EDIT THIS FILE, IT WILL BE OVERWRITTEN DURING THE BUILD
/* CIF Keep Specific Geode ASNFilename 'dataview-uniq.asn' */
use Datamodel;
system Function1;
signal pulse;
procedure getData;
fpar
in/out P1 MyInteger;
external;
procedure setData;
fpar
in P1 MyInteger,
in P2 T_Boolean;
external;
channel c
from env to Function1 with pulse;
endchannel;
block Function1;
signalroute r
from env to Function1 with pulse;
connect c and r;
process Function1 referenced;
endblock;
endsystem;
export ASN1SCC=$(shell which asn1.exe)
all:
gprbuild -p -P function2.gpr # generate Ada code from the SDL model
gprbuild -p -P dataview_ada.gpr # generate Ada code from the ASN.1 model
gprbuild -p -P code/function2_ada.gpr # build the Ada code
clean:
rm -rf obj code
\ No newline at end of file
SYNC-SDL-DATAVIEW DEFINITIONS ::=
BEGIN
MyInteger ::= INTEGER (0 .. 10000)
-- ASN.1 Type definitions must start with an uppercase
-- Field names in records (SEQUENCE) must start with a lowercase
-- Underscores are not allowed: use dash (hyphen)
-- For integers do not assume that small ranges will be translated to small
-- types in C or Ada (expect unsigned or signed 64 bits types with subtypes
-- for the range in Ada)
-- Simple types:
-- TASTE-Boolean ::= BOOLEAN
-- MyInteger ::= INTEGER (0..255)
-- MyReal ::= REAL (0.0 .. 1000.0)
-- MyBool ::= BOOLEAN
-- MyEnum ::= ENUMERATED { hello, world, how-are-you }
-- Complex types:
-- MySeq ::= SEQUENCE {
-- input-data MyInteger,
-- output-data MyInteger,
-- validity ENUMERATED { valid, invalid }
-- }
--
-- MyChoice ::= CHOICE {
-- a BOOLEAN,
-- b MySeq
-- }
--
-- MySeqOf ::= SEQUENCE (SIZE (2)) OF MyEnum
--
-- MyOctStr ::= OCTET STRING (SIZE (3))
--
-- -- You can also declare constants
-- myVar MySeqOf ::= { hello, world }
END
TASTE-BasicTypes DEFINITIONS ::=
BEGIN
-- Set of TASTE predefined basic types
T-Int32 ::= INTEGER (-2147483648 .. 2147483647)
T-UInt32 ::= INTEGER (0 .. 4294967295)
T-Int8 ::= INTEGER (-128 .. 127)
T-UInt8 ::= INTEGER (0 .. 255)
T-Boolean ::= BOOLEAN
T-Null-Record ::= SEQUENCE {}
END
project DataView_Ada is
for Languages use ("ASN1");
for Source_Dirs use (".");
for Source_Files use ("dataview-uniq.asn");
for Object_Dir use "code";
package Naming is
for Body_Suffix ("ASN1") use ".asn";
end Naming;
package Compiler is
for Driver ("ASN1") use "mono";
for Leading_Required_Switches ("ASN1") use
(external("ASN1SCC"),
"-Ada",
"-typePrefix",
"Asn1Scc");
end Compiler;
end DataView_Ada;
\ No newline at end of file
project DataView_c is
for Languages use ("ASN1");
for Source_Dirs use (".");
for Source_Files use ("dataview-uniq.asn");
for Object_Dir use "code";
package Naming is
for Body_Suffix ("ASN1") use ".asn";
end Naming;
package Compiler is
for Driver ("ASN1") use "mono";
for Leading_Required_Switches ("ASN1") use
(external("ASN1SCC"),
"-c",
"-typePrefix",
"Asn1Scc");
end Compiler;
end DataView_c;
\ No newline at end of file
project function2 is
for Languages use ("SDL");
for Source_Dirs use (".");
for Object_Dir use "code";
for Source_Files use ("system_structure.pr");
package Naming is
for Body_Suffix ("SDL") use ".pr";
end Naming;
package Compiler is
for Driver ("SDL") use "opengeode";
for Object_File_Suffix ("SDL") use ".adb";
for Leading_Required_Switches ("SDL") use ("--toAda", "../function2.pr");
end Compiler;
end function2;
\ No newline at end of file
/* CIF PROCESS (250, 150), (150, 75) */
process Function2;
/* CIF procedure (541, 214), (75, 35) */
procedure getData;
/* CIF TEXT (412, 134), (267, 148) */
fpar
in/out P1 MyInteger;
/* CIF ENDTEXT */
/* CIF START (78, 72), (70, 35) */
START;
/* CIF return (95, 127), (35, 35) */
return ;
endprocedure;
/* CIF procedure (793, 361), (77, 35) */
procedure setData;
/* CIF TEXT (412, 134), (267, 148) */
fpar
in P1 MyInteger,
in P2 T_Boolean;
/* CIF ENDTEXT */
/* CIF START (157, 86), (70, 35) */
START;
/* CIF PROCEDURECALL (13, 141), (356, 35) */
call writeln('procedure setData called with params: ', p1, p2);
/* CIF return (174, 196), (35, 35) */
return ;
endprocedure;
/* CIF START (320, 10), (70, 35) */
START;
/* CIF NEXTSTATE (320, 60), (70, 35) */
NEXTSTATE Wait;
/* CIF state (450, 10), (70, 35) */
state Wait;
endstate;
endprocess Function2;
\ No newline at end of file
[General]
geometry=@ByteArray(\x1\xd9\xd0\xcb\0\x2\0\0\0\0\x4\xdb\0\0\0[\0\0\bd\0\0\x3\xd2\0\0\x4\xde\0\0\0x\0\0\ba\0\0\x3\xcf\0\0\0\0\0\0\0\0\rp)
windowState=@ByteArray(\0\0\0\xff\0\0\0\0\xfd\0\0\0\x2\0\0\0\x1\0\0\x1\x12\0\0\x2m\xfc\x2\0\0\0\x1\xfc\0\0\0<\0\0\x2m\0\0\0\x87\x1\0\0\x1b\xfa\0\0\0\x1\x2\0\0\0\x2\xfb\0\0\0\x1c\0\x64\0\x61\0t\0\x61\0t\0y\0p\0\x65\0s\0_\0\x64\0o\0\x63\0k\x1\0\0\0\0\xff\xff\xff\xff\0\0\0k\0\xff\xff\xff\xfb\0\0\0\x1a\0\x64\0\x61\0t\0\x61\0\x64\0i\0\x63\0t\0_\0\x64\0o\0\x63\0k\x1\0\0\0\0\xff\xff\xff\xff\0\0\0k\0\xff\xff\xff\0\0\0\x3\0\0\x3Q\0\0\0\x8c\xfc\x1\0\0\0\x1\xfb\0\0\0\xe\0m\0s\0g\0\x44\0o\0\x63\0k\x1\0\0\0\x33\0\0\x3Q\0\0\0\x46\0\a\xff\xff\0\0\x2\x39\0\0\x2m\0\0\0\x4\0\0\0\x4\0\0\0\b\0\0\0\b\xfc\0\0\0\x2\0\0\0\0\0\0\0\x1\0\0\0\x16\0S\0\x44\0L\0 \0T\0o\0o\0l\0\x62\0\x61\0r\x3\0\0\0\0\xff\xff\xff\xff\0\0\0\0\0\0\0\0\0\0\0\x2\0\0\0\x1\0\0\0\x18\0\x46\0i\0l\0\x65\0 \0T\0o\0o\0l\0\x62\0\x61\0r\x1\0\0\0\0\xff\xff\xff\xff\0\0\0\0\0\0\0\0)
-- Header file for function Function2 in SDL language
-- Component type : FALSE
-- Instance of :
-- Generated by TASTE on 2021-03-29 10:24:09
-- Context Parameters present : NO
-- Provided interfaces : getData, setData
-- Required interfaces :
-- User-defined properties for this function:
-- * Taste::Active_Interfaces = any
-- * Taste::coordinates = 131147 45518 151378 59557
-- DO NOT EDIT THIS FILE, IT WILL BE OVERWRITTEN DURING THE BUILD
/* CIF Keep Specific Geode ASNFilename 'dataview-uniq.asn' */
use Datamodel;
system Function2;
-- Synchronous PI getData
-- You must create a procedure with this name
-- and copy the signature (the FPAR section) in a text box
exported procedure getData;
fpar
in/out P1 MyInteger;
referenced;
-- Synchronous PI setData
-- You must create a procedure with this name
-- and copy the signature (the FPAR section) in a text box
exported procedure setData;
fpar
in P1 MyInteger,
in P2 T_Boolean;
referenced;
block Function2;
process Function2 referenced;
endblock;
endsystem;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment