-
Notifications
You must be signed in to change notification settings - Fork 65
/
vehicle_data.proto
247 lines (237 loc) · 6.15 KB
/
vehicle_data.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
syntax = "proto3";
package telemetry.vehicle_data;
import "google/protobuf/timestamp.proto";
option go_package = "github.com/teslamotors/fleet-telemetry/protos";
enum Field {
Unknown = 0;
DriveRail = 1;
ChargeState = 2;
BmsFullchargecomplete = 3;
VehicleSpeed = 4;
Odometer = 5;
PackVoltage = 6;
PackCurrent = 7;
Soc = 8;
DCDCEnable = 9;
Gear = 10;
IsolationResistance = 11;
PedalPosition = 12;
BrakePedal = 13;
DiStateR = 14;
DiHeatsinkTR = 15;
DiAxleSpeedR = 16;
DiTorquemotor = 17;
DiStatorTempR = 18;
DiVBatR = 19;
DiMotorCurrentR = 20;
Location = 21;
GpsState = 22;
GpsHeading = 23;
NumBrickVoltageMax = 24;
BrickVoltageMax = 25;
NumBrickVoltageMin = 26;
BrickVoltageMin = 27;
NumModuleTempMax = 28;
ModuleTempMax = 29;
NumModuleTempMin = 30;
ModuleTempMin = 31;
RatedRange = 32;
Hvil = 33;
DCChargingEnergyIn = 34;
DCChargingPower = 35;
ACChargingEnergyIn = 36;
ACChargingPower = 37;
ChargeLimitSoc = 38;
FastChargerPresent = 39;
EstBatteryRange = 40;
IdealBatteryRange = 41;
BatteryLevel = 42;
TimeToFullCharge = 43;
ScheduledChargingStartTime = 44;
ScheduledChargingPending = 45;
ScheduledDepartureTime = 46;
PreconditioningEnabled = 47;
ScheduledChargingMode = 48;
ChargeAmps = 49;
ChargeEnableRequest = 50;
ChargerPhases = 51;
ChargePortColdWeatherMode = 52;
ChargeCurrentRequest = 53;
ChargeCurrentRequestMax = 54;
BatteryHeaterOn = 55;
NotEnoughPowerToHeat = 56;
SuperchargerSessionTripPlanner = 57;
DoorState = 58;
Locked = 59;
FdWindow = 60;
FpWindow = 61;
RdWindow = 62;
RpWindow = 63;
VehicleName = 64;
SentryMode = 65;
SpeedLimitMode = 66;
CurrentLimitMph = 67;
Version = 68;
TpmsPressureFl = 69;
TpmsPressureFr = 70;
TpmsPressureRl = 71;
TpmsPressureRr = 72;
SemitruckTpmsPressureRe1L0 = 73; // Semi-truck only
SemitruckTpmsPressureRe1L1 = 74; // Semi-truck only
SemitruckTpmsPressureRe1R0 = 75; // Semi-truck only
SemitruckTpmsPressureRe1R1 = 76; // Semi-truck only
SemitruckTpmsPressureRe2L0 = 77; // Semi-truck only
SemitruckTpmsPressureRe2L1 = 78; // Semi-truck only
SemitruckTpmsPressureRe2R0 = 79; // Semi-truck only
SemitruckTpmsPressureRe2R1 = 80; // Semi-truck only
TpmsLastSeenPressureTimeFl = 81;
TpmsLastSeenPressureTimeFr = 82;
TpmsLastSeenPressureTimeRl = 83;
TpmsLastSeenPressureTimeRr = 84;
InsideTemp = 85;
OutsideTemp = 86;
SeatHeaterLeft = 87;
SeatHeaterRight = 88;
SeatHeaterRearLeft = 89;
SeatHeaterRearRight = 90;
SeatHeaterRearCenter = 91;
AutoSeatClimateLeft = 92;
AutoSeatClimateRight = 93;
DriverSeatBelt = 94;
PassengerSeatBelt = 95;
DriverSeatOccupied = 96;
SemitruckPassengerSeatFoldPosition = 97; // Semi-truck only
LateralAcceleration = 98;
LongitudinalAcceleration = 99;
CruiseState = 100;
CruiseSetSpeed = 101;
LifetimeEnergyUsed = 102;
LifetimeEnergyUsedDrive = 103;
SemitruckTractorParkBrakeStatus = 104; // Semi-truck only
SemitruckTrailerParkBrakeStatus = 105; // Semi-truck only
BrakePedalPos = 106;
RouteLastUpdated = 107;
RouteLine = 108;
MilesToArrival = 109;
MinutesToArrival = 110;
OriginLocation = 111;
DestinationLocation = 112;
CarType = 113;
Trim = 114;
ExteriorColor = 115;
RoofColor = 116;
ChargePort = 117;
ChargePortLatch = 118;
Experimental_1 = 119;
Experimental_2 = 120;
Experimental_3 = 121;
Experimental_4 = 122;
GuestModeEnabled = 123;
PinToDriveEnabled = 124;
PairedPhoneKeyAndKeyFobQty = 125;
CruiseFollowDistance = 126;
AutomaticBlindSpotCamera = 127;
BlindSpotCollisionWarningChime = 128;
SpeedLimitWarning = 129;
ForwardCollisionWarning = 130;
LaneDepartureAvoidance = 131;
EmergencyLaneDepartureAvoidance = 132;
AutomaticEmergencyBrakingOff = 133;
LifetimeEnergyGainedRegen = 134;
DiStateF = 135;
DiStateREL = 136;
DiStateRER = 137;
DiHeatsinkTF = 138;
DiHeatsinkTREL = 139;
DiHeatsinkTRER = 140;
DiAxleSpeedF = 141;
DiAxleSpeedREL = 142;
DiAxleSpeedRER = 143;
DiSlaveTorqueCmd = 144;
DiTorqueActualR = 145;
DiTorqueActualF = 146;
DiTorqueActualREL = 147;
DiTorqueActualRER = 148;
DiStatorTempF = 149;
DiStatorTempREL = 150;
DiStatorTempRER = 151;
DiVBatF = 152;
DiVBatREL = 153;
DiVBatRER = 154;
DiMotorCurrentF = 155;
DiMotorCurrentREL = 156;
DiMotorCurrentRER = 157;
EnergyRemaining = 158;
ServiceMode = 159;
BMSState = 160;
GuestModeMobileAccessState = 161;
Deprecated_1 = 162;
DestinationName = 163;
DiInverterTR = 164;
DiInverterTF = 165;
DiInverterTREL = 166;
DiInverterTRER = 167;
Experimental_5 = 168;
Experimental_6 = 169;
Experimental_7 = 170;
Experimental_8 = 171;
Experimental_9 = 172;
Experimental_10 = 173;
Experimental_11 = 174;
Experimental_12 = 175;
Experimental_13 = 176;
Experimental_14 = 177;
Experimental_15 = 178;
}
// ChargingState are the charging options
enum ChargingState {
ChargeStateUnknown = 0;
ChargeStateDisconnected = 1;
ChargeStateNoPower = 2;
ChargeStateStarting = 3;
ChargeStateCharging = 4;
ChargeStateComplete = 5;
ChargeStateStopped = 6;
}
// ShiftState are the gear options
enum ShiftState {
ShiftStateUnknown = 0;
ShiftStateInvalid = 1;
ShiftStateP = 2;
ShiftStateR = 3;
ShiftStateD = 4;
ShiftStateN = 5;
ShiftStateSNA = 6;
}
// LocationValue is a Datum value type
message LocationValue {
double latitude = 1;
double longitude = 2;
}
// Value is a dynamic Datum type. Most Datums are strings and is the default format
// Note: Fields may have their types updated with different software and vehicle
// versions to optimize for precision or space
message Value {
oneof value {
string string_value = 1;
int32 int_value = 2;
int64 long_value = 3;
float float_value = 4;
double double_value = 5;
bool boolean_value = 6;
LocationValue location_value = 7;
ChargingState charging_value = 8;
ShiftState shift_state_value = 9;
}
}
// Datum represents a single field and its value
message Datum {
Field key = 1;
Value value = 2;
}
// Payload holds a collection of values, and may not have a vin
message Payload {
repeated Datum data = 1;
google.protobuf.Timestamp created_at = 2;
string vin = 3;
}