Skip to content

Commit 2a7ea18

Browse files
authored
added support for publishing mtb4 IMU data (#286)
1 parent 577f423 commit 2a7ea18

File tree

3 files changed

+77
-0
lines changed

3 files changed

+77
-0
lines changed
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
<?xml version="1.0" encoding="UTF-8" ?>
2+
<!DOCTYPE devices PUBLIC "-//YARP//DTD yarprobotinterface 3.0//EN" "http://www.yarp.it/DTD/yarprobotinterfaceV3.0.dtd">
3+
4+
5+
6+
<device xmlns:xi="http://www.w3.org/2001/XInclude" name="mc4plusloco-imu" type="embObjIMU">
7+
8+
<xi:include href="../../general.xml" />
9+
10+
<xi:include href="../../hardware/electronics/devmc4plusloco-mc4plus01-eln.xml" />
11+
12+
<group name="SERVICE">
13+
14+
<param name="type"> eomn_serv_AS_inertials3 </param>
15+
16+
<group name="PROPERTIES">
17+
18+
<group name="CANBOARDS">
19+
<param name="type"> mtb4 </param>
20+
21+
<group name="PROTOCOL">
22+
<param name="major"> 2 </param>
23+
<param name="minor"> 0 </param>
24+
</group>
25+
<group name="FIRMWARE">
26+
<param name="major"> 1 </param>
27+
<param name="minor"> 4 </param>
28+
<param name="build"> 6 </param>
29+
</group>
30+
</group>
31+
32+
<group name="SENSORS">
33+
<param name="id"> mc4plusloco_acc mc4plusloco_gyro mc4plusloco_eul mc4plusloco_mag mc4plusloco_stat </param>
34+
35+
<param name="type"> eoas_imu_acc eoas_imu_gyr eoas_imu_eul eoas_imu_mag eoas_imu_status </param>
36+
37+
<param name="boardType"> mtb4 mtb4 mtb4 mtb4 mtb4 </param>
38+
39+
<param name="location"> CAN1:14 CAN1:14 CAN1:14 CAN1:14 CAN1:14 </param>
40+
</group>
41+
42+
</group>
43+
44+
<group name="SETTINGS">
45+
<param name="acquisitionRate"> 50 </param>
46+
<param name="enabledSensors"> mc4plusloco_acc mc4plusloco_gyro mc4plusloco_eul mc4plusloco_mag mc4plusloco_stat
47+
</param>
48+
</group>
49+
50+
</group>
51+
52+
</device>

experimentalSetups/mc4plus-loco-project/main.xml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@
88
<xi:include href="./hardware/motorControl/mc4plusloco_mc_hardware.xml" />
99
<xi:include href="./wrappers/motorControl/mc4plusloco_mc_wrapper.xml" />
1010

11+
<!-- IMU-->
12+
<xi:include href="hardware/inertials/mc4plusloco-IMU.xml" />
13+
14+
<xi:include href="wrappers/inertials/mc4plusloco-IMU-wrapper.xml" />
15+
1116
<!-- CALIBRATORS -->
1217
<xi:include href="./calibrators/mc4plusloco_calib.xml" />
1318

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<?xml version="1.0" encoding="UTF-8" ?>
2+
<!DOCTYPE devices PUBLIC "-//YARP//DTD yarprobotinterface 3.0//EN" "http://www.yarp.it/DTD/yarprobotinterfaceV3.0.dtd">
3+
4+
5+
<device xmlns:xi="http://www.w3.org/2001/XInclude" name="mc4plusloco-imu_wrapper" type="multipleanalogsensorsserver">
6+
<param name="period"> 10 </param>
7+
<param name="name"> /icub/mc4plusloco-imu/imu </param>
8+
9+
10+
<action phase="startup" level="5" type="attach">
11+
<paramlist name="networks">
12+
<!-- The name of the element can be any string (we use SetOfInertials to better express its nature).
13+
Its value must match the device name in the corresponding body_part-jx_y-inertials.xml file
14+
or in body_part-ebX-inertials.xml -->
15+
<elem name="SetOfInertials">mc4plusloco-imu </elem>
16+
</paramlist>
17+
</action>
18+
19+
<action phase="shutdown" level="5" type="detach" />
20+
</device>

0 commit comments

Comments
 (0)