{"action":"created","issue":{"url":"https://api.github.com/repos/robotology/gazebo-yarp-plugins/issues/204","labels_url":"https://api.github.com/repos/robotology/gazebo-yarp-plugins/issues/204/labels{/name}","comments_url":"https://api.github.com/repos/robotology/gazebo-yarp-plugins/issues/204/comments","events_url":"https://api.github.com/repos/robotology/gazebo-yarp-plugins/issues/204/events","html_url":"https://github.com/robotology/gazebo-yarp-plugins/pull/204","id":111063353,"number":204,"title":"Add support for using gazebo-specific \"enviromental variables\" in yarp configuration files ","user":{"login":"traversaro","id":1857049,"avatar_url":"https://avatars.githubusercontent.com/u/1857049?v=3","gravatar_id":"","url":"https://api.github.com/users/traversaro","html_url":"https://github.com/traversaro","followers_url":"https://api.github.com/users/traversaro/followers","following_url":"https://api.github.com/users/traversaro/following{/other_user}","gists_url":"https://api.github.com/users/traversaro/gists{/gist_id}","starred_url":"https://api.github.com/users/traversaro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/traversaro/subscriptions","organizations_url":"https://api.github.com/users/traversaro/orgs","repos_url":"https://api.github.com/users/traversaro/repos","events_url":"https://api.github.com/users/traversaro/events{/privacy}","received_events_url":"https://api.github.com/users/traversaro/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-10-12T21:56:21Z","updated_at":"2015-10-13T08:33:33Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/robotology/gazebo-yarp-plugins/pulls/204","html_url":"https://github.com/robotology/gazebo-yarp-plugins/pull/204","diff_url":"https://github.com/robotology/gazebo-yarp-plugins/pull/204.diff","patch_url":"https://github.com/robotology/gazebo-yarp-plugins/pull/204.patch"},"body":"To simplify passing using Gazebo values (such as the runtime robot\r\nname or sensor name) in yarp configuration files, now some special\r\nyarp configuration values (for now gazeboYarpPluginsRobotName and\r\ngazeboYarpPluginsSensorName) are present when loading the plugins\r\nconfiguration file. \r\n\r\nIn this way the user can either ignore them,\r\neither use them using the ${variableName} syntax, either overwriting\r\nthem specifying explicit value for them in the configuration files.\r\n\r\nTo understand the use of this feature, take the icub model from \r\nhttps://github.com/robotology-playground/icub-gazebo/tree/master/icub \r\nand comment out the `gazeboYarpPluginsRobotName icubGazeboSim` in\r\n https://github.com/robotology-playground/icub-gazebo/blob/master/icub/conf/gazebo_icub_robotname.ini . In this way the gazeboYarpPluginsRobotName \r\nconfiguration value is not overwritten by the user configuration files, and so its value\r\n(and hence the prefix of all the ports opened by the robot)  will be the one of the robot in Gazebo .\r\nGiven that any robot has a unique name in Gazebo, using this feature is possible to \r\nspawn multiple robots from the same model without yarp port names conflicts. \r\n\r\nWhitespace-free diff available at https://github.com/robotology/gazebo-yarp-plugins/pull/204/files . \r\n\r\ncc @EnricoMingo "},"comment":{"url":"https://api.github.com/repos/robotology/gazebo-yarp-plugins/issues/comments/147647359","html_url":"https://github.com/robotology/gazebo-yarp-plugins/pull/204#issuecomment-147647359","issue_url":"https://api.github.com/repos/robotology/gazebo-yarp-plugins/issues/204","id":147647359,"user":{"login":"traversaro","id":1857049,"avatar_url":"https://avatars.githubusercontent.com/u/1857049?v=3","gravatar_id":"","url":"https://api.github.com/users/traversaro","html_url":"https://github.com/traversaro","followers_url":"https://api.github.com/users/traversaro/followers","following_url":"https://api.github.com/users/traversaro/following{/other_user}","gists_url":"https://api.github.com/users/traversaro/gists{/gist_id}","starred_url":"https://api.github.com/users/traversaro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/traversaro/subscriptions","organizations_url":"https://api.github.com/users/traversaro/orgs","repos_url":"https://api.github.com/users/traversaro/repos","events_url":"https://api.github.com/users/traversaro/events{/privacy}","received_events_url":"https://api.github.com/users/traversaro/received_events","type":"User","site_admin":false},"created_at":"2015-10-13T08:33:33Z","updated_at":"2015-10-13T08:33:33Z","body":"Probably \"environmental variable\" is a confusing name. : ) \r\nThis are just yarp config values that are \"prefiled\" by gazebo when loading the configuration files, not actual \"enviromental variables\". In this way, you can refer to them when writing yarp ini configuration files, using the `${confParamName}` syntax. "}}