View Single Post
Old 09-14-2007, 02:50 AM   #261
inh
Maximum Bitrate
 
Join Date: Jan 2007
Location: Fort Riley KS
Posts: 514
Ok, i guess this will be the start of my SpaceNav driver guide.. Attached are two config.xml files. One is the one I am currently using, which was really just a test to get the app to do different things based on where i was in the roadrunner skin. The second is one that will just act as a medai controller all the time.

Now, In the config i use that supports context switching you will see this code, in which it defines the two contexts i use, media controlling and mouse simulting:
Code:
<deviceContexts> <deviceContext name="Media" 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="RR Mute" 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="" negAction=""/> <!-- axe 5 twist --> <buttons> <button simulateMouseButton="left" /> <button simulateMouseButton="right" /> </buttons> </deviceContext> </deviceContexts>

The DeviceContextName is the name of the context, and the device is the interface. You can choose differnt interfaces, but in both configs i only have the space navigator setup, so they will always be the same.
Attached Files
File Type: txt mediaconfig.xml.txt (8.4 KB, 42 views)
File Type: txt myconfig.xml.txt (9.2 KB, 56 views)
__________________
Space Navigator - 6 Axis input device: Take it apart - Driver App
RRCam - Video/webcam capture, text overlay, and recording: 2.0 Stable
inh is offline   Reply With Quote