-
Notifications
You must be signed in to change notification settings - Fork 0
/
canopen_master.orogen
50 lines (36 loc) · 1.18 KB
/
canopen_master.orogen
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
42
43
44
45
46
47
48
49
50
# frozen_string_literal: true
name "canopen_master"
import_types_from "canbus"
using_library "canopen_master"
import_types_from "canopen_master/PDOCommunicationParameters.hpp"
typekit.export_types "canopen_master/PDOCommunicationParameters"
# Task containing basic features needed to integrate a canopen_master driver
task_context "SlaveTask" do
abstract
needs_configuration
property "node_id", "/int"
input_port("can_in", "/canbus/Message")
.needs_reliable_connection
output_port "can_out", "/canbus/Message"
port_driven :can_in
exception_states :SDO_TIMEOUT
exception_states :NMT_TIMEOUT
end
# Task that generates SYNC messages
task_context "SyncTask" do
needs_configuration
# Sending of CAN messages
output_port "can_out", "/canbus/Message"
end
### Test
task_context "test::ReadSDO", subclasses: "SlaveTask" do
output_port "received_values", "/int16_t"
end
task_context "test::WriteSDO", subclasses: "SlaveTask" do
end
task_context "test::NMTMinimalState", subclasses: "SlaveTask" do
property "state_target", "/uint8_t"
property "state_transition", "/uint8_t"
end
task_context "test::NMTStateChange", subclasses: "SlaveTask" do
end