## For instruction on writing tutorials ## http://www.ros.org/wiki/WritingTutorials #################################### ##FILL ME IN #################################### ## for a custom note with links: ## note = This tutorial assumes that you have complete the previous tutorials: [[roch/Tutorials/Using package of roch_bringup|roch_bringup]], [[ROS/EnvironmentVariables|ROS enviroment variables]] and [[ROS/Tutorials/InstallingandConfiguringROSEnvironment|How to configure enviroment]] ## for the canned note of "This tutorial assumes that you have completed the previous tutorials:" just add the links ## note.0= ## descriptive title for the tutorial ## title = Changing env about roch ## multi-line description to be displayed in search ## description = Check out and configure env variables on Roch. ## the next tutorial description (optional) ## next = ## links to next tutorial (optional) ## next.0.link= [[roch/Tutorials/Using package of roch_follower|Using package of roch_follower]] ## next.1.link= ## what level user is this tutorial for ## level= BeginnerCategory ## keywords = #################################### <<IncludeCSTemplate(TutorialCSHeaderTemplate)>> <<TableOfContents(4)>> == Env on Roch == This assumes that you hav a [[Robots/Roch|Roch]] and configuration has done. Now, Let's check out how many variables of environment on Roch, typing following command: {{{ export | grep ROCH_ }}} or {{{ env | grep ROCH_ }}} After preceding command you will get following output : {{{ declare -x ROCH_3D_SENSOR="astra" declare -x ROCH_3D_SENSOR_ENABLE="TRUE" declare -x ROCH_3D_SENSOR_NAV_ENABLE="FALSE" declare -x ROCH_BASE="roch" declare -x ROCH_BATTERY declare -x ROCH_DESCRIPTION="/home/carl/test_husky/src/roch_v106120170117172/roch_project/roch/roch_description/robots/roch_standard_asus_xtion_pro.urdf.xacro" declare -x ROCH_GAZEBO_DESCRIPTION="/home/carl/test_husky/src/roch_v106120170117172/roch_project/roch_simulator/roch_gazebo/urdf/description.gazebo.xacro" declare -x ROCH_GAZEBO_MAP_FILE="/home/carl/test_husky/src/roch_v106120170117172/roch_project/roch_simulator/roch_gazebo/maps/sawyer_playgen.yaml" declare -x ROCH_GAZEBO_WORLD_FILE="/home/carl/test_husky/src/roch_v106120170117172/roch_project/roch_simulator/roch_gazebo/worlds/sawyer_playgen.world" declare -x ROCH_INTERACTIONS_LIST="[roch_bringup/admin.interactions, roch_bringup/documentation.interactions, roch_bringup/pairing.interactions, roch_bringup/visualisation.interactions]" declare -x ROCH_LASER="rplidar" declare -x ROCH_LASER_ENABLE="FALSE" declare -x ROCH_MAG_CONFIG="" declare -x ROCH_MAP_FILE="/home/carl/test_husky/src/roch_v106120170117172/roch_project/roch/roch_navigation/maps/willow-2010-02-18-0.10.yaml" declare -x ROCH_NAME="roch" declare -x ROCH_RAPP_PACKAGE_BLACKLIST="[]" declare -x ROCH_RAPP_PACKAGE_WHITELIST="[rocon_apps, roch_rapps]" declare -x ROCH_SERIAL_PORT="/dev/roch" declare -x ROCH_SIMULATION="false" declare -x ROCH_STACKS="standard" declare -x ROCH_TYPE="roch" }}} == Change Values == We had checkout environment variables about Roch, and now we should change the values that we don not wanner such as '''''ROCH_3D_SENSOR''''' is '''astra''' we don not want, we can change the value to we need such as '''xtion''', '''astra'''. Now there have some ways to change the values. === Command-line === We can use following command to change values which we don not wanner, like we change '''''ROCH_LASER''''' to rplidar: {{{ export ROCH_LASER=rplidar }}} Typing following command to check out: {{{ env | grep ROCH_LASER }}} Once you close current terminal, the value of '''''ROCH_LASER''''' will recovery to '''rplidar''', so we should get a permanent ways to keep values not change. === .bashrc file === The '''.bashrc''' file will do we wanner, once we put our values into '''.bashrc''' file, the values will never change until you change value in '''.bashrc'''. Open '''''~/.bashrc''''' file using your favorite editor, such as '''gedit''': {{{ gedit ~/.bashrc }}} Adding following lines at end of '''.bashrc''' file: {{{ export ROCH_BASE=roch export ROCH_STACKS=standard export ROCH_3D_SENSOR=astra #for now have four support sensor [ asus_xtion_pro, kinect, r200, astra] export ROCH_LASER=rplidar #for now have two support laser [ ls01c, rplidar] export ROCH_3D_SENSOR_ENABLE=true export ROCH_3D_SENSOR_NAV_ENABLE=false export ROCH_LASER_ENABLE=true }}} Close file and reopen terminal, using following command to checkout: {{{ env | grep ROCH_ }}} ## AUTOGENERATED DO NOT DELETE ## TutorialCategory ## FILL IN THE STACK TUTORIAL CATEGORY HERE