Skip to content

Commit 446eb89

Browse files
committed
add more energy consumption and efficiency related properties
1 parent 7a4405d commit 446eb89

File tree

7 files changed

+114
-18
lines changed

7 files changed

+114
-18
lines changed

capabilities/charging.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1412,3 +1412,16 @@ properties:
14121412
- data_component: '3feccccccccccccd'
14131413
value: 0.9
14141414
description: State of health of the high-voltage battery is 90%.
1415+
1416+
- id: 0x51
1417+
name: distance_since_charging
1418+
name_cased: distanceSinceCharging
1419+
name_pretty: Distance since charging
1420+
type: unit.length
1421+
size: 10
1422+
description: The distance driven since the last charging session
1423+
examples:
1424+
- data_component: '12044028cccccccccccd'
1425+
value:
1426+
kilometers: 12.4
1427+
description: 12.4km driven since the last charging session

capabilities/diagnostics.yml

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1009,16 +1009,3 @@ properties:
10091009
- data_component: '3fe999999999999a'
10101010
value: 0.8
10111011
description: Secondary energy level is at 80%
1012-
1013-
- id: 0x3d
1014-
name: distance_since_charging
1015-
name_cased: distanceSinceCharging
1016-
name_pretty: Distance since charging
1017-
type: unit.length
1018-
size: 10
1019-
description: The distance driven since the last charging session
1020-
examples:
1021-
- data_component: '12044028cccccccccccd'
1022-
value:
1023-
kilometers: 12.4
1024-
description: 12.4km driven since the last charging session

capabilities/maintenance.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -505,3 +505,44 @@ properties:
505505
due: 'almost'
506506
reason: 'distance_driven'
507507
description: Service is almost due because of distance driven.
508+
509+
- id: 0x26
510+
name: last_service_date
511+
name_cased: lastServiceDate
512+
name_pretty: Last service date
513+
added: 0x0d
514+
type: timestamp
515+
size: 8
516+
description: Date of the last service performed on the vehicle.
517+
examples:
518+
- data_component: '0000017fe45286dd'
519+
value: '2022-04-01T08:51:28.093Z'
520+
description: Last service was on 1. April 2022 at 11:51:28 EEST.
521+
522+
- id: 0x27
523+
name: last_service_distance
524+
name_cased: lastServiceDistance
525+
name_pretty: Last service distance
526+
added: 0x0d
527+
type: unit.length
528+
size: 10
529+
description: Distance reading at the time of the last service.
530+
examples:
531+
- data_component: '120440f7590000000000'
532+
value:
533+
kilometers: 95632.0
534+
description: Distance reading at last service was 95'632km.
535+
536+
- id: 0x28
537+
name: next_inspection_distance
538+
name_cased: nextInspectionDistance
539+
name_pretty: Next inspection distance
540+
added: 0x0d
541+
type: unit.length
542+
size: 10
543+
description: Distance reading at which the next inspection is due.
544+
examples:
545+
- data_component: '120440e86a0000000000'
546+
value:
547+
kilometers: 50000.0
548+
description: Next inspection is due at 50'000km.

capabilities/trips.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -449,3 +449,17 @@ properties:
449449
value:
450450
minutes: 123.0
451451
description: Duration of trip was 123.0 minutes.
452+
453+
- id: 0x1a
454+
name: average_electric_consumption
455+
name_cased: averageElectricConsumption
456+
name_pretty: Average electric consumption
457+
added: 0x0d
458+
type: unit.energy_efficiency
459+
size: 10
460+
description: Average electric consumption during the trip
461+
examples:
462+
- data_component: '0d00401d5c28f5c28f5c'
463+
value:
464+
kilometers_per_kwh: 7.34
465+
description: Average electric consumption during the trip was 7.34 km/kWh.

capabilities/usage.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -796,3 +796,17 @@ properties:
796796
value:
797797
kilometers_per_hour: 44.2
798798
description: Average speed was 44.2km/h since the last charging session.
799+
800+
- id: 0x36
801+
name: fuel_consumption_rate_since_start
802+
name_cased: fuelConsumptionRateSinceStart
803+
name_pretty: Fuel consumption rate since start
804+
added: 0x0c
805+
type: unit.fuel_efficiency
806+
size: 10
807+
description: Liquid fuel consumption rate since start
808+
examples:
809+
- data_component: '0f00401599999999999a'
810+
value:
811+
liters_per_100_kilometers: 5.4
812+
description: Consumed 5.4 L/100km since start

changelogs/L13.6_changelog.md

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# AutoAPI L13 Extensions #6 Changelog
22

3-
**Level 13** _6th extension_ (aka **L13.6**) contains only additive updates to the protocol.
3+
**Level 13** _6th extension_ (aka **L13.6**) contains mostly additive updates to the protocol.
44
These include new properties for existing capabilities, additions to already existing enums, and new custom types.
55

66
Changes from L13.5 are divided into these sub-sections:
@@ -18,25 +18,42 @@ Some enums have gained new values.
1818
- `charging.station_status` (added `initialising`, `fault`, `inactive`)
1919
- `dashboard_lights.dashboard_lights` (added `high_beam_left_failure`, `high_beam_right_failure`, `daytime_running_light_left_failure`, `daytime_running_light_right_failure`, `side_mark_lights_failure`, `licence_plate_light_failure`)
2020

21+
There are also a few new units added to existing unit types:
22+
23+
- `unit.energy_efficiency`
24+
- `kilometers_per_kwh`
25+
- `miles_per_gallon_equivalent`
26+
- `miles_per_imperial_gallon_equivalent`
27+
28+
- `unit.fuel_efficiency`
29+
- `kilometers_per_liter`
30+
2131

2232
## Properties
2333

2434
New properties added to pre-existing capabilities:
2535

26-
- _diagnostics_
36+
- _charging_
2737
- `distance_since_charging`
2838

2939
- _maintenance_
3040
- `service_warning`
41+
- `last_service_date`
42+
- `last_service_distance`
43+
- `next_inspection_distance`
44+
45+
- _trips_
46+
- `average_electric_consumption`
3147

3248
- _usage_
49+
- `average_speed_since_charging`
3350
- `energy_consumption_last_trip`
3451
- `energy_consumption_since_reset`
3552
- `energy_consumption_since_charging`
3653
- `energy_consumption_percentages_last_trip`
3754
- `energy_consumption_percentages_since_reset`
3855
- `energy_consumption_percentages_since_charging`
39-
- `average_speed_since_charging`
56+
- `fuel_consumption_rate_since_start`
4057

4158
## Custom Types
4259

misc/unit_types.yml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,7 @@
88
# [0x04, 0x00, 0x02, measurement_type_id, unit_type_id]
99
#
1010

11-
1211
measurement_types:
13-
1412
- name: acceleration
1513
id: 0x01
1614
unit_types:
@@ -126,6 +124,15 @@ measurement_types:
126124
- name: miles_per_kwh
127125
id: 0x01
128126
conversion_inverse: 62.137119223733397
127+
- name: kilometers_per_kwh
128+
id: 0x02
129+
conversion_inverse: 100.0
130+
- name: miles_per_gallon_equivalent
131+
id: 0x03
132+
conversion_inverse: 2094.331603
133+
- name: miles_per_imperial_gallon_equivalent
134+
id: 0x04
135+
conversion_inverse: 2515.187
129136

130137
- name: frequency
131138
id: 0x0e
@@ -167,6 +174,9 @@ measurement_types:
167174
- name: miles_per_gallon
168175
id: 0x02
169176
conversion_inverse: 235.2145833
177+
- name: kilometers_per_liter
178+
id: 0x03
179+
conversion_inverse: 100.0
170180

171181
- name: illuminance
172182
id: 0x11

0 commit comments

Comments
 (0)