Fawkes-robotino の設定変更
研究室のアカウントを持っている人は,RCLL2018への変更点を参照して下さい.
Index: /fawkes-robotino/cfg/conf.d/amcl.yaml =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -8,6 +8,8 @@ # If path starts with slash (/) it's considered to be absolute, # otherwise relative to the config directory - map_file: maps/halle.png + #map_file: maps/halle.png # Resolution of the map; meters per pixel + # -------- RCLL 2017 -------- + map_file: maps/rcll-2017-map.png resolution: 0.05 @@ -17,7 +19,11 @@ # There is a wall of one grid cell thickness around the map, therefore # set the origin to (-0.05, -0.05) - origin_x: 0.0 - origin_y: 0.0 - origin_theta: 0.0 + # origin_x: 0.0 + # origin_y: 0.0 + # origin_theta: 0.0 + origin_x: -9.5 #// setting of version RCLL 2017 + origin_y: -2.0 #// setting of version RCLL 2017 + origin_theta: 0 + # Pixels with occupancy probability greater than this threshold are @@ -29,10 +35,11 @@ # considered completely free free_threshold: 0.2 - + # Laser Minimum Range, beams shorter than this are ignored laser_min_range: 0.05 # Laser Maximum Range, beams longer than this are ignored - laser_max_range: 15.0 + # laser_max_range: 15.0 + laser_max_range: 5.0 # Maximum number of beams to consider @@ -111,6 +118,10 @@ # Initial pose (x, y, yaw) + #init_pose_x: 4.5 + #init_pose_y: -0.5 + # init_pose_a: 1.57 + # ----- Initial pose RCLL 2017 ----- init_pose_x: 4.5 - init_pose_y: -0.5 + init_pose_y: 0.5 init_pose_a: 1.57 @@ -147,6 +158,9 @@ # If path starts with slash (/) it's considered to be absolute, # otherwise relative to the config directory - map_file: maps/halle-wall.png + # map_file: maps/halle-wall.png # Resolution of the map; meters per pixel + # resolution: 0.05 + # -------- RCLL 2017 -------- + map_file: maps/rcll-2017-wall.png resolution: 0.05 @@ -156,7 +170,10 @@ # There is a wall of one grid cell thickness around the map, therefore # set the origin to (-0.05, -0.05) - origin_x: 0.0 - origin_y: 0.0 - origin_theta: 0.0 + # origin_x: 0.0 + # origin_y: 0.0 + # rigin_theta: 0.0 + origin_x: -9.5 #// setting of version RCLL 2017 + origin_y: -2.0 #// setting of version RCLL 2017 + origin_theta: 0 # Pixels with occupancy probability greater than this threshold are
Index: fawkes-robotino/cfg/conf.d/clips-agent.yaml =================================================================== --- リビジョン 2260 +++ リビジョン 2266 @@ -43,5 +43,6 @@ # Note that this release does not include the production phase code for 2016 # for the rcll2016 domain model and agent specification - agent: rcll2016/rcll2016 + # agent: rcll2016/rcll2016 + agent: rcll2018/btr2018 # To use the 2015 agent, which does include the old production phase code, # uncomment the following line. The config values are in clips-agent-2015.yaml. @@ -49,5 +50,5 @@ - rcll2016: + rcll2018: #agent-role defined in host.yaml (this is only the default!) agent-role: nothing @@ -130,7 +131,11 @@ row: MID - row-high: ["Z16", "Z3", "Z2", "Z1", "Z13", "Z14", "Z15", "Z4"] - row-mid: ["Z9", "Z10", "Z11", "Z12", "Z8", "Z7", "Z6", "Z5"] - row-low: ["Z17", "Z18", "Z19", "Z20", "Z24", "Z23", "Z22", "Z21"] + # row-high: ["Z16", "Z3", "Z2", "Z1", "Z13", "Z14", "Z15", "Z4"] + # row-mid: ["Z9", "Z10", "Z11", "Z12", "Z8", "Z7", "Z6", "Z5"] + # row-low: ["Z17", "Z18", "Z19", "Z20", "Z24", "Z23", "Z22", "Z21"] + row-high: ["C_Z52" ,"C_Z62" ,"C_Z72", "C_Z73", "C_Z74", "C_Z75", "C_Z76", "C_Z77", "C_Z78", "C_Z68", "C_Z67", "C_Z66", "C_Z65", "C_Z64", "C_Z63", "C_Z53", "C_Z54", "C_Z55", "C_Z56", "C_Z57", "C_Z58", "C_Z48", "C_Z47", "C_Z46", "C_Z45", "C_Z44", "C_Z43", "C_Z42", "C_Z32", "C_Z33", "C_Z34", "C_Z35", "C_Z36", "C_Z37", "C_Z38", "C_Z28", "C_Z27", "C_Z26", "C_Z25", "C_Z24", "C_Z23", "C_Z22", "C_Z12", "C_Z13", "C_Z14", "C_Z15", "C_Z16", "C_Z17", "C_Z18", "C_Z77"] + row-mid: ["C_Z52" ,"C_Z62" ,"C_Z72", "C_Z73", "C_Z74", "C_Z75", "C_Z76", "C_Z77", "C_Z78", "C_Z68", "C_Z67", "C_Z66", "C_Z65", "C_Z64", "C_Z63", "C_Z53", "C_Z54", "C_Z55", "C_Z56", "C_Z57", "C_Z58", "C_Z48", "C_Z47", "C_Z46", "C_Z45", "C_Z44", "C_Z43", "C_Z42", "C_Z32", "C_Z33", "C_Z34", "C_Z35", "C_Z36", "C_Z37", "C_Z38", "C_Z28", "C_Z27", "C_Z26", "C_Z25", "C_Z24", "C_Z23", "C_Z22", "C_Z12", "C_Z13", "C_Z14", "C_Z15", "C_Z16", "C_Z17", "C_Z18","C_Z77"] + row-low: ["C_Z52" ,"C_Z62" ,"C_Z72", "C_Z73", "C_Z74", "C_Z75", "C_Z76", "C_Z77", "C_Z78", "C_Z68", "C_Z67", "C_Z66", "C_Z65", "C_Z64", "C_Z63", "C_Z53", "C_Z54", "C_Z55", "C_Z56", "C_Z57", "C_Z58", "C_Z48", "C_Z47", "C_Z46", "C_Z45", "C_Z44", "C_Z43", "C_Z42", "C_Z32", "C_Z33", "C_Z34", "C_Z35", "C_Z36", "C_Z37", "C_Z38", "C_Z28", "C_Z27", "C_Z26", "C_Z25", "C_Z24", "C_Z23", "C_Z22", "C_Z12", "C_Z13", "C_Z14", "C_Z15", "C_Z16", "C_Z17", "C_Z18","C_Z77"] + #the time in seconds to report all machines even if we are not prepared for production
Index: fawkes-robotino/cfg/conf.d/dynamixel.yaml =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -59,5 +59,5 @@ # Either set the desired servo IDs that should be found in the servo chain # or leave this field empty (servos: []) to discover all available servos - servos: [1, 2] + servos: [] # Autorecover of servos which disable their torque (by setting torque limit to 0) @@ -66,4 +66,11 @@ # autorecover_flags is used to specify to recover only on certian errors. This can for example be 0x20 (32) # to recover on overload shutdown. To recover on all errors set autorecover_flags to 127 (7 bits per error) - autorecover_enabled: false + autorecover_enabled: true autorecover_flags: 127 + + # set return_level + # 0: SRL_RESPONDE_NONE + # 1: SRL_RESPOND_READ + # 2: SRL_RESPOND_ALL + return_level: 1 +
Index: fawkes-robotino/cfg/conf.d/gazsim.yaml =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -135,6 +135,6 @@ llsf-control: - team-cyan-name: "Carologistics" - team-magenta-name: "Carologistics-2" + team-cyan-name: "BabyTigers" + team-magenta-name: "Carologistics" start-game-automatically: true time-to-wait-before-set-team: 5.0
Index: fawkes-robotino/cfg/conf.d/laser-filter.yaml =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -9,6 +9,6 @@ # URG input interface - #in/urg: Laser360Interface::Laser urg - in/sick-tim55x: Laser360Interface::Laser tim55x 360 + in/urg: Laser360Interface::Laser urg + #in/sick-tim55x: Laser360Interface::Laser tim55x 360 # URG filtered output interface @@ -32,9 +32,9 @@ robot-1080: - active: true + active: false # URG input interface #in/urg: Laser360Interface::Laser urg - in/sick-tim55x: Laser1080Interface::Laser tim55x + # in/sick-tim55x: Laser1080Interface::Laser tim55x # URG filtered output interface @@ -87,9 +87,9 @@ sick-downsample: - active: true + active: false # URG input interface - #in/urg: Laser360Interface::Laser urg - in/sick-tim55x: Laser1080Interface::Laser tim55x + in/urg: Laser360Interface::Laser urg + #in/sick-tim55x: Laser1080Interface::Laser tim55x # URG filtered output interface
Index: fawkes-robotino/cfg/conf.d/laser.yaml =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -9,5 +9,5 @@ urg: # Enable this configuration? - active: false + active: true # Configuration is for Hokuyo URG laser range finder using URG library @@ -21,5 +21,5 @@ tim55x: # Enable this configuration? - active: true + active: false # Configuration is for Sick TiM55x over USB
Index: fawkes-robotino/cfg/conf.d/navgraph-clusters.yaml =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -12,5 +12,5 @@ # If a cluster centroid is as close or closer than this threshold # to an edge that very edge will be marked as blocke. - close-threshold: 0.5 + close-threshold: 0.9 # Minimum visibility history value a cluster must have before it is
Index: fawkes-robotino/cfg/conf.d/navgraph-generator.yaml =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -67,3 +67,3 @@ # provide an exploration graph for when there are no recognized # machines, yet. - base-graph: navgraph-basis.yaml + base-graph: navgraph-basis-2018.yaml
Index: fawkes-robotino/cfg/conf.d/navgraph.yaml =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -16,5 +16,5 @@ # Graph file to use for path planning - graph_file: navgraph-basis.yaml + graph_file: navgraph-basis-2018.yaml # Interval in which the resend the goto command; sec
Index: fawkes-robotino/cfg/maps/llsf-map.yaml =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -2,5 +3,7 @@ -image: llsf-map-2015.png +#image: llsf-map-2015.png +image: rcll2018-map.png resolution: 0.05 -origin: [-7.0, -1.0, 0.0] +# origin: [-7.0, -1.0, 0.0] +origin: [0, 1.0, 0] occupied_thresh: 0.65 free_thresh: 0.196
Index: fawkes-robotino/cfg/navgraph-basis.yaml =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -54,10 +54,10 @@ - !unconnected name: C-ins-out - pos: [3.3, -0.55] + pos: [4.3, 0.55] properties: - always-copy: true - !unconnected name: C-ins-in - pos: [3.3, 0.75] + pos: [4.3, 0.75] properties: - always-copy: true @@ -65,10 +65,10 @@ - !unconnected name: M-ins-out - pos: [-3.3, -0.55] + pos: [-4.3, 0.55] properties: - always-copy: true - !unconnected name: M-ins-in - pos: [-3.3, 0.75] + pos: [-4.3, 0.75] properties: - always-copy: true
Index: fawkes-robotino/etc/scripts/gazsim.bash =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -36,4 +36,14 @@ -v Run Fawkes in valgrind -t Skip Exploration and add all navgraph points + --team-cyan Set cyan team name + --team-magenta Set magenta team name + --start-game Automatically run game after initialization + (if used with -t go into PRODUCTION phase, + otherwise the phase will be EXPLORATION, + optionally, "--start-game=PHASE" may be given + to set the phase explicitly) + Typically requires at least --team-cyan. + --rviz Start Rviz + --mps Load the plugin of gazsim-navgraph-generator EOF } @@ -64,6 +74,11 @@ SKIP_EXPLORATION= FAWKES_USED=false - -OPTS=$(getopt -o "hx:c:lrksn:e:dm:aof:p:gvt" -l "ros,ros-launch-main:,ros-launch:" -- "$@") +START_GAME= +TEAM_CYAN= +TEAM_MAGENTA= +RVIZ=false +MPS=false + +OPTS=$(getopt -o "hx:c:lrksn:e:dm:aof:p:gvt" -l "ros,ros-launch-main:,ros-launch:,start-game::,team-cyan:,team-magenta:,rviz,mps" -- "$@") if [ $? != 0 ] then @@ -155,4 +170,21 @@ ROS_LAUNCH_ROBOT="--ros-launch $OPTARG" ;; + --team-cyan) + TEAM_CYAN="$OPTARG" + ;; + --team-magenta) + TEAM_MAGENTA="$OPTARG" + ;; + --start-game) + if [ -n "$OPTARG" ]; then + START_GAME="$OPTARG" + else + if [ -n "$SKIP_EXPLORATION" ]; then + START_GAME="PRODUCTION" + else + START_GAME="EXPLORATION" + fi + fi + ;; -f) FIRST_ROBOTINO_NUMBER=$OPTARG @@ -163,4 +195,10 @@ -p) FAWKES_BIN=$OPTARG/bin + ;; + --rviz) + RVIZ=true + ;; + --mps) + MPS=true ;; --) break; @@ -201,4 +239,5 @@ killall llsf-refbox killall llsf-refbox-shell + killall rviz exit 0 fi @@ -218,5 +257,5 @@ # delete old shm files. Only do this for the simulation, not on live bot. - rm /dev/shm/*fawkes* + rm /dev/shm/*fawkes* 2>&1 >/dev/null #construct command to open everything in one terminal window with multiple tabs instead of 10.000 windows @@ -274,4 +313,15 @@ fi + if $RVIZ + then +# OPEN_COMMAND="$OPEN_COMMAND --tab -e 'bash -c \"$startup_script_location -x rviz $KEEP\"'" + OPEN_COMMAND="$OPEN_COMMAND --tab -e 'bash -c \"export TAB_START_TIME=$(date +%s); $script_path/wait-at-first-start.bash 7; $startup_script_location -x rviz $KEEP\"'" + fi + + if $MPS + then + OPEN_COMMAND="$OPEN_COMMAND --tab -e 'bash -c \"echo please enter to load the gazsim-navgraph-generator plugin; read a; wget http://localhost:8081/plugins/load/gazsim-navgraph-generator -q; rm gazsim-navgraph-generator*\"'" + fi + # open windows #echo $OPEN_COMMAND @@ -289,4 +339,12 @@ fi + if [ -n "$START_GAME" ]; then + if [ ! -x $LLSF_REFBOX_DIR/bin/rcll-refbox-instruct ]; then + echo "rcll-refbox-instruct not found, not built or old version?" + else + echo "Starting game (Phase: $START_GAME ${TEAM_CYAN:+Cyan: ${TEAM_CYAN}}${TEAM_MAGENTA:+ Magenta: ${TEAM_MAGENTA}})" + $LLSF_REFBOX_DIR/bin/rcll-refbox-instruct -p $START_GAME -s RUNNING ${TEAM_CYAN:+-c ${TEAM_CYAN}}${TEAM_MAGENTA:+-m ${TEAM_MAGENTA}} + fi + fi else
Index: fawkes-robotino/fawkes/cfg/conf.d/dynamixel.yaml =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -10,5 +10,5 @@ example: active: true - device: /dev/ttyUSB0 + device: /dev/usb2ax read_timeout_ms: 30 @@ -69,2 +69,7 @@ autorecover_flags: 127 + # set return_level + # 0: SRL_RESPONDE_NONE + # 1: SRL_RESPOND_READ + # 2: SRL_RESPOND_ALL + return_level: 1
Index: fawkes-robotino/fawkes/src/libs/protobuf_clips/communicator.cpp =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -329,6 +329,6 @@ } catch (std::runtime_error &e) { if (logger_) { - logger_->log_warn("CLIPS-Protobuf", "Cannot create message of type %s: %s", - full_name.c_str(), e.what()); + // logger_->log_warn("CLIPS-Protobuf", "Cannot create message of type %s: %s", + // full_name.c_str(), e.what()); } return CLIPS::Value(new std::shared_ptr<google::protobuf::Message>());
Index: fawkes-robotino/fawkes/src/plugins/clips-ros/Makefile =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -38,4 +38,8 @@ LDFLAGS += $(LDFLAGS_ROS) $(LDFLAGS_CLIPS) $(call ros-pkg-lflags,xmlrpcpp) \ $(call boost-libs-ldflags,$(REQ_BOOST_LIBS)) + + ifeq ($(call ros-pkg-version-atleast,xmlrpcpp,1.12.7),1) + CFLAGS += -DHAVE_NEW_ROS_XMLRPCPP_PATH + endif PLUGINS_all = $(PLUGINDIR)/clips-ros.$(SOEXT)
Index: fawkes-robotino/fawkes/src/plugins/clips-ros/clips_ros_thread.cpp =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -27,5 +27,9 @@ #include <ros/network.h> #include <ros/xmlrpc_manager.h> -#include <XmlRpc.h> +#ifdef HAVE_NEW_ROS_XMLRPCPP_PATH +# include <xmlrpcpp/XmlRpc.h> +#else +# include <XmlRpc.h> +#endif #include <tuple>
Index: fawkes-robotino/fawkes/src/plugins/dynamixel/driver_thread.cpp =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -86,4 +86,5 @@ cfg_max_voltage_ = config->get_float((cfg_prefix_ + "max_voltage").c_str()); cfg_servos_to_discover_ = config->get_uints((cfg_prefix_ + "servos").c_str()); + cfg_return_level_ = config->get_uint((cfg_prefix_ + "return_level").c_str()); chain_ = new DynamixelChain(cfg_device_.c_str(), cfg_read_timeout_ms_, cfg_enable_echo_fix_, cfg_enable_connection_stability_, cfg_min_voltage_, cfg_max_voltage_); @@ -145,6 +146,14 @@ } + unsigned char cfg_return_levels_[] = {DynamixelChain::SRL_RESPOND_NONE, + DynamixelChain::SRL_RESPOND_READ, + DynamixelChain::SRL_RESPOND_ALL}; + + /* // We only want responses to be sent on explicit READ to speed up communication chain_->set_status_return_level(DynamixelChain::BROADCAST_ID, DynamixelChain::SRL_RESPOND_READ); + */ + chain_->set_status_return_level(DynamixelChain::BROADCAST_ID, cfg_return_levels_[cfg_return_level_]); + // set compliance values chain_->set_compliance_values(DynamixelChain::BROADCAST_ID, @@ -862,6 +871,6 @@ if ( (pos < 0) || ((unsigned int)pos < pos_min) || ((unsigned int)pos > pos_max) ) { - logger->log_warn(name(), "Position out of bounds, min: %u max: %u des: %i", - pos_min, pos_max, pos); + logger->log_warn(name(), "Position out of bounds (id %d), min: %u max: %u des: %i", + servo_id, pos_min, pos_max, pos); return; }
Index: fawkes-robotino/fawkes/src/plugins/robotino/openrobotino_com_thread.cpp =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -277,5 +277,5 @@ #ifdef HAVE_OPENROBOTINO_API_2 com_->processComEvents(); - + update_velocities(); double odo_x = 0, odo_y = 0, odo_phi = 0; unsigned int odo_seq = 0;
Index: fawkes-robotino/src/libs/llsf_msgs/Makefile =================================================================== --- リビジョン 2253 +++ リビジョン 2266 @@ -22,4 +22,6 @@ MSGS_llsf_msgs = $(notdir $(patsubst %.proto,%,$(wildcard $(SRCDIR)/*.proto))) +MachineReport.pb.cpp: | Team.pb.cpp + include $(BUILDSYSDIR)/protobuf.mk include $(BUILDSYSDIR)/base.mk
Index: fawkes-robotino/src/plugins/agent-monitor/agent-monitor-processor.cpp =================================================================== --- リビジョン 2260 +++ リビジョン 2266 @@ -64,5 +64,6 @@ env_name_ = config_->get_string("/agent-monitor/clips-environment"); // own_name_ = config_->get_string("/clips-agent/llsf2014/robot-name"); - own_name_ = config_->get_string("/clips-agent/rcll2016/robot-name"); + // own_name_ = config_->get_string("/clips-agent/rcll2016/robot-name"); + own_name_ = config_->get_string("/clips-agent/rcll2018/robot-name"); refresh_interval_ = std::to_string(config_->get_int("/agent-monitor/refresh-interval"));
Index: fawkes-robotino/src/plugins/gazebo/gazsim-llsfrbcomm/gazsim_llsfrbcomm_thread.cpp =================================================================== --- リビジョン 2264 +++ リビジョン 2266 @@ -207,5 +207,5 @@ /* -void GazsimLLSFRbCommThread::on_puck_place_msg(ConstPlacePuckUnderMachinePtr &msg) + void GazsimLLSFRbCommThread::on_puck_place_msg(ConstPlacePuckUnderMachinePtr &msg) { //logger->log_info(name(), "Sending PPUM to refbox"); @@ -220,5 +220,5 @@ /* -void GazsimLLSFRbCommThread::on_puck_remove_msg(ConstRemovePuckFromMachinePtr &msg) + void GazsimLLSFRbCommThread::on_puck_remove_msg(ConstRemovePuckFromMachinePtr &msg) { //logger->log_info(name(), "Sending RPFM to refbox");
Index: fawkes-robotino/src/plugins/gazebo/gazsim-llsfrbcomm/gazsim_llsfrbcomm_thread.h =================================================================== --- リビジョン 2264 +++ リビジョン 2266 @@ -52,5 +52,5 @@ typedef const boost::shared_ptr<llsf_msgs::MachineInfo const> ConstMachineInfoPtr; -//typedef const boost::shared_ptr<llsf_msgs::PlacePuckUnderMachine const> ConstPlacePuckUnderMachinePtr; +// typedef const boost::shared_ptr<llsf_msgs::PlacePuckUnderMachine const> ConstPlacePuckUnderMachinePtr; // typedef const boost::shared_ptr<llsf_msgs::RemovePuckFromMachine const> ConstRemovePuckFromMachinePtr; typedef const boost::shared_ptr<gazsim_msgs::SimTime const> ConstSimTimePtr; @@ -108,6 +108,6 @@ //handler methods -// void on_puck_place_msg(ConstPlacePuckUnderMachinePtr &msg); -// void on_puck_remove_msg(ConstRemovePuckFromMachinePtr &msg); + // void on_puck_place_msg(ConstPlacePuckUnderMachinePtr &msg); + // void on_puck_remove_msg(ConstRemovePuckFromMachinePtr &msg); void on_time_sync_msg(ConstSimTimePtr &msg); void on_set_game_state_msg(ConstSetGameStatePtr &msg);
コメントを残す