In most circumstances you will be able to configure your robot using MiRoapp. If you need more control, this page details the options available.

If you are having trouble configuring your robot—for example, its connection to the network—have a look through this page in case one of the options here is what you need.

Configuration files

The settings below are stored on-board at ~/.miro2/config/user_setup.bash. This file is also used in off-board installations of the MDK, and by MiRoapp—you can safely ignore comments and settings that are not described on this page.


Constrain accepted dynamic address

See the related FAQ: Why can I not reach the on-board ROS master?

In some conditions, your local network DHCP may briefly assign a bogus IP address to the robot before assigning a valid one. If network services are started on the robot using this bogus address, they will not work correctly after the valid address has been assigned (e.g. ROS master will be unreachable). You will see that the IP addresses under System information on the MiRoapp Home page do not all match.

There are two approaches to solving this problem.

Use static network address mode

The first is to use MiRoapp to switch Network address mode to "static", and to specify the valid address in advance. Visit the Home page and follow the instructions under Network settings.

Constrain valid dynamic address

If you can't do this (because you want to use a dynamic address), the second approach is to restrict the set of valid IP addresses that the robot will accept at boot time by modifying the setting MIRO_DYNAMIC_IP_MATCH in user_setup.bash. The robot will then wait for a matching address before starting network services.

For example, the setting below will allow only addresses starting with the number '192'.


For more complete control, you can use a full regular expression for the address. The example below is more explicit, allowing only valid IP addresses starting '192'.

export MIRO_DYNAMIC_IP_MATCH='^192\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$'
The setting MIRO_DYNAMIC_IP_MATCH was introduced at R190407—if the variable is not present in your user_setup.bash, add it manually using the template at ~/mdk/share/config/user_setup.bash.

Bridge flags

Various configuration options are available through the ROS topic control/flags, which allows configuring the robot "per-session", i.e. until a reboot. Controllers that need to first configure the robot should do so at the beginning of their execution—see the example client_template for an example of this (search for "--no-cliff").

These control/flags can, alternatively, be set permanently on-board the robot. To do this, find the setting MIRO_BRIDGE_FLAGS in user_setup.bash, and use the following table to choose a value.

For example, disable the cliff reflex and the automatic idling of kinematic servos by setting MIRO_BRIDGE_FLAGS=rk.

NB: The default setting is MIRO_BRIDGE_FLAGS=l—you should retain the l flag, or the status LEDs will light up across MiRos PCBs, which is usually unhelpful.

!Any flags appearing before this marker (the exclamation mark) will be locked—that is, clients will be unable to release them through the ROS topic control/flags.