1/* 2 * Copyright (C) 2016 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17package [email protected]; 18 19/** 20 * Enumerates supported data type for VehicleProperty. 21 * 22 * Used to create property ID in VehicleProperty enum. 23 */ 24enum VehiclePropertyType : int32_t { 25 STRING = 0x00100000, 26 BOOLEAN = 0x00200000, 27 INT32 = 0x00400000, 28 INT32_VEC = 0x00410000, 29 INT64 = 0x00500000, 30 INT64_VEC = 0x00510000, 31 FLOAT = 0x00600000, 32 FLOAT_VEC = 0x00610000, 33 BYTES = 0x00700000, 34 35 /** 36 * Any combination of scalar or vector types. The exact format must be 37 * provided in the description of the property. 38 * 39 * For vendor MIXED type properties, configArray needs to be formatted in this 40 * structure. 41 * configArray[0], 1 indicates the property has a String value 42 * configArray[1], 1 indicates the property has a Boolean value . 43 * configArray[2], 1 indicates the property has an Integer value. 44 * configArray[3], the number indicates the size of Integer[] in the property. 45 * configArray[4], 1 indicates the property has a Long value. 46 * configArray[5], the number indicates the size of Long[] in the property. 47 * configArray[6], 1 indicates the property has a Float value. 48 * configArray[7], the number indicates the size of Float[] in the property. 49 * configArray[8], the number indicates the size of byte[] in the property. 50 * For example: 51 * {@code configArray = {1, 1, 1, 3, 0, 0, 0, 0, 0}} indicates the property has 52 * a String value, a Boolean value, an Integer value and an array with 3 integers. 53 */ 54 MIXED = 0x00e00000, 55 56 MASK = 0x00ff0000 57}; 58 59/** 60 * List of different supported area types for vehicle properties. 61 * Used to construct property IDs in the VehicleProperty enum. 62 * 63 * Some properties may be associated with particular areas in the vehicle. For example, 64 * VehicleProperty#DOOR_LOCK property must be associated with a particular door, thus this property 65 * must be of the VehicleArea#DOOR area type. 66 * 67 * Other properties may not be associated with a particular area in the vehicle. These kinds of 68 * properties must be of the VehicleArea#GLOBAL area type. 69 * 70 * Note: This is not the same as areaId used in VehicleAreaConfig. E.g. for a global property, the 71 * property ID is of the VehicleArea#GLOBAL area type, however, the area ID must be 0. 72 */ 73// A better name would be VehicleAreaType 74enum VehicleArea : int32_t { 75 /** 76 * A global property is a property that applies to the entire vehicle and is not associated with 77 * a specific area. For example, FUEL_LEVEL, HVAC_STEERING_WHEEL_HEAT are global properties. 78 */ 79 GLOBAL = 0x01000000, 80 /** WINDOW maps to enum VehicleAreaWindow */ 81 WINDOW = 0x03000000, 82 /** MIRROR maps to enum VehicleAreaMirror */ 83 MIRROR = 0x04000000, 84 /** SEAT maps to enum VehicleAreaSeat */ 85 SEAT = 0x05000000, 86 /** DOOR maps to enum VehicleAreaDoor */ 87 DOOR = 0x06000000, 88 /** WHEEL maps to enum VehicleAreaWheel */ 89 WHEEL = 0x07000000, 90 91 MASK = 0x0f000000, 92}; 93 94/** 95 * Enumerates property groups. 96 * 97 * Used to create property ID in VehicleProperty enum. 98 */ 99enum VehiclePropertyGroup : int32_t { 100 /** 101 * Properties declared in AOSP must use this flag. 102 */ 103 SYSTEM = 0x10000000, 104 105 /** 106 * Properties declared by vendors must use this flag. 107 */ 108 VENDOR = 0x20000000, 109 110 MASK = 0xf0000000, 111}; 112 113/** 114 * Declares all vehicle properties. VehicleProperty has a bitwise structure. 115 * Each property must have: 116 * - a unique id from range 0x0100 - 0xffff 117 * - associated data type using VehiclePropertyType 118 * - property group (VehiclePropertyGroup) 119 * - vehicle area (VehicleArea) 120 * 121 * Vendors are allowed to extend this enum with their own properties. In this 122 * case they must use VehiclePropertyGroup:VENDOR flag when the property is 123 * declared. 124 * 125 * When a property's status field is not set to AVAILABLE: 126 * - IVehicle#set may return StatusCode::NOT_AVAILABLE. 127 * - IVehicle#get is not guaranteed to work. 128 * 129 * Properties set to values out of range must be ignored and no action taken 130 * in response to such ill formed requests. 131 */ 132enum VehicleProperty : int32_t { 133 134 /** Undefined property. */ 135 INVALID = 0x00000000, 136 137 /** 138 * VIN of vehicle 139 * 140 * @change_mode VehiclePropertyChangeMode:STATIC 141 * @access VehiclePropertyAccess:READ 142 */ 143 INFO_VIN = ( 144 0x0100 145 | VehiclePropertyGroup:SYSTEM 146 | VehiclePropertyType:STRING 147 | VehicleArea:GLOBAL), 148 149 /** 150 * Manufacturer of vehicle 151 * 152 * @change_mode VehiclePropertyChangeMode:STATIC 153 * @access VehiclePropertyAccess:READ 154 */ 155 INFO_MAKE = ( 156 0x0101 157 | VehiclePropertyGroup:SYSTEM 158 | VehiclePropertyType:STRING 159 | VehicleArea:GLOBAL), 160 161 /** 162 * Model of vehicle 163 * 164 * @change_mode VehiclePropertyChangeMode:STATIC 165 * @access VehiclePropertyAccess:READ 166 */ 167 INFO_MODEL = ( 168 0x0102 169 | VehiclePropertyGroup:SYSTEM 170 | VehiclePropertyType:STRING 171 | VehicleArea:GLOBAL), 172 173 /** 174 * Model year of vehicle. 175 * 176 * @change_mode VehiclePropertyChangeMode:STATIC 177 * @access VehiclePropertyAccess:READ 178 * @unit VehicleUnit:YEAR 179 */ 180 INFO_MODEL_YEAR = ( 181 0x0103 182 | VehiclePropertyGroup:SYSTEM 183 | VehiclePropertyType:INT32 184 | VehicleArea:GLOBAL), 185 186 /** 187 * Fuel capacity of the vehicle in milliliters 188 * 189 * @change_mode VehiclePropertyChangeMode:STATIC 190 * @access VehiclePropertyAccess:READ 191 * @unit VehicleUnit:MILLILITER 192 */ 193 INFO_FUEL_CAPACITY = ( 194 0x0104 195 | VehiclePropertyGroup:SYSTEM 196 | VehiclePropertyType:FLOAT 197 | VehicleArea:GLOBAL), 198 199 /** 200 * List of fuels the vehicle may use 201 * 202 * @change_mode VehiclePropertyChangeMode:STATIC 203 * @access VehiclePropertyAccess:READ 204 * @data_enum FuelType 205 */ 206 INFO_FUEL_TYPE = ( 207 0x0105 208 | VehiclePropertyGroup:SYSTEM 209 | VehiclePropertyType:INT32_VEC 210 | VehicleArea:GLOBAL), 211 212 /** 213 * Battery capacity of the vehicle, if EV or hybrid. This is the nominal 214 * battery capacity when the vehicle is new. 215 * 216 * @change_mode VehiclePropertyChangeMode:STATIC 217 * @access VehiclePropertyAccess:READ 218 * @unit VehicleUnit:WH 219 */ 220 INFO_EV_BATTERY_CAPACITY = ( 221 0x0106 222 | VehiclePropertyGroup:SYSTEM 223 | VehiclePropertyType:FLOAT 224 | VehicleArea:GLOBAL), 225 226 /** 227 * List of connectors this EV may use 228 * 229 * @change_mode VehiclePropertyChangeMode:STATIC 230 * @data_enum EvConnectorType 231 * @access VehiclePropertyAccess:READ 232 */ 233 INFO_EV_CONNECTOR_TYPE = ( 234 0x0107 235 | VehiclePropertyGroup:SYSTEM 236 | VehiclePropertyType:INT32_VEC 237 | VehicleArea:GLOBAL), 238 239 /** 240 * Fuel door location 241 * 242 * @change_mode VehiclePropertyChangeMode:STATIC 243 * @data_enum PortLocationType 244 * @access VehiclePropertyAccess:READ 245 */ 246 INFO_FUEL_DOOR_LOCATION = ( 247 0x0108 248 | VehiclePropertyGroup:SYSTEM 249 | VehiclePropertyType:INT32 250 | VehicleArea:GLOBAL), 251 252 /** 253 * EV port location 254 * 255 * @change_mode VehiclePropertyChangeMode:STATIC 256 * @access VehiclePropertyAccess:READ 257 * @data_enum PortLocationType 258 */ 259 INFO_EV_PORT_LOCATION = ( 260 0x0109 261 | VehiclePropertyGroup:SYSTEM 262 | VehiclePropertyType:INT32 263 | VehicleArea:GLOBAL), 264 265 /** 266 * Driver's seat location 267 * VHAL implementations must ignore the areaId. Use VehicleArea:GLOBAL. 268 * 269 * @change_mode VehiclePropertyChangeMode:STATIC 270 * @data_enum VehicleAreaSeat 271 * @access VehiclePropertyAccess:READ 272 */ 273 INFO_DRIVER_SEAT = ( 274 0x010A 275 | VehiclePropertyGroup:SYSTEM 276 | VehiclePropertyType:INT32 277 | VehicleArea:SEAT), 278 279 /** 280 * Exterior dimensions of vehicle. 281 * 282 * int32Values[0] = height 283 * int32Values[1] = length 284 * int32Values[2] = width 285 * int32Values[3] = width including mirrors 286 * int32Values[4] = wheel base 287 * int32Values[5] = track width front 288 * int32Values[6] = track width rear 289 * int32Values[7] = curb to curb turning radius 290 * 291 * @change_mode VehiclePropertyChangeMode:STATIC 292 * @access VehiclePropertyAccess:READ 293 * @unit VehicleUnit:MILLIMETER 294 */ 295 INFO_EXTERIOR_DIMENSIONS = ( 296 0x010B 297 | VehiclePropertyGroup:SYSTEM 298 | VehiclePropertyType:INT32_VEC 299 | VehicleArea:GLOBAL), 300 301 /** 302 * Multiple EV port locations 303 * 304 * Implement this property if the vehicle has multiple EV ports. 305 * Port locations are defined in PortLocationType. 306 * For example, a car has one port in front left and one port in rear left: 307 * int32Values[0] = PortLocationType::FRONT_LEFT 308 * int32Values[0] = PortLocationType::REAR_LEFT 309 * 310 * @change_mode VehiclePropertyChangeMode:STATIC 311 * @access VehiclePropertyAccess:READ 312 * @data_enum PortLocationType 313 */ 314 INFO_MULTI_EV_PORT_LOCATIONS = ( 315 0x010C 316 | VehiclePropertyGroup:SYSTEM 317 | VehiclePropertyType:INT32_VEC 318 | VehicleArea:GLOBAL), 319 320 /** 321 * Current odometer value of the vehicle 322 * 323 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 324 * @access VehiclePropertyAccess:READ 325 * @unit VehicleUnit:KILOMETER 326 */ 327 PERF_ODOMETER = ( 328 0x0204 329 | VehiclePropertyGroup:SYSTEM 330 | VehiclePropertyType:FLOAT 331 | VehicleArea:GLOBAL), 332 333 /** 334 * Speed of the vehicle 335 * 336 * The value must be positive when the vehicle is moving forward and negative when 337 * the vehicle is moving backward. This value is independent of gear value 338 * (CURRENT_GEAR or GEAR_SELECTION), for example, if GEAR_SELECTION is GEAR_NEUTRAL, 339 * PERF_VEHICLE_SPEED is positive when the vehicle is moving forward, negative when moving 340 * backward, and zero when not moving. 341 * 342 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 343 * @access VehiclePropertyAccess:READ 344 * @unit VehicleUnit:METER_PER_SEC 345 */ 346 PERF_VEHICLE_SPEED = ( 347 0x0207 348 | VehiclePropertyGroup:SYSTEM 349 | VehiclePropertyType:FLOAT 350 | VehicleArea:GLOBAL), 351 352 /** 353 * Speed of the vehicle for displays 354 * 355 * Some cars display a slightly slower speed than the actual speed. This is 356 * usually displayed on the speedometer. 357 * 358 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 359 * @access VehiclePropertyAccess:READ 360 * @unit VehicleUnit:METER_PER_SEC 361 */ 362 PERF_VEHICLE_SPEED_DISPLAY = ( 363 0x0208 364 | VehiclePropertyGroup:SYSTEM 365 | VehiclePropertyType:FLOAT 366 | VehicleArea:GLOBAL), 367 368 /** 369 * Front bicycle model steering angle for vehicle 370 * 371 * Angle is in degrees. Left is negative. 372 * 373 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 374 * @access VehiclePropertyAccess:READ 375 * @unit VehicleUnit:DEGREES 376 */ 377 PERF_STEERING_ANGLE = ( 378 0x0209 379 | VehiclePropertyGroup:SYSTEM 380 | VehiclePropertyType:FLOAT 381 | VehicleArea:GLOBAL), 382 383 /** 384 * Rear bicycle model steering angle for vehicle 385 * 386 * Angle is in degrees. Left is negative. 387 * 388 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 389 * @access VehiclePropertyAccess:READ 390 * @unit VehicleUnit:DEGREES 391 */ 392 PERF_REAR_STEERING_ANGLE = ( 393 0x0210 394 | VehiclePropertyGroup:SYSTEM 395 | VehiclePropertyType:FLOAT 396 | VehicleArea:GLOBAL), 397 398 /** 399 * Temperature of engine coolant 400 * 401 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 402 * @access VehiclePropertyAccess:READ 403 * @unit VehicleUnit:CELSIUS 404 */ 405 ENGINE_COOLANT_TEMP = ( 406 0x0301 407 | VehiclePropertyGroup:SYSTEM 408 | VehiclePropertyType:FLOAT 409 | VehicleArea:GLOBAL), 410 411 /** 412 * Engine oil level 413 * 414 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 415 * @access VehiclePropertyAccess:READ 416 * @data_enum VehicleOilLevel 417 */ 418 ENGINE_OIL_LEVEL = ( 419 0x0303 420 | VehiclePropertyGroup:SYSTEM 421 | VehiclePropertyType:INT32 422 | VehicleArea:GLOBAL), 423 424 /** 425 * Temperature of engine oil 426 * 427 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 428 * @access VehiclePropertyAccess:READ 429 * @unit VehicleUnit:CELSIUS 430 */ 431 ENGINE_OIL_TEMP = ( 432 0x0304 433 | VehiclePropertyGroup:SYSTEM 434 | VehiclePropertyType:FLOAT 435 | VehicleArea:GLOBAL), 436 437 /** 438 * Engine rpm 439 * 440 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 441 * @access VehiclePropertyAccess:READ 442 * @unit VehicleUnit:RPM 443 */ 444 ENGINE_RPM = ( 445 0x0305 446 | VehiclePropertyGroup:SYSTEM 447 | VehiclePropertyType:FLOAT 448 | VehicleArea:GLOBAL), 449 450 /** 451 * Reports wheel ticks 452 * 453 * The first element in the vector is a reset count. A reset indicates 454 * previous tick counts are not comparable with this and future ones. Some 455 * sort of discontinuity in tick counting has occurred. 456 * 457 * The next four elements represent ticks for individual wheels in the 458 * following order: front left, front right, rear right, rear left. All 459 * tick counts are cumulative. Tick counts increment when the vehicle 460 * moves forward, and decrement when vehicles moves in reverse. The ticks 461 * should be reset to 0 when the vehicle is started by the user. 462 * 463 * int64Values[0] = reset count 464 * int64Values[1] = front left ticks 465 * int64Values[2] = front right ticks 466 * int64Values[3] = rear right ticks 467 * int64Values[4] = rear left ticks 468 * 469 * configArray is used to indicate the micrometers-per-wheel-tick values and 470 * which wheels are supported. Each micrometers-per-wheel-tick value is static (i.e. will not 471 * update based on wheel's status) and a best approximation. For example, if a vehicle has 472 * multiple rim/tire size options, the micrometers-per-wheel-tick values are set to those for 473 * the typically expected rim/tire size. configArray is set as follows: 474 * 475 * configArray[0], bits [0:3] = supported wheels. Uses enum Wheel. 476 * configArray[1] = micrometers per front left wheel tick 477 * configArray[2] = micrometers per front right wheel tick 478 * configArray[3] = micrometers per rear right wheel tick 479 * configArray[4] = micrometers per rear left wheel tick 480 * 481 * NOTE: If a wheel is not supported, its value shall always be set to 0. 482 * 483 * VehiclePropValue.timestamp must be correctly filled in. 484 * 485 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 486 * @access VehiclePropertyAccess:READ 487 */ 488 WHEEL_TICK = ( 489 0x0306 490 | VehiclePropertyGroup:SYSTEM 491 | VehiclePropertyType:INT64_VEC 492 | VehicleArea:GLOBAL), 493 494 495 /** 496 * Fuel remaining in the the vehicle, in milliliters 497 * 498 * Value may not exceed INFO_FUEL_CAPACITY 499 * 500 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 501 * @access VehiclePropertyAccess:READ 502 * @unit VehicleUnit:MILLILITER 503 */ 504 FUEL_LEVEL = ( 505 0x0307 506 | VehiclePropertyGroup:SYSTEM 507 | VehiclePropertyType:FLOAT 508 | VehicleArea:GLOBAL), 509 510 /** 511 * Fuel door open 512 * 513 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 514 * @access VehiclePropertyAccess:READ_WRITE 515 */ 516 FUEL_DOOR_OPEN = ( 517 0x0308 518 | VehiclePropertyGroup:SYSTEM 519 | VehiclePropertyType:BOOLEAN 520 | VehicleArea:GLOBAL), 521 522 /** 523 * EV battery level in WH, if EV or hybrid 524 * 525 * Value may not exceed INFO_EV_BATTERY_CAPACITY 526 * 527 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 528 * @access VehiclePropertyAccess:READ 529 * @unit VehicleUnit:WH 530 */ 531 EV_BATTERY_LEVEL = ( 532 0x0309 533 | VehiclePropertyGroup:SYSTEM 534 | VehiclePropertyType:FLOAT 535 | VehicleArea:GLOBAL), 536 537 /** 538 * EV charge port open 539 * 540 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 541 * @access VehiclePropertyAccess:READ_WRITE 542 */ 543 EV_CHARGE_PORT_OPEN = ( 544 0x030A 545 | VehiclePropertyGroup:SYSTEM 546 | VehiclePropertyType:BOOLEAN 547 | VehicleArea:GLOBAL), 548 549 /** 550 * EV charge port connected 551 * 552 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 553 * @access VehiclePropertyAccess:READ 554 */ 555 EV_CHARGE_PORT_CONNECTED = ( 556 0x030B 557 | VehiclePropertyGroup:SYSTEM 558 | VehiclePropertyType:BOOLEAN 559 | VehicleArea:GLOBAL), 560 561 /** 562 * EV instantaneous charge rate in milliwatts 563 * 564 * Positive value indicates battery is being charged. 565 * Negative value indicates battery being discharged. 566 * 567 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 568 * @access VehiclePropertyAccess:READ 569 * @unit VehicleUnit:MW 570 */ 571 EV_BATTERY_INSTANTANEOUS_CHARGE_RATE = ( 572 0x030C 573 | VehiclePropertyGroup:SYSTEM 574 | VehiclePropertyType:FLOAT 575 | VehicleArea:GLOBAL), 576 577 /** 578 * Range remaining 579 * 580 * Meters remaining of fuel and charge. Range remaining shall account for 581 * all energy sources in a vehicle. For example, a hybrid car's range will 582 * be the sum of the ranges based on fuel and battery. 583 * 584 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 585 * @access VehiclePropertyAccess:READ_WRITE 586 * @unit VehicleUnit:METER 587 */ 588 RANGE_REMAINING = ( 589 0x0308 590 | VehiclePropertyGroup:SYSTEM 591 | VehiclePropertyType:FLOAT 592 | VehicleArea:GLOBAL), 593 594 /** 595 * Tire pressure 596 * 597 * Each tires is identified by its areaConfig.areaId config and their 598 * minFloatValue/maxFloatValue are used to store OEM recommended pressure 599 * range. 600 * The Min value in the areaConfig data represents the lower bound of 601 * the recommended tire pressure. 602 * The Max value in the areaConfig data represents the upper bound of 603 * the recommended tire pressure. 604 * For example: 605 * The following areaConfig indicates the recommended tire pressure 606 * of left_front tire is from 200.0 KILOPASCAL to 240.0 KILOPASCAL. 607 * .areaConfigs = { 608 * VehicleAreaConfig { 609 * .areaId = VehicleAreaWheel::LEFT_FRONT, 610 * .minFloatValue = 200.0, 611 * .maxFloatValue = 240.0, 612 * } 613 * }, 614 * 615 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 616 * @access VehiclePropertyAccess:READ 617 * @unit VehicleUnit:KILOPASCAL 618 */ 619 TIRE_PRESSURE = ( 620 0x0309 621 | VehiclePropertyGroup:SYSTEM 622 | VehiclePropertyType:FLOAT 623 | VehicleArea:WHEEL), 624 625 /** 626 * Critically low tire pressure 627 * 628 * This property indicates the critically low pressure threshold for each tire. 629 * It indicates when it is time for tires to be replaced or fixed. The value 630 * must be less than or equal to minFloatValue in TIRE_PRESSURE. 631 * Minimum and maximum property values (that is, minFloatValue, maxFloatValue) 632 * are not applicable to this property. 633 * 634 * @change_mode VehiclePropertyChangeMode:STATIC 635 * @access VehiclePropertyAccess:READ 636 * @unit VehicleUnit:KILOPASCAL 637 */ 638 CRITICALLY_LOW_TIRE_PRESSURE = ( 639 0x030A 640 | VehiclePropertyGroup:SYSTEM 641 | VehiclePropertyType:FLOAT 642 | VehicleArea:WHEEL), 643 644 /** 645 * Currently selected gear 646 * 647 * This is the gear selected by the user. 648 * 649 * Values in the config data must represent the list of supported gears 650 * for this vehicle. For example, config data for an automatic transmission 651 * must contain {GEAR_NEUTRAL, GEAR_REVERSE, GEAR_PARK, GEAR_DRIVE, 652 * GEAR_1, GEAR_2,...} and for manual transmission the list must be 653 * {GEAR_NEUTRAL, GEAR_REVERSE, GEAR_1, GEAR_2,...} 654 * 655 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 656 * @access VehiclePropertyAccess:READ 657 * @data_enum VehicleGear 658 */ 659 GEAR_SELECTION = ( 660 0x0400 661 | VehiclePropertyGroup:SYSTEM 662 | VehiclePropertyType:INT32 663 | VehicleArea:GLOBAL), 664 665 /** 666 * Current gear. In non-manual case, selected gear may not 667 * match the current gear. For example, if the selected gear is GEAR_DRIVE, 668 * the current gear will be one of GEAR_1, GEAR_2 etc, which reflects 669 * the actual gear the transmission is currently running in. 670 * 671 * Values in the config data must represent the list of supported gears 672 * for this vehicle. For example, config data for an automatic transmission 673 * must contain {GEAR_NEUTRAL, GEAR_REVERSE, GEAR_PARK, GEAR_1, GEAR_2,...} 674 * and for manual transmission the list must be 675 * {GEAR_NEUTRAL, GEAR_REVERSE, GEAR_1, GEAR_2,...}. This list need not be the 676 * same as that of the supported gears reported in GEAR_SELECTION. 677 * 678 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 679 * @access VehiclePropertyAccess:READ 680 * @data_enum VehicleGear 681 */ 682 CURRENT_GEAR = ( 683 0x0401 684 | VehiclePropertyGroup:SYSTEM 685 | VehiclePropertyType:INT32 686 | VehicleArea:GLOBAL), 687 688 /** 689 * Parking brake state. 690 * 691 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 692 * @access VehiclePropertyAccess:READ 693 */ 694 PARKING_BRAKE_ON = ( 695 0x0402 696 | VehiclePropertyGroup:SYSTEM 697 | VehiclePropertyType:BOOLEAN 698 | VehicleArea:GLOBAL), 699 700 /** 701 * Auto-apply parking brake. 702 * 703 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 704 * @access VehiclePropertyAccess:READ 705 */ 706 PARKING_BRAKE_AUTO_APPLY = ( 707 0x0403 708 | VehiclePropertyGroup:SYSTEM 709 | VehiclePropertyType:BOOLEAN 710 | VehicleArea:GLOBAL), 711 712 /** 713 * Warning for fuel low level. 714 * 715 * This property corresponds to the low fuel warning on the dashboard. 716 * Once FUEL_LEVEL_LOW is set, it should not be cleared until more fuel is 717 * added to the vehicle. This property may take into account all fuel 718 * sources for a vehicle - for example: 719 * 720 * For a gas powered vehicle, this property is based soley on gas level. 721 * For a battery powered vehicle, this property is based solely on battery level. 722 * For a hybrid vehicle, this property may be based on the combination of gas and battery 723 * levels, at the OEM's discretion. 724 * 725 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 726 * @access VehiclePropertyAccess:READ 727 */ 728 FUEL_LEVEL_LOW = ( 729 0x0405 730 | VehiclePropertyGroup:SYSTEM 731 | VehiclePropertyType:BOOLEAN 732 | VehicleArea:GLOBAL), 733 734 /** 735 * Night mode 736 * 737 * True indicates that the night mode sensor has detected that the car cabin environment has 738 * low light. The platform could use this, for example, to enable appropriate UI for 739 * better viewing in dark or low light environments. 740 * 741 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 742 * @access VehiclePropertyAccess:READ 743 */ 744 NIGHT_MODE = ( 745 0x0407 746 | VehiclePropertyGroup:SYSTEM 747 | VehiclePropertyType:BOOLEAN 748 | VehicleArea:GLOBAL), 749 750 /** 751 * State of the vehicles turn signals 752 * 753 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 754 * @access VehiclePropertyAccess:READ 755 * @data_enum VehicleTurnSignal 756 */ 757 TURN_SIGNAL_STATE = ( 758 0x0408 759 | VehiclePropertyGroup:SYSTEM 760 | VehiclePropertyType:INT32 761 | VehicleArea:GLOBAL), 762 763 /** 764 * Represents ignition state 765 * 766 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 767 * @access VehiclePropertyAccess:READ 768 * @data_enum VehicleIgnitionState 769 */ 770 IGNITION_STATE = ( 771 0x0409 772 | VehiclePropertyGroup:SYSTEM 773 | VehiclePropertyType:INT32 774 | VehicleArea:GLOBAL), 775 776 /** 777 * ABS is active 778 * 779 * Set to true when ABS is active. Reset to false when ABS is off. This 780 * property may be intermittently set (pulsing) based on the real-time 781 * state of the ABS system. 782 * 783 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 784 * @access VehiclePropertyAccess:READ 785 */ 786 ABS_ACTIVE = ( 787 0x040A 788 | VehiclePropertyGroup:SYSTEM 789 | VehiclePropertyType:BOOLEAN 790 | VehicleArea:GLOBAL), 791 792 /** 793 * Traction Control is active 794 * 795 * Set to true when traction control (TC) is active. Reset to false when 796 * TC is off. This property may be intermittently set (pulsing) based on 797 * the real-time state of the TC system. 798 * 799 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 800 * @access VehiclePropertyAccess:READ 801 */ 802 TRACTION_CONTROL_ACTIVE = ( 803 0x040B 804 | VehiclePropertyGroup:SYSTEM 805 | VehiclePropertyType:BOOLEAN 806 | VehicleArea:GLOBAL), 807 808 /* 809 * HVAC Properties 810 * 811 * Additional rules for mapping non-GLOBAL VehicleArea type HVAC properties 812 * to AreaIDs: 813 * - Every “area” for a specific VehicleArea type that is affected by the 814 * property, must be included in an area ID for that property. 815 * 816 * Example 1: A car has two front seats (ROW_1_LEFT, ROW_1_RIGHT) and three 817 * back seats (ROW_2_LEFT, ROW_2_CENTER, ROW_2_RIGHT). There are two 818 * temperature control units -- driver side and passenger side. 819 * - A valid mapping set of AreaIDs for HVAC_TEMPERATURE_SET would be a 820 * two element array: 821 * - ROW_1_LEFT | ROW_2_LEFT 822 * - ROW_1_RIGHT | ROW_2_CENTER | ROW_2_RIGHT 823 * - An alternative mapping for the same hardware configuration would be: 824 * - ROW_1_LEFT | ROW_2_CENTER | ROW_2_LEFT 825 * - ROW_1_RIGHT | ROW_2_RIGHT 826 * The temperature controllers are assigned to the seats which they 827 * "most influence", but every seat must be included exactly once. The 828 * assignment of the center rear seat to the left or right AreaID may seem 829 * arbitrary, but the inclusion of every seat in exactly one AreaID ensures 830 * that the seats in the car are all expressed and that a "reasonable" way 831 * to affect each seat is available. 832 * 833 * Example 2: A car has three seat rows with two seats in the front row (ROW_1_LEFT, 834 * ROW_1_RIGHT) and three seats in the second (ROW_2_LEFT, ROW_2_CENTER, 835 * ROW_2_RIGHT) and third rows (ROW_3_LEFT, ROW_3_CENTER, ROW_3_RIGHT). There 836 * are three temperature control units -- driver side, passenger side, and rear. 837 * - A reasonable way to map HVAC_TEMPERATURE_SET to AreaIDs is a three 838 * element array: 839 * - ROW_1_LEFT 840 * - ROW_1_RIGHT 841 * - ROW_2_LEFT | ROW_2_CENTER | ROW_2_RIGHT | ROW_3_LEFT | ROW_3_CENTER | ROW_3_RIGHT 842 * 843 * Example 3: A car has two front seats (ROW_1_LEFT, ROW_1_RIGHT) and three 844 * back seats (ROW_2_LEFT, ROW_2_CENTER, ROW_2_RIGHT). Suppose the car 845 * supports HVAC_AUTO_ON for just the two front seats. 846 * - A valid mapping set of AreaIDs for HVAC_AUTO_ON would be: 847 * - ROW_1_LEFT | ROW_1_RIGHT 848 * - If HVAC_AUTO_ON had two separate control units for the driver side 849 * and passenger side, an alternative mapping would be: 850 * - ROW_1_LEFT 851 * - ROW_1_RIGHT 852 */ 853 854 /** 855 * Fan speed setting 856 * 857 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 858 * @access VehiclePropertyAccess:READ_WRITE 859 */ 860 HVAC_FAN_SPEED = ( 861 0x0500 862 | VehiclePropertyGroup:SYSTEM 863 | VehiclePropertyType:INT32 864 | VehicleArea:SEAT), 865 866 /** 867 * Fan direction setting 868 * 869 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 870 * @access VehiclePropertyAccess:READ_WRITE 871 * @data_enum VehicleHvacFanDirection 872 */ 873 HVAC_FAN_DIRECTION = ( 874 0x0501 875 | VehiclePropertyGroup:SYSTEM 876 | VehiclePropertyType:INT32 877 | VehicleArea:SEAT), 878 879 /** 880 * HVAC current temperature. 881 * 882 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 883 * @access VehiclePropertyAccess:READ 884 * @unit VehicleUnit:CELSIUS 885 */ 886 HVAC_TEMPERATURE_CURRENT = ( 887 0x0502 888 | VehiclePropertyGroup:SYSTEM 889 | VehiclePropertyType:FLOAT 890 | VehicleArea:SEAT), 891 892 /** 893 * HVAC, target temperature set. 894 * 895 * The configArray is used to indicate the valid values for HVAC in Fahrenheit and Celsius. 896 * Android might use it in the HVAC app UI. 897 * The configArray is set as follows: 898 * configArray[0] = [the lower bound of the supported temperature in Celsius] * 10. 899 * configArray[1] = [the upper bound of the supported temperature in Celsius] * 10. 900 * configArray[2] = [the increment in Celsius] * 10. 901 * configArray[3] = [the lower bound of the supported temperature in Fahrenheit] * 10. 902 * configArray[4] = [the upper bound of the supported temperature in Fahrenheit] * 10. 903 * configArray[5] = [the increment in Fahrenheit] * 10. 904 * For example, if the vehicle supports temperature values as: 905 * [16.0, 16.5, 17.0 ,..., 28.0] in Celsius 906 * [60.5, 61.5, 62.5 ,..., 85.5] in Fahrenheit. 907 * The configArray should be configArray = {160, 280, 5, 605, 825, 10}. 908 * 909 * If the vehicle supports HVAC_TEMPERATURE_VALUE_SUGGESTION, the application can use 910 * that property to get the suggested value before setting HVAC_TEMPERATURE_SET. Otherwise, 911 * the application may choose the value in HVAC_TEMPERATURE_SET configArray by itself. 912 * 913 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 914 * @access VehiclePropertyAccess:READ_WRITE 915 * @unit VehicleUnit:CELSIUS 916 */ 917 HVAC_TEMPERATURE_SET = ( 918 0x0503 919 | VehiclePropertyGroup:SYSTEM 920 | VehiclePropertyType:FLOAT 921 | VehicleArea:SEAT), 922 923 /** 924 * Fan-based defrost for designated window. 925 * 926 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 927 * @access VehiclePropertyAccess:READ_WRITE 928 */ 929 HVAC_DEFROSTER = ( 930 0x0504 931 | VehiclePropertyGroup:SYSTEM 932 | VehiclePropertyType:BOOLEAN 933 | VehicleArea:WINDOW), 934 935 /** 936 * On/off AC for designated areaId 937 * 938 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 939 * @access VehiclePropertyAccess:READ_WRITE 940 * @config_flags Supported areaIds 941 */ 942 HVAC_AC_ON = ( 943 0x0505 944 | VehiclePropertyGroup:SYSTEM 945 | VehiclePropertyType:BOOLEAN 946 | VehicleArea:SEAT), 947 948 /** 949 * On/off max AC 950 * 951 * When MAX AC is on, the ECU may adjust the vent position, fan speed, 952 * temperature, etc as necessary to cool the vehicle as quickly as possible. 953 * Any parameters modified as a side effect of turning on/off the MAX AC 954 * parameter shall generate onPropertyEvent() callbacks to the VHAL. 955 * 956 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 957 * @access VehiclePropertyAccess:READ_WRITE 958 */ 959 HVAC_MAX_AC_ON = ( 960 0x0506 961 | VehiclePropertyGroup:SYSTEM 962 | VehiclePropertyType:BOOLEAN 963 | VehicleArea:SEAT), 964 965 /** 966 * On/off max defrost 967 * 968 * When MAX DEFROST is on, the ECU may adjust the vent position, fan speed, 969 * temperature, etc as necessary to defrost the windows as quickly as 970 * possible. Any parameters modified as a side effect of turning on/off 971 * the MAX DEFROST parameter shall generate onPropertyEvent() callbacks to 972 * the VHAL. 973 * The AreaIDs for HVAC_MAX_DEFROST_ON indicate MAX DEFROST can be controlled 974 * in the area. 975 * For example: 976 * areaConfig.areaId = {ROW_1_LEFT | ROW_1_RIGHT} indicates HVAC_MAX_DEFROST_ON 977 * only can be controlled for the front rows. 978 * 979 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 980 * @access VehiclePropertyAccess:READ_WRITE 981 */ 982 HVAC_MAX_DEFROST_ON = ( 983 0x0507 984 | VehiclePropertyGroup:SYSTEM 985 | VehiclePropertyType:BOOLEAN 986 | VehicleArea:SEAT), 987 988 /** 989 * Recirculation on/off 990 * 991 * Controls the supply of exterior air to the cabin. Recirc “on” means the 992 * majority of the airflow into the cabin is originating in the cabin. 993 * Recirc “off” means the majority of the airflow into the cabin is coming 994 * from outside the car. 995 * 996 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 997 * @access VehiclePropertyAccess:READ_WRITE 998 */ 999 HVAC_RECIRC_ON = ( 1000 0x0508 1001 | VehiclePropertyGroup:SYSTEM 1002 | VehiclePropertyType:BOOLEAN 1003 | VehicleArea:SEAT), 1004 1005 /** 1006 * Enable temperature coupling between areas. 1007 * 1008 * The AreaIDs for HVAC_DUAL_ON property shall contain a combination of 1009 * HVAC_TEMPERATURE_SET AreaIDs that can be coupled together. If 1010 * HVAC_TEMPERATURE_SET is mapped to AreaIDs [a_1, a_2, ..., a_n], and if 1011 * HVAC_DUAL_ON can be enabled to couple a_i and a_j, then HVAC_DUAL_ON 1012 * property must be mapped to [a_i | a_j]. Further, if a_k and a_l can also 1013 * be coupled together separately then HVAC_DUAL_ON must be mapped to 1014 * [a_i | a_j, a_k | a_l]. 1015 * 1016 * Example: A car has two front seats (ROW_1_LEFT, ROW_1_RIGHT) and three 1017 * back seats (ROW_2_LEFT, ROW_2_CENTER, ROW_2_RIGHT). There are two 1018 * temperature control units -- driver side and passenger side -- which can 1019 * be optionally synchronized. This may be expressed in the AreaIDs this way: 1020 * - HVAC_TEMPERATURE_SET->[ROW_1_LEFT | ROW_2_LEFT, ROW_1_RIGHT | ROW_2_CENTER | ROW_2_RIGHT] 1021 * - HVAC_DUAL_ON->[ROW_1_LEFT | ROW_2_LEFT | ROW_1_RIGHT | ROW_2_CENTER | ROW_2_RIGHT] 1022 * 1023 * When the property is enabled, the ECU must synchronize the temperature 1024 * for the affected areas. Any parameters modified as a side effect 1025 * of turning on/off the DUAL_ON parameter shall generate 1026 * onPropertyEvent() callbacks to the VHAL. In addition, if setting 1027 * a temperature (i.e. driver's temperature) changes another temperature 1028 * (i.e. front passenger's temperature), then the appropriate 1029 * onPropertyEvent() callbacks must be generated. If a user changes a 1030 * temperature that breaks the coupling (e.g. setting the passenger 1031 * temperature independently) then the VHAL must send the appropriate 1032 * onPropertyEvent() callbacks (i.e. HVAC_DUAL_ON = false, 1033 * HVAC_TEMPERATURE_SET[AreaID] = xxx, etc). 1034 * 1035 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1036 * @access VehiclePropertyAccess:READ_WRITE 1037 */ 1038 HVAC_DUAL_ON = ( 1039 0x0509 1040 | VehiclePropertyGroup:SYSTEM 1041 | VehiclePropertyType:BOOLEAN 1042 | VehicleArea:SEAT), 1043 1044 /** 1045 * On/off automatic mode 1046 * 1047 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1048 * @access VehiclePropertyAccess:READ_WRITE 1049 */ 1050 HVAC_AUTO_ON = ( 1051 0x050A 1052 | VehiclePropertyGroup:SYSTEM 1053 | VehiclePropertyType:BOOLEAN 1054 | VehicleArea:SEAT), 1055 1056 /** 1057 * Seat heating/cooling 1058 * 1059 * Negative values indicate cooling. 1060 * 0 indicates off. 1061 * Positive values indicate heating. 1062 * 1063 * Some vehicles may have multiple levels of heating and cooling. The 1064 * min/max range defines the allowable range and number of steps in each 1065 * direction. 1066 * 1067 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1068 * @access VehiclePropertyAccess:READ_WRITE 1069 */ 1070 HVAC_SEAT_TEMPERATURE = ( 1071 0x050B 1072 | VehiclePropertyGroup:SYSTEM 1073 | VehiclePropertyType:INT32 1074 | VehicleArea:SEAT), 1075 1076 /** 1077 * Side Mirror Heat 1078 * 1079 * Increasing values denote higher heating levels for side mirrors. 1080 * The Max value in the config data represents the highest heating level. 1081 * The Min value in the config data MUST be zero and indicates no heating. 1082 * 1083 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1084 * @access VehiclePropertyAccess:READ_WRITE 1085 */ 1086 HVAC_SIDE_MIRROR_HEAT = ( 1087 0x050C 1088 | VehiclePropertyGroup:SYSTEM 1089 | VehiclePropertyType:INT32 1090 | VehicleArea:MIRROR), 1091 1092 /** 1093 * Steering Wheel Heating/Cooling 1094 * 1095 * Sets the amount of heating/cooling for the steering wheel 1096 * config data Min and Max MUST be set appropriately. 1097 * Positive value indicates heating. 1098 * Negative value indicates cooling. 1099 * 0 indicates temperature control is off. 1100 * 1101 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1102 * @access VehiclePropertyAccess:READ_WRITE 1103 */ 1104 HVAC_STEERING_WHEEL_HEAT = ( 1105 0x050D 1106 | VehiclePropertyGroup:SYSTEM 1107 | VehiclePropertyType:INT32 1108 | VehicleArea:GLOBAL), 1109 1110 /** 1111 * Temperature units for display 1112 * 1113 * Indicates whether the vehicle is displaying temperature to the user as 1114 * Celsius or Fahrenheit. 1115 * VehiclePropConfig.configArray is used to indicate the supported temperature display units. 1116 * For example: configArray[0] = CELSIUS 1117 * configArray[1] = FAHRENHEIT 1118 * 1119 * This parameter MAY be used for displaying any HVAC temperature in the system. 1120 * Values must be one of VehicleUnit::CELSIUS or VehicleUnit::FAHRENHEIT 1121 * Note that internally, all temperatures are represented in floating point Celsius. 1122 * 1123 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1124 * @access VehiclePropertyAccess:READ_WRITE 1125 * @data_enum VehicleUnit 1126 */ 1127 HVAC_TEMPERATURE_DISPLAY_UNITS = ( 1128 0x050E 1129 | VehiclePropertyGroup:SYSTEM 1130 | VehiclePropertyType:INT32 1131 | VehicleArea:GLOBAL), 1132 1133 /** 1134 * Actual fan speed 1135 * 1136 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1137 * @access VehiclePropertyAccess:READ 1138 */ 1139 HVAC_ACTUAL_FAN_SPEED_RPM = ( 1140 0x050F 1141 | VehiclePropertyGroup:SYSTEM 1142 | VehiclePropertyType:INT32 1143 | VehicleArea:SEAT), 1144 1145 /** 1146 * Represents global power state for HVAC. Setting this property to false 1147 * MAY mark some properties that control individual HVAC features/subsystems 1148 * to UNAVAILABLE state. Setting this property to true MAY mark some 1149 * properties that control individual HVAC features/subsystems to AVAILABLE 1150 * state (unless any/all of them are UNAVAILABLE on their own individual 1151 * merits). 1152 * 1153 * [Definition] HvacPower_DependentProperties: Properties that need HVAC to be 1154 * powered on in order to enable their functionality. For example, in some cars, 1155 * in order to turn on the AC, HVAC must be powered on first. 1156 * 1157 * HvacPower_DependentProperties list must be set in the 1158 * VehiclePropConfig.configArray. HvacPower_DependentProperties must only contain 1159 * properties that are associated with VehicleArea:SEAT. Properties that are not 1160 * associated with VehicleArea:SEAT, for example, HVAC_DEFROSTER, must never 1161 * depend on HVAC_POWER_ON property and must never be part of 1162 * HvacPower_DependentProperties list. 1163 * 1164 * AreaID mapping for HVAC_POWER_ON property must contain all AreaIDs that 1165 * HvacPower_DependentProperties are mapped to. 1166 * 1167 * Example 1: A car has two front seats (ROW_1_LEFT, ROW_1_RIGHT) and three back 1168 * seats (ROW_2_LEFT, ROW_2_CENTER, ROW_2_RIGHT). If the HVAC features (AC, 1169 * Temperature etc.) throughout the car are dependent on a single HVAC power 1170 * controller then HVAC_POWER_ON must be mapped to 1171 * [ROW_1_LEFT | ROW_1_RIGHT | ROW_2_LEFT | ROW_2_CENTER | ROW_2_RIGHT]. 1172 * 1173 * Example 2: A car has two seats in the front row (ROW_1_LEFT, ROW_1_RIGHT) and 1174 * three seats in the second (ROW_2_LEFT, ROW_2_CENTER, ROW_2_RIGHT) and third 1175 * rows (ROW_3_LEFT, ROW_3_CENTER, ROW_3_RIGHT). If the car has temperature 1176 * controllers in the front row which can operate entirely independently of 1177 * temperature controllers in the back of the vehicle, then HVAC_POWER_ON 1178 * must be mapped to a two element array: 1179 * - ROW_1_LEFT | ROW_1_RIGHT 1180 * - ROW_2_LEFT | ROW_2_CENTER | ROW_2_RIGHT | ROW_3_LEFT | ROW_3_CENTER | ROW_3_RIGHT 1181 * 1182 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1183 * @access VehiclePropertyAccess:READ_WRITE 1184 */ 1185 HVAC_POWER_ON = ( 1186 0x0510 1187 | VehiclePropertyGroup:SYSTEM 1188 | VehiclePropertyType:BOOLEAN 1189 | VehicleArea:SEAT), 1190 1191 /** 1192 * Fan Positions Available 1193 * 1194 * This is a bit mask of fan positions available for the zone. Each 1195 * available fan direction is denoted by a separate entry in the vector. A 1196 * fan direction may have multiple bits from vehicle_hvac_fan_direction set. 1197 * For instance, a typical car may have the following fan positions: 1198 * - FAN_DIRECTION_FACE (0x1) 1199 * - FAN_DIRECTION_FLOOR (0x2) 1200 * - FAN_DIRECTION_FACE | FAN_DIRECTION_FLOOR (0x3) 1201 * - FAN_DIRECTION_DEFROST (0x4) 1202 * - FAN_DIRECTION_FLOOR | FAN_DIRECTION_DEFROST (0x6) 1203 * 1204 * @change_mode VehiclePropertyChangeMode:STATIC 1205 * @access VehiclePropertyAccess:READ 1206 * @data_enum VehicleHvacFanDirection 1207 */ 1208 HVAC_FAN_DIRECTION_AVAILABLE = ( 1209 0x0511 1210 | VehiclePropertyGroup:SYSTEM 1211 | VehiclePropertyType:INT32_VEC 1212 | VehicleArea:SEAT), 1213 1214 /** 1215 * Automatic recirculation on/off 1216 * 1217 * When automatic recirculation is ON, the HVAC system may automatically 1218 * switch to recirculation mode if the vehicle detects poor incoming air 1219 * quality. 1220 * 1221 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1222 * @access VehiclePropertyAccess:READ_WRITE 1223 */ 1224 HVAC_AUTO_RECIRC_ON = ( 1225 0x0512 1226 | VehiclePropertyGroup:SYSTEM 1227 | VehiclePropertyType:BOOLEAN 1228 | VehicleArea:SEAT), 1229 1230 /** 1231 * Seat ventilation 1232 * 1233 * 0 indicates off. 1234 * Positive values indicates ventilation level. 1235 * 1236 * Used by HVAC apps and Assistant to enable, change, or read state of seat 1237 * ventilation. This is different than seating cooling. It can be on at the 1238 * same time as cooling, or not. 1239 * 1240 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1241 * @access VehiclePropertyAccess:READ_WRITE 1242 */ 1243 HVAC_SEAT_VENTILATION = ( 1244 0x0513 1245 | VehiclePropertyGroup:SYSTEM 1246 | VehiclePropertyType:INT32 1247 | VehicleArea:SEAT), 1248 1249 /** 1250 * Electric defrosters' status 1251 * 1252 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1253 * @access VehiclePropertyAccess:READ_WRITE 1254 */ 1255 HVAC_ELECTRIC_DEFROSTER_ON = ( 1256 0x0514 1257 | VehiclePropertyGroup:SYSTEM 1258 | VehiclePropertyType:BOOLEAN 1259 | VehicleArea:WINDOW), 1260 1261 /** 1262 * Suggested values for setting HVAC temperature. 1263 * 1264 * Implement the property to help applications understand the closest supported temperature 1265 * value in Celsius or Fahrenheit. 1266 * 1267 * floatValues[0] = the requested value that an application wants to set a temperature to. 1268 * floatValues[1] = the unit for floatValues[0]. It should be one of 1269 * {VehicleUnit:CELSIUS, VehicleUnit:FAHRENHEIT}. 1270 * floatValues[2] = the value OEMs suggested in CELSIUS. This value is not included 1271 * in the request. 1272 * floatValues[3] = the value OEMs suggested in FAHRENHEIT. This value is not included 1273 * in the request. 1274 * 1275 * An application calls set(VehiclePropValue propValue) with the requested value and unit for 1276 * the value. OEMs need to return the suggested values in floatValues[2] and floatValues[3] by 1277 * onPropertyEvent() callbacks. 1278 * 1279 * For example, when a user uses the voice assistant to set HVAC temperature to 66.2 in 1280 * Fahrenheit. 1281 * First, an application will set this property with the value 1282 * [66.2, (float)VehicleUnit:FAHRENHEIT,0,0]. 1283 * If OEMs suggest to set 19.0 in Celsius or 66.5 in Fahrenheit for user's request, then VHAL 1284 * must generate a callback with property value 1285 * [66.2, (float)VehicleUnit:FAHRENHEIT, 19.0, 66.5]. After the voice assistant gets the 1286 * callback, it will inform the user and set HVAC temperature to the suggested value. 1287 * 1288 * Another example, an application receives 21 Celsius as the current temperature value by 1289 * querying HVC_TEMPERATURE_SET. But the application wants to know what value is displayed on 1290 * the car's UI in Fahrenheit. 1291 * For this, the application sets the property to [21, (float)VehicleUnit:CELSIUS, 0, 0]. If 1292 * the suggested value by the OEM for 21 Celsius is 70 Fahrenheit, then VHAL must generate a 1293 * callback with property value [21, (float)VehicleUnit:CELSIUS, 21.0, 70.0]. 1294 * In this case, the application can know that the value is 70.0 Fahrenheit in the car’s UI. 1295 * 1296 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1297 * @access VehiclePropertyAccess:READ_WRITE 1298 */ 1299 HVAC_TEMPERATURE_VALUE_SUGGESTION = ( 1300 0x0515 1301 | VehiclePropertyGroup:SYSTEM 1302 | VehiclePropertyType:FLOAT_VEC 1303 | VehicleArea:GLOBAL), 1304 1305 /** 1306 * Distance units for display 1307 * 1308 * Indicates which units the car is using to display distances to the user. Eg. Mile, Meter 1309 * Kilometer. 1310 * 1311 * Distance units are defined in VehicleUnit. 1312 * VehiclePropConfig.configArray is used to indicate the supported distance display units. 1313 * For example: configArray[0] = METER 1314 * configArray[1] = KILOMETER 1315 * configArray[2] = MILE 1316 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1317 * @access VehiclePropertyAccess:READ_WRITE 1318 * @data_enum VehicleUnit 1319 */ 1320 DISTANCE_DISPLAY_UNITS = ( 1321 0x0600 1322 | VehiclePropertyGroup:SYSTEM 1323 | VehiclePropertyType:INT32 1324 | VehicleArea:GLOBAL), 1325 1326 /** 1327 * Fuel volume units for display 1328 * 1329 * Indicates which units the car is using to display fuel volume to the user. Eg. Liter or 1330 * Gallon. 1331 * 1332 * VehiclePropConfig.configArray is used to indicate the supported fuel volume display units. 1333 * Volume units are defined in VehicleUnit. 1334 * For example: configArray[0] = LITER 1335 * configArray[1] = GALLON 1336 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1337 * @access VehiclePropertyAccess:READ_WRITE 1338 * @data_enum VehicleUnit 1339 */ 1340 FUEL_VOLUME_DISPLAY_UNITS = ( 1341 0x0601 1342 | VehiclePropertyGroup:SYSTEM 1343 | VehiclePropertyType:INT32 1344 | VehicleArea:GLOBAL), 1345 1346 /** 1347 * Tire pressure units for display 1348 * 1349 * Indicates which units the car is using to display tire pressure to the user. Eg. PSI, Bar or 1350 * Kilopascal. 1351 * 1352 * VehiclePropConfig.configArray is used to indicate the supported pressure display units. 1353 * Pressure units are defined in VehicleUnit. 1354 * For example: configArray[0] = KILOPASCAL 1355 * configArray[1] = PSI 1356 * configArray[2] = BAR 1357 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1358 * @access VehiclePropertyAccess:READ_WRITE 1359 * @data_enum VehicleUnit 1360 */ 1361 TIRE_PRESSURE_DISPLAY_UNITS = ( 1362 0x0602 1363 | VehiclePropertyGroup:SYSTEM 1364 | VehiclePropertyType:INT32 1365 | VehicleArea:GLOBAL), 1366 1367 /** 1368 * EV battery units for display 1369 * 1370 * Indicates which units the car is using to display EV battery information to the user. Eg. 1371 * watt-hours(Wh), kilowatt-hours(kWh) or ampere-hours(Ah). 1372 * 1373 * VehiclePropConfig.configArray is used to indicate the supported electrical energy units. 1374 * Electrical energy units are defined in VehicleUnit. 1375 * For example: configArray[0] = WATT_HOUR 1376 * configArray[1] = AMPERE_HOURS 1377 * configArray[2] = KILOWATT_HOUR 1378 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1379 * @access VehiclePropertyAccess:READ_WRITE 1380 * @data_enum VehicleUnit 1381 */ 1382 EV_BATTERY_DISPLAY_UNITS = ( 1383 0x0603 1384 | VehiclePropertyGroup:SYSTEM 1385 | VehiclePropertyType:INT32 1386 | VehicleArea:GLOBAL), 1387 1388 /** 1389 * Fuel consumption units for display 1390 * 1391 * Indicates type of units the car is using to display fuel consumption information to user 1392 * True indicates units are distance over volume such as MPG. 1393 * False indicates units are volume over distance such as L/100KM. 1394 * 1395 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1396 * @access VehiclePropertyAccess:READ_WRITE 1397 */ 1398 FUEL_CONSUMPTION_UNITS_DISTANCE_OVER_VOLUME = ( 1399 0x0604 1400 | VehiclePropertyGroup:SYSTEM 1401 | VehiclePropertyType:BOOLEAN 1402 | VehicleArea:GLOBAL), 1403 1404 /** 1405 * Speed units for display 1406 * 1407 * Indicates type of units the car is using to display speed to user. Eg. m/s, km/h, or mph. 1408 * 1409 * VehiclePropConfig.configArray is used to indicate the supported speed display units. 1410 * Pressure units are defined in VehicleUnit. 1411 * For example: configArray[0] = METER_PER_SEC 1412 * configArray[1] = MILES_PER_HOUR 1413 * configArray[2] = KILOMETERS_PER_HOUR 1414 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1415 * @access VehiclePropertyAccess:READ_WRITE 1416 */ 1417 VEHICLE_SPEED_DISPLAY_UNITS = ( 1418 0x0605 1419 | VehiclePropertyGroup:SYSTEM 1420 | VehiclePropertyType:INT32 1421 | VehicleArea:GLOBAL), 1422 1423 /** 1424 * Current date and time, encoded as Unix time (in milliseconds). 1425 * This value denotes the number of milliseconds seconds that have 1426 * elapsed since 1/1/1970 UTC. 1427 * 1428 * AAOS will write to this value to give VHAL the Android system's time, 1429 * if the VHAL supports this property. This can be useful to synchronize 1430 * other vehicle systems (dash clock etc) with Android's time. 1431 * 1432 * AAOS writes to this property once during boot, and 1433 * will thereafter write only when some time-source changes are propagated. 1434 * AAOS will fill in VehiclePropValue.timestamp correctly. 1435 * Note that AAOS will not send updates for natural elapse of time. 1436 * int64Values[0] = provided Unix time (in milliseconds) 1437 * 1438 * Note that the property may take >0 ms to get propagated through the stack 1439 * and, having a timestamped property helps reduce any time drift. So, 1440 * for all writes to the property, the timestamp can be used to negate this 1441 * drift: 1442 * drift = currentTimeMillis - PropValue.timestamp 1443 * effectiveTime = PropValue.value.int64Values[0] + diff 1444 * 1445 * Aside, this property could have been better named ANDROID_EPOCH_TIME, but it 1446 * continues to be called EPOCH_TIME for legacy reasons. We will try to fix 1447 * this naming discrepancy when we migrate to AIDL. 1448 * 1449 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1450 * @access VehiclePropertyAccess:WRITE_ONLY 1451 * @unit VehicleUnit:MILLI_SECS 1452 */ 1453 EPOCH_TIME = ( 1454 0x0606 1455 | VehiclePropertyGroup:SYSTEM 1456 | VehiclePropertyType:INT64 1457 | VehicleArea:GLOBAL), 1458 1459 /** 1460 * External encryption binding seed. 1461 * 1462 * This value is mixed with the local key storage encryption key. 1463 * This property holds 16 bytes, and is expected to be persisted on an ECU separate from 1464 * the IVI. The property is initially set by AAOS, who generates it using a CSRNG. 1465 * AAOS will then read the property on subsequent boots. The binding seed is expected to be 1466 * reliably persisted. Any loss of the seed results in a factory reset of the IVI. 1467 * 1468 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1469 * @access VehiclePropertyAccess:READ_WRITE 1470 */ 1471 STORAGE_ENCRYPTION_BINDING_SEED = ( 1472 0x0607 1473 | VehiclePropertyGroup:SYSTEM 1474 | VehiclePropertyType:BYTES 1475 | VehicleArea:GLOBAL), 1476 1477 /** 1478 * Outside temperature 1479 * 1480 * @change_mode VehiclePropertyChangeMode:CONTINUOUS 1481 * @access VehiclePropertyAccess:READ 1482 * @unit VehicleUnit:CELSIUS 1483 */ 1484 ENV_OUTSIDE_TEMPERATURE = ( 1485 0x0703 1486 | VehiclePropertyGroup:SYSTEM 1487 | VehiclePropertyType:FLOAT 1488 | VehicleArea:GLOBAL), 1489 1490 /** 1491 * Property to control power state of application processor 1492 * 1493 * It is assumed that AP's power state is controlled by a separate power 1494 * controller. 1495 * 1496 * For configuration information, VehiclePropConfig.configArray can have bit flag combining 1497 * values in VehicleApPowerStateConfigFlag. 1498 * 1499 * int32Values[0] : VehicleApPowerStateReq enum value 1500 * int32Values[1] : additional parameter relevant for each state, 1501 * 0 if not used. 1502 * 1503 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1504 * @access VehiclePropertyAccess:READ 1505 */ 1506 AP_POWER_STATE_REQ = ( 1507 0x0A00 1508 | VehiclePropertyGroup:SYSTEM 1509 | VehiclePropertyType:INT32_VEC 1510 | VehicleArea:GLOBAL), 1511 1512 /** 1513 * Property to report power state of application processor 1514 * 1515 * It is assumed that AP's power state is controller by separate power 1516 * controller. 1517 * 1518 * int32Values[0] : VehicleApPowerStateReport enum value 1519 * int32Values[1] : Time in ms to wake up, if necessary. Otherwise 0. 1520 1521 * 1522 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1523 * @access VehiclePropertyAccess:READ_WRITE 1524 */ 1525 AP_POWER_STATE_REPORT = ( 1526 0x0A01 1527 | VehiclePropertyGroup:SYSTEM 1528 | VehiclePropertyType:INT32_VEC 1529 | VehicleArea:GLOBAL), 1530 1531 /** 1532 * Property to report bootup reason for the current power on. This is a 1533 * static property that will not change for the whole duration until power 1534 * off. For example, even if user presses power on button after automatic 1535 * power on with door unlock, bootup reason must stay with 1536 * VehicleApPowerBootupReason#USER_UNLOCK. 1537 * 1538 * int32Values[0] must be VehicleApPowerBootupReason. 1539 * 1540 * @change_mode VehiclePropertyChangeMode:STATIC 1541 * @access VehiclePropertyAccess:READ 1542 */ 1543 AP_POWER_BOOTUP_REASON = ( 1544 0x0A02 1545 | VehiclePropertyGroup:SYSTEM 1546 | VehiclePropertyType:INT32 1547 | VehicleArea:GLOBAL), 1548 1549 /** 1550 * Property to represent brightness of the display. Some cars have single 1551 * control for the brightness of all displays and this property is to share 1552 * change in that control. 1553 * 1554 * If this is writable, android side can set this value when user changes 1555 * display brightness from Settings. If this is read only, user may still 1556 * change display brightness from Settings, but that must not be reflected 1557 * to other displays. 1558 * 1559 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1560 * @access VehiclePropertyAccess:READ_WRITE 1561 */ 1562 DISPLAY_BRIGHTNESS = ( 1563 0x0A03 1564 | VehiclePropertyGroup:SYSTEM 1565 | VehiclePropertyType:INT32 1566 | VehicleArea:GLOBAL), 1567 1568 /** 1569 * Property to feed H/W input events to android 1570 * 1571 * int32Values[0] : action defined by VehicleHwKeyInputAction 1572 * int32Values[1] : key code, must use standard android key code 1573 * int32Values[2] : target display defined in VehicleDisplay. Events not 1574 * tied to specific display must be sent to 1575 * VehicleDisplay#MAIN. 1576 * int32Values[3] : [optional] Number of ticks. The value must be equal or 1577 * greater than 1. When omitted, Android will default to 1. 1578 * 1579 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1580 * @access VehiclePropertyAccess:READ 1581 * @config_flags 1582 */ 1583 HW_KEY_INPUT = ( 1584 0x0A10 1585 | VehiclePropertyGroup:SYSTEM 1586 | VehiclePropertyType:INT32_VEC 1587 | VehicleArea:GLOBAL), 1588 1589 /** 1590 * Property to feed H/W rotary events to android 1591 * 1592 * int32Values[0] : RotaryInputType identifying which rotary knob rotated 1593 * int32Values[1] : number of detents (clicks), positive for clockwise, 1594 * negative for counterclockwise 1595 * int32Values[2] : target display defined in VehicleDisplay. Events not 1596 * tied to specific display must be sent to 1597 * VehicleDisplay#MAIN. 1598 * int32values[3 .. 3 + abs(number of detents) - 2]: 1599 * nanosecond deltas between pairs of consecutive detents, 1600 * if the number of detents is > 1 or < -1 1601 * 1602 * VehiclePropValue.timestamp: when the rotation occurred. If the number of 1603 * detents is > 1 or < -1, this is when the 1604 * first detent of rotation occurred. 1605 * 1606 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1607 * @data_enum RotaryInputType 1608 * @access VehiclePropertyAccess:READ 1609 */ 1610 HW_ROTARY_INPUT = ( 1611 0x0A20 1612 | VehiclePropertyGroup:SYSTEM 1613 | VehiclePropertyType:INT32_VEC 1614 | VehicleArea:GLOBAL), 1615 1616 /** 1617 * Defines a custom OEM partner input event. 1618 * 1619 * This input event must be used by OEM partners who wish to propagate events not supported 1620 * by Android. It is composed by an array of int32 values only. 1621 * 1622 * The Android properties are: 1623 * 1624 * int32Values[0] : Input code identifying the function representing this event. OEMs are free 1625 * to use any signed 32 bits number to represent the input code value. 1626 * int32Values[1] : target display type defined in VehicleDisplay. Events not tied to specific 1627 * display must be sent to VehicleDisplay#MAIN. 1628 * int32Values[2] : repeat counter, if 0 then event is not repeated. Values 1 or above means 1629 * how many times this event repeated. 1630 * 1631 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1632 * @data_enum CustomInputType 1633 * @access VehiclePropertyAccess:READ 1634 */ 1635 HW_CUSTOM_INPUT = ( 1636 0X0A30 1637 | VehiclePropertyGroup:SYSTEM 1638 | VehiclePropertyType:INT32_VEC 1639 | VehicleArea:GLOBAL), 1640 1641 /*************************************************************************** 1642 * Most Car Cabin properties have both a POSition and MOVE parameter. These 1643 * are used to control the various movements for seats, doors, and windows 1644 * in a vehicle. 1645 * 1646 * A POS parameter allows the user to set the absolution position. For 1647 * instance, for a door, 0 indicates fully closed and max value indicates 1648 * fully open. Thus, a value halfway between min and max must indicate 1649 * the door is halfway open. 1650 * 1651 * A MOVE parameter moves the device in a particular direction. The sign 1652 * indicates direction, and the magnitude indicates speed (if multiple 1653 * speeds are available). For a door, a move of -1 will close the door, and 1654 * a move of +1 will open it. Once a door reaches the limit of open/close, 1655 * the door should automatically stop moving. The user must NOT need to 1656 * send a MOVE(0) command to stop the door at the end of its range. 1657 **************************************************************************/ 1658 1659 /** 1660 * Door position 1661 * 1662 * This is an integer in case a door may be set to a particular position. 1663 * Max value indicates fully open, min value (0) indicates fully closed. 1664 * 1665 * Some vehicles (minivans) can open the door electronically. Hence, the 1666 * ability to write this property. 1667 * 1668 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1669 * @access VehiclePropertyAccess:READ_WRITE 1670 */ 1671 DOOR_POS = ( 1672 0x0B00 1673 | VehiclePropertyGroup:SYSTEM 1674 | VehiclePropertyType:INT32 1675 | VehicleArea:DOOR), 1676 1677 /** 1678 * Door move 1679 * 1680 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1681 * @access VehiclePropertyAccess:READ_WRITE 1682 */ 1683 DOOR_MOVE = ( 1684 0x0B01 1685 | VehiclePropertyGroup:SYSTEM 1686 | VehiclePropertyType:INT32 1687 | VehicleArea:DOOR), 1688 1689 /** 1690 * Door lock 1691 * 1692 * 'true' indicates door is locked 1693 * 1694 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1695 * @access VehiclePropertyAccess:READ_WRITE 1696 */ 1697 DOOR_LOCK = ( 1698 0x0B02 1699 | VehiclePropertyGroup:SYSTEM 1700 | VehiclePropertyType:BOOLEAN 1701 | VehicleArea:DOOR), 1702 1703 /** 1704 * Mirror Z Position 1705 * 1706 * Positive value indicates tilt upwards, negative value is downwards 1707 * 1708 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1709 * @access VehiclePropertyAccess:READ_WRITE 1710 */ 1711 MIRROR_Z_POS = ( 1712 0x0B40 1713 | VehiclePropertyGroup:SYSTEM 1714 | VehiclePropertyType:INT32 1715 | VehicleArea:MIRROR), 1716 1717 /** 1718 * Mirror Z Move 1719 * 1720 * Positive value indicates tilt upwards, negative value is downwards 1721 * 1722 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1723 * @access VehiclePropertyAccess:READ_WRITE 1724 */ 1725 MIRROR_Z_MOVE = ( 1726 0x0B41 1727 | VehiclePropertyGroup:SYSTEM 1728 | VehiclePropertyType:INT32 1729 | VehicleArea:MIRROR), 1730 1731 /** 1732 * Mirror Y Position 1733 * 1734 * Positive value indicate tilt right, negative value is left 1735 * 1736 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1737 * @access VehiclePropertyAccess:READ_WRITE 1738 */ 1739 MIRROR_Y_POS = ( 1740 0x0B42 1741 | VehiclePropertyGroup:SYSTEM 1742 | VehiclePropertyType:INT32 1743 | VehicleArea:MIRROR), 1744 1745 /** 1746 * Mirror Y Move 1747 * 1748 * Positive value indicate tilt right, negative value is left 1749 * 1750 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1751 * @access VehiclePropertyAccess:READ_WRITE 1752 */ 1753 MIRROR_Y_MOVE = ( 1754 0x0B43 1755 | VehiclePropertyGroup:SYSTEM 1756 | VehiclePropertyType:INT32 1757 | VehicleArea:MIRROR), 1758 1759 /** 1760 * Mirror Lock 1761 * 1762 * True indicates mirror positions are locked and not changeable 1763 * 1764 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1765 * @access VehiclePropertyAccess:READ_WRITE 1766 */ 1767 MIRROR_LOCK = ( 1768 0x0B44 1769 | VehiclePropertyGroup:SYSTEM 1770 | VehiclePropertyType:BOOLEAN 1771 | VehicleArea:GLOBAL), 1772 1773 /** 1774 * Mirror Fold 1775 * 1776 * True indicates mirrors are folded 1777 * 1778 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1779 * @access VehiclePropertyAccess:READ_WRITE 1780 */ 1781 MIRROR_FOLD = ( 1782 0x0B45 1783 | VehiclePropertyGroup:SYSTEM 1784 | VehiclePropertyType:BOOLEAN 1785 | VehicleArea:GLOBAL), 1786 1787 /** 1788 * Seat memory select 1789 * 1790 * This parameter selects the memory preset to use to select the seat 1791 * position. The minValue is always 0, and the maxValue determines the 1792 * number of seat positions available (i.e. numSeatPositions - 1). 1793 * 1794 * For instance, if the driver's seat has 3 memory presets, the maxValue 1795 * will be 2. When the user wants to select a preset, the desired preset 1796 * number (0, 1, or 2) is set. 1797 * 1798 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1799 * @access VehiclePropertyAccess:WRITE 1800 */ 1801 SEAT_MEMORY_SELECT = ( 1802 0x0B80 1803 | VehiclePropertyGroup:SYSTEM 1804 | VehiclePropertyType:INT32 1805 | VehicleArea:SEAT), 1806 1807 /** 1808 * Seat memory set 1809 * 1810 * This setting allows the user to save the current seat position settings 1811 * into the selected preset slot. The maxValue for each seat position 1812 * must match the maxValue for SEAT_MEMORY_SELECT. 1813 * 1814 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1815 * @access VehiclePropertyAccess:WRITE 1816 */ 1817 SEAT_MEMORY_SET = ( 1818 0x0B81 1819 | VehiclePropertyGroup:SYSTEM 1820 | VehiclePropertyType:INT32 1821 | VehicleArea:SEAT), 1822 1823 /** 1824 * Seatbelt buckled 1825 * 1826 * True indicates belt is buckled. 1827 * 1828 * Write access indicates automatic seat buckling capabilities. There are 1829 * no known cars at this time, but you never know... 1830 * 1831 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1832 * @access VehiclePropertyAccess:READ_WRITE 1833 */ 1834 SEAT_BELT_BUCKLED = ( 1835 0x0B82 1836 | VehiclePropertyGroup:SYSTEM 1837 | VehiclePropertyType:BOOLEAN 1838 | VehicleArea:SEAT), 1839 1840 /** 1841 * Seatbelt height position 1842 * 1843 * Adjusts the shoulder belt anchor point. 1844 * Max value indicates highest position 1845 * Min value indicates lowest position 1846 * 1847 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1848 * @access VehiclePropertyAccess:READ_WRITE 1849 */ 1850 SEAT_BELT_HEIGHT_POS = ( 1851 0x0B83 1852 | VehiclePropertyGroup:SYSTEM 1853 | VehiclePropertyType:INT32 1854 | VehicleArea:SEAT), 1855 1856 /** 1857 * Seatbelt height move 1858 * 1859 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1860 * @access VehiclePropertyAccess:READ_WRITE 1861 */ 1862 SEAT_BELT_HEIGHT_MOVE = ( 1863 0x0B84 1864 | VehiclePropertyGroup:SYSTEM 1865 | VehiclePropertyType:INT32 1866 | VehicleArea:SEAT), 1867 1868 /** 1869 * Seat fore/aft position 1870 * 1871 * Sets the seat position forward (closer to steering wheel) and backwards. 1872 * Max value indicates closest to wheel, min value indicates most rearward 1873 * position. 1874 * 1875 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1876 * @access VehiclePropertyAccess:READ_WRITE 1877 */ 1878 SEAT_FORE_AFT_POS = ( 1879 0x0B85 1880 | VehiclePropertyGroup:SYSTEM 1881 | VehiclePropertyType:INT32 1882 | VehicleArea:SEAT), 1883 1884 /** 1885 * Seat fore/aft move 1886 * 1887 * Moves the seat position forward and aft. 1888 * 1889 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1890 * @access VehiclePropertyAccess:READ_WRITE 1891 */ 1892 SEAT_FORE_AFT_MOVE = ( 1893 0x0B86 1894 | VehiclePropertyGroup:SYSTEM 1895 | VehiclePropertyType:INT32 1896 | VehicleArea:SEAT), 1897 1898 /** 1899 * Seat backrest angle 1 position 1900 * 1901 * Backrest angle 1 is the actuator closest to the bottom of the seat. 1902 * Max value indicates angling forward towards the steering wheel. 1903 * Min value indicates full recline. 1904 * 1905 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1906 * @access VehiclePropertyAccess:READ_WRITE 1907 */ 1908 SEAT_BACKREST_ANGLE_1_POS = ( 1909 0x0B87 1910 | VehiclePropertyGroup:SYSTEM 1911 | VehiclePropertyType:INT32 1912 | VehicleArea:SEAT), 1913 1914 /** 1915 * Seat backrest angle 1 move 1916 * 1917 * Moves the backrest forward or recline. 1918 * 1919 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1920 * @access VehiclePropertyAccess:READ_WRITE 1921 */ 1922 SEAT_BACKREST_ANGLE_1_MOVE = ( 1923 0x0B88 1924 | VehiclePropertyGroup:SYSTEM 1925 | VehiclePropertyType:INT32 1926 | VehicleArea:SEAT), 1927 1928 /** 1929 * Seat backrest angle 2 position 1930 * 1931 * Backrest angle 2 is the next actuator up from the bottom of the seat. 1932 * Max value indicates angling forward towards the steering wheel. 1933 * Min value indicates full recline. 1934 * 1935 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1936 * @access VehiclePropertyAccess:READ_WRITE 1937 */ 1938 SEAT_BACKREST_ANGLE_2_POS = ( 1939 0x0B89 1940 | VehiclePropertyGroup:SYSTEM 1941 | VehiclePropertyType:INT32 1942 | VehicleArea:SEAT), 1943 1944 /** 1945 * Seat backrest angle 2 move 1946 * 1947 * Moves the backrest forward or recline. 1948 * 1949 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1950 * @access VehiclePropertyAccess:READ_WRITE 1951 */ 1952 SEAT_BACKREST_ANGLE_2_MOVE = ( 1953 0x0B8A 1954 | VehiclePropertyGroup:SYSTEM 1955 | VehiclePropertyType:INT32 1956 | VehicleArea:SEAT), 1957 1958 /** 1959 * Seat height position 1960 * 1961 * Sets the seat height. 1962 * Max value indicates highest position. 1963 * Min value indicates lowest position. 1964 * 1965 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1966 * @access VehiclePropertyAccess:READ_WRITE 1967 */ 1968 SEAT_HEIGHT_POS = ( 1969 0x0B8B 1970 | VehiclePropertyGroup:SYSTEM 1971 | VehiclePropertyType:INT32 1972 | VehicleArea:SEAT), 1973 1974 /** 1975 * Seat height move 1976 * 1977 * Moves the seat height. 1978 * 1979 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1980 * @access VehiclePropertyAccess:READ_WRITE 1981 */ 1982 SEAT_HEIGHT_MOVE = ( 1983 0x0B8C 1984 | VehiclePropertyGroup:SYSTEM 1985 | VehiclePropertyType:INT32 1986 | VehicleArea:SEAT), 1987 1988 /** 1989 * Seat depth position 1990 * 1991 * Sets the seat depth, distance from back rest to front edge of seat. 1992 * Max value indicates longest depth position. 1993 * Min value indicates shortest position. 1994 * 1995 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 1996 * @access VehiclePropertyAccess:READ_WRITE 1997 */ 1998 SEAT_DEPTH_POS = ( 1999 0x0B8D 2000 | VehiclePropertyGroup:SYSTEM 2001 | VehiclePropertyType:INT32 2002 | VehicleArea:SEAT), 2003 2004 /** 2005 * Seat depth move 2006 * 2007 * Adjusts the seat depth. 2008 * 2009 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2010 * @access VehiclePropertyAccess:READ_WRITE 2011 */ 2012 SEAT_DEPTH_MOVE = ( 2013 0x0B8E 2014 | VehiclePropertyGroup:SYSTEM 2015 | VehiclePropertyType:INT32 2016 | VehicleArea:SEAT), 2017 2018 /** 2019 * Seat tilt position 2020 * 2021 * Sets the seat tilt. 2022 * Max value indicates front edge of seat higher than back edge. 2023 * Min value indicates front edge of seat lower than back edge. 2024 * 2025 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2026 * @access VehiclePropertyAccess:READ_WRITE 2027 */ 2028 SEAT_TILT_POS = ( 2029 0x0B8F 2030 | VehiclePropertyGroup:SYSTEM 2031 | VehiclePropertyType:INT32 2032 | VehicleArea:SEAT), 2033 2034 /** 2035 * Seat tilt move 2036 * 2037 * Tilts the seat. 2038 * 2039 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2040 * @access VehiclePropertyAccess:READ_WRITE 2041 */ 2042 SEAT_TILT_MOVE = ( 2043 0x0B90 2044 | VehiclePropertyGroup:SYSTEM 2045 | VehiclePropertyType:INT32 2046 | VehicleArea:SEAT), 2047 2048 /** 2049 * Lumber fore/aft position 2050 * 2051 * Pushes the lumbar support forward and backwards 2052 * Max value indicates most forward position. 2053 * Min value indicates most rearward position. 2054 * 2055 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2056 * @access VehiclePropertyAccess:READ_WRITE 2057 */ 2058 SEAT_LUMBAR_FORE_AFT_POS = ( 2059 0x0B91 2060 | VehiclePropertyGroup:SYSTEM 2061 | VehiclePropertyType:INT32 2062 | VehicleArea:SEAT), 2063 2064 /** 2065 * Lumbar fore/aft move 2066 * 2067 * Adjusts the lumbar support. 2068 * 2069 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2070 * @access VehiclePropertyAccess:READ_WRITE 2071 */ 2072 SEAT_LUMBAR_FORE_AFT_MOVE = ( 2073 0x0B92 2074 | VehiclePropertyGroup:SYSTEM 2075 | VehiclePropertyType:INT32 2076 | VehicleArea:SEAT), 2077 2078 /** 2079 * Lumbar side support position 2080 * 2081 * Sets the amount of lateral lumbar support. 2082 * Max value indicates widest lumbar setting (i.e. least support) 2083 * Min value indicates thinnest lumbar setting. 2084 * 2085 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2086 * @access VehiclePropertyAccess:READ_WRITE 2087 */ 2088 SEAT_LUMBAR_SIDE_SUPPORT_POS = ( 2089 0x0B93 2090 | VehiclePropertyGroup:SYSTEM 2091 | VehiclePropertyType:INT32 2092 | VehicleArea:SEAT), 2093 2094 /** 2095 * Lumbar side support move 2096 * 2097 * Adjusts the amount of lateral lumbar support. 2098 * 2099 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2100 * @access VehiclePropertyAccess:READ_WRITE 2101 */ 2102 SEAT_LUMBAR_SIDE_SUPPORT_MOVE = ( 2103 0x0B94 2104 | VehiclePropertyGroup:SYSTEM 2105 | VehiclePropertyType:INT32 2106 | VehicleArea:SEAT), 2107 2108 /** 2109 * DO NOT USE 2110 * 2111 * This property is defined as type VehicleArea:GLOBAL, which means all seats use the same 2112 * value. Use SEAT_HEADREST_HEIGHT_POS_V2 instead which fixes this issue by being defined as 2113 * type VehicleArea:SEAT. 2114 * 2115 * Headrest height position 2116 * 2117 * Sets the headrest height. 2118 * Max value indicates tallest setting. 2119 * Min value indicates shortest setting. 2120 * 2121 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2122 * @access VehiclePropertyAccess:READ_WRITE 2123 */ 2124 SEAT_HEADREST_HEIGHT_POS = ( 2125 0x0B95 2126 | VehiclePropertyGroup:SYSTEM 2127 | VehiclePropertyType:INT32 2128 | VehicleArea:GLOBAL), 2129 2130 /** 2131 * Headrest height move 2132 * 2133 * Moves the headrest up and down. 2134 * 2135 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2136 * @access VehiclePropertyAccess:READ_WRITE 2137 */ 2138 SEAT_HEADREST_HEIGHT_MOVE = ( 2139 0x0B96 2140 | VehiclePropertyGroup:SYSTEM 2141 | VehiclePropertyType:INT32 2142 | VehicleArea:SEAT), 2143 2144 /** 2145 * Headrest angle position 2146 * 2147 * Sets the angle of the headrest. 2148 * Max value indicates most upright angle. 2149 * Min value indicates shallowest headrest angle. 2150 * 2151 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2152 * @access VehiclePropertyAccess:READ_WRITE 2153 */ 2154 SEAT_HEADREST_ANGLE_POS = ( 2155 0x0B97 2156 | VehiclePropertyGroup:SYSTEM 2157 | VehiclePropertyType:INT32 2158 | VehicleArea:SEAT), 2159 2160 /** 2161 * Headrest angle move 2162 * 2163 * Adjusts the angle of the headrest 2164 * 2165 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2166 * @access VehiclePropertyAccess:READ_WRITE 2167 */ 2168 SEAT_HEADREST_ANGLE_MOVE = ( 2169 0x0B98 2170 | VehiclePropertyGroup:SYSTEM 2171 | VehiclePropertyType:INT32 2172 | VehicleArea:SEAT), 2173 2174 /** 2175 * Headrest fore/aft position 2176 * 2177 * Adjusts the headrest forwards and backwards. 2178 * Max value indicates position closest to front of car. 2179 * Min value indicates position closest to rear of car. 2180 * 2181 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2182 * @access VehiclePropertyAccess:READ_WRITE 2183 */ 2184 SEAT_HEADREST_FORE_AFT_POS = ( 2185 0x0B99 2186 | VehiclePropertyGroup:SYSTEM 2187 | VehiclePropertyType:INT32 2188 | VehicleArea:SEAT), 2189 2190 /** 2191 * Headrest fore/aft move 2192 * 2193 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2194 * @access VehiclePropertyAccess:READ_WRITE 2195 */ 2196 SEAT_HEADREST_FORE_AFT_MOVE = ( 2197 0x0B9A 2198 | VehiclePropertyGroup:SYSTEM 2199 | VehiclePropertyType:INT32 2200 | VehicleArea:SEAT), 2201 2202 /** 2203 * Seat Occupancy 2204 * 2205 * Indicates whether a particular seat is occupied or not, to the best of the car's ability 2206 * to determine. Valid values are from the VehicleSeatOccupancyState enum. 2207 * 2208 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2209 * @access VehiclePropertyAccess:READ 2210 * @data_enum VehicleSeatOccupancyState 2211 */ 2212 SEAT_OCCUPANCY = ( 2213 0x0BB0 2214 | VehiclePropertyGroup:SYSTEM 2215 | VehiclePropertyType:INT32 2216 | VehicleArea:SEAT), 2217 2218 /** 2219 * Window Position 2220 * 2221 * Min = window up / closed 2222 * Max = window down / open 2223 * 2224 * For a window that may open out of plane (i.e. vent mode of sunroof) this 2225 * parameter will work with negative values as follows: 2226 * Max = sunroof completely open 2227 * 0 = sunroof closed. 2228 * Min = sunroof vent completely open 2229 * 2230 * Note that in this mode, 0 indicates the window is closed. 2231 * 2232 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2233 * @access VehiclePropertyAccess:READ_WRITE 2234 */ 2235 WINDOW_POS = ( 2236 0x0BC0 2237 | VehiclePropertyGroup:SYSTEM 2238 | VehiclePropertyType:INT32 2239 | VehicleArea:WINDOW), 2240 2241 /** 2242 * Window Move 2243 * 2244 * Max = Open the window as fast as possible 2245 * Min = Close the window as fast as possible 2246 * Magnitude denotes relative speed. I.e. +2 is faster than +1 in closing 2247 * the window. 2248 * 2249 * For a window that may open out of plane (i.e. vent mode of sunroof) this 2250 * parameter will work as follows: 2251 * 2252 * If sunroof is open: 2253 * Max = open the sunroof further, automatically stop when fully open. 2254 * Min = close the sunroof, automatically stop when sunroof is closed. 2255 * 2256 * If vent is open: 2257 * Max = close the vent, automatically stop when vent is closed. 2258 * Min = open the vent further, automatically stop when vent is fully open. 2259 * 2260 * If sunroof is in the closed position: 2261 * Max = open the sunroof, automatically stop when sunroof is fully open. 2262 * Min = open the vent, automatically stop when vent is fully open. 2263 * 2264 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2265 * @access VehiclePropertyAccess:READ_WRITE 2266 */ 2267 WINDOW_MOVE = ( 2268 0x0BC1 2269 | VehiclePropertyGroup:SYSTEM 2270 | VehiclePropertyType:INT32 2271 | VehicleArea:WINDOW), 2272 2273 /** 2274 * Window Lock 2275 * 2276 * True indicates windows are locked and can't be moved. 2277 * 2278 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2279 * @access VehiclePropertyAccess:READ_WRITE 2280 */ 2281 WINDOW_LOCK = ( 2282 0x0BC4 2283 | VehiclePropertyGroup:SYSTEM 2284 | VehiclePropertyType:BOOLEAN 2285 | VehicleArea:WINDOW), 2286 2287 2288 /** 2289 * Vehicle Maps Service (VMS) message 2290 * 2291 * This property uses MIXED data to communicate vms messages. 2292 * 2293 * Its contents are to be interpreted as follows: 2294 * the indices defined in VmsMessageIntegerValuesIndex are to be used to 2295 * read from int32Values; 2296 * bytes is a serialized VMS message as defined in the vms protocol 2297 * which is opaque to the framework; 2298 * 2299 * IVehicle#get must always return StatusCode::NOT_AVAILABLE. 2300 * 2301 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2302 * @access VehiclePropertyAccess:READ_WRITE 2303 */ 2304 VEHICLE_MAP_SERVICE = ( 2305 0x0C00 2306 | VehiclePropertyGroup:SYSTEM 2307 | VehiclePropertyType:MIXED 2308 | VehicleArea:GLOBAL), 2309 2310 /** 2311 * OBD2 Live Sensor Data 2312 * 2313 * Reports a snapshot of the current (live) values of the OBD2 sensors available. 2314 * 2315 * The configArray is set as follows: 2316 * configArray[0] = number of vendor-specific integer-valued sensors 2317 * configArray[1] = number of vendor-specific float-valued sensors 2318 * 2319 * The values of this property are to be interpreted as in the following example. 2320 * Considering a configArray = {2,3} 2321 * int32Values must be a vector containing Obd2IntegerSensorIndex.LAST_SYSTEM_INDEX + 2 2322 * elements (that is, 33 elements); 2323 * floatValues must be a vector containing Obd2FloatSensorIndex.LAST_SYSTEM_INDEX + 3 2324 * elements (that is, 73 elements); 2325 * 2326 * It is possible for each frame to contain a different subset of sensor values, both system 2327 * provided sensors, and vendor-specific ones. In order to support that, the bytes element 2328 * of the property value is used as a bitmask,. 2329 * 2330 * bytes must have a sufficient number of bytes to represent the total number of possible 2331 * sensors (in this case, 14 bytes to represent 106 possible values); it is to be read as 2332 * a contiguous bitmask such that each bit indicates the presence or absence of a sensor 2333 * from the frame, starting with as many bits as the size of int32Values, immediately 2334 * followed by as many bits as the size of floatValues. 2335 * 2336 * For example, should bytes[0] = 0x4C (0b01001100) it would mean that: 2337 * int32Values[0 and 1] are not valid sensor values 2338 * int32Values[2 and 3] are valid sensor values 2339 * int32Values[4 and 5] are not valid sensor values 2340 * int32Values[6] is a valid sensor value 2341 * int32Values[7] is not a valid sensor value 2342 * Should bytes[5] = 0x61 (0b01100001) it would mean that: 2343 * int32Values[32] is a valid sensor value 2344 * floatValues[0 thru 3] are not valid sensor values 2345 * floatValues[4 and 5] are valid sensor values 2346 * floatValues[6] is not a valid sensor value 2347 * 2348 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2349 * @access VehiclePropertyAccess:READ 2350 */ 2351 OBD2_LIVE_FRAME = ( 2352 0x0D00 2353 | VehiclePropertyGroup:SYSTEM 2354 | VehiclePropertyType:MIXED 2355 | VehicleArea:GLOBAL), 2356 2357 /** 2358 * OBD2 Freeze Frame Sensor Data 2359 * 2360 * Reports a snapshot of the value of the OBD2 sensors available at the time that a fault 2361 * occurred and was detected. 2362 * 2363 * A configArray must be provided with the same meaning as defined for OBD2_LIVE_FRAME. 2364 * 2365 * The values of this property are to be interpreted in a similar fashion as those for 2366 * OBD2_LIVE_FRAME, with the exception that the stringValue field may contain a non-empty 2367 * diagnostic troubleshooting code (DTC). 2368 * 2369 * A IVehicle#get request of this property must provide a value for int64Values[0]. 2370 * This will be interpreted as the timestamp of the freeze frame to retrieve. A list of 2371 * timestamps can be obtained by a IVehicle#get of OBD2_FREEZE_FRAME_INFO. 2372 * 2373 * Should no freeze frame be available at the given timestamp, a response of NOT_AVAILABLE 2374 * must be returned by the implementation. Because vehicles may have limited storage for 2375 * freeze frames, it is possible for a frame request to respond with NOT_AVAILABLE even if 2376 * the associated timestamp has been recently obtained via OBD2_FREEZE_FRAME_INFO. 2377 * 2378 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2379 * @access VehiclePropertyAccess:READ 2380 */ 2381 OBD2_FREEZE_FRAME = ( 2382 0x0D01 2383 | VehiclePropertyGroup:SYSTEM 2384 | VehiclePropertyType:MIXED 2385 | VehicleArea:GLOBAL), 2386 2387 /** 2388 * OBD2 Freeze Frame Information 2389 * 2390 * This property describes the current freeze frames stored in vehicle 2391 * memory and available for retrieval via OBD2_FREEZE_FRAME. 2392 * 2393 * The values are to be interpreted as follows: 2394 * each element of int64Values must be the timestamp at which a a fault code 2395 * has been detected and the corresponding freeze frame stored, and each 2396 * such element can be used as the key to OBD2_FREEZE_FRAME to retrieve 2397 * the corresponding freeze frame. 2398 * 2399 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2400 * @access VehiclePropertyAccess:READ 2401 */ 2402 OBD2_FREEZE_FRAME_INFO = ( 2403 0x0D02 2404 | VehiclePropertyGroup:SYSTEM 2405 | VehiclePropertyType:MIXED 2406 | VehicleArea:GLOBAL), 2407 2408 /** 2409 * OBD2 Freeze Frame Clear 2410 * 2411 * This property allows deletion of any of the freeze frames stored in 2412 * vehicle memory, as described by OBD2_FREEZE_FRAME_INFO. 2413 * 2414 * The configArray is set as follows: 2415 * configArray[0] = 1 if the implementation is able to clear individual freeze frames 2416 * by timestamp, 0 otherwise 2417 * 2418 * IVehicle#set of this property is to be interpreted as follows: 2419 * if int64Values contains no elements, then all frames stored must be cleared; 2420 * if int64Values contains one or more elements, then frames at the timestamps 2421 * stored in int64Values must be cleared, and the others not cleared. Should the 2422 * vehicle not support selective clearing of freeze frames, this latter mode must 2423 * return NOT_AVAILABLE. 2424 * 2425 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2426 * @access VehiclePropertyAccess:WRITE 2427 */ 2428 OBD2_FREEZE_FRAME_CLEAR = ( 2429 0x0D03 2430 | VehiclePropertyGroup:SYSTEM 2431 | VehiclePropertyType:MIXED 2432 | VehicleArea:GLOBAL), 2433 2434 /** 2435 * Headlights State 2436 * 2437 * Return the current state of headlights. 2438 * 2439 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2440 * @access VehiclePropertyAccess:READ 2441 * @data_enum VehicleLightState 2442 */ 2443 HEADLIGHTS_STATE = ( 2444 0x0E00 2445 | VehiclePropertyGroup:SYSTEM 2446 | VehiclePropertyType:INT32 2447 | VehicleArea:GLOBAL), 2448 2449 /** 2450 * High beam lights state 2451 * 2452 * Return the current state of high beam lights. 2453 * 2454 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2455 * @access VehiclePropertyAccess:READ 2456 * @data_enum VehicleLightState 2457 */ 2458 HIGH_BEAM_LIGHTS_STATE = ( 2459 0x0E01 2460 | VehiclePropertyGroup:SYSTEM 2461 | VehiclePropertyType:INT32 2462 | VehicleArea:GLOBAL), 2463 2464 /** 2465 * Fog light state 2466 * 2467 * Return the current state of fog lights. 2468 * 2469 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2470 * @access VehiclePropertyAccess:READ 2471 * @data_enum VehicleLightState 2472 */ 2473 FOG_LIGHTS_STATE = ( 2474 0x0E02 2475 | VehiclePropertyGroup:SYSTEM 2476 | VehiclePropertyType:INT32 2477 | VehicleArea:GLOBAL), 2478 2479 /** 2480 * Hazard light status 2481 * 2482 * Return the current status of hazard lights. 2483 * 2484 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2485 * @access VehiclePropertyAccess:READ 2486 * @data_enum VehicleLightState 2487 */ 2488 HAZARD_LIGHTS_STATE = ( 2489 0x0E03 2490 | VehiclePropertyGroup:SYSTEM 2491 | VehiclePropertyType:INT32 2492 | VehicleArea:GLOBAL), 2493 2494 /** 2495 * Headlight switch 2496 * 2497 * The setting that the user wants. 2498 * 2499 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2500 * @access VehiclePropertyAccess:READ_WRITE 2501 * @data_enum VehicleLightSwitch 2502 */ 2503 HEADLIGHTS_SWITCH = ( 2504 0x0E10 2505 | VehiclePropertyGroup:SYSTEM 2506 | VehiclePropertyType:INT32 2507 | VehicleArea:GLOBAL), 2508 2509 /** 2510 * High beam light switch 2511 * 2512 * The setting that the user wants. 2513 * 2514 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2515 * @access VehiclePropertyAccess:READ_WRITE 2516 * @data_enum VehicleLightSwitch 2517 */ 2518 HIGH_BEAM_LIGHTS_SWITCH = ( 2519 0x0E11 2520 | VehiclePropertyGroup:SYSTEM 2521 | VehiclePropertyType:INT32 2522 | VehicleArea:GLOBAL), 2523 2524 /** 2525 * Fog light switch 2526 * 2527 * The setting that the user wants. 2528 * 2529 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2530 * @access VehiclePropertyAccess:READ_WRITE 2531 * @data_enum VehicleLightSwitch 2532 */ 2533 FOG_LIGHTS_SWITCH = ( 2534 0x0E12 2535 | VehiclePropertyGroup:SYSTEM 2536 | VehiclePropertyType:INT32 2537 | VehicleArea:GLOBAL), 2538 2539 /** 2540 * Hazard light switch 2541 * 2542 * The setting that the user wants. 2543 * 2544 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2545 * @access VehiclePropertyAccess:READ_WRITE 2546 * @data_enum VehicleLightSwitch 2547 */ 2548 HAZARD_LIGHTS_SWITCH = ( 2549 0x0E13 2550 | VehiclePropertyGroup:SYSTEM 2551 | VehiclePropertyType:INT32 2552 | VehicleArea:GLOBAL), 2553 2554 /** 2555 * Cabin lights 2556 * 2557 * Return current status of cabin lights. 2558 * 2559 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2560 * @access VehiclePropertyAccess:READ 2561 * @data_enum VehicleLightState 2562 */ 2563 CABIN_LIGHTS_STATE = ( 2564 0x0F01 2565 | VehiclePropertyGroup:SYSTEM 2566 | VehiclePropertyType:INT32 2567 | VehicleArea:GLOBAL), 2568 2569 /** 2570 * Cabin lights switch 2571 * 2572 * The position of the physical switch which controls the cabin lights. 2573 * This might be different than the CABIN_LIGHTS_STATE if the lights are on because a door 2574 * is open or because of a voice command. 2575 * For example, while the switch is in the "off" or "automatic" position. 2576 * 2577 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2578 * @access VehiclePropertyAccess:READ_WRITE 2579 * @data_enum VehicleLightSwitch 2580 */ 2581 CABIN_LIGHTS_SWITCH = ( 2582 0x0F02 2583 | VehiclePropertyGroup:SYSTEM 2584 | VehiclePropertyType:INT32 2585 | VehicleArea:GLOBAL), 2586 2587 /** 2588 * Reading lights 2589 * 2590 * Return current status of reading lights. 2591 * 2592 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2593 * @access VehiclePropertyAccess:READ 2594 * @data_enum VehicleLightState 2595 */ 2596 READING_LIGHTS_STATE = ( 2597 0x0F03 2598 | VehiclePropertyGroup:SYSTEM 2599 | VehiclePropertyType:INT32 2600 | VehicleArea:SEAT), 2601 2602 /** 2603 * Reading lights switch 2604 * 2605 * The position of the physical switch which controls the reading lights. 2606 * This might be different than the READING_LIGHTS_STATE if the lights are on because a door 2607 * is open or because of a voice command. 2608 * For example, while the switch is in the "off" or "automatic" position. 2609 * 2610 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2611 * @access VehiclePropertyAccess:READ_WRITE 2612 * @data_enum VehicleLightSwitch 2613 */ 2614 READING_LIGHTS_SWITCH = ( 2615 0x0F04 2616 | VehiclePropertyGroup:SYSTEM 2617 | VehiclePropertyType:INT32 2618 | VehicleArea:SEAT), 2619 2620 /** 2621 * Support customize permissions for vendor properties 2622 * 2623 * Implement this property if vehicle hal support customize vendor permissions feature. 2624 * VehiclePropConfig.configArray is used to indicate vendor properties and permissions 2625 * which selected for this vendor property. The permission must be one of enum in 2626 * VehicleVendorPermission. 2627 * The configArray is set as follows: 2628 * configArray[n] = propId : property ID for the vendor property 2629 * configArray[n+1] = one of enums in VehicleVendorPermission. It indicates the permission 2630 * for reading value of the property. 2631 * configArray[n+2] = one of enums in VehicleVendorPermission. It indicates the permission 2632 * for writing value of the property. 2633 * 2634 * For example: 2635 * configArray = { 2636 * vendor_prop_1, PERMISSION_VENDOR_SEAT_READ, PERMISSION_VENDOR_SEAT_WRITE, 2637 * vendor_prop_2, PERMISSION_VENDOR_INFO, PERMISSION_NOT_ACCESSIBLE, 2638 * } 2639 * If vendor properties are not in this array, they will have the default vendor permission. 2640 * If vendor chose PERMISSION_NOT_ACCESSIBLE, android will not have access to the property. In 2641 * the example, Android can not write value for vendor_prop_2. 2642 * 2643 * @change_mode VehiclePropertyChangeMode:STATIC 2644 * @access VehiclePropertyAccess:READ 2645 */ 2646 SUPPORT_CUSTOMIZE_VENDOR_PERMISSION = ( 2647 0x0F05 2648 | VehiclePropertyGroup:SYSTEM 2649 | VehiclePropertyType:BOOLEAN 2650 | VehicleArea:GLOBAL), 2651 2652 /** 2653 * Allow disabling optional featurs from vhal. 2654 * 2655 * This property reports optional features that should be disabled. 2656 * All allowed optional features for the system is declared in Car service overlay, 2657 * config_allowed_optional_car_features. 2658 * This property allows disabling features defined in the overlay. Without this property, 2659 * all the features declared in the overlay will be enabled. 2660 * 2661 * Value read should include all features disabled with ',' separation. 2662 * ex) "com.android.car.user.CarUserNoticeService,storage_monitoring" 2663 * @change_mode VehiclePropertyChangeMode:STATIC 2664 * @access VehiclePropertyAccess:READ 2665 */ 2666 DISABLED_OPTIONAL_FEATURES = ( 2667 0x0F06 2668 | VehiclePropertyGroup:SYSTEM 2669 | VehiclePropertyType:STRING 2670 | VehicleArea:GLOBAL), 2671 2672 /** 2673 * Defines the initial Android user to be used during initialization. 2674 * 2675 * This property is called by the Android system when it initializes and it lets the HAL 2676 * define which Android user should be started. 2677 * 2678 * This request is made by setting a VehiclePropValue (defined by InitialUserInfoRequest), 2679 * and the HAL must respond with a property change event (defined by InitialUserInfoResponse). 2680 * If the HAL doesn't respond after some time (defined by the Android system), the Android 2681 * system will proceed as if HAL returned a response of action 2682 * InitialUserInfoResponseAction:DEFAULT. 2683 * 2684 * For example, on first boot, the request could be: 2685 * 2686 * int32[0]: 42 // request id (arbitrary number set by Android system) 2687 * int32[1]: 1 // InitialUserInfoRequestType::FIRST_BOOT 2688 * int32[2]: 0 // id of current user (usersInfo.currentUser.userId) 2689 * int32[3]: 1 // flag of current user (usersInfo.currentUser.flags = SYSTEM) 2690 * int32[4]: 1 // number of existing users (usersInfo.numberUsers); 2691 * int32[5]: 0 // user #0 (usersInfo.existingUsers[0].userId) 2692 * int32[6]: 1 // flags of user #0 (usersInfo.existingUsers[0].flags) 2693 * 2694 * And if the HAL want to respond with the creation of an admin user called "Owner", the 2695 * response would be: 2696 * 2697 * int32[0]: 42 // must match the request id from the request 2698 * int32[1]: 2 // action = InitialUserInfoResponseAction::CREATE 2699 * int32[2]: -10000 // userToSwitchOrCreate.userId (not used as user will be created) 2700 * int32[3]: 8 // userToSwitchOrCreate.flags = ADMIN 2701 * string: "||Owner" // userLocales + separator + userNameToCreate 2702 * 2703 * Notice the string value represents multiple values, separated by ||. The first value is the 2704 * (optional) system locales for the user to be created (in this case, it's empty, meaning it 2705 * will use Android's default value), while the second value is the (also optional) name of the 2706 * to user to be created (when the type of response is InitialUserInfoResponseAction:CREATE). 2707 * For example, to create the same "Owner" user with "en-US" and "pt-BR" locales, the string 2708 * value of the response would be "en-US,pt-BR||Owner". As such, neither the locale nor the 2709 * name can have || on it, although a single | is fine. 2710 * 2711 * NOTE: if the HAL doesn't support user management, then it should not define this property, 2712 * which in turn would disable the other user-related properties (for example, the Android 2713 * system would never issue them and user-related requests from the HAL layer would be ignored 2714 * by the Android System). But if it supports user management, then it must support all core 2715 * user-related properties (INITIAL_USER_INFO, SWITCH_USER, CREATE_USER, and REMOVE_USER). 2716 * 2717 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2718 * @access VehiclePropertyAccess:READ_WRITE 2719 */ 2720 INITIAL_USER_INFO = ( 2721 0x0F07 2722 | VehiclePropertyGroup:SYSTEM 2723 | VehiclePropertyType:MIXED 2724 | VehicleArea:GLOBAL), 2725 2726 /** 2727 * Defines a request to switch the foreground Android user. 2728 * 2729 * This property is used primarily by the Android System to inform the HAL that the 2730 * current foreground Android user is switching, but it could also be used by the HAL to request 2731 * the Android system to switch users - the 2732 * 2733 * When the request is made by Android, it sets a VehiclePropValue and the HAL must responde 2734 * with a property change event; when the HAL is making the request, it must also do it through 2735 * a property change event (the main difference is that the request id will be positive in the 2736 * former case, and negative in the latter; the SwitchUserMessageType will also be different). 2737 * 2738 * The format of both request is defined by SwitchUserRequest and the format of the response 2739 * (when needed) is defined by SwitchUserResponse. How the HAL (or Android System) should 2740 * proceed depends on the message type (which is defined by the SwitchUserMessageType 2741 * parameter), as defined below. 2742 * 2743 * 1.LEGACY_ANDROID_SWITCH 2744 * ----------------------- 2745 * 2746 * Called by the Android System to indicate the Android user is about to change, when the change 2747 * request was made in a way that is not integrated with the HAL (for example, through 2748 * adb shell am switch-user). 2749 * 2750 * The HAL can switch its internal user once it receives this request, but it doesn't need to 2751 * reply back to the Android System. If its internal user cannot be changed for some reason, 2752 * then it must wait for the SWITCH_USER(type=ANDROID_POST_SWITCH) call to recover 2753 * (for example, it could issue a SWITCH_USER(type=VEHICLE_REQUEST) to switch back to 2754 * the previous user), but ideally it should never fail (as switching back could result in a 2755 * confusing experience for the end user). 2756 * 2757 * For example, if the system have users (0, 10, 11) and it's switching from 0 to 11 (where none 2758 * of them have any special flag), the request would be: 2759 * 2760 * int32[0]: 42 // request id 2761 * int32[1]: 1 // SwitchUserMessageType::LEGACY_ANDROID_SWITCH 2762 * int32[2]: 11 // target user id 2763 * int32[3]: 0 // target user flags (none) 2764 * int32[4]: 10 // current user 2765 * int32[5]: 0 // current user flags (none) 2766 * int32[6]: 3 // number of users 2767 * int32[7]: 0 // user #0 (Android user id 0) 2768 * int32[8]: 0 // flags of user #0 (none) 2769 * int32[9]: 10 // user #1 (Android user id 10) 2770 * int32[10]: 0 // flags of user #1 (none) 2771 * int32[11]: 11 // user #2 (Android user id 11) 2772 * int32[12]: 0 // flags of user #2 (none) 2773 * 2774 * 2.ANDROID_SWITCH 2775 * ---------------- 2776 * Called by the Android System to indicate the Android user is about to change, but Android 2777 * will wait for the HAL's response (up to some time) before proceeding. 2778 * 2779 * The HAL must switch its internal user once it receives this request, then respond back to 2780 * Android with a SWITCH_USER(type=VEHICLE_RESPONSE) indicating whether its internal 2781 * user was switched or not (through the SwitchUserStatus enum). 2782 * 2783 * For example, if Android has users (0, 10, 11) and it's switching from 10 to 11 (where 2784 * none of them have any special flag), the request would be: 2785 * 2786 * int32[0]: 42 // request id 2787 * int32[1]: 2 // SwitchUserMessageType::ANDROID_SWITCH 2788 * int32[2]: 11 // target user id 2789 * int32[3]: 0 // target user flags (none) 2790 * int32[4]: 10 // current user 2791 * int32[5]: 0 // current user flags (none) 2792 * int32[6]: 3 // number of users 2793 * int32[7]: 0 // 1st user (user 0) 2794 * int32[8]: 1 // 1st user flags (SYSTEM) 2795 * int32[9]: 10 // 2nd user (user 10) 2796 * int32[10]: 0 // 2nd user flags (none) 2797 * int32[11]: 11 // 3rd user (user 11) 2798 * int32[12]: 0 // 3rd user flags (none) 2799 * 2800 * If the request succeeded, the HAL must update the propery with: 2801 * 2802 * int32[0]: 42 // request id 2803 * int32[1]: 3 // messageType = SwitchUserMessageType::VEHICLE_RESPONSE 2804 * int32[2]: 1 // status = SwitchUserStatus::SUCCESS 2805 * 2806 * But if it failed, the response would be something like: 2807 * 2808 * int32[0]: 42 // request id 2809 * int32[1]: 3 // messageType = SwitchUserMessageType::VEHICLE_RESPONSE 2810 * int32[2]: 2 // status = SwitchUserStatus::FAILURE 2811 * string: "108-D'OH!" // OEM-spefic error message 2812 * 2813 * 3.VEHICLE_RESPONSE 2814 * ------------------ 2815 * Called by the HAL to indicate whether a request of type ANDROID_SWITCH should proceed or 2816 * abort - see the ANDROID_SWITCH section above for more info. 2817 * 2818 * 4.VEHICLE_REQUEST 2819 * ------------------ 2820 * Called by the HAL to request that the current foreground Android user is switched. 2821 * 2822 * This is useful in situations where Android started as one user, but the vehicle identified 2823 * the driver as another user. For example, user A unlocked the car using the key fob of user B; 2824 * the INITIAL_USER_INFO request returned user B, but then a face recognition subsubsystem 2825 * identified the user as A. 2826 * 2827 * The HAL makes this request by a property change event (passing a negative request id), and 2828 * the Android system will response by issue an ANDROID_POST_SWITCH call which the same 2829 * request id. 2830 * 2831 * For example, if the current foreground Android user is 10 and the HAL asked it to switch to 2832 * 11, the request would be: 2833 * 2834 * int32[0]: -108 // request id 2835 * int32[1]: 4 // messageType = SwitchUserMessageType::VEHICLE_REQUEST 2836 * int32[2]: 11 // Android user id 2837 * 2838 * If the request succeeded and Android has 3 users (0, 10, 11), the response would be: 2839 * 2840 * int32[0]: -108 // request id 2841 * int32[1]: 5 // messageType = SwitchUserMessageType::ANDROID_POST_SWITCH 2842 * int32[2]: 11 // target user id 2843 * int32[3]: 0 // target user id flags (none) 2844 * int32[4]: 11 // current user 2845 * int32[5]: 0 // current user flags (none) 2846 * int32[6]: 3 // number of users 2847 * int32[7]: 0 // 1st user (user 0) 2848 * int32[8]: 0 // 1st user flags (none) 2849 * int32[9]: 10 // 2nd user (user 10) 2850 * int32[10]: 4 // 2nd user flags (none) 2851 * int32[11]: 11 // 3rd user (user 11) 2852 * int32[12]: 3 // 3rd user flags (none) 2853 * 2854 * Notice that both the current and target user ids are the same - if the request failed, then 2855 * they would be different (i.e, target user would be 11, but current user would still be 10). 2856 * 2857 * 5.ANDROID_POST_SWITCH 2858 * --------------------- 2859 * Called by the Android System after a request to switch a user was made. 2860 * 2861 * This property is called after switch requests of any type (i.e., LEGACY_ANDROID_SWITCH, 2862 * ANDROID_SWITCH, or VEHICLE_REQUEST) and can be used to determine if the request succeeded or 2863 * failed: 2864 * 2865 * 1. When it succeeded, it's called when the Android user is in the unlocked state and the 2866 * value of the current and target users ids in the response are the same. This would be 2867 * equivalent to receiving an Intent.ACTION_USER_UNLOCKED in an Android app. 2868 * 2. When it failed it's called right away and the value of the current and target users ids 2869 * in the response are different (as the current user didn't change to the target). 2870 * 3. If a new switch request is made before the HAL responded to the previous one or before 2871 * the user was unlocked, then the ANDROID_POST_SWITCH request is not made. For example, 2872 * the driver could accidentally switch to the wrong user which has lock credentials, then 2873 * switch to the right one before entering the credentials. 2874 * 2875 * The HAL can update its internal state once it receives this request, but it doesn't need to 2876 * reply back to the Android System. 2877 * 2878 * Request: the first N values as defined by INITIAL_USER_INFO (where the request-specific 2879 * value at index 1 is SwitchUserMessageType::ANDROID_POST_SWITCH), then 2 more values for the 2880 * target user id (i.e., the Android user id that was requested to be switched to) and its flags 2881 * (as defined by UserFlags). 2882 * 2883 * Response: none. 2884 * 2885 * Example: see VEHICLE_REQUEST section above. 2886 * 2887 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2888 * @access VehiclePropertyAccess:READ_WRITE 2889 */ 2890 SWITCH_USER = ( 2891 0x0F08 2892 | VehiclePropertyGroup:SYSTEM 2893 | VehiclePropertyType:MIXED 2894 | VehicleArea:GLOBAL), 2895 2896 /** 2897 * Called by the Android System after an Android user was created. 2898 * 2899 * The HAL can use this property to create its equivalent user. 2900 * 2901 * This is an async request: Android makes the request by setting a VehiclePropValue, and HAL 2902 * must respond with a property change indicating whether the request succeeded or failed. If 2903 * it failed, the Android system will remove the user. 2904 * 2905 * The format of the request is defined by CreateUserRequest and the format of the response by 2906 * CreateUserResponse. 2907 * 2908 * For example, if system had 2 users (0 and 10) and a 3rd one (which is an ephemeral guest) was 2909 * created, the request would be: 2910 * 2911 * int32[0]: 42 // request id 2912 * int32[1]: 11 // Android id of the created user 2913 * int32[2]: 6 // Android flags (ephemeral guest) of the created user 2914 * int32[3]: 10 // current user 2915 * int32[4]: 0 // current user flags (none) 2916 * int32[5]: 3 // number of users 2917 * int32[6]: 0 // 1st user (user 0) 2918 * int32[7]: 0 // 1st user flags (none) 2919 * int32[8]: 10 // 2nd user (user 10) 2920 * int32[9]: 0 // 2nd user flags (none) 2921 * int32[19]: 11 // 3rd user (user 11) 2922 * int32[11]: 6 // 3rd user flags (ephemeral guest) 2923 * string: "ElGuesto" // name of the new user 2924 * 2925 * Then if the request succeeded, the HAL would return: 2926 * 2927 * int32[0]: 42 // request id 2928 * int32[1]: 1 // CreateUserStatus::SUCCESS 2929 * 2930 * But if it failed: 2931 * 2932 * int32[0]: 42 // request id 2933 * int32[1]: 2 // CreateUserStatus::FAILURE 2934 * string: "D'OH!" // The meaning is a blackbox - it's passed to the caller (like Settings UI), 2935 * // which in turn can take the proper action. 2936 * 2937 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 2938 * @access VehiclePropertyAccess:READ_WRITE 2939 */ 2940 CREATE_USER = ( 2941 0x0F09 2942 | VehiclePropertyGroup:SYSTEM 2943 | VehiclePropertyType:MIXED 2944 | VehicleArea:GLOBAL), 2945 2946 /** 2947 * Called by the Android System after an Android user was removed. 2948 * 2949 * The HAL can use this property to remove its equivalent user. 2950 * 2951 * This is write-only call - the Android System is not expecting a reply from the HAL. Hence, 2952 * this request should not fail - if the equivalent HAL user cannot be removed, then HAL should 2953 * mark it as inactive or recover in some other way. 2954 * 2955 * The request is made by setting the VehiclePropValue with the contents defined by 2956 * RemoveUserRequest. 2957 * 2958 * For example, if system had 3 users (0, 10, and 11) and user 11 was removed, the request 2959 * would be: 2960 * 2961 * int32[0]: 42 // request id 2962 * int32[1]: 11 // (Android user id of the removed user) 2963 * int32[2]: 0 // (Android user flags of the removed user) 2964 * int32[3]: 10 // current user 2965 * int32[4]: 0 // current user flags (none) 2966 * int32[5]: 2 // number of users 2967 * int32[6]: 0 // 1st user (user 0) 2968 * int32[7]: 0 // 1st user flags (none) 2969 * int32[8]: 10 // 2nd user (user 10) 2970 * int32[9]: 0 // 2nd user flags (none) 2971 * 2972 * @change_mode VehiclePropertyChangeMode:STATIC 2973 * @access VehiclePropertyAccess:WRITE 2974 */ 2975 REMOVE_USER = ( 2976 0x0F0A 2977 | VehiclePropertyGroup:SYSTEM 2978 | VehiclePropertyType:MIXED 2979 | VehicleArea:GLOBAL), 2980 2981 /** 2982 * Property used to associate (or query the association) the current user with vehicle-specific 2983 * identification mechanisms (such as key FOB). 2984 * 2985 * This is an optional user management property - the OEM could still support user management 2986 * without defining it. In fact, this property could be used without supporting the core 2987 * user-related functions described on INITIAL_USER_INFO. 2988 * 2989 * To query the association, the Android system gets the property, passing a VehiclePropValue 2990 * containing the types of associations are being queried, as defined by 2991 * UserIdentificationGetRequest. The HAL must return right away, returning a VehiclePropValue 2992 * with a UserIdentificationResponse. Notice that user identification should have already 2993 * happened while system is booting up and the VHAL implementation should only return the 2994 * already identified association (like the key FOB used to unlock the car), instead of starting 2995 * a new association from the get call. 2996 * 2997 * To associate types, the Android system sets the property, passing a VehiclePropValue 2998 * containing the types and values of associations being set, as defined by the 2999 * UserIdentificationSetRequest. The HAL will then use a property change event (whose 3000 * VehiclePropValue is defined by UserIdentificationResponse) indicating the current status of 3001 * the types after the request. 3002 * 3003 * For example, to query if the current user (10) is associated with the FOB that unlocked the 3004 * car and a custom mechanism provided by the OEM, the request would be: 3005 * 3006 * int32[0]: 42 // request id 3007 * int32[1]: 10 (Android user id) 3008 * int32[2]: 0 (Android user flags) 3009 * int32[3]: 2 (number of types queried) 3010 * int32[4]: 1 (1st type queried, UserIdentificationAssociationType::KEY_FOB) 3011 * int32[5]: 101 (2nd type queried, UserIdentificationAssociationType::CUSTOM_1) 3012 * 3013 * If the user is associated with the FOB but not with the custom mechanism, the response would 3014 * be: 3015 * 3016 * int32[0]: 42 // request id 3017 * int32[1]: 2 (number of associations in the response) 3018 * int32[2]: 1 (1st type: UserIdentificationAssociationType::KEY_FOB) 3019 * int32[3]: 2 (1st value: UserIdentificationAssociationValue::ASSOCIATED_CURRENT_USER) 3020 * int32[4]: 101 (2st type: UserIdentificationAssociationType::CUSTOM_1) 3021 * int32[5]: 4 (2nd value: UserIdentificationAssociationValue::NOT_ASSOCIATED_ANY_USER) 3022 * 3023 * Then to associate the user with the custom mechanism, a set request would be made: 3024 * 3025 * int32[0]: 43 // request id 3026 * int32[1]: 10 (Android user id) 3027 * int32[2]: 0 (Android user flags) 3028 * int32[3]: 1 (number of associations being set) 3029 * int32[4]: 101 (1st type: UserIdentificationAssociationType::CUSTOM_1) 3030 * int32[5]: 1 (1st value: UserIdentificationAssociationSetValue::ASSOCIATE_CURRENT_USER) 3031 * 3032 * If the request succeeded, the response would be simply: 3033 * 3034 * int32[0]: 43 // request id 3035 * int32[1]: 1 (number of associations in the response) 3036 * int32[2]: 101 (1st type: UserIdentificationAssociationType::CUSTOM_1) 3037 * int32[3]: 1 (1st value: UserIdentificationAssociationValue::ASSOCIATED_CURRENT_USER) 3038 * 3039 * Notice that the set request adds associations, but doesn't remove the existing ones. In the 3040 * example above, the end state would be 2 associations (FOB and CUSTOM_1). If we wanted to 3041 * associate the user with just CUSTOM_1 but not FOB, then the request should have been: 3042 * 3043 * int32[0]: 43 // request id 3044 * int32[1]: 10 (Android user id) 3045 * int32[2]: 2 (number of types set) 3046 * int32[3]: 1 (1st type: UserIdentificationAssociationType::KEY_FOB) 3047 * int32[4]: 2 (1st value: UserIdentificationAssociationValue::DISASSOCIATE_CURRENT_USER) 3048 * int32[5]: 101 (2nd type: UserIdentificationAssociationType::CUSTOM_1) 3049 * int32[6]: 1 (2nd value: UserIdentificationAssociationValue::ASSOCIATE_CURRENT_USER) 3050 * 3051 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3052 * @access VehiclePropertyAccess:READ_WRITE 3053 */ 3054 USER_IDENTIFICATION_ASSOCIATION = ( 3055 0x0F0B 3056 | VehiclePropertyGroup:SYSTEM 3057 | VehiclePropertyType:MIXED 3058 | VehicleArea:GLOBAL), 3059 3060 /** 3061 * Enable/request an EVS service. 3062 * 3063 * The property provides a generalized way to trigger EVS services. VHAL 3064 * should use this property to request Android to start or stop EVS service. 3065 * 3066 * int32Values[0] = a type of the EVS service. The value must be one of enums in 3067 * EvsServiceType. 3068 * int32Values[1] = the state of the EVS service. The value must be one of enums in 3069 * EvsServiceState. 3070 * 3071 * For example, to enable rear view EVS service, android side can set the property value as 3072 * [EvsServiceType::REAR_VIEW, EvsServiceState::ON]. 3073 * 3074 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3075 * @access VehiclePropertyAccess:READ 3076 */ 3077 EVS_SERVICE_REQUEST = ( 3078 0x0F10 3079 | VehiclePropertyGroup:SYSTEM 3080 | VehiclePropertyType:INT32_VEC 3081 | VehicleArea:GLOBAL), 3082 3083 /** 3084 * Defines a request to apply power policy. 3085 * 3086 * VHAL sets this property to change car power policy. Car power policy service subscribes to 3087 * this property and actually changes the power policy. 3088 * The request is made by setting the VehiclePropValue with the ID of a power policy which is 3089 * defined at /vendor/etc/power_policy.xml. If the given ID is not defined, car power policy 3090 * service ignores the request and the current power policy is maintained. 3091 * 3092 * string: "sample_policy_id" // power policy ID 3093 * 3094 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3095 * @access VehiclePropertyAccess:READ 3096 */ 3097 POWER_POLICY_REQ = ( 3098 0x0F21 3099 | VehiclePropertyGroup:SYSTEM 3100 | VehiclePropertyType:STRING 3101 | VehicleArea:GLOBAL), 3102 3103 /** 3104 * Defines a request to set the power polic group used to decide a default power policy per 3105 * power status transition. 3106 * 3107 * VHAL sets this property with the ID of a power policy group in order to set the default power 3108 * policy applied at power status transition. Power policy groups are defined at 3109 * /vendor/etc/power_policy.xml. If the given ID is not defined, car power policy service 3110 * ignores the request. 3111 * Car power policy service subscribes to this property and sets the power policy group. 3112 * The actual application of power policy takes place when the system power status changes and 3113 * there is a valid mapped power policy for the new power status. 3114 * 3115 * string: "sample_policy_group_id" // power policy group ID 3116 * 3117 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3118 * @access VehiclePropertyAccess:READ 3119 */ 3120 POWER_POLICY_GROUP_REQ = ( 3121 0x0F22 3122 | VehiclePropertyGroup:SYSTEM 3123 | VehiclePropertyType:STRING 3124 | VehicleArea:GLOBAL), 3125 3126 /** 3127 * Notifies the current power policy to VHAL layer. 3128 * 3129 * Car power policy service sets this property when the current power policy is changed. 3130 * 3131 * string: "sample_policy_id" // power policy ID 3132 * 3133 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3134 * @access VehiclePropertyAccess:READ_WRITE 3135 */ 3136 CURRENT_POWER_POLICY = ( 3137 0x0F23 3138 | VehiclePropertyGroup:SYSTEM 3139 | VehiclePropertyType:STRING 3140 | VehicleArea:GLOBAL), 3141 3142 /** 3143 * Defines an event that car watchdog updates to tell it's alive. 3144 * 3145 * Car watchdog sets this property to system uptime in milliseconds at every 3 second. 3146 * During the boot, the update may take longer time. 3147 * 3148 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3149 * @access VehiclePropertyAccess:WRITE 3150 */ 3151 WATCHDOG_ALIVE = ( 3152 0xF31 3153 | VehiclePropertyGroup:SYSTEM 3154 | VehiclePropertyType:INT64 3155 | VehicleArea:GLOBAL), 3156 3157 /** 3158 * Defines a process terminated by car watchdog and the reason of termination. 3159 * 3160 * int32Values[0]: 1 // ProcessTerminationReason showing why a process is terminated. 3161 * string: "/system/bin/log" // Process execution command. 3162 * 3163 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3164 * @access VehiclePropertyAccess:WRITE 3165 */ 3166 WATCHDOG_TERMINATED_PROCESS = ( 3167 0x0F32 3168 | VehiclePropertyGroup:SYSTEM 3169 | VehiclePropertyType:MIXED 3170 | VehicleArea:GLOBAL), 3171 3172 /** 3173 * Defines an event that VHAL signals to car watchdog as a heartbeat. 3174 * 3175 * If VHAL supports this property, VHAL should write system uptime to this property at every 3 3176 * second. Car watchdog subscribes to this property and checks if the property is updated at 3177 * every 3 second. With the buffer time of 3 second, car watchdog waits for a heart beat to be 3178 * signaled up to 6 seconds from the last heart beat. If it isn’t, car watchdog considers 3179 * VHAL unhealthy and terminates it. 3180 * If this property is not supported by VHAL, car watchdog doesn't check VHAL health status. 3181 * 3182 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3183 * @access VehiclePropertyAccess:READ 3184 */ 3185 VHAL_HEARTBEAT = ( 3186 0x0F33 3187 | VehiclePropertyGroup:SYSTEM 3188 | VehiclePropertyType:INT64 3189 | VehicleArea:GLOBAL), 3190 3191 /** 3192 * Starts the ClusterUI in cluster display. 3193 * 3194 * int32: the type of ClusterUI to show 3195 * 0 indicates ClusterHome, that is a home screen of cluster display, and provides 3196 * the default UI and a kind of launcher functionality for cluster display. 3197 * the other values are followed by OEM's definition. 3198 * 3199 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3200 * @access VehiclePropertyAccess:READ 3201 */ 3202 CLUSTER_SWITCH_UI = ( 3203 0x0F34 3204 | VehiclePropertyGroup:SYSTEM 3205 | VehiclePropertyType:INT32 3206 | VehicleArea:GLOBAL), 3207 3208 /** 3209 * Changes the state of the cluster display. 3210 * 3211 * Bounds: the area to render the cluster Activity. 3212 * Inset: the area which Activity should avoid from placing any important 3213 * information. 3214 * 3215 * int32[0]: on/off: 0 - off, 1 - on, -1 - don't care 3216 * int32[1]: Bounds - left: positive number - left position in pixels 3217 -1 - don't care (should set all Bounds fields) 3218 * int32[2]: Bounds - top: same format with 'left' 3219 * int32[3]: Bounds - right: same format with 'left' 3220 * int32[4]: Bounds - bottom: same format with 'left' 3221 * int32[5]: Inset - left: positive number - actual left inset value in pixels 3222 -1 - don't care (should set "don't care" all Inset fields) 3223 * int32[6]: Inset - top: same format with 'left' 3224 * int32[7]: Inset - right: same format with 'left' 3225 * int32[8]: Inset - bottom: same format with 'left' 3226 * 3227 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3228 * @access VehiclePropertyAccess:READ 3229 */ 3230 CLUSTER_DISPLAY_STATE = ( 3231 0x0F35 3232 | VehiclePropertyGroup:SYSTEM 3233 | VehiclePropertyType:INT32_VEC 3234 | VehicleArea:GLOBAL), 3235 3236 /** 3237 * Reports the current display state and ClusterUI state. 3238 * 3239 * ClusterHome will send this message when it handles CLUSTER_SWITCH_UI, CLUSTER_DISPLAY_STATE. 3240 * 3241 * In addition, ClusterHome should send this message when it starts for the first time. 3242 * When ClusterOS receives this message and if the internal expectation is different with the 3243 * received message, then it should send CLUSTER_SWITCH_UI, CLUSTER_DISPLAY_STATE again to 3244 * match the state. 3245 * 3246 * int32[0]: on/off: 0 - off, 1 - on 3247 * int32[1]: Bounds - left 3248 * int32[2]: Bounds - top 3249 * int32[3]: Bounds - right 3250 * int32[4]: Bounds - bottom 3251 * int32[5]: Inset - left 3252 * int32[6]: Inset - top 3253 * int32[7]: Inset - right 3254 * int32[8]: Inset - bottom 3255 * int32[9]: the type of ClusterUI in the fullscreen or main screen. 3256 * 0 indicates ClusterHome. 3257 * the other values are followed by OEM's definition. 3258 * int32[10]: the type of ClusterUI in sub screen if the currently two UIs are shown. 3259 * -1 indicates the area isn't used any more. 3260 * bytes: the array to represent the availability of ClusterUI. 3261 * 0 indicates non-available and 1 indicates available. 3262 * For example, let's assume a car supports 3 OEM defined ClusterUI like HOME, MAPS, CALL, 3263 * and it only supports CALL UI only when the cellular network is available. Then, if the 3264 * nework is avaibale, it'll send [1 1 1], and if it's out of network, it'll send [1 1 0]. 3265 * 3266 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3267 * @access VehiclePropertyAccess:WRITE 3268 */ 3269 CLUSTER_REPORT_STATE = ( 3270 0x0F36 3271 | VehiclePropertyGroup:SYSTEM 3272 | VehiclePropertyType:MIXED 3273 | VehicleArea:GLOBAL), 3274 3275 /** 3276 * Requests to change the cluster display state to show some ClusterUI. 3277 * 3278 * When the current display state is off and ClusterHome sends this message to ClusterOS to 3279 * request to turn the display on to show some specific ClusterUI. 3280 * ClusterOS should response this with CLUSTER_DISPLAY_STATE. 3281 * 3282 * int32: the type of ClusterUI to show 3283 * 3284 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3285 * @access VehiclePropertyAccess:WRITE 3286 */ 3287 CLUSTER_REQUEST_DISPLAY = ( 3288 0x0F37 3289 | VehiclePropertyGroup:SYSTEM 3290 | VehiclePropertyType:INT32 3291 | VehicleArea:GLOBAL), 3292 3293 /** 3294 * Informs the current navigation state. 3295 * 3296 * bytes: the serialized message of NavigationStateProto. 3297 * 3298 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3299 * @access VehiclePropertyAccess:WRITE 3300 */ 3301 CLUSTER_NAVIGATION_STATE = ( 3302 0x0F38 3303 | VehiclePropertyGroup:SYSTEM 3304 | VehiclePropertyType:BYTES 3305 | VehicleArea:GLOBAL), 3306 3307 /** 3308 * Electronic Toll Collection card type. 3309 * 3310 * This property indicates the type of ETC card in this vehicle. 3311 * If the head unit is aware of an ETC card attached to the vehicle, this property should 3312 * return the type of card attached; otherwise, this property should be UNAVAILABLE. 3313 * 3314 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3315 * @access VehiclePropertyAccess:READ 3316 * @data_enum ElectronicTollCollectionCardType 3317 */ 3318 ELECTRONIC_TOLL_COLLECTION_CARD_TYPE = ( 3319 0x0F39 3320 | VehiclePropertyGroup:SYSTEM 3321 | VehiclePropertyType:INT32 3322 | VehicleArea:GLOBAL), 3323 3324 /** 3325 * Electronic Toll Collection card status. 3326 * 3327 * This property indicates the status of ETC card in this vehicle. 3328 * If the head unit is aware of an ETC card attached to the vehicle, 3329 * ELECTRONIC_TOLL_COLLECTION_CARD_TYPE gives that status of the card; otherwise, 3330 * this property should be UNAVAILABLE. 3331 * 3332 * @change_mode VehiclePropertyChangeMode:ON_CHANGE 3333 * @access VehiclePropertyAccess:READ 3334 * @data_enum ElectronicTollCollectionCardStatus 3335 */ 3336 ELECTRONIC_TOLL_COLLECTION_CARD_STATUS = ( 3337 0x0F3A 3338 | VehiclePropertyGroup:SYSTEM 3339 | VehiclePropertyType:INT32 3340 | VehicleArea:GLOBAL), 3341}; 3342 3343/** 3344 * Used by ELECTRONIC_TOLL_COLLECTION_CARD_TYPE. 3345 */ 3346enum ElectronicTollCollectionCardType : int32_t { 3347 // Type is unknown or not in the list below. 3348 UNKNOWN = 0, 3349 // A Japanese ETC card reader that does not support ETC 2.0. 3350 JP_ELECTRONIC_TOLL_COLLECTION_CARD = 1, 3351 // A Japanese ETC 2.0 card reader. 3352 JP_ELECTRONIC_TOLL_COLLECTION_CARD_V2 = 2, 3353}; 3354 3355/** 3356 * Used by ELECTRONIC_TOLL_COLLECTION_CARD_STATUS. 3357 */ 3358enum ElectronicTollCollectionCardStatus : int32_t { 3359 // Status could not be determined 3360 UNKNOWN = 0, 3361 // A valid ETC card is present 3362 ELECTRONIC_TOLL_COLLECTION_CARD_VALID = 1, 3363 // An ETC card is present, but it is expired or otherwise invalid 3364 ELECTRONIC_TOLL_COLLECTION_CARD_INVALID = 2, 3365 // No ETC card is inserted in the reader. 3366 ELECTRONIC_TOLL_COLLECTION_CARD_NOT_INSERTED = 3, 3367}; 3368 3369/** 3370 * Used by SUPPORT_CUSTOMIZE_VENDOR_PERMISSION to indicate the permission of vendor properties. 3371 */ 3372enum VehicleVendorPermission : int32_t { 3373 PERMISSION_DEFAULT = 0x00000000, 3374 3375 // permissions for the property related with window 3376 PERMISSION_SET_VENDOR_CATEGORY_WINDOW= 0X00000001, 3377 PERMISSION_GET_VENDOR_CATEGORY_WINDOW = 0x00000002, 3378 // permissions for the property related with door 3379 PERMISSION_SET_VENDOR_CATEGORY_DOOR = 0x00000003, 3380 PERMISSION_GET_VENDOR_CATEGORY_DOOR = 0x00000004, 3381 // permissions for the property related with seat 3382 PERMISSION_SET_VENDOR_CATEGORY_SEAT = 0x00000005, 3383 PERMISSION_GET_VENDOR_CATEGORY_SEAT = 0x00000006, 3384 // permissions for the property related with mirror 3385 PERMISSION_SET_VENDOR_CATEGORY_MIRROR= 0x00000007, 3386 PERMISSION_GET_VENDOR_CATEGORY_MIRROR = 0x00000008, 3387 3388 // permissions for the property related with car's information 3389 PERMISSION_SET_VENDOR_CATEGORY_INFO = 0x00000009, 3390 PERMISSION_GET_VENDOR_CATEGORY_INFO = 0x0000000A, 3391 // permissions for the property related with car's engine 3392 PERMISSION_SET_VENDOR_CATEGORY_ENGINE= 0x0000000B, 3393 PERMISSION_GET_VENDOR_CATEGORY_ENGINE = 0x0000000C, 3394 // permissions for the property related with car's HVAC 3395 PERMISSION_SET_VENDOR_CATEGORY_HVAC = 0x0000000D, 3396 PERMISSION_GET_VENDOR_CATEGORY_HVAC = 0x0000000E, 3397 // permissions for the property related with car's light 3398 PERMISSION_SET_VENDOR_CATEGORY_LIGHT = 0x0000000F, 3399 PERMISSION_GET_VENDOR_CATEGORY_LIGHT = 0x00000010, 3400 3401 // permissions reserved for other vendor permission 3402 PERMISSION_SET_VENDOR_CATEGORY_1 = 0x00010000, 3403 PERMISSION_GET_VENDOR_CATEGORY_1 = 0x00011000, 3404 PERMISSION_SET_VENDOR_CATEGORY_2 = 0x00020000, 3405 PERMISSION_GET_VENDOR_CATEGORY_2 = 0x00021000, 3406 PERMISSION_SET_VENDOR_CATEGORY_3 = 0x00030000, 3407 PERMISSION_GET_VENDOR_CATEGORY_3 = 0x00031000, 3408 PERMISSION_SET_VENDOR_CATEGORY_4 = 0x00040000, 3409 PERMISSION_GET_VENDOR_CATEGORY_4 = 0x00041000, 3410 PERMISSION_SET_VENDOR_CATEGORY_5 = 0x00050000, 3411 PERMISSION_GET_VENDOR_CATEGORY_5 = 0x00051000, 3412 PERMISSION_SET_VENDOR_CATEGORY_6 = 0x00060000, 3413 PERMISSION_GET_VENDOR_CATEGORY_6 = 0x00061000, 3414 PERMISSION_SET_VENDOR_CATEGORY_7 = 0x00070000, 3415 PERMISSION_GET_VENDOR_CATEGORY_7 = 0x00071000, 3416 PERMISSION_SET_VENDOR_CATEGORY_8 = 0x00080000, 3417 PERMISSION_GET_VENDOR_CATEGORY_8 = 0x00081000, 3418 PERMISSION_SET_VENDOR_CATEGORY_9 = 0x00090000, 3419 PERMISSION_GET_VENDOR_CATEGORY_9 = 0x00091000, 3420 PERMISSION_SET_VENDOR_CATEGORY_10 = 0x000A0000, 3421 PERMISSION_GET_VENDOR_CATEGORY_10 = 0x000A1000, 3422 3423 // Indicate not available for android to access. 3424 PERMISSION_NOT_ACCESSIBLE = 0xF0000000 3425}; 3426 3427/** 3428 * Used by seat occupancy to enumerate the current occupancy state of the seat. 3429 */ 3430enum VehicleSeatOccupancyState : int32_t { 3431 3432 UNKNOWN = 0, 3433 VACANT = 1, 3434 OCCUPIED = 2 3435}; 3436 3437/** 3438 * Used by EVS_SERVICE_REQUEST to enumerate the service's type. 3439 */ 3440enum EvsServiceType : int32_t { 3441 3442 REARVIEW = 0, 3443 SURROUNDVIEW = 1, 3444}; 3445 3446/** 3447 * Used by EVS_SERVICE_REQUEST to enumerate the service's state. 3448 */ 3449enum EvsServiceState : int32_t { 3450 3451 OFF = 0, 3452 ON = 1, 3453}; 3454 3455/** 3456 * Index in int32VAlues for VehicleProperty#EVS_SERVICE_REQUEST property. 3457 */ 3458enum EvsServiceRequestIndex : int32_t { 3459 3460 TYPE = 0, 3461 STATE = 1, 3462}; 3463 3464/** 3465 * Used by lights state properties to enumerate the current state of the lights. 3466 * 3467 * Most XXX_LIGHTS_STATE properties will only report ON and OFF states. Only 3468 * the HEADLIGHTS_STATE property will report DAYTIME_RUNNING. 3469 */ 3470enum VehicleLightState : int32_t { 3471 3472 OFF = 0, 3473 ON = 1, 3474 DAYTIME_RUNNING = 2 3475}; 3476 3477/** 3478 * Used by lights switch properties to enumerate user selected switch setting. 3479 * 3480 * XXX_LIGHTS_SWITCH properties report the switch settings that the user 3481 * selects. The switch setting may be decoupled from the state reported if the 3482 * user selects AUTOMATIC. 3483 */ 3484enum VehicleLightSwitch : int32_t { 3485 OFF = 0, 3486 ON = 1, 3487 /** 3488 * Daytime running lights mode. Most cars automatically use DRL but some 3489 * cars allow the user to activate them manually. 3490 */ 3491 DAYTIME_RUNNING = 2, 3492 /** 3493 * Allows the vehicle ECU to set the lights automatically 3494 */ 3495 AUTOMATIC = 0x100, 3496}; 3497 3498/** 3499 * Used by INFO_EV_CONNECTOR_TYPE to enumerate the type of connectors 3500 * available to charge the vehicle. 3501 */ 3502enum EvConnectorType : int32_t { 3503 /** 3504 * Default type if the vehicle does not know or report the EV connector 3505 * type. 3506 */ 3507 UNKNOWN = 0, 3508 IEC_TYPE_1_AC = 1, // aka Yazaki 3509 IEC_TYPE_2_AC = 2, // aka Mennekes 3510 IEC_TYPE_3_AC = 3, // aka Scame 3511 IEC_TYPE_4_DC = 4, // aka CHAdeMO 3512 IEC_TYPE_1_CCS_DC = 5, // aka Combo 1 3513 IEC_TYPE_2_CCS_DC = 6, // aka Combo 2 3514 TESLA_ROADSTER = 7, 3515 TESLA_HPWC = 8, 3516 TESLA_SUPERCHARGER = 9, 3517 GBT_AC = 10, 3518 GBT_DC = 11, 3519 3520 /** 3521 * Connector type to use when no other types apply. Before using this 3522 * value, work with Google to see if the EvConnectorType enum can be 3523 * extended with an appropriate value. 3524 */ 3525 OTHER = 101, 3526}; 3527 3528/** 3529 * Used by INFO_FUEL_DOOR_LOCATION/INFO_CHARGE_PORT_LOCATION to enumerate fuel door or 3530 * ev port location. 3531 */ 3532enum PortLocationType : int32_t { 3533 /** 3534 * Default type if the vehicle does not know or report the Fuel door 3535 * and ev port location. 3536 */ 3537 UNKNOWN = 0, 3538 FRONT_LEFT = 1, 3539 FRONT_RIGHT = 2, 3540 REAR_RIGHT = 3, 3541 REAR_LEFT = 4, 3542 FRONT = 5, 3543 REAR = 6, 3544}; 3545 3546/** 3547 * Used by INFO_FUEL_TYPE to enumerate the type of fuels this vehicle uses. 3548 * Consistent with projection protocol. 3549 */ 3550enum FuelType : int32_t { 3551 /** 3552 * Fuel type to use if the HU does not know on which types of fuel the vehicle 3553 * runs. The use of this value is generally discouraged outside of aftermarket units. 3554 */ 3555 FUEL_TYPE_UNKNOWN = 0, 3556 /** Unleaded gasoline */ 3557 FUEL_TYPE_UNLEADED = 1, 3558 /** Leaded gasoline */ 3559 FUEL_TYPE_LEADED = 2, 3560 /** Diesel #1 */ 3561 FUEL_TYPE_DIESEL_1 = 3, 3562 /** Diesel #2 */ 3563 FUEL_TYPE_DIESEL_2 = 4, 3564 /** Biodiesel */ 3565 FUEL_TYPE_BIODIESEL = 5, 3566 /** 85% ethanol/gasoline blend */ 3567 FUEL_TYPE_E85 = 6, 3568 /** Liquified petroleum gas */ 3569 FUEL_TYPE_LPG = 7, 3570 /** Compressed natural gas */ 3571 FUEL_TYPE_CNG = 8, 3572 /** Liquified natural gas */ 3573 FUEL_TYPE_LNG = 9, 3574 /** Electric */ 3575 FUEL_TYPE_ELECTRIC = 10, 3576 /** Hydrogen fuel cell */ 3577 FUEL_TYPE_HYDROGEN = 11, 3578 /** 3579 * Fuel type to use when no other types apply. Before using this value, work with 3580 * Google to see if the FuelType enum can be extended with an appropriate value. 3581 */ 3582 FUEL_TYPE_OTHER = 12, 3583}; 3584 3585/** 3586 * Bit flags for fan direction 3587 */ 3588enum VehicleHvacFanDirection : int32_t { 3589 UNKNOWN = 0x0, 3590 3591 FACE = 0x1, 3592 FLOOR = 0x2, 3593 /** 3594 * FACE_AND_FLOOR = FACE | FLOOR 3595 */ 3596 FACE_AND_FLOOR = 0x3, 3597 DEFROST = 0x4, 3598 /** 3599 * DEFROST_AND_FLOOR = DEFROST | FLOOR 3600 */ 3601 DEFROST_AND_FLOOR = 0x06, 3602}; 3603 3604enum VehicleOilLevel : int32_t { 3605 /** 3606 * Oil level values 3607 */ 3608 CRITICALLY_LOW = 0, 3609 LOW = 1, 3610 NORMAL = 2, 3611 HIGH = 3, 3612 ERROR = 4, 3613}; 3614 3615enum VehicleApPowerStateConfigFlag : int32_t { 3616 /** 3617 * AP can enter deep sleep state. If not set, AP will always shutdown from 3618 * VehicleApPowerState#SHUTDOWN_PREPARE power state. 3619 */ 3620 ENABLE_DEEP_SLEEP_FLAG = 0x1, 3621 3622 /** 3623 * The power controller can power on AP from off state after timeout 3624 * specified in VehicleApPowerSet VEHICLE_AP_POWER_SET_SHUTDOWN_READY message. 3625 */ 3626 CONFIG_SUPPORT_TIMER_POWER_ON_FLAG = 0x2, 3627}; 3628 3629enum VehicleApPowerStateReq : int32_t { 3630 /** 3631 * This requests Android to enter its normal operating state. 3632 * This may be sent after the AP has reported 3633 * VehicleApPowerStateReport#DEEP_SLEEP_EXIT, 3634 * VehicleApPowerStateReport#SHUTDOWN_CANCELLED, or 3635 * VehicleApPowerStateReport#WAIT_FOR_VHAL. 3636 */ 3637 ON = 0, 3638 3639 /** 3640 * The power controller issues this request to shutdown the system. 3641 * This may be sent after the AP has reported 3642 * VehicleApPowerStateReport#DEEP_SLEEP_EXIT, 3643 * VehicleApPowerStateReport#ON, 3644 * VehicleApPowerStateReport#SHUTDOWN_CANCELLED, 3645 * VehicleApPowerStateReport#SHUTDOWN_POSTPONE, 3646 * VehicleApPowerStateReport#SHUTDOWN_PREPARE, or 3647 * VehicleApPowerStateReport#WAIT_FOR_VHAL. 3648 * 3649 * int32Values[1] : One of VehicleApPowerStateShutdownParam. 3650 * This parameter indicates if the AP should shut 3651 * down fully or sleep. This parameter also 3652 * indicates if the shutdown should be immediate 3653 * or if it can be postponed. If the shutdown can 3654 * be postponed, AP requests postponing by sending 3655 * VehicleApPowerStateReport#SHUTDOWN_POSTPONE. 3656 */ 3657 SHUTDOWN_PREPARE = 1, 3658 3659 /** 3660 * Cancel the shutdown. 3661 * This may be sent after the AP has reported 3662 * VehicleApPowerStateReport#SHUTDOWN_POSTPONE or 3663 * VehicleApPowerStateReport#SHUTDOWN_PREPARE. 3664 * After receiving this request, the AP will report 3665 * VehicleApPowerStateReport#WAIT_FOR_VHAL in preparation to going ON. 3666 */ 3667 CANCEL_SHUTDOWN = 2, 3668 3669 /** 3670 * Completes the shutdown process. 3671 * This may be sent after the AP has reported 3672 * VehicleApPowerStateReport#DEEP_SLEEP_ENTRY or 3673 * VehicleApPowerStateReport#SHUTDOWN_START. The AP will not report new 3674 * state information after receiving this request. 3675 */ 3676 FINISHED = 3, 3677}; 3678 3679/** 3680 * Index in int32Values for VehicleProperty#AP_POWER_STATE_REQ property. 3681 */ 3682enum VehicleApPowerStateReqIndex : int32_t { 3683 STATE = 0, 3684 ADDITIONAL = 1, 3685}; 3686 3687 3688 3689enum VehicleApPowerStateShutdownParam : int32_t { 3690 /** AP must shutdown immediately. Postponing is not allowed. */ 3691 SHUTDOWN_IMMEDIATELY = 1, 3692 3693 /** AP can enter deep sleep instead of shutting down completely. */ 3694 CAN_SLEEP = 2, 3695 3696 /** AP can only shutdown with postponing allowed. */ 3697 SHUTDOWN_ONLY = 3, 3698 3699 /** 3700 * AP may enter deep sleep, but must either sleep or shut down immediately. 3701 * Postponing is not allowed. */ 3702 SLEEP_IMMEDIATELY = 4, 3703}; 3704 3705enum VehicleApPowerStateReport : int32_t { 3706 /** 3707 * The device has booted. CarService has initialized and is ready to accept commands 3708 * from VHAL. The user is not logged in, and vendor apps and services are expected to 3709 * control the display and audio. 3710 * After reporting this state, AP will accept VehicleApPowerStateReq#ON or 3711 * VehicleApPowerStateReq#SHUTDOWN_PREPARE. Other power state requests are ignored. 3712 */ 3713 WAIT_FOR_VHAL = 0x1, 3714 3715 /** 3716 * AP is ready to suspend. 3717 * The AP will not send any more state reports after this. 3718 * After reporting this state, AP will accept VehicleApPowerStateReq#FINISHED. 3719 * Other power state requests are ignored. 3720 * 3721 * int32Values[1]: Time to turn AP back on, in seconds. Power controller should turn on 3722 * AP after the specified time has elapsed, so AP can run tasks like 3723 * update. If this value is 0, no wake up is requested. The power 3724 * controller may not necessarily support timed wake-up. 3725 */ 3726 DEEP_SLEEP_ENTRY = 0x2, 3727 3728 /** 3729 * AP is exiting from deep sleep state. 3730 * After reporting this state, AP will accept VehicleApPowerStateReq#ON or 3731 * VehicleApPowerStateReq#SHUTDOWN_PREPARE. Other power state requests are ignored. 3732 */ 3733 DEEP_SLEEP_EXIT = 0x3, 3734 3735 /** 3736 * AP sends this message repeatedly while cleanup and idle tasks execute. 3737 * After reporting this state, AP will accept VehicleApPowerStateReq#SHUTDOWN_PREPARE 3738 * requesting immediate shutdown or VehicleApPowerStateReq#CANCEL_SHUTDOWN. Other 3739 * power state requests are ignored. 3740 * 3741 * int32Values[1]: Time to postpone shutdown in ms. Maximum value is 3742 * 5000 ms. 3743 * If AP needs more time, it will send another SHUTDOWN_POSTPONE 3744 * message before the previous one expires. 3745 */ 3746 SHUTDOWN_POSTPONE = 0x4, 3747 3748 /** 3749 * AP is ready to shutdown. 3750 * The AP will not send any more state reports after this. 3751 * After reporting this state, AP will accept VehicleApPowerStateReq#FINISHED. 3752 * Other power state requests are ignored. 3753 * 3754 * int32Values[1]: Time to turn AP back on, in seconds. Power controller should turn on 3755 * AP after the specified time has elapsed so AP can run tasks like 3756 * update. If this value is 0, no wake up is specified. The power 3757 * controller may not necessarily support timed wake-up. 3758 */ 3759 SHUTDOWN_START = 0x5, 3760 3761 /** 3762 * AP is entering its normal operating state. 3763 * After reporting this state, AP will accept VehicleApPowerStateReq#SHUTDOWN_PREPARE. 3764 * Other power state requests are ignored. 3765 */ 3766 ON = 0x6, 3767 3768 /** 3769 * AP is preparing to shut down. In this state, Garage Mode is active and idle 3770 * tasks are allowed to run. 3771 * After reporting this state, AP will accept VehicleApPowerStateReq#SHUTDOWN_PREPARE 3772 * requesting immediate shutdown or VehicleApPowerStateReq#CANCEL_SHUTDOWN. Other 3773 * power state requests are ignored. 3774 */ 3775 SHUTDOWN_PREPARE = 0x7, 3776 3777 /** 3778 * AP has stopped preparing to shut down. 3779 * After reporting this state, AP will accept VehicleApPowerStateReq#ON or 3780 * VehicleApPowerStateReq#SHUTDOWN_PREPARE. Other power state requests are ignored. 3781 */ 3782 SHUTDOWN_CANCELLED = 0x8, 3783}; 3784 3785enum VehicleHwKeyInputAction : int32_t { 3786 /** Key down */ 3787 ACTION_DOWN = 0, 3788 3789 /** Key up */ 3790 ACTION_UP = 1, 3791}; 3792 3793enum VehicleDisplay : int32_t { 3794 /** The primary Android display (for example, center console) */ 3795 MAIN = 0, 3796 3797 INSTRUMENT_CLUSTER = 1, 3798}; 3799 3800/** 3801 * Units used for int or float type with no attached enum types. 3802 */ 3803enum VehicleUnit : int32_t { 3804 SHOULD_NOT_USE = 0x000, 3805 3806 METER_PER_SEC = 0x01, 3807 RPM = 0x02, 3808 HERTZ = 0x03, 3809 PERCENTILE = 0x10, 3810 MILLIMETER = 0x20, 3811 METER = 0x21, 3812 KILOMETER = 0x23, 3813 MILE = 0x24, 3814 CELSIUS = 0x30, 3815 FAHRENHEIT = 0x31, 3816 KELVIN = 0x32, 3817 MILLILITER = 0x40, 3818 LITER = 0x41, 3819 3820 /** deprecated. Use US_GALLON instead. */ 3821 GALLON = 0x42, 3822 US_GALLON = 0x42, 3823 IMPERIAL_GALLON = 0x43, 3824 NANO_SECS = 0x50, 3825 MILLI_SECS = 0x51, 3826 SECS = 0x53, 3827 YEAR = 0x59, 3828 3829 // Electrical Units 3830 WATT_HOUR = 0x60, 3831 MILLIAMPERE = 0x61, 3832 MILLIVOLT = 0x62, 3833 MILLIWATTS = 0x63, 3834 AMPERE_HOURS = 0x64, 3835 KILOWATT_HOUR = 0x65, 3836 3837 KILOPASCAL = 0x70, 3838 PSI = 0x71, 3839 BAR = 0x72, 3840 DEGREES = 0x80, 3841 3842 MILES_PER_HOUR = 0x90, 3843 KILOMETERS_PER_HOUR = 0x91, 3844}; 3845 3846/** 3847 * This describes how value of property can change. 3848 */ 3849enum VehiclePropertyChangeMode : int32_t { 3850 /** 3851 * Property of this type must never be changed. Subscription is not supported 3852 * for these properties. 3853 */ 3854 STATIC = 0x00, 3855 3856 /** 3857 * Properties of this type must report when there is a change. 3858 * IVehicle#get call must return the current value. 3859 * Set operation for this property is assumed to be asynchronous. When the 3860 * property is read (using IVehicle#get) after IVehicle#set, it may still 3861 * return old value until underlying H/W backing this property has actually 3862 * changed the state. Once state is changed, the property must dispatch 3863 * changed value as event. 3864 */ 3865 ON_CHANGE = 0x01, 3866 3867 /** 3868 * Properties of this type change continuously and require a fixed rate of 3869 * sampling to retrieve the data. Implementers may choose to send extra 3870 * notifications on significant value changes. 3871 */ 3872 CONTINUOUS = 0x02, 3873}; 3874 3875/** 3876 * Property config defines the capabilities of it. User of the API 3877 * must first get the property config to understand the output from get() 3878 * commands and also to ensure that set() or events commands are in sync with 3879 * the expected output. 3880 */ 3881enum VehiclePropertyAccess : int32_t { 3882 NONE = 0x00, 3883 3884 READ = 0x01, 3885 WRITE = 0x02, 3886 READ_WRITE = 0x03, 3887}; 3888 3889/** 3890 * Property status is a dynamic value that may change based on the vehicle state. 3891 */ 3892enum VehiclePropertyStatus : int32_t { 3893 /** Property is available and behaving normally */ 3894 AVAILABLE = 0x00, 3895 /** 3896 * A property in this state is not available for reading and writing. This 3897 * is a transient state that depends on the availability of the underlying 3898 * implementation (e.g. hardware or driver). It MUST NOT be used to 3899 * represent features that this vehicle is always incapable of. A get() of 3900 * a property in this state MAY return an undefined value, but MUST 3901 * correctly describe its status as UNAVAILABLE A set() of a property in 3902 * this state MAY return NOT_AVAILABLE. The HAL implementation MUST ignore 3903 * the value of the status field when writing a property value coming from 3904 * Android. 3905 */ 3906 UNAVAILABLE = 0x01, 3907 /** There is an error with this property. */ 3908 ERROR = 0x02, 3909}; 3910 3911/** 3912 * Various gears which can be selected by user and chosen in system. 3913 */ 3914enum VehicleGear : int32_t { 3915 GEAR_UNKNOWN = 0x0000, 3916 3917 GEAR_NEUTRAL = 0x0001, 3918 GEAR_REVERSE = 0x0002, 3919 GEAR_PARK = 0x0004, 3920 GEAR_DRIVE = 0x0008, 3921 GEAR_1 = 0x0010, 3922 GEAR_2 = 0x0020, 3923 GEAR_3 = 0x0040, 3924 GEAR_4 = 0x0080, 3925 GEAR_5 = 0x0100, 3926 GEAR_6 = 0x0200, 3927 GEAR_7 = 0x0400, 3928 GEAR_8 = 0x0800, 3929 GEAR_9 = 0x1000, 3930}; 3931 3932/** 3933 * Various Seats in the car. 3934 */ 3935enum VehicleAreaSeat : int32_t { 3936 ROW_1_LEFT = 0x0001, 3937 ROW_1_CENTER = 0x0002, 3938 ROW_1_RIGHT = 0x0004, 3939 ROW_2_LEFT = 0x0010, 3940 ROW_2_CENTER = 0x0020, 3941 ROW_2_RIGHT = 0x0040, 3942 ROW_3_LEFT = 0x0100, 3943 ROW_3_CENTER = 0x0200, 3944 ROW_3_RIGHT = 0x0400 3945}; 3946 3947/** 3948 * Various windshields/windows in the car. 3949 */ 3950enum VehicleAreaWindow : int32_t { 3951 FRONT_WINDSHIELD = 0x00000001, 3952 REAR_WINDSHIELD = 0x00000002, 3953 ROW_1_LEFT = 0x00000010, 3954 ROW_1_RIGHT = 0x00000040, 3955 ROW_2_LEFT = 0x00000100, 3956 ROW_2_RIGHT = 0x00000400, 3957 ROW_3_LEFT = 0x00001000, 3958 ROW_3_RIGHT = 0x00004000, 3959 3960 ROOF_TOP_1 = 0x00010000, 3961 ROOF_TOP_2 = 0x00020000, 3962 3963}; 3964 3965enum VehicleAreaDoor : int32_t { 3966 ROW_1_LEFT = 0x00000001, 3967 ROW_1_RIGHT = 0x00000004, 3968 ROW_2_LEFT = 0x00000010, 3969 ROW_2_RIGHT = 0x00000040, 3970 ROW_3_LEFT = 0x00000100, 3971 ROW_3_RIGHT = 0x00000400, 3972 HOOD = 0x10000000, 3973 REAR = 0x20000000, 3974}; 3975 3976enum VehicleAreaMirror : int32_t { 3977 DRIVER_LEFT = 0x00000001, 3978 DRIVER_RIGHT = 0x00000002, 3979 DRIVER_CENTER = 0x00000004, 3980}; 3981 3982enum VehicleTurnSignal : int32_t { 3983 NONE = 0x00, 3984 RIGHT = 0x01, 3985 LEFT = 0x02, 3986}; 3987 3988struct VehicleAreaConfig { 3989 /** 3990 * Area id is ignored for VehiclePropertyGroup:GLOBAL properties. 3991 */ 3992 int32_t areaId; 3993 3994 /** 3995 * If the property has @data_enum, leave the range to zero. 3996 * 3997 * Range will be ignored in the following cases: 3998 * - The VehiclePropertyType is not INT32, INT64 or FLOAT. 3999 * - Both of min value and max value are zero. 4000 */ 4001 4002 int32_t minInt32Value; 4003 int32_t maxInt32Value; 4004 4005 int64_t minInt64Value; 4006 int64_t maxInt64Value; 4007 4008 float minFloatValue; 4009 float maxFloatValue; 4010}; 4011 4012struct VehiclePropConfig { 4013 /** Property identifier */ 4014 int32_t prop; 4015 4016 /** 4017 * Defines if the property is read or write or both. 4018 */ 4019 VehiclePropertyAccess access; 4020 4021 /** 4022 * Defines the change mode of the property. 4023 */ 4024 VehiclePropertyChangeMode changeMode; 4025 4026 /** 4027 * Contains per-area configuration. 4028 */ 4029 vec<VehicleAreaConfig> areaConfigs; 4030 4031 /** Contains additional configuration parameters */ 4032 vec<int32_t> configArray; 4033 4034 /** 4035 * Some properties may require additional information passed over this 4036 * string. Most properties do not need to set this. 4037 */ 4038 string configString; 4039 4040 /** 4041 * Min sample rate in Hz. 4042 * Must be defined for VehiclePropertyChangeMode::CONTINUOUS 4043 */ 4044 float minSampleRate; 4045 4046 /** 4047 * Must be defined for VehiclePropertyChangeMode::CONTINUOUS 4048 * Max sample rate in Hz. 4049 */ 4050 float maxSampleRate; 4051}; 4052 4053/** 4054 * Encapsulates the property name and the associated value. It 4055 * is used across various API calls to set values, get values or to register for 4056 * events. 4057 */ 4058struct VehiclePropValue { 4059 /** 4060 * Time is elapsed nanoseconds since boot. It's equivalent to 4061 * {@code SystemClock.elapsedRealtimeNano()}. 4062 */ 4063 int64_t timestamp; 4064 4065 /** 4066 * Area type(s) for non-global property it must be one of the value from 4067 * VehicleArea* enums or 0 for global properties. 4068 */ 4069 int32_t areaId; 4070 4071 /** Property identifier */ 4072 int32_t prop; 4073 4074 /** Status of the property */ 4075 VehiclePropertyStatus status; 4076 4077 /** 4078 * Contains value for a single property. Depending on property data type of 4079 * this property (VehiclePropetyType) one field of this structure must be filled in. 4080 */ 4081 struct RawValue { 4082 /** 4083 * This is used for properties of types VehiclePropertyType#INT 4084 * and VehiclePropertyType#INT_VEC 4085 */ 4086 vec<int32_t> int32Values; 4087 4088 /** 4089 * This is used for properties of types VehiclePropertyType#FLOAT 4090 * and VehiclePropertyType#FLOAT_VEC 4091 */ 4092 vec<float> floatValues; 4093 4094 /** This is used for properties of type VehiclePropertyType#INT64 */ 4095 vec<int64_t> int64Values; 4096 4097 /** This is used for properties of type VehiclePropertyType#BYTES */ 4098 vec<uint8_t> bytes; 4099 4100 /** This is used for properties of type VehiclePropertyType#STRING */ 4101 string stringValue; 4102 }; 4103 4104 RawValue value; 4105}; 4106 4107enum VehicleIgnitionState : int32_t { 4108 UNDEFINED = 0, 4109 4110 /** Steering wheel is locked */ 4111 LOCK = 1, 4112 4113 /** 4114 * Steering wheel is not locked, engine and all accessories are OFF. If 4115 * car can be in LOCK and OFF state at the same time than HAL must report 4116 * LOCK state. 4117 */ 4118 OFF, 4119 4120 /** 4121 * Typically in this state accessories become available (e.g. radio). 4122 * Instrument cluster and engine are turned off 4123 */ 4124 ACC, 4125 4126 /** 4127 * Ignition is in state ON. Accessories and instrument cluster available, 4128 * engine might be running or ready to be started. 4129 */ 4130 ON, 4131 4132 /** Typically in this state engine is starting (cranking). */ 4133 START 4134}; 4135 4136enum SubscribeFlags : int32_t { 4137 UNDEFINED = 0x0, 4138 4139 /** 4140 * Subscribe to event that was originated in vehicle HAL 4141 * (most likely this event came from the vehicle itself). 4142 */ 4143 EVENTS_FROM_CAR = 0x1, 4144 4145 /** 4146 * Use this flag to subscribe on events when IVehicle#set(...) was called by 4147 * vehicle HAL's client (e.g. Car Service). 4148 */ 4149 EVENTS_FROM_ANDROID = 0x2, 4150}; 4151 4152/** 4153 * Encapsulates information about subscription to vehicle property events. 4154 */ 4155struct SubscribeOptions { 4156 /** Property to subscribe */ 4157 int32_t propId; 4158 4159 /** 4160 * Sample rate in Hz. 4161 * 4162 * Must be provided for properties with 4163 * VehiclePropertyChangeMode::CONTINUOUS. The value must be within 4164 * VehiclePropConfig#minSamplingRate .. VehiclePropConfig#maxSamplingRate 4165 * for a given property. 4166 * This value indicates how many updates per second client wants to receive. 4167 */ 4168 float sampleRate; 4169 4170 /** Flags that indicate to which event sources to listen. */ 4171 SubscribeFlags flags; 4172}; 4173 4174/** Error codes used in vehicle HAL interface. */ 4175enum StatusCode : int32_t { 4176 OK = 0, 4177 4178 /** Try again. */ 4179 TRY_AGAIN = 1, 4180 4181 /** Invalid argument provided. */ 4182 INVALID_ARG = 2, 4183 4184 /** 4185 * This code must be returned when device that associated with the vehicle 4186 * property is not available. For example, when client tries to set HVAC 4187 * temperature when the whole HVAC unit is turned OFF. 4188 */ 4189 NOT_AVAILABLE = 3, 4190 4191 /** Access denied */ 4192 ACCESS_DENIED = 4, 4193 4194 /** Something unexpected has happened in Vehicle HAL */ 4195 INTERNAL_ERROR = 5, 4196}; 4197 4198enum VehicleAreaWheel : int32_t { 4199 UNKNOWN = 0x0, 4200 4201 LEFT_FRONT = 0x1, 4202 RIGHT_FRONT = 0x2, 4203 LEFT_REAR = 0x4, 4204 RIGHT_REAR = 0x8, 4205}; 4206 4207/** 4208 * The status of the vehicle's fuel system. 4209 * These values come from the SAE J1979 standard. 4210 */ 4211enum Obd2FuelSystemStatus : int32_t { 4212 OPEN_INSUFFICIENT_ENGINE_TEMPERATURE = 1, 4213 CLOSED_LOOP = 2, 4214 OPEN_ENGINE_LOAD_OR_DECELERATION = 4, 4215 OPEN_SYSTEM_FAILURE = 8, 4216 CLOSED_LOOP_BUT_FEEDBACK_FAULT = 16, 4217}; 4218 4219/** Defines which ignition monitors are available to be read. */ 4220enum Obd2IgnitionMonitorKind : int32_t { 4221 SPARK = 0, 4222 COMPRESSION = 1, 4223}; 4224 4225/** 4226 * Ignition monitors common to both SPARK and COMPRESSION. 4227 * These values come from the SAE J1979 standard. 4228 */ 4229enum Obd2CommonIgnitionMonitors : int32_t { 4230 COMPONENTS_AVAILABLE = 0x1 << 0, 4231 COMPONENTS_INCOMPLETE = 0x1 << 1, 4232 4233 FUEL_SYSTEM_AVAILABLE = 0x1 << 2, 4234 FUEL_SYSTEM_INCOMPLETE = 0x1 << 3, 4235 4236 MISFIRE_AVAILABLE = 0x1 << 4, 4237 MISFIRE_INCOMPLETE = 0x1 << 5, 4238}; 4239 4240/** 4241 * Ignition monitors available for SPARK vehicles. 4242 * These values come from the SAE J1979 standard. 4243 */ 4244enum Obd2SparkIgnitionMonitors : Obd2CommonIgnitionMonitors { 4245 EGR_AVAILABLE = 0x1 << 6, 4246 EGR_INCOMPLETE = 0x1 << 7, 4247 4248 OXYGEN_SENSOR_HEATER_AVAILABLE = 0x1 << 8, 4249 OXYGEN_SENSOR_HEATER_INCOMPLETE = 0x1 << 9, 4250 4251 OXYGEN_SENSOR_AVAILABLE = 0x1 << 10, 4252 OXYGEN_SENSOR_INCOMPLETE = 0x1 << 11, 4253 4254 AC_REFRIGERANT_AVAILABLE = 0x1 << 12, 4255 AC_REFRIGERANT_INCOMPLETE = 0x1 << 13, 4256 4257 SECONDARY_AIR_SYSTEM_AVAILABLE = 0x1 << 14, 4258 SECONDARY_AIR_SYSTEM_INCOMPLETE = 0x1 << 15, 4259 4260 EVAPORATIVE_SYSTEM_AVAILABLE = 0x1 << 16, 4261 EVAPORATIVE_SYSTEM_INCOMPLETE = 0x1 << 17, 4262 4263 HEATED_CATALYST_AVAILABLE = 0x1 << 18, 4264 HEATED_CATALYST_INCOMPLETE = 0x1 << 19, 4265 4266 CATALYST_AVAILABLE = 0x1 << 20, 4267 CATALYST_INCOMPLETE = 0x1 << 21, 4268}; 4269 4270/** 4271 * Ignition monitors only available for COMPRESSION vehicles. 4272 * These values come from the SAE J1979 standard. 4273 */ 4274enum Obd2CompressionIgnitionMonitors : Obd2CommonIgnitionMonitors { 4275 EGR_OR_VVT_AVAILABLE = 0x1 << 6, 4276 EGR_OR_VVT_INCOMPLETE = 0x1 << 7, 4277 4278 PM_FILTER_AVAILABLE = 0x1 << 8, 4279 PM_FILTER_INCOMPLETE = 0x1 << 9, 4280 4281 EXHAUST_GAS_SENSOR_AVAILABLE = 0x1 << 10, 4282 EXHAUST_GAS_SENSOR_INCOMPLETE = 0x1 << 11, 4283 4284 BOOST_PRESSURE_AVAILABLE = 0x1 << 12, 4285 BOOST_PRESSURE_INCOMPLETE = 0x1 << 13, 4286 4287 NOx_SCR_AVAILABLE = 0x1 << 14, 4288 NOx_SCR_INCOMPLETE = 0x1 << 15, 4289 4290 NMHC_CATALYST_AVAILABLE = 0x1 << 16, 4291 NMHC_CATALYST_INCOMPLETE = 0x1 << 17, 4292}; 4293 4294/** 4295 * The status of the vehicle's secondary air system. 4296 * These values come from the SAE J1979 standard. 4297 */ 4298enum Obd2SecondaryAirStatus : int32_t { 4299 UPSTREAM = 1, 4300 DOWNSTREAM_OF_CATALYCIC_CONVERTER = 2, 4301 FROM_OUTSIDE_OR_OFF = 4, 4302 PUMP_ON_FOR_DIAGNOSTICS = 8, 4303}; 4304 4305/** 4306 * The fuel type(s) supported by a vehicle. 4307 * These values come from the SAE J1979 standard. 4308 */ 4309enum Obd2FuelType : int32_t { 4310 NOT_AVAILABLE = 0, 4311 GASOLINE = 1, 4312 METHANOL = 2, 4313 ETHANOL = 3, 4314 DIESEL = 4, 4315 LPG = 5, 4316 CNG = 6, 4317 PROPANE = 7, 4318 ELECTRIC = 8, 4319 BIFUEL_RUNNING_GASOLINE = 9, 4320 BIFUEL_RUNNING_METHANOL = 10, 4321 BIFUEL_RUNNING_ETHANOL = 11, 4322 BIFUEL_RUNNING_LPG = 12, 4323 BIFUEL_RUNNING_CNG = 13, 4324 BIFUEL_RUNNING_PROPANE = 14, 4325 BIFUEL_RUNNING_ELECTRIC = 15, 4326 BIFUEL_RUNNING_ELECTRIC_AND_COMBUSTION = 16, 4327 HYBRID_GASOLINE = 17, 4328 HYBRID_ETHANOL = 18, 4329 HYBRID_DIESEL = 19, 4330 HYBRID_ELECTRIC = 20, 4331 HYBRID_RUNNING_ELECTRIC_AND_COMBUSTION = 21, 4332 HYBRID_REGENERATIVE = 22, 4333 BIFUEL_RUNNING_DIESEL = 23, 4334}; 4335 4336/** 4337 * This enum provides the canonical mapping for sensor properties that have an integer value. 4338 * The ordering of the values is taken from the OBD2 specification. 4339 * Some of the properties are represented as an integer mapping to another enum. In those cases 4340 * expect a comment by the property definition describing the enum to look at for the mapping. 4341 * Any value greater than the last reserved index is available to vendors to map their extensions. 4342 * While these values do not directly map to SAE J1979 PIDs, an equivalence is listed next 4343 * to each one to aid implementors. 4344 */ 4345enum DiagnosticIntegerSensorIndex : int32_t { 4346 /** refer to FuelSystemStatus for a description of this value. */ 4347 FUEL_SYSTEM_STATUS = 0, /* PID 0x03 */ 4348 MALFUNCTION_INDICATOR_LIGHT_ON = 1, /* PID 0x01 */ 4349 4350 /** refer to IgnitionMonitorKind for a description of this value. */ 4351 IGNITION_MONITORS_SUPPORTED = 2, /* PID 0x01 */ 4352 4353 /** 4354 * The value of this sensor is a bitmask that specifies whether ignition-specific 4355 * tests are available and whether they are complete. The semantics of the individual 4356 * bits in this value are given by, respectively, SparkIgnitionMonitors and 4357 * CompressionIgnitionMonitors depending on the value of IGNITION_MONITORS_SUPPORTED. 4358 */ 4359 IGNITION_SPECIFIC_MONITORS = 3, /* PID 0x01 */ 4360 INTAKE_AIR_TEMPERATURE = 4, /* PID 0x0F */ 4361 4362 /** refer to SecondaryAirStatus for a description of this value. */ 4363 COMMANDED_SECONDARY_AIR_STATUS = 5, /* PID 0x12 */ 4364 NUM_OXYGEN_SENSORS_PRESENT = 6, /* PID 0x13 */ 4365 RUNTIME_SINCE_ENGINE_START = 7, /* PID 0x1F */ 4366 DISTANCE_TRAVELED_WITH_MALFUNCTION_INDICATOR_LIGHT_ON = 8, /* PID 0x21 */ 4367 WARMUPS_SINCE_CODES_CLEARED = 9, /* PID 0x30 */ 4368 DISTANCE_TRAVELED_SINCE_CODES_CLEARED = 10, /* PID 0x31 */ 4369 ABSOLUTE_BAROMETRIC_PRESSURE = 11, /* PID 0x33 */ 4370 CONTROL_MODULE_VOLTAGE = 12, /* PID 0x42 */ 4371 AMBIENT_AIR_TEMPERATURE = 13, /* PID 0x46 */ 4372 TIME_WITH_MALFUNCTION_LIGHT_ON = 14, /* PID 0x4D */ 4373 TIME_SINCE_TROUBLE_CODES_CLEARED = 15, /* PID 0x4E */ 4374 MAX_FUEL_AIR_EQUIVALENCE_RATIO = 16, /* PID 0x4F */ 4375 MAX_OXYGEN_SENSOR_VOLTAGE = 17, /* PID 0x4F */ 4376 MAX_OXYGEN_SENSOR_CURRENT = 18, /* PID 0x4F */ 4377 MAX_INTAKE_MANIFOLD_ABSOLUTE_PRESSURE = 19, /* PID 0x4F */ 4378 MAX_AIR_FLOW_RATE_FROM_MASS_AIR_FLOW_SENSOR = 20, /* PID 0x50 */ 4379 4380 /** refer to FuelType for a description of this value. */ 4381 FUEL_TYPE = 21, /* PID 0x51 */ 4382 FUEL_RAIL_ABSOLUTE_PRESSURE = 22, /* PID 0x59 */ 4383 ENGINE_OIL_TEMPERATURE = 23, /* PID 0x5C */ 4384 DRIVER_DEMAND_PERCENT_TORQUE = 24, /* PID 0x61 */ 4385 ENGINE_ACTUAL_PERCENT_TORQUE = 25, /* PID 0x62 */ 4386 ENGINE_REFERENCE_PERCENT_TORQUE = 26, /* PID 0x63 */ 4387 ENGINE_PERCENT_TORQUE_DATA_IDLE = 27, /* PID 0x64 */ 4388 ENGINE_PERCENT_TORQUE_DATA_POINT1 = 28, /* PID 0x64 */ 4389 ENGINE_PERCENT_TORQUE_DATA_POINT2 = 29, /* PID 0x64 */ 4390 ENGINE_PERCENT_TORQUE_DATA_POINT3 = 30, /* PID 0x64 */ 4391 ENGINE_PERCENT_TORQUE_DATA_POINT4 = 31, /* PID 0x64 */ 4392 LAST_SYSTEM_INDEX = ENGINE_PERCENT_TORQUE_DATA_POINT4, 4393}; 4394 4395/** 4396 * This enum provides the canonical mapping for sensor properties that have a floating-point value. 4397 * The ordering of the values is taken from the OBD2 specification. 4398 * Any value greater than the last reserved index is available to vendors to map their extensions. 4399 * While these values do not directly map to SAE J1979 PIDs, an equivalence is listed next 4400 * to each one to aid implementors. 4401 */ 4402enum DiagnosticFloatSensorIndex : int32_t { 4403 CALCULATED_ENGINE_LOAD = 0, /* PID 0x04 */ 4404 ENGINE_COOLANT_TEMPERATURE = 1, /* PID 0x05 */ 4405 SHORT_TERM_FUEL_TRIM_BANK1 = 2, /* PID 0x06 */ 4406 LONG_TERM_FUEL_TRIM_BANK1 = 3, /* PID 0x07 */ 4407 SHORT_TERM_FUEL_TRIM_BANK2 = 4, /* PID 0x08 */ 4408 LONG_TERM_FUEL_TRIM_BANK2 = 5, /* PID 0x09 */ 4409 FUEL_PRESSURE = 6, /* PID 0x0A */ 4410 INTAKE_MANIFOLD_ABSOLUTE_PRESSURE = 7, /* PID 0x0B */ 4411 ENGINE_RPM = 8, /* PID 0x0C */ 4412 VEHICLE_SPEED = 9, /* PID 0x0D */ 4413 TIMING_ADVANCE = 10, /* PID 0x0E */ 4414 MAF_AIR_FLOW_RATE = 11, /* PID 0x10 */ 4415 THROTTLE_POSITION = 12, /* PID 0x11 */ 4416 OXYGEN_SENSOR1_VOLTAGE = 13, /* PID 0x14 */ 4417 OXYGEN_SENSOR1_SHORT_TERM_FUEL_TRIM = 14, /* PID 0x14 */ 4418 OXYGEN_SENSOR1_FUEL_AIR_EQUIVALENCE_RATIO = 15, /* PID 0x24 */ 4419 OXYGEN_SENSOR2_VOLTAGE = 16, /* PID 0x15 */ 4420 OXYGEN_SENSOR2_SHORT_TERM_FUEL_TRIM = 17, /* PID 0x15 */ 4421 OXYGEN_SENSOR2_FUEL_AIR_EQUIVALENCE_RATIO = 18, /* PID 0x25 */ 4422 OXYGEN_SENSOR3_VOLTAGE = 19, /* PID 0x16 */ 4423 OXYGEN_SENSOR3_SHORT_TERM_FUEL_TRIM = 20, /* PID 0x16 */ 4424 OXYGEN_SENSOR3_FUEL_AIR_EQUIVALENCE_RATIO = 21, /* PID 0x26 */ 4425 OXYGEN_SENSOR4_VOLTAGE = 22, /* PID 0x17 */ 4426 OXYGEN_SENSOR4_SHORT_TERM_FUEL_TRIM = 23, /* PID 0x17 */ 4427 OXYGEN_SENSOR4_FUEL_AIR_EQUIVALENCE_RATIO = 24, /* PID 0x27 */ 4428 OXYGEN_SENSOR5_VOLTAGE = 25, /* PID 0x18 */ 4429 OXYGEN_SENSOR5_SHORT_TERM_FUEL_TRIM = 26, /* PID 0x18 */ 4430 OXYGEN_SENSOR5_FUEL_AIR_EQUIVALENCE_RATIO = 27, /* PID 0x28 */ 4431 OXYGEN_SENSOR6_VOLTAGE = 28, /* PID 0x19 */ 4432 OXYGEN_SENSOR6_SHORT_TERM_FUEL_TRIM = 29, /* PID 0x19 */ 4433 OXYGEN_SENSOR6_FUEL_AIR_EQUIVALENCE_RATIO = 30, /* PID 0x29 */ 4434 OXYGEN_SENSOR7_VOLTAGE = 31, /* PID 0x1A */ 4435 OXYGEN_SENSOR7_SHORT_TERM_FUEL_TRIM = 32, /* PID 0x1A */ 4436 OXYGEN_SENSOR7_FUEL_AIR_EQUIVALENCE_RATIO = 33, /* PID 0x2A */ 4437 OXYGEN_SENSOR8_VOLTAGE = 34, /* PID 0x1B */ 4438 OXYGEN_SENSOR8_SHORT_TERM_FUEL_TRIM = 35, /* PID 0x1B */ 4439 OXYGEN_SENSOR8_FUEL_AIR_EQUIVALENCE_RATIO = 36, /* PID 0x2B */ 4440 FUEL_RAIL_PRESSURE = 37, /* PID 0x22 */ 4441 FUEL_RAIL_GAUGE_PRESSURE = 38, /* PID 0x23 */ 4442 COMMANDED_EXHAUST_GAS_RECIRCULATION = 39, /* PID 0x2C */ 4443 EXHAUST_GAS_RECIRCULATION_ERROR = 40, /* PID 0x2D */ 4444 COMMANDED_EVAPORATIVE_PURGE = 41, /* PID 0x2E */ 4445 FUEL_TANK_LEVEL_INPUT = 42, /* PID 0x2F */ 4446 EVAPORATION_SYSTEM_VAPOR_PRESSURE = 43, /* PID 0x32 */ 4447 CATALYST_TEMPERATURE_BANK1_SENSOR1 = 44, /* PID 0x3C */ 4448 CATALYST_TEMPERATURE_BANK2_SENSOR1 = 45, /* PID 0x3D */ 4449 CATALYST_TEMPERATURE_BANK1_SENSOR2 = 46, /* PID 0x3E */ 4450 CATALYST_TEMPERATURE_BANK2_SENSOR2 = 47, /* PID 0x3F */ 4451 ABSOLUTE_LOAD_VALUE = 48, /* PID 0x43 */ 4452 FUEL_AIR_COMMANDED_EQUIVALENCE_RATIO = 49, /* PID 0x44 */ 4453 RELATIVE_THROTTLE_POSITION = 50, /* PID 0x45 */ 4454 ABSOLUTE_THROTTLE_POSITION_B = 51, /* PID 0x47 */ 4455 ABSOLUTE_THROTTLE_POSITION_C = 52, /* PID 0x48 */ 4456 ACCELERATOR_PEDAL_POSITION_D = 53, /* PID 0x49 */ 4457 ACCELERATOR_PEDAL_POSITION_E = 54, /* PID 0x4A */ 4458 ACCELERATOR_PEDAL_POSITION_F = 55, /* PID 0x4B */ 4459 COMMANDED_THROTTLE_ACTUATOR = 56, /* PID 0x4C */ 4460 ETHANOL_FUEL_PERCENTAGE = 57, /* PID 0x52 */ 4461 ABSOLUTE_EVAPORATION_SYSTEM_VAPOR_PRESSURE = 58, /* PID 0x53 */ 4462 SHORT_TERM_SECONDARY_OXYGEN_SENSOR_TRIM_BANK1 = 59, /* PID 0x55 */ 4463 SHORT_TERM_SECONDARY_OXYGEN_SENSOR_TRIM_BANK2 = 60, /* PID 0x57 */ 4464 SHORT_TERM_SECONDARY_OXYGEN_SENSOR_TRIM_BANK3 = 61, /* PID 0x55 */ 4465 SHORT_TERM_SECONDARY_OXYGEN_SENSOR_TRIM_BANK4 = 62, /* PID 0x57 */ 4466 LONG_TERM_SECONDARY_OXYGEN_SENSOR_TRIM_BANK1 = 63, /* PID 0x56 */ 4467 LONG_TERM_SECONDARY_OXYGEN_SENSOR_TRIM_BANK2 = 64, /* PID 0x58 */ 4468 LONG_TERM_SECONDARY_OXYGEN_SENSOR_TRIM_BANK3 = 65, /* PID 0x56 */ 4469 LONG_TERM_SECONDARY_OXYGEN_SENSOR_TRIM_BANK4 = 66, /* PID 0x58 */ 4470 RELATIVE_ACCELERATOR_PEDAL_POSITION = 67, /* PID 0x5A */ 4471 HYBRID_BATTERY_PACK_REMAINING_LIFE = 68, /* PID 0x5B */ 4472 FUEL_INJECTION_TIMING = 69, /* PID 0x5D */ 4473 ENGINE_FUEL_RATE = 70, /* PID 0x5E */ 4474 LAST_SYSTEM_INDEX = ENGINE_FUEL_RATE, 4475}; 4476 4477/** 4478 * This enum lists the types of supported VMS messages. It is used as the first 4479 * integer in the vehicle property integers array and determines how the rest of 4480 * the message is decoded. 4481 */ 4482enum VmsMessageType : int32_t { 4483 /** 4484 * A request from the subscribers to the VMS service to subscribe to a layer. 4485 * 4486 * This message type uses enum VmsMessageWithLayerIntegerValuesIndex. 4487 */ 4488 SUBSCRIBE = 1, 4489 4490 /** 4491 * A request from the subscribers to the VMS service to subscribe to a layer from a specific publisher. 4492 * 4493 * This message type uses enum VmsMessageWithLayerAndPublisherIdIntegerValuesIndex. 4494 */ 4495 SUBSCRIBE_TO_PUBLISHER = 2, 4496 4497 /** 4498 * A request from the subscribers to the VMS service to unsubscribes from a layer. 4499 * 4500 * This message type uses enum VmsMessageWithLayerIntegerValuesIndex. 4501 */ 4502 UNSUBSCRIBE = 3, 4503 4504 /** 4505 * A request from the subscribers to the VMS service to unsubscribes from a layer from a specific publisher. 4506 * 4507 * This message type uses enum VmsMessageWithLayerAndPublisherIdIntegerValuesIndex. 4508 */ 4509 UNSUBSCRIBE_TO_PUBLISHER = 4, 4510 4511 /** 4512 * Information from the publishers to the VMS service about the layers which the client can publish. 4513 * 4514 * This message type uses enum VmsOfferingMessageIntegerValuesIndex. 4515 */ 4516 OFFERING = 5, 4517 4518 /** 4519 * A request from the subscribers to the VMS service to get the available layers. 4520 * 4521 * This message type uses enum VmsBaseMessageIntegerValuesIndex. 4522 */ 4523 AVAILABILITY_REQUEST = 6, 4524 4525 /** 4526 * A request from the publishers to the VMS service to get the layers with subscribers. 4527 * 4528 * This message type uses enum VmsBaseMessageIntegerValuesIndex. 4529 */ 4530 SUBSCRIPTIONS_REQUEST = 7, 4531 4532 /** 4533 * A response from the VMS service to the subscribers to a VmsMessageType.AVAILABILITY_REQUEST 4534 * 4535 * This message type uses enum VmsAvailabilityStateIntegerValuesIndex. 4536 */ 4537 AVAILABILITY_RESPONSE = 8, 4538 4539 /** 4540 * A notification from the VMS service to the subscribers on a change in the available layers. 4541 * 4542 * This message type uses enum VmsAvailabilityStateIntegerValuesIndex. 4543 */ 4544 AVAILABILITY_CHANGE = 9, 4545 4546 /** 4547 * A response from the VMS service to the publishers to a VmsMessageType.SUBSCRIPTIONS_REQUEST 4548 * 4549 * This message type uses enum VmsSubscriptionsStateIntegerValuesIndex. 4550 */ 4551 SUBSCRIPTIONS_RESPONSE = 10, 4552 4553 /** 4554 * A notification from the VMS service to the publishers on a change in the layers with subscribers. 4555 * 4556 * This message type uses enum VmsSubscriptionsStateIntegerValuesIndex. 4557 */ 4558 SUBSCRIPTIONS_CHANGE = 11, 4559 4560 /** 4561 * A message from the VMS service to the subscribers or from the publishers to the VMS service 4562 * with a serialized VMS data packet as defined in the VMS protocol. 4563 * 4564 * This message type uses enum VmsMessageWithLayerAndPublisherIdIntegerValuesIndex. 4565 */ 4566 DATA = 12, 4567 4568 /** 4569 * A request from the publishers to the VMS service to get a Publisher ID for a serialized VMS 4570 * provider description packet as defined in the VMS protocol. 4571 * 4572 * This message type uses enum VmsBaseMessageIntegerValuesIndex. 4573 */ 4574 PUBLISHER_ID_REQUEST = 13, 4575 4576 /** 4577 * A response from the VMS service to the publisher that contains a provider description packet 4578 * and the publisher ID assigned to it. 4579 * 4580 * This message type uses enum VmsPublisherInformationIntegerValuesIndex. 4581 */ 4582 PUBLISHER_ID_RESPONSE = 14, 4583 4584 /** 4585 * A request from the subscribers to the VMS service to get information for a Publisher ID. 4586 * 4587 * This message type uses enum VmsPublisherInformationIntegerValuesIndex. 4588 */ 4589 PUBLISHER_INFORMATION_REQUEST = 15, 4590 4591 /** 4592 * A response from the VMS service to the subscribers that contains a provider description packet 4593 * and the publisher ID assigned to it. 4594 * 4595 * This message type uses enum VmsPublisherInformationIntegerValuesIndex. 4596 */ 4597 PUBLISHER_INFORMATION_RESPONSE = 16, 4598 4599 /** 4600 * A notification indicating that the sender has been reset. 4601 * 4602 * The receiving party must reset its internal state and respond to the 4603 * sender with a START_SESSION message as acknowledgement. 4604 * 4605 * This message type uses enum VmsStartSessionMessageIntegerValuesIndex. 4606 */ 4607 START_SESSION = 17, 4608 4609 LAST_VMS_MESSAGE_TYPE = START_SESSION, 4610}; 4611 4612/** 4613 * Every VMS message starts with the type of the message from the VmsMessageType enum. 4614 * Messages with no parameters such as VmsMessageType.AVAILABILITY_REQUEST, 4615 * VmsMessageType.SUBSCRIPTIONS_REQUEST and VmsMessageType.DATA are also based on this enum. 4616 */ 4617enum VmsBaseMessageIntegerValuesIndex : int32_t { 4618 /* The message type as enumerated by VmsMessageType enum. */ 4619 MESSAGE_TYPE = 0, 4620}; 4621 4622/* 4623 * Handshake data sent as part of a VmsMessageType.START_SESSION message. 4624 * 4625 * A new session is initiated by sending a START_SESSION message with the 4626 * sender's identifier populated and the receiver's identifier set to -1. 4627 * 4628 * Identifier values are independently generated, but must be non-negative, and 4629 * increase monotonically between reboots. 4630 * 4631 * Upon receiving a START_SESSION with a mis-matching identifier, the receiver 4632 * must clear any cached VMS offering or subscription state and acknowledge the 4633 * new session by responding with a START_SESSION message that populates both 4634 * identifier fields. 4635 * 4636 * Any VMS messages received between initiation and completion of the handshake 4637 * must be discarded. 4638 */ 4639enum VmsStartSessionMessageIntegerValuesIndex : VmsBaseMessageIntegerValuesIndex { 4640 /* Identifier field for the Android system service. */ 4641 SERVICE_ID = 1, 4642 /* Identifier field for the HAL client process. */ 4643 CLIENT_ID = 2, 4644}; 4645 4646/* 4647 * A VMS message with a layer is sent as part of a VmsMessageType.SUBSCRIBE or 4648 * VmsMessageType.UNSUBSCRIBE messages. 4649 * 4650 * The layer type is defined in the VMS protocol, and the subtype and version are 4651 * controlled by the implementer of the publisher. 4652 */ 4653enum VmsMessageWithLayerIntegerValuesIndex : VmsBaseMessageIntegerValuesIndex { 4654 LAYER_TYPE = 1, 4655 LAYER_SUBTYPE = 2, 4656 LAYER_VERSION = 3, 4657}; 4658 4659/* 4660 * A VMS message with a layer and publisher ID is sent as part of a 4661 * VmsMessageType.SUBSCRIBE_TO_PUBLISHER, VmsMessageType.UNSUBSCRIBE_TO_PUBLISHER messages and 4662 * VmsMessageType.DATA . 4663 */ 4664enum VmsMessageWithLayerAndPublisherIdIntegerValuesIndex : VmsMessageWithLayerIntegerValuesIndex { 4665 PUBLISHER_ID = 4, 4666}; 4667 4668/* 4669 * An offering can be sent by publishers as part of VmsMessageType.OFFERING in order to 4670 * advertise which layers they can publish and under which constraints: e.g., I can publish Layer X 4671 * if someone else will publish Layer Y. 4672 * The offering contains the publisher ID which was assigned to the publisher by the VMS service. 4673 * A single offering is represented as: 4674 * - Layer type 4675 * - Layer subtype 4676 * - Layer version 4677 * - Number of dependencies (N) 4678 * - N x (Layer type, Layer subtype, Layer version) 4679 */ 4680enum VmsOfferingMessageIntegerValuesIndex : VmsBaseMessageIntegerValuesIndex { 4681 PUBLISHER_ID = 1, 4682 NUMBER_OF_OFFERS = 2, 4683 OFFERING_START = 3, 4684}; 4685 4686/** 4687 * A subscriptions state is sent to the publishers in response to a change in the subscriptions 4688 * as part of a VmsMessageType.SUBSCRIPTIONS_CHANGE, or in response to a 4689 * VmsMessageType.SUBSCRIPTIONS_REQUEST message as part of VmsMessageType.SUBSCRIPTIONS_RESPONSE. 4690 * The VMS service issues monotonically increasing sequence numbers, and in case a subscriber receives 4691 * a smaller sequnce number it should ignore the message. 4692 * The subscriptions are sent as a list of layers followed by a list of associated layers: 4693 * {Sequence number, N, M, N x layer, M x associated layer} 4694 * A subscribed layer is represented as three integers: 4695 * - Layer type 4696 * - Layer subtype 4697 * - Layer version 4698 * A subscribed associated layer is a layer with a list of publisher IDs. It is represented as: 4699 * - Layer type 4700 * - Layer subtype 4701 * - Layer version 4702 * - Number of publisher IDs (N) 4703 * - N x publisher ID 4704 */ 4705enum VmsSubscriptionsStateIntegerValuesIndex : VmsBaseMessageIntegerValuesIndex { 4706 SEQUENCE_NUMBER = 1, 4707 NUMBER_OF_LAYERS = 2, 4708 NUMBER_OF_ASSOCIATED_LAYERS = 3, 4709 SUBSCRIPTIONS_START = 4, 4710}; 4711 4712/** 4713 * An availability state is sent to the subscribers in response to a change in the available 4714 * layers as part of a VmsMessageType.AVAILABILITY_CHANGE message, or in response to a 4715 * VmsMessageType.AVAILABILITY_REQUEST message as part of a VmsMessageType.AVAILABILITY_RESPONSE. 4716 * The VMS service issues monotonically increasing sequence numbers, and in case a subscriber receives 4717 * a smaller sequnce number, it should ignore the message. 4718 * An available associated layer is a layer with a list of publisher IDs: 4719 * - Layer type 4720 * - Layer subtype 4721 * - Layer version 4722 * - Number of publisher IDs (N) 4723 * - N x publisher ID 4724 */ 4725enum VmsAvailabilityStateIntegerValuesIndex : VmsBaseMessageIntegerValuesIndex { 4726 SEQUENCE_NUMBER = 1, 4727 NUMBER_OF_ASSOCIATED_LAYERS = 2, 4728 LAYERS_START = 3, 4729}; 4730 4731/* 4732 * Publishers send the VMS service their information and assigned in response a publisher ID. 4733 * Subscribers can request the publisher information for a publisher ID they received in other messages. 4734 */ 4735enum VmsPublisherInformationIntegerValuesIndex : VmsBaseMessageIntegerValuesIndex { 4736 PUBLISHER_ID = 1, 4737}; 4738 4739/** 4740 * Information about a specific Android user. 4741 */ 4742struct UserInfo { 4743 4744 UserId userId; 4745 4746 UserFlags flags; 4747}; 4748 4749/** 4750 * Id of an Android user. 4751 * 4752 * Must be > 0 for valid ids, or -10000 (which is the same as Android.UserHandle.USER_NULL) when 4753 * it's not used. 4754 */ 4755typedef int32_t UserId; 4756 4757/** 4758 * Flags used to define the characteristics of an Android user. 4759 */ 4760enum UserFlags: int32_t { 4761 /** 4762 * No flags. 4763 */ 4764 NONE = 0x0, 4765 4766 /** 4767 * System user. 4768 * On automotive, that user is always running, although never on foreground (except during 4769 * boot or exceptional circumstances). 4770 */ 4771 SYSTEM = 0x01, 4772 4773 /** 4774 * Guest users have restrictions. 4775 */ 4776 GUEST = 0x02, 4777 4778 /** 4779 * Ephemeral users have non-persistent state. 4780 */ 4781 EPHEMERAL = 0x04, 4782 4783 /** 4784 * Admin users have additional privileges such as permission to create other users. 4785 */ 4786 ADMIN = 0x08, 4787 4788 /** 4789 * Disabled users are marked for deletion. 4790 */ 4791 DISABLED = 0x10, 4792 4793 /** 4794 * Profile user is a profile of another user. 4795 */ 4796 PROFILE = 0x20, 4797}; 4798 4799/** 4800 * Information about all Android users. 4801 * 4802 * NOTE: this struct is not used in the HAL properties directly, it's part of other structs, which 4803 * in turn are converted to a VehiclePropValue.RawValue through libraries provided by the default 4804 * Vehicle HAL implementation. 4805 */ 4806struct UsersInfo { 4807 4808 /** The current foreground user. */ 4809 UserInfo currentUser; 4810 4811 /** 4812 * Number of existing users; includes the current user, recently removed users (with DISABLED 4813 * flag), and profile users (with PROFILE flag). 4814 */ 4815 int32_t numberUsers; 4816 4817 /** 4818 * List of existing users; includes the current user, recently removed users (with DISABLED 4819 * flag), and profile users (with PROFILE flag). 4820 */ 4821 vec<UserInfo> existingUsers; 4822 }; 4823 4824/** 4825 * Id of a request related to user management. 4826 * 4827 * This id can be used by the Android system to map responses sent by the HAL, and vice-versa. 4828 * 4829 * For requests originated by Android, the value is positive (> 0), while for requests originated by 4830 * the HAL it must be negative (< 0). 4831 */ 4832typedef int32_t UserRequestId; 4833 4834/** 4835 * Defines the format of a INITIAL_USER_INFO request made by the Android system. 4836 * 4837 * NOTE: this struct is not used in the HAL properties directly, it must be converted to 4838 * VehiclePropValue.RawValue through libraries provided by the default Vehicle HAL implementation. 4839 */ 4840struct InitialUserInfoRequest { 4841 /** 4842 * Arbitrary id used to map the HAL response to the request. 4843 */ 4844 UserRequestId requestId; 4845 4846 /** 4847 * Type of request. 4848 */ 4849 InitialUserInfoRequestType requestType; 4850 4851 /** 4852 * Information about the current state of the Android system. 4853 */ 4854 UsersInfo usersInfo; 4855}; 4856 4857/** 4858 * Defines when a INITIAL_USER_INFO request was made. 4859 */ 4860enum InitialUserInfoRequestType : int32_t { 4861 /** At the first time Android was booted (or after a factory reset). */ 4862 FIRST_BOOT = 1, 4863 4864 /** At the first time Android was booted after the system was updated. */ 4865 FIRST_BOOT_AFTER_OTA = 2, 4866 4867 /** When Android was booted "from scratch". */ 4868 COLD_BOOT = 3, 4869 4870 /** When Android was resumed after the system was suspended to memory. */ 4871 RESUME = 4, 4872}; 4873 4874/** 4875 * Defines the format of a HAL response to a INITIAL_USER_INFO request. 4876 * 4877 * NOTE: this struct is not used in the HAL properties directly, it must be converted to 4878 * VehiclePropValue.RawValue through libraries provided by the default Vehicle HAL implementation. 4879 */ 4880struct InitialUserInfoResponse { 4881 /** 4882 * Id of the request being responded. 4883 */ 4884 UserRequestId requestId; 4885 4886 /** 4887 * which action the Android system should take. 4888 */ 4889 InitialUserInfoResponseAction action; 4890 4891 /** 4892 * Information about the user that should be switched to or created. 4893 */ 4894 UserInfo userToSwitchOrCreate; 4895 4896 /** 4897 * System locales of the initial user (value will be passed as-is to 4898 * android.provider.Settings.System.SYSTEM_LOCALES) 4899 */ 4900 string userLocales; 4901 4902 /** 4903 * Name of the user that should be created. 4904 */ 4905 string userNameToCreate; 4906}; 4907 4908/** 4909 * Defines which action the Android system should take in an INITIAL_USER_INFO request. 4910 */ 4911enum InitialUserInfoResponseAction : int32_t { 4912 /** 4913 * Let the Android System decide what to do. 4914 * 4915 * For example, it might create a new user on first boot, and switch to the last 4916 * active user afterwards. 4917 */ 4918 DEFAULT = 0, 4919 4920 /** 4921 * Switch to an existing Android user. 4922 */ 4923 SWITCH = 1, 4924 4925 /** 4926 * Create a new Android user (and switch to it). 4927 */ 4928 CREATE = 2, 4929}; 4930 4931/** 4932 * Defines the format of a SWITCH_USER property. 4933 * 4934 * NOTE: this struct is not used in the HAL properties directly, it must be converted to 4935 * VehiclePropValue.RawValue through libraries provided by the default Vehicle HAL implementation. 4936 */ 4937struct SwitchUserRequest { 4938 /** 4939 * Arbitrary id used to map the response to the request. 4940 */ 4941 UserRequestId requestId; 4942 4943 /** 4944 * Type of message. 4945 */ 4946 SwitchUserMessageType messageType; 4947 4948 /** 4949 * Information about the Android user being switched to. 4950 * 4951 * Only the user id (but not the flags) should be set when the request is made by HAL. 4952 */ 4953 UserInfo targetUser; 4954 4955 /** 4956 * Information about the current state of the Android system. 4957 * 4958 * Should not be set when the request is made by HAL. 4959 */ 4960 UsersInfo usersInfo; 4961}; 4962 4963/** 4964 * Defines the reason a SWITCH_USER call was made. 4965 * 4966 * The meaning of each constant is explained in that property. 4967 */ 4968enum SwitchUserMessageType: int32_t { 4969 LEGACY_ANDROID_SWITCH = 1, 4970 ANDROID_SWITCH = 2, 4971 VEHICLE_RESPONSE = 3, 4972 VEHICLE_REQUEST = 4, 4973 ANDROID_POST_SWITCH = 5, 4974}; 4975 4976/** 4977 * Defines the result of a SwitchUserRequest. 4978 * 4979 * NOTE: this struct is not used in the HAL properties directly, it must be converted to 4980 * VehiclePropValue.RawValue through libraries provided by the default Vehicle HAL implementation. 4981 */ 4982struct SwitchUserResponse { 4983 /** 4984 * Id of the request being responded. 4985 */ 4986 UserRequestId requestId; 4987 4988 /** 4989 * Type of message. 4990 */ 4991 SwitchUserMessageType messageType; 4992 4993 /** 4994 * Status of the request. 4995 */ 4996 SwitchUserStatus status; 4997 4998 /** 4999 * HAL-specific error message. 5000 * 5001 * This argument is optional, and when defined, it's passed "as-is" to the caller. It could be 5002 * used to show custom error messages to the end user. 5003 */ 5004 string errorMessage; 5005}; 5006 5007/** 5008 * Status of the response to a SwitchUserRequest. 5009 */ 5010enum SwitchUserStatus : int32_t { 5011 /** The request succeeded and the HAL user was switched. */ 5012 SUCCESS = 1, 5013 /** The request failed and the HAL user remained the same. */ 5014 FAILURE = 2, 5015}; 5016 5017/** 5018 * Defines the format of a CREATE_USER property. 5019 * 5020 * NOTE: this struct is not used in the HAL properties directly, it must be converted to 5021 * VehiclePropValue.RawValue through libraries provided by the default Vehicle HAL implementation. 5022 */ 5023struct CreateUserRequest { 5024 /** 5025 * Arbitrary id used to map the response to the request. 5026 */ 5027 UserRequestId requestId; 5028 5029 /** 5030 * Basic information about Android user that was created. 5031 */ 5032 UserInfo newUserInfo; 5033 5034 /** 5035 * Name of the new Android user. 5036 */ 5037 string newUserName; 5038 5039 /** 5040 * Information about the current state of the Android system. 5041 */ 5042 UsersInfo usersInfo; 5043}; 5044 5045/** 5046 * Defines the result of a CreateUserRequest. 5047 * 5048 * NOTE: this struct is not used in the HAL properties directly, it must be converted to 5049 * VehiclePropValue.RawValue through libraries provided by the default Vehicle HAL implementation. 5050 */ 5051struct CreateUserResponse { 5052 /** 5053 * Id of the request being responded. 5054 */ 5055 UserRequestId requestId; 5056 5057 /** 5058 * Status of the request. 5059 */ 5060 CreateUserStatus status; 5061 5062 /** 5063 * HAL-specific error message. 5064 * 5065 * This argument is optional, and when defined, it's passed "as-is" to the caller. It could be 5066 * used to show custom error messages to the end user. 5067 */ 5068 string errorMessage; 5069}; 5070 5071/** 5072 * Status of the response to a CreateUserRequest. 5073 */ 5074enum CreateUserStatus : int32_t { 5075 /** 5076 * The request succeeded (for example, HAL created a new internal user, or associated the 5077 * Android user to an existing internal user). 5078 */ 5079 SUCCESS = 1, 5080 5081 /** 5082 * The request failed (and Android will remove the Android user). 5083 */ 5084 FAILURE = 2, 5085}; 5086 5087/** 5088 * Defines the format of a REMOVE_USER property. 5089 * 5090 * NOTE: this struct is not used in the HAL properties directly, it must be converted to 5091 * VehiclePropValue.RawValue through libraries provided by the default Vehicle HAL implementation. 5092 */ 5093struct RemoveUserRequest { 5094 /** 5095 * Arbitrary id used to map the response to the request. 5096 */ 5097 UserRequestId requestId; 5098 5099 /** 5100 * Information about the Android user that was removed. 5101 */ 5102 UserInfo removedUserInfo; 5103 5104 /** 5105 * Information about the current state of the Android system. 5106 */ 5107 UsersInfo usersInfo; 5108}; 5109 5110/** 5111 * Types of mechanisms used to identify an Android user. 5112 * 5113 * See USER_IDENTIFICATION_ASSOCIATION for more details and example. 5114 */ 5115enum UserIdentificationAssociationType: int32_t { 5116 /** Key used to unlock the car. */ 5117 KEY_FOB = 1, 5118 /** Custom mechanism defined by the OEM. */ 5119 CUSTOM_1 = 101, 5120 /** Custom mechanism defined by the OEM. */ 5121 CUSTOM_2 = 102, 5122 /** Custom mechanism defined by the OEM. */ 5123 CUSTOM_3 = 103, 5124 /** Custom mechanism defined by the OEM. */ 5125 CUSTOM_4 = 104, 5126}; 5127 5128/** 5129 * Whether a UserIdentificationAssociationType is associate with an Android user. 5130 */ 5131enum UserIdentificationAssociationValue : int32_t { 5132 /** 5133 * Used when the status of an association could not be determined. 5134 * 5135 * For example, in a set() request, it would indicate a failure to set the given type. 5136 */ 5137 UNKNOWN = 1, 5138 5139 /** 5140 * The identification type is associated with the current foreground Android user. 5141 */ 5142 ASSOCIATED_CURRENT_USER = 2, 5143 5144 /** 5145 * The identification type is associated with another Android user. 5146 */ 5147 ASSOCIATED_ANOTHER_USER = 3, 5148 5149 /** 5150 * The identification type is not associated with any Android user. 5151 */ 5152 NOT_ASSOCIATED_ANY_USER = 4, 5153}; 5154 5155/** 5156 * Used to set a UserIdentificationAssociationType with an Android user. 5157 */ 5158enum UserIdentificationAssociationSetValue : int32_t { 5159 /** 5160 * Associate the identification type with the current foreground Android user. 5161 */ 5162 ASSOCIATE_CURRENT_USER = 1, 5163 5164 /** 5165 * Disassociate the identification type from the current foreground Android user. 5166 */ 5167 DISASSOCIATE_CURRENT_USER = 2, 5168 5169 /** 5170 * Disassociate the identification type from all Android users. 5171 */ 5172 DISASSOCIATE_ALL_USERS = 3, 5173}; 5174 5175/** 5176 * Defines the format of a get() call to USER_IDENTIFICATION_ASSOCIATION. 5177 * 5178 * NOTE: this struct is not used in the HAL properties directly, it must be converted to 5179 * VehiclePropValue.RawValue through libraries provided by the default Vehicle HAL implementation. 5180 */ 5181struct UserIdentificationGetRequest { 5182 /** 5183 * Id of the request being responded. 5184 */ 5185 UserRequestId requestId; 5186 5187 /** 5188 * Information about the current foreground Android user. 5189 */ 5190 UserInfo userInfo; 5191 5192 /** 5193 * Number of association being queried. 5194 */ 5195 int32_t numberAssociationTypes; 5196 5197 /** 5198 * Types of association being queried. 5199 */ 5200 vec<UserIdentificationAssociationType> associationTypes; 5201}; 5202 5203/** 5204 * Defines the format of a set() call to USER_IDENTIFICATION_ASSOCIATION. 5205 * 5206 * NOTE: this struct is not used in the HAL properties directly, it must be converted to 5207 * VehiclePropValue.RawValue through libraries provided by the default Vehicle HAL implementation. 5208 */ 5209struct UserIdentificationSetRequest { 5210 /** 5211 * Id of the request being responded. 5212 */ 5213 UserRequestId requestId; 5214 5215 /** 5216 * Information about the current foreground Android user. 5217 */ 5218 UserInfo userInfo; 5219 5220 /** 5221 * Number of association being set. 5222 */ 5223 int32_t numberAssociations; 5224 5225 /** 5226 * Associations being set. 5227 */ 5228 vec<UserIdentificationSetAssociation> associations; 5229}; 5230 5231/** 5232 * Defines the result of a USER_IDENTIFICATION_ASSOCIATION - both for get() and set(). 5233 * 5234 * NOTE: this struct is not used in the HAL properties directly, it must be converted to 5235 * VehiclePropValue.RawValue through libraries provided by the default Vehicle HAL implementation. 5236 */ 5237struct UserIdentificationResponse { 5238 /** 5239 * Id of the request being responded. 5240 */ 5241 UserRequestId requestId; 5242 5243 /** 5244 * Number of associations being returned. 5245 */ 5246 int32_t numberAssociation; 5247 5248 /** 5249 * Values associated with the user. 5250 */ 5251 vec<UserIdentificationAssociation> associations; 5252 5253 /** 5254 * HAL-specific error message. 5255 * 5256 * This argument is optional, and when defined, it's passed "as-is" to the caller. It could be 5257 * used to show custom error messages to the end user. 5258 */ 5259 string errorMessage; 5260}; 5261 5262/** 5263 * Helper struct used when getting a user/identification association type. 5264 */ 5265struct UserIdentificationAssociation { 5266 5267 UserIdentificationAssociationType type; 5268 5269 UserIdentificationAssociationValue value; 5270}; 5271 5272/** 5273 * Helper struct used when setting a user/identification association type. 5274 */ 5275struct UserIdentificationSetAssociation { 5276 5277 UserIdentificationAssociationType type; 5278 5279 UserIdentificationAssociationSetValue value; 5280}; 5281 5282/** 5283 * A rotary control which can rotate without limits. These controls use HW_ROTARY_INPUT to report 5284 * relative clockwise or counterclockwise motion. They have no absolute position. 5285 */ 5286enum RotaryInputType : int32_t { 5287 /** 5288 * Main rotary control, typically in the center console, used to navigate the user interface. 5289 */ 5290 ROTARY_INPUT_TYPE_SYSTEM_NAVIGATION = 0, 5291 5292 /** Volume control for adjusting audio volume. */ 5293 ROTARY_INPUT_TYPE_AUDIO_VOLUME = 1, 5294}; 5295 5296/** 5297 * The reason why a process is terminated by car watchdog. 5298 * This is used with WATCHDOG_TERMINATED_PROCESS property. 5299 */ 5300enum ProcessTerminationReason : int32_t { 5301 /** 5302 * A process doesn't respond to car watchdog within the timeout. 5303 */ 5304 NOT_RESPONDING = 1, 5305 5306 /** 5307 * A process uses more IO operations than what is allowed. 5308 */ 5309 IO_OVERUSE = 2, 5310 5311 /** 5312 * A process uses more memory space than what is allowed. 5313 */ 5314 MEMORY_OVERUSE = 3, 5315}; 5316 5317/** 5318 * Input code values for HW_CUSTOM_INPUT. 5319 */ 5320enum CustomInputType : int32_t { 5321 /** 5322 * Ten optional function codes to be used in case OEM don't need more than 10 input code values. 5323 * 5324 * OEMs are free to use any signed 32 bits number to represent the input code value. 5325 * The following function keys are only for convenience and any other integer values are 5326 * also allowed. 5327 */ 5328 CUSTOM_EVENT_F1 = 1001, 5329 CUSTOM_EVENT_F2 = 1002, 5330 CUSTOM_EVENT_F3 = 1003, 5331 CUSTOM_EVENT_F4 = 1004, 5332 CUSTOM_EVENT_F5 = 1005, 5333 CUSTOM_EVENT_F6 = 1006, 5334 CUSTOM_EVENT_F7 = 1007, 5335 CUSTOM_EVENT_F8 = 1008, 5336 CUSTOM_EVENT_F9 = 1009, 5337 CUSTOM_EVENT_F10 = 1010, 5338}; 5339 5340