Vizzy Segway

From ISRWiki
Jump to navigation Jump to search

Segway RMP 50

The Player project http://playerstage.sourceforge.net/ includes a driver for all the Segway RMP platforms. The Player version installed is the 3.0.2, which needs the CAN driver from Kvaser http://www.kvaser.com/, already available for new versions of linux.

"NOTE:" After downloading and installing the driver from Kvaser and before installing the Player, create a 'build' folder inside the Player folder that was decompressed, enter the 'build' folder and run 'cmake ../'. After this, run 'ccmake ../' from the 'build' folder and point the CANLIB_DIR variable to the folder where the Kvaser folder was decompressed (don't forget to 'toggle' to advance mode to see this variable on the 'ccmake' list otherwise it won't appear). Press 'c' to configure and 'g' to generate. After that, edit the file '/usr/include/canlib.h' by comment out the definitions for DWORD, HANDLE, and BOOL.

You are now ready to do 'sudo make install' in 'build' folder.

After installing player, a way to test the installation is to plug an USB joystick for controlling the Segway and define a configuration file for player as follows:

   driver
   (
     name "linuxjoystick"
     provides ["joystick:0" ]
     requires ["position2d:0"]
     alwayson 1
     timeout 0.0
     max_speed [ 3.0 3.0  30 ]
     port "/dev/input/js0"
   )
   driver
   (
     name "segwayrmp"
     provides ["position2d:0" "position3d:0" "power:0"]
     bus "usb"
     usb_device "/dev/ttyUSB0"
     max_xspeed 1.5
     max_yawspeed 80
   )

Then, execute

   player <configFileName>


<< Back to Vizzy wiki homepage