Files
firestar5683 ab81464bd1 Maps
Add navigation and map matching providers with the vendored map service sources.

Co-authored-by: Daniel Koepping <elkoled@gmail.com>
Co-authored-by: Danny <dannyirwin31@yahoo.com>
Co-authored-by: Prabhaav Pillai <prabhaav@msu.edu>
Co-authored-by: dirwin31 <83434411+dirwin31@users.noreply.github.com>
2026-10-14 19:56:17 -05:00

20 KiB

Settings

Mapd settings are stored in the MapdSettings param. They can be directly controlled through the param or through MapdIn cereal messages. See inputs.md for more details about loading and saving settings. The following is details about each setting, including location in the MapdSettings param and their corresponding MapdIn actions.

Settings Version and Schema

The MapdSettings param (and the custom defaults/recommended json files described in overriding-internal-defaults.md) are versioned with a settings_version field, currently 2. As of version 2 the settings are grouped into nested objects (subscriber, speed_limit, logger, personalities) instead of one flat object. Param Key values below use dot notation to show the full path within that nested structure, e.g. speed_limit.speed_limit_offset means {"speed_limit": {"speed_limit_offset": ...}}.

If mapd loads a param or custom json file with an older settings_version it automatically migrates it to the current version before use, so existing v1 settings continue to work without manual changes. New custom defaults/ recommended files should be written directly in the v2 shape documented here.

Setting Values Through MapdIn

Most settings can be set with the generic setJsonPathBool, setJsonPathFloat, and setJsonPathText MapdIn types: put the setting's Param Key (the dot path) in the jsonPath field and the value in the matching bool/float/str field.

A number of dedicated MapdIn types from before settings v2 (e.g. setSpeedLimitOffset, setTargetSpeedJerk, setLogLevel) still work and are listed as deprecated below where applicable. Where a dedicated type touches a value that is now personality-specific (jerk, accel, lat A, time offsets, next-speed-limit behavior), it sets that value for all three personalities at once rather than one at a time.

Settings Version

The schema version of the settings. Mapd migrates older versions to the current schema on load; this should not normally be set directly.

Item Description
Param Key settings_version

Speed Limit Control Enabled

When enabled mapd will use the speed limit to determine a suggested speed

Item Description
MapdIn Type setJsonPathBool (jsonPath: speed_limit_control_enabled)
MapdIn Type (deprecated) setSpeedLimitControl
MapdIn Field bool
Param Key speed_limit_control_enabled

Map Curve Speed Control Enabled

When enabled mapd will use map based curvature calculations to determine a suggested speed

Item Description
MapdIn Type setJsonPathBool (jsonPath: map_curve_speed_control_enabled)
MapdIn Type (deprecated) setMapCurveSpeedControl
MapdIn Field bool
Param Key map_curve_speed_control_enabled

Vision Curve Speed Control Enabled

When enabled mapd will use vision model based curvature calculations to determine a suggested speed

Item Description
MapdIn Type setJsonPathBool (jsonPath: vision_curve_speed_control_enabled)
MapdIn Type (deprecated) setVisionCurveSpeedControl
MapdIn Field bool
Param Key vision_curve_speed_control_enabled

Conditional Speed Limit Control Enabled

When enabled mapd applies conditional speed limits (the osm maxspeed:conditional tag) to the speed limit when their condition currently applies. Only simple day/time conditions are evaluated (e.g. 25 mph @ (Mo-Fr 07:00-17:00) school zones or 100 @ (22:00-06:00) night limits); conditions mapd can't fully evaluate (weather, public holidays, months, vehicle class) are ignored and the regular speed limit is used. Conditions are checked against the device's local time, so the device timezone must be correct. The raw tag is always output in mapdOut regardless of this setting so forks can do their own handling.

Item Description
MapdIn Type setConditionalSpeedLimitControl
MapdIn Field bool
Param Key conditional_speed_limit_control_enabled

External Speed Limit Control Enabled

When enabled mapd will use fork provided speed limits to determine a suggested speed

Item Description
MapdIn Type setJsonPathBool (jsonPath: external_speed_limit_control_enabled)
MapdIn Type (deprecated) setExternalSpeedLimitControl
MapdIn Field bool
Param Key external_speed_limit_control_enabled

Mapd Enable Speed

The speed you can set your cruise control to that will then cause mapd features to engage

Item Description
MapdIn Type setJsonPathFloat (jsonPath: enable_speed)
MapdIn Type (deprecated) setEnableSpeed
MapdIn Field float
Units meters/second
Param Key enable_speed

Use Enable Speed For Speed Limit

Determines whether the Mapd Enable Speed controls enabling of Speed Limit Control

Item Description
MapdIn Type setJsonPathBool (jsonPath: speed_limit_use_enable_speed)
MapdIn Type (deprecated) setSpeedLimitUseEnableSpeed
MapdIn Field bool
Param Key speed_limit_use_enable_speed

Use Enable Speed for Map Curve Speed Control

Determines whether the Mapd Enable Speed controls enabling of Curve Speed Control

Item Description
MapdIn Type setJsonPathBool (jsonPath: map_curve_use_enable_speed)
MapdIn Type (deprecated) setMapCurveUseEnableSpeed
MapdIn Field bool
Param Key map_curve_use_enable_speed

Use Enable Speed for Vision Curve Speed Control

Determines whether the Mapd Enable Speed controls enabling of Vision Curve Speed Control

Item Description
MapdIn Type setJsonPathBool (jsonPath: vision_curve_use_enable_speed)
MapdIn Type (deprecated) setVisionCurveUseEnableSpeed
MapdIn Field bool
Param Key vision_curve_use_enable_speed

Default Lane Width

The default lane width to use when determining if we are currently on a road

Item Description
MapdIn Type setJsonPathFloat (jsonPath: default_lane_width)
MapdIn Type (deprecated) setDefaultLaneWidth
MapdIn Field float
Units meters
Param Key default_lane_width

Speed Limit Settings (speed_limit)

These settings live under the speed_limit object in the MapdSettings param.

Speed Limit Priority

Sets the prioritization method for available speed limits

Item Description
MapdIn Type setJsonPathText (jsonPath: speed_limit.speed_limit_priority)
MapdIn Type (deprecated) setSpeedLimitPriority
MapdIn Field str
Values map, external, highest, lowest
Param Key speed_limit.speed_limit_priority

Speed Limit Offset

The offset that gets applied to a speed limit to determine a target speed

Item Description
MapdIn Type setJsonPathFloat (jsonPath: speed_limit.speed_limit_offset)
MapdIn Type (deprecated) setSpeedLimitOffset
MapdIn Field float
Units meters/second
Param Key speed_limit.speed_limit_offset

Speed Limit Change Requires Accept

Requires user acceptance of any speed limit changes before activating

Item Description
MapdIn Type setJsonPathBool (jsonPath: speed_limit.speed_limit_change_requires_accept)
MapdIn Type (deprecated) setSpeedLimitChangeRequiresAccept
MapdIn Field bool
Param Key speed_limit.speed_limit_change_requires_accept

Press Gas To Accept Speed Limit

Pressing the gas will accept a speed limit change

Item Description
MapdIn Type setJsonPathBool (jsonPath: speed_limit.press_gas_to_accept_speed_limit)
MapdIn Type (deprecated) setPressGasToAcceptSpeedLimit
MapdIn Field bool
Param Key speed_limit.press_gas_to_accept_speed_limit

Press Gas To Override Speed Limit

Pressing the gas will override the speed limit to hold the current speed. Resets when the speed limit changes

Item Description
MapdIn Type setJsonPathBool (jsonPath: speed_limit.press_gas_to_override_speed_limit)
MapdIn Type (deprecated) setPressGasToOverrideSpeedLimit
MapdIn Field bool
Param Key speed_limit.press_gas_to_override_speed_limit

Adjust Set Speed To Accept Speed Limit

Adjusting the set speed once in either direction will accept a speed limit change. Additional set speed changes reject the speed limit

Item Description
MapdIn Type setJsonPathBool (jsonPath: speed_limit.adjust_set_speed_to_accept_speed_limit)
MapdIn Type (deprecated) setAdjustSetSpeedToAcceptSpeedLimit
MapdIn Field bool
Param Key speed_limit.adjust_set_speed_to_accept_speed_limit

Accept Speed Limit Timeout

The amount of time after a speed limit change is detected that accept inputs will be used. 0 is no limit

Item Description
MapdIn Type setJsonPathFloat (jsonPath: speed_limit.accept_speed_limit_timeout)
MapdIn Type (deprecated) setAcceptSpeedLimitTimeout
MapdIn Field float
Units seconds
Param Key speed_limit.accept_speed_limit_timeout

Hold Speed Limit While Changing Set Speed

When enabled mapd will suggest using the speed limit while the cruise control speed is changing. This prevents speeding up while trying to reach the enable speed

Item Description
MapdIn Type setJsonPathBool (jsonPath: speed_limit.hold_speed_limit_while_changing_set_speed)
MapdIn Type (deprecated) setHoldSpeedLimitWhileChangingSetSpeed
MapdIn Field bool
Param Key speed_limit.hold_speed_limit_while_changing_set_speed

Hold Last Seen Speed Limit

When enabled mapd will use the last seen speed limit if it cannot determine a current speed limit

Item Description
MapdIn Type setJsonPathBool (jsonPath: speed_limit.hold_last_seen_speed_limit)
MapdIn Type (deprecated) setHoldLastSeenSpeedLimit
MapdIn Field bool
Param Key speed_limit.hold_last_seen_speed_limit

Personalities (personalities)

Mapd computes speed change activation distances and curve/speed-limit targets using one of three tunable profiles: relaxed, standard, or aggressive. Mapd subscribes to openpilot's selfdriveState message and reads selfdriveState.personality (openpilot's longitudinal personality, set by the user through openpilot's own UI/controls) every tick to pick which profile is currently active; standard is used as the fallback when no valid value has been read yet. All three profiles are configured independently in the MapdSettings param under personalities.relaxed, personalities.standard, and personalities.aggressive.

There is no dedicated per-personality MapdIn type — set these values with setJsonPathFloat/setJsonPathBool using a jsonPath of the form personalities.<relaxed|standard|aggressive>.<field>, e.g. personalities.aggressive.target_speed_jerk. The deprecated non-path MapdIn types below (carried over from before personalities existed) set the same field on all three personalities at once.

Target Speed Jerk

The target amount of jerk to use when determining speed change activation distance (map curve and speed limit)

Item Description
MapdIn Type setJsonPathFloat (jsonPath: personalities.<name>.target_speed_jerk)
MapdIn Type (deprecated, sets all personalities) setTargetSpeedJerk
MapdIn Field float
Units meters/second^3
Param Key personalities.<name>.target_speed_jerk

Target Speed Accel

The target amount of acceleration to use when determining speed change activation distance (map curve and speed limit)

Item Description
MapdIn Type setJsonPathFloat (jsonPath: personalities.<name>.target_speed_accel)
MapdIn Type (deprecated, sets all personalities) setTargetSpeedAccel
MapdIn Field float
Units meters/second^2
Param Key personalities.<name>.target_speed_accel

Curve Target Speed Time Offset

An offset for the time before a target position to reach the target speed (map curve)

Item Description
MapdIn Type setJsonPathFloat (jsonPath: personalities.<name>.curve_target_speed_time_offset)
MapdIn Field float
Units seconds
Param Key personalities.<name>.curve_target_speed_time_offset

Speed Limit Increase Target Speed Time Offset

An offset for the time before a target position to reach the target speed (speed limit, when the upcoming limit is higher than the current one)

Item Description
MapdIn Type setJsonPathFloat (jsonPath: personalities.<name>.speed_limit_increase_target_speed_time_offset)
MapdIn Field float
Units seconds
Param Key personalities.<name>.speed_limit_increase_target_speed_time_offset

Speed Limit Decrease Target Speed Time Offset

An offset for the time before a target position to reach the target speed (speed limit, when the upcoming limit is lower than the current one)

Item Description
MapdIn Type setJsonPathFloat (jsonPath: personalities.<name>.speed_limit_decrease_target_speed_time_offset)
MapdIn Field float
Units seconds
Param Key personalities.<name>.speed_limit_decrease_target_speed_time_offset

Target Speed Time Offset (Deprecated)

Sets Curve Target Speed Time Offset, Speed Limit Increase Target Speed Time Offset, and Speed Limit Decrease Target Speed Time Offset to the same value for all three personalities. Kept for backwards compatibility; new integrations should set the settings above independently.

Item Description
MapdIn Type setTargetSpeedTimeOffset
MapdIn Field float
Units seconds

Map Curve Target Lateral Acceleration

The maximum lateral acceleration used in the Map Curve Control speed calculations

Item Description
MapdIn Type setJsonPathFloat (jsonPath: personalities.<name>.map_curve_target_lat_a)
MapdIn Type (deprecated, sets all personalities) setMapCurveTargetLatA
MapdIn Field float
Units meters/second^2
Param Key personalities.<name>.map_curve_target_lat_a

Vision Target Lateral Acceleration

The maximum lateral acceleration used in the Vision Curve Control speed calculations

Item Description
MapdIn Type setJsonPathFloat (jsonPath: personalities.<name>.vision_curve_target_lat_a)
MapdIn Type (deprecated, sets all personalities) setVisionCurveTargetLatA
MapdIn Field float
Units meters/second^2
Param Key personalities.<name>.vision_curve_target_lat_a

Vision Minimum Target Velocity

The minimum speed that Vision Curve Control will request to drive

Item Description
MapdIn Type setJsonPathFloat (jsonPath: personalities.<name>.vision_curve_min_target_v)
MapdIn Type (deprecated, sets all personalities) setVisionCurveMinTargetV
MapdIn Field float
Units meters/second
Param Key personalities.<name>.vision_curve_min_target_v

Slow Down For Next Speed Limit

Determines if mapd will try to meet the upcoming speed limit before reaching it when the upcoming speed limit is lower than the current limit

Item Description
MapdIn Type setJsonPathBool (jsonPath: personalities.<name>.slow_down_for_next_speed_limit)
MapdIn Type (deprecated, sets all personalities) setSlowDownForNextSpeedLimit
MapdIn Field bool
Param Key personalities.<name>.slow_down_for_next_speed_limit

Speed Up For Next Speed Limit

Determines if mapd will try to meet the upcoming speed limit before reaching it when the upcoming speed limit is higher than the current limit

Item Description
MapdIn Type setJsonPathBool (jsonPath: personalities.<name>.speed_up_for_next_speed_limit)
MapdIn Type (deprecated, sets all personalities) setSpeedUpForNextSpeedLimit
MapdIn Field bool
Param Key personalities.<name>.speed_up_for_next_speed_limit

Subscriber Settings (subscriber)

Openpilot has a limited number of msgq subscriber slots. mapd normally shadows only the carState subscriber (piggybacking on an existing subscription rather than opening a new one) since stock openpilot uses nearly every slot. These settings let a fork shadow additional subscribers instead of opening new ones if it runs into subscriber slot exhaustion, at the cost of sharing that subscription's read cursor with whatever else shadows it. Restarting mapd is required for changes to these settings to take effect, since subscribers are only created at startup.

Shadow Car State

Shadow the carState subscriber instead of opening a dedicated one

Item Description
MapdIn Type setJsonPathBool (jsonPath: subscriber.shadow_car_state)
MapdIn Type (deprecated) setShadowCarState
MapdIn Field bool
Param Key subscriber.shadow_car_state

Shadow Model V2

Shadow the modelV2 subscriber instead of opening a dedicated one

Item Description
MapdIn Type setJsonPathBool (jsonPath: subscriber.shadow_model_v2)
MapdIn Type (deprecated) setShadowModelV2
MapdIn Field bool
Param Key subscriber.shadow_model_v2

Shadow GPS Location

Shadow the gpsLocation subscriber instead of opening a dedicated one

Item Description
MapdIn Type setJsonPathBool (jsonPath: subscriber.shadow_gps_location)
MapdIn Type (deprecated) setShadowGpsLocation
MapdIn Field bool
Param Key subscriber.shadow_gps_location

Shadow GPS Location External

Shadow the gpsLocationExternal subscriber instead of opening a dedicated one

Item Description
MapdIn Type setJsonPathBool (jsonPath: subscriber.shadow_gps_location_external)
MapdIn Type (deprecated) setShadowGpsLocationExternal
MapdIn Field bool
Param Key subscriber.shadow_gps_location_external

Shadow Selfdrive State

Shadow the selfdriveState subscriber instead of opening a dedicated one. There is no dedicated MapdIn type for this setting; use setJsonPathBool.

Item Description
MapdIn Type setJsonPathBool (jsonPath: subscriber.shadow_selfdrive_state)
MapdIn Field bool
Param Key subscriber.shadow_selfdrive_state

Logger Settings (logger)

These settings live under the logger object in the MapdSettings param.

Log Level

Modify how verbose logging will be for the mapd system

Item Description
MapdIn Type setJsonPathText (jsonPath: logger.log_level)
MapdIn Type (deprecated) setLogLevel
MapdIn Field str
Values error, warn, info, debug
Param Key logger.log_level

Use JSON Logger

When true the logs will be output in a json format instead of a text format

Item Description
MapdIn Type setJsonPathBool (jsonPath: logger.log_json)
MapdIn Type (deprecated) setLogJson
MapdIn Field bool
Param Key logger.log_json

Log Source Location

When true the logs will include the file and line that wrote the log

Item Description
MapdIn Type setJsonPathBool (jsonPath: logger.log_source)
MapdIn Type (deprecated) setLogSource
MapdIn Field bool
Param Key logger.log_source