-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfreertos-example.asn
42 lines (34 loc) · 1.06 KB
/
freertos-example.asn
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
FREERTOS-EXAMPLE-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