forked from UMLRoverHawks/phidgets
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathservo_glimpse.launch
99 lines (86 loc) · 4.21 KB
/
servo_glimpse.launch
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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
<!--
Launcher for servo glimpse
This requires:
Phidgets advanced servo controller
Pan servo connected to servo 0
Tilt servo connected to servo 1
-->
<launch>
<!-- Machine settings. See http://www.ros.org/wiki/roslaunch/XML/machine -->
<machine name="local_alt" address="localhost" default="true" />
<!-- phidgets advanced servo controller -->
<node pkg="phidgets" type="advanced_servo" name="advanced_servo" respawn="true">
<!-- phidget device serial number -->
<param name="serial" value="-1" />
</node>
<!-- glimpse -->
<node pkg="phidgets" type="servo_glimpse" name="servo_glimpse" respawn="false" output="screen">
<!-- -->
<param name="enable" value="true" />
<!-- Speed of movement -->
<param name="speed" value="80" />
<!-- Acceleration of movement -->
<param name="acceleration" value="80" />
<!-- Deadband -->
<param name="deadband" value="0.1" />
<!-- Pan servo index -->
<param name="servoindex0" value="0" />
<!-- Tilt servo index -->
<param name="servoindex1" value="1" />
<!-- Head pan and tilt joints within the URDF model -->
<param name="panjoint" value="joint_head_pan" />
<param name="tiltjoint" value="joint_head_tilt" />
<!-- Pan servo position 0 -->
<param name="servo0pos0" value="180" />
<!-- Pan servo angle 0 (degrees) -->
<param name="servo0angle0" value="-50" />
<!-- Pan servo position 1 -->
<param name="servo0pos1" value="74" />
<!-- Pan servo angle 1 (degrees) -->
<param name="servo0angle1" value="50" />
<!-- Tilt servo position 0 -->
<param name="servo1pos0" value="127" />
<!-- Tilt servo angle 0 (degrees) -->
<param name="servo1angle0" value="0" />
<!-- Tilt servo position 1 -->
<param name="servo1pos1" value="180" />
<!-- Tilt servo angle 1 (degrees) -->
<param name="servo1angle1" value="35" />
<!-- Tilt servo rear camera position 0 -->
<param name="servo2pos0" value="127" />
<!-- Tilt servo rear camera angle 0 (degrees) -->
<param name="servo2angle0" value="0" />
<!-- Tilt servo rear camera position 1 -->
<param name="servo2pos1" value="180" />
<!-- Tilt servo rear camera angle 1 (degrees) -->
<param name="servo2angle1" value="35" />
<!-- Minimum pan angle (degrees) -->
<param name="minpanangle" value="-45" />
<!-- Maximum pan angle (degrees) -->
<param name="maxpanangle" value="45" />
<!-- Minimum tilt angle (degrees) -->
<param name="mintiltangle" value="0" />
<!-- Maximum tilt angle (degrees) -->
<param name="maxtiltangle" value="35" />
<!-- Pan Steps -->
<param name="pansteps" value="3" />
<!-- Tilt Steps -->
<param name="tiltsteps" value="2" />
<!-- Forward translation of the camera relative to the pan servo centre in millimetres -->
<param name="forward" value="90" />
<!-- vertical translation of the camera relative to the pan servo centre in millimetres -->
<param name="vertical" value="0" />
<!-- Glimpse time in seconds -->
<param name="glimpsetime" value="3" />
<!-- Directory to save files to -->
<param name="outputdirectory" value="/home/motters/develop/phidgets/glimpse/" />
<!-- Command to run for each position -->
<param name="glimpsecommand" value="v4l2stereo --dev0 /dev/video2 --dev1 /dev/video1 --flipleft --vcamera --equal --calibrationfile /home/motters/develop/libv4l2cam/v4l2stereo/calibration.grok2 --poserotation '%d %d 0' --posetranslation '%d %d %d' --pointcloud %sgl%d.dat" />
<!-- If there is a second rearward pointing camera this command will be run for each position -->
<param name="glimpsecommand2" value="" />
<!-- Command to run after all glimpses -->
<param name="finalcommand" value="pcloud -f %s --savex3d %sglimpse.x3d" />
<!-- If there is a second rearward pointing camera this command will be run after all glimpses -->
<param name="finalcommand2" value="" />
</node>
</launch>