Below is (most of) my config file. When the program start up, it acts as a mouse, using the mouse butons like normal.
When you twist it to the right, it changes contexts and goes to the SpaceNavigator
context, which will send commands to RoadRunner for controlling themedia player.
To get back in to mouse mode, you press the left button.
Code:
<deviceContexts>
<deviceContext name="SpaceNavigator" device="SpaceNavigator">
<axe threshold="200" type="binary" posAction="" negAction=""/> <!-- axe 0 pan left/right -->
<axe threshold="200" type="binary" posAction="" negAction=""/> <!-- axe 1 pan foreward/back -->
<axe threshold="500" type="binary" posAction="RR Play/Pause" negAction=""/> <!-- axe 2 push/pull -->
<axe threshold="200" type="binary" posAction="" negAction=""/> <!-- axe 3 tilt foreward/back -->
<axe threshold="200" type="binary" posAction="RR Prev" negAction="RR Next"/> <!-- axe 4 tilt left/right -->
<axe threshold="100"
type="exponential"
startPulse="1"
endPulse="20"
posAction="RR Volume Up"
negAction="RR Volume Down" /> <!-- axe 5 Twist -->
<buttons>
<button downAction="Context Down"
upAction="" />
<button downAction="RR FullVisu"
upAction="" />
</buttons>
</deviceContext>
<deviceContext name="Mouse" device="SpaceNavigator">
<axe threshold="200" type="binary" posAction="" negAction=""/> <!-- axe 0 pan left/right -->
<axe threshold="200" type="binary" posAction="" negAction=""/> <!-- axe 1 pan foreward/back -->
<axe threshold="500" type="binary" posAction="" negAction=""/> <!-- axe 2 push/pull -->
<axe simulateMouseMove="y"
threshold="50"
divisor="30" />
<axe simulateMouseMove="x"
threshold="50"
divisor="30" />
<axe threshold="200" type="binary" posAction="Context Up" negAction=""/> <!-- axe 5 twist -->
<buttons>
<button simulateMouseButton="left" />
<button simulateMouseButton="right" />
</buttons>
</deviceContext>
</deviceContexts>
<contexts>
<context name="Default"
deviceContext="Mouse" />
<context name="SpaceNavigator"
deviceContext="SpaceNavigator" />
<context name="Mouse"
deviceContext="Mouse" />
</contexts>
<actions>
<sendWindowMessage name="Context Up"
type="CopyData"
window="SpaceNavigatorDriver"
message="CONTEXT;Up"/>
<sendWindowMessage name="Context Down"
type="CopyData"
window="SpaceNavigatorDriver"
message="CONTEXT;Down"/>
<sendWindowMessage name="RR Volume Up"
type="CopyData"
window="RoadRunner"
message="VOL+"/>
<sendWindowMessage name="RR Volume Down"
type="CopyData"
window="RoadRunner"
message="VOL-"/>
<sendWindowMessage name="RR Mute"
type="CopyData"
window="RoadRunner"
message="MUTE"/>
<sendWindowMessage name="RR Play/Pause"
type="CopyData"
window="RoadRunner"
message="PLAY"/>
<sendWindowMessage name="RR Next"
type="CopyData"
window="RoadRunner"
message="NEXT"/>
<sendWindowMessage name="RR Prev"
type="CopyData"
window="RoadRunner"
message="PREV"/>
<sendWindowMessage name="RR FullVisu"
type="CopyData"
window="RoadRunner"
message="Full_Visu"/>
<keyPress name="Copy">
<key>17</key>
<key>67</key>
</keyPress>
<keyPress name="Paste">
<key>17</key>
<key>86</key>
</keyPress>
</actions>
Bookmarks