Configuring Vehicle Specific Module (VSM)

Vehicle Specific Module is used to connect to the vehicle and governs advanced routing settings. To configure VSM it is necessary to edit the vsm-ardupilot.conf file which is typically located in
C:\Program Files (x86)\UgCS\bin or the specified installation directory

Connection-related settings

To start connecting the VSM to the available vehicles using UDP protocol, it is necessary to indicate which ports the VSM must listen to for available devices (flight controllers). Lines 36-38 of vsm-ardupilot.conf file contains the following text:

The vehicle can be connected via UDP.

UDP port which will listen for incoming Mavlink messages.

connection.udp_in.1.local_port = 14550

To configure the connection to vehicles it is either necessary to set all the vehicles to send messages to the same UDP Port (in which case it will be problematic to connect to one single vehicle only) or to set the local port unique for each vehicle (recommended).
Example configuration for 3 vehicles:

connection.udp_in.1.local_port = 14561
connection.udp_in.2.local_port = 14562
connection.udp_in.3.local_port = 14563

Notice how both port and number of vehicles (1, 2, 3) change. Make sure to restart VSM after
making any changes to start using them.

Other routing-related settings

Another important routing setting that can be configured within vsm-ardupilot.conf file is enabling and disabling auto heading. If the auto heading is enabled, the route will be created in a way that vehicle will always face the following waypoint. If an auto heading is disabled, the vehicle will not change its yaw angle unless changed using the “Yaw” action for the corresponding waypoint. The behavior is governed by changing the following line within vsm-ardupilot.conf file:

vehicle.ardupilot.autoheading = no

Group Arducopter parameter change using vsm-ardupilot.conf file

It is possible to change one or more Ardupilot configuration parameters by changing vsm-ardupilot.conf file. There is one sample line within vsm-ardupilot.conf file. When parameters are added to this file, they are changed within Ardupilot when VSM connects to vehicles. For example, if one would like to set action on loss of RC = N/A, to disable the corresponding fail-safe, one could add the following line to vsm-ardupilot.conf file and restart the ArduPilot VSM:


Once vehicles have been discovered by the VSM, the line can be removed from the config file.