Commit 2f03e251 authored by Maxime Perrotin's avatar Maxime Perrotin

Add placeholder for shared types

parent 6b554022
This diff is collapsed.
AIR-IOP1-DATAVIEW DEFINITIONS ::= BEGIN
-- In this ACN model, you can specify custom binary encoding rules for
-- your data types. For example if you require a specific memory layout
-- for a record, or need to add padding fields, define endianness, etc.
-- you can do that with ACN. Refer to the TASTE wiki for documentation:
-- https://taste.tuxfamily.org/wiki/index.php?title=Main_Page
-- Example of custom encoding:
-- My-Integer [encoding pos-int, endianness big, size 16]
END
AIR-IOP-DEVICE-DATAVIEW DEFINITIONS ::=
BEGIN
-- Define a buffer to receive data from devices
Data-Stream ::= OCTET STRING (SIZE (0..100))
-- Device configuration
IOP-Device-Identifier ::= CHOICE {
eth IOP-ETHn,
grspw IOP-GRSPWn,
can IOP-CANn,
spwrtr IOP-SPWRTR,
mil IOP-MILn
}
-- All types below give the detailed configuration for each
-- supported device.
IP-Address ::= SEQUENCE (SIZE (4)) OF INTEGER (0..255)
MAC-Address ::= SEQUENCE (SIZE(6)) OF INTEGER (0..255)
IOP-ETHn ::= SEQUENCE {
n INTEGER (0..7), -- Max range not specified
ip IP-Address,
mac MAC-Address,
routes SEQUENCE (SIZE (1..5)) OF Route -- Max size not specified
}
Route ::= SEQUENCE {
route-ip IP-Address,
route-mac MAC-Address,
route-port INTEGER (0..65535)
}
IOP-GRSPWn ::= SEQUENCE {
n INTEGER (0 .. 7),
addr INTEGER (-1 .. 31),
mask INTEGER (0 .. 255),
retry INTEGER (-1 .. 50),
rx-max INTEGER (4 .. 1520),
pro BOOLEAN,
routes SEQUENCE (SIZE (1 .. 5)) OF INTEGER (-1 .. 31)
}
IOP-CANn ::= SEQUENCE {
n INTEGER (0 .. 7),
baud INTEGER (0 .. 2048),
code INTEGER (0 .. 4294967295),
mask INTEGER (0 .. 4294967295),
selection INTEGER (0 .. 1),
enable0 INTEGER (0 .. 1),
enable1 INTEGER (0 .. 1),
routes SEQUENCE (SIZE (1 .. 5)) OF Can-Route
}
Can-Route ::= SEQUENCE {
extended BOOLEAN,
rtr BOOLEAN,
can-id INTEGER (0 .. 7) -- Max range not specified
}
IOP-MILn ::= SEQUENCE {
major-frame INTEGER (0 .. 10000000),
slots SEQUENCE (SIZE (1 .. 10)) OF MIL-Slot, -- Range not specified
routes SEQUENCE (SIZE (1 .. 5)) OF MIL-Route -- Range not specified
}
MIL-Slot ::= SEQUENCE {
slot-bus ENUMERATED { bus-a, bus-b },
slot-type ENUMERATED { rt-bc, bc-rt, rt-rt },
slot-addr INTEGER (0 .. 31),
slot-subAddr INTEGER (0 .. 31),
slot-wcmc INTEGER (0 .. 32),
slot-time INTEGER (0 .. 1000000),
slot-addrTx INTEGER (0 .. 30),
slot-subAddrTx INTEGER (0 ..30)
}
MIL-Route ::= SEQUENCE {
route-addr INTEGER (0 .. 31),
route-subAddr INTEGER (0 .. 31)
}
IOP-SPWRTR ::= SEQUENCE {
flags SPW-Flags,
config SPW-Config,
idd INTEGER (0 .. 2048),
idiv INTEGER (0 .. 2048),
prescaler INTEGER (0 .. 2048)
}
SPW-Flags ::= SEQUENCE {
timer-reload-register BOOLEAN,
timer-prescaler-register BOOLEAN,
clock-divisor-register BOOLEAN,
instance-id-register BOOLEAN,
config-register BOOLEAN
}
SPW-Config ::= SEQUENCE {
spw-reset BOOLEAN,
auto-disconnect BOOLEAN,
link-start-on-request BOOLEAN,
self-addressing-enable BOOLEAN,
time-code-control-flag-mode BOOLEAN,
memory-error BOOLEAN
}
END
---------------------------------------------------
-- AADL2.2
-- TASTE type interfaceview
--
-- generated code: do not edit
---------------------------------------------------
PACKAGE sharedTypelibrary::IV::Air_Device
PUBLIC
WITH Taste;
WITH DataView;
WITH TASTE_IV_Properties;
SUBPROGRAM PI_Write_to_Device
PROPERTIES
Taste::Associated_Queue_Size => 1;
END PI_Write_to_Device;
SUBPROGRAM IMPLEMENTATION PI_Write_to_Device.others
PROPERTIES
Compute_Execution_Time => 0 ms .. 0 ms;
END PI_Write_to_Device.others;
SUBPROGRAM PI_Poll_Device
PROPERTIES
Taste::Associated_Queue_Size => 1;
END PI_Poll_Device;
SUBPROGRAM IMPLEMENTATION PI_Poll_Device.others
PROPERTIES
Compute_Execution_Time => 0 ms .. 0 ms;
END PI_Poll_Device.others;
SUBPROGRAM RI_Received_Data
FEATURES
stream : IN PARAMETER DataView::Data_Stream {
Taste::encoding => NATIVE;
};
END RI_Received_Data;
SUBPROGRAM IMPLEMENTATION RI_Received_Data.others
END RI_Received_Data.others;
SYSTEM Air_Device
FEATURES
PI_Write_to_Device : PROVIDES SUBPROGRAM ACCESS sharedTypelibrary::IV::Air_Device::PI_Write_to_Device.others {
Taste::coordinates => "93226 65116";
Taste::RCMoperationKind => sporadic;
Taste::RCMperiod => 500 ms;
Taste::Deadline => 0 ms;
Taste::InterfaceName => "Write_to_Device";
};
PI_Poll_Device : PROVIDES SUBPROGRAM ACCESS sharedTypelibrary::IV::Air_Device::PI_Poll_Device.others {
Taste::coordinates => "93226 74614";
Taste::RCMoperationKind => cyclic;
Taste::RCMperiod => 500 ms;
Taste::Deadline => 0 ms;
Taste::InterfaceName => "Poll_Device";
};
RI_Received_Data : REQUIRES SUBPROGRAM ACCESS sharedTypelibrary::IV::Air_Device::RI_Received_Data.others {
Taste::coordinates => "139524 67688";
Taste::RCMoperationKind => sporadic;
Taste::InterfaceName => "Received_Data";
Taste::labelInheritance => "false";
};
PROPERTIES
Source_Language => (CPP);
Taste::Active_Interfaces => any;
Taste::is_Component_Type => true;
END Air_Device;
SYSTEM IMPLEMENTATION Air_Device.others
SUBCOMPONENTS
device_config : DATA DataView::IOP_Device_Identifier {
Taste::FS_Default_Value => "eth: {n 0, ip {127, 0, 0, 1}, mac {0, 0, 0, 0, 0, 0}, routes {{route-ip {127,0,0,1}, route-mac {0,0,0,0,0,0}, route-port 5115}}}";
};
END Air_Device.others;
END sharedTypelibrary::IV::Air_Device;
PACKAGE sharedTypelibrary::IV
PUBLIC
WITH sharedTypelibrary::IV::Air_Device;
WITH Taste;
WITH DataView;
WITH TASTE_IV_Properties;
SYSTEM sharedTypelibrary
END sharedTypelibrary;
SYSTEM IMPLEMENTATION sharedTypelibrary.others
SUBCOMPONENTS
Air_Device : SYSTEM sharedTypelibrary::IV::Air_Device::Air_Device.others {
Taste::coordinates => "93226 61415 139524 100155";
};
END sharedTypelibrary.others;
PROPERTIES
Taste::version => "2.4";
END sharedTypelibrary::IV;
Markdown is supported
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