mirror of
https://github.com/dragonpilot/dragonpilot.git
synced 2026-06-24 15:32:07 +08:00
Compare commits
321 Commits
0.6.3-en
...
v0.6.3-zht
| Author | SHA1 | Date | |
|---|---|---|---|
| f6f58d2a7e | |||
| 296daec59a | |||
| 97ed349d04 | |||
| 9a1ceeb0e8 | |||
| 9affab1f27 | |||
| 8934720785 | |||
| af1d476c50 | |||
| b14f39b2c8 | |||
| 4b806911ad | |||
| 69780971aa | |||
| 2f49572d72 | |||
| 0105342caf | |||
| 8c442ec989 | |||
| c29f96069e | |||
| 781c392a22 | |||
| 23f142bcf0 | |||
| da42760e55 | |||
| 4f0061d71c | |||
| fd86f04e82 | |||
| 95aca22809 | |||
| f5a9a08863 | |||
| df85e66a6d | |||
| 49eec4cab3 | |||
| f2648fd12f | |||
| d50811859a | |||
| c1f03ce883 | |||
| 7ce952e165 | |||
| d1e95be073 | |||
| 04a7dd2633 | |||
| 6168ce1ef9 | |||
| 466dce4090 | |||
| 227578ef15 | |||
| 29d10aed97 | |||
| c2d2780772 | |||
| 6045192107 | |||
| b617372907 | |||
| 67a595e321 | |||
| e1509808ac | |||
| c21334cb95 | |||
| 2dc8bd5655 | |||
| cfe34284a4 | |||
| eebf70fd59 | |||
| be2bf61420 | |||
| d7a5fb0c65 | |||
| 55dad14711 | |||
| 6f47f3c4d6 | |||
| 234ddbebaf | |||
| 6f6c96735a | |||
| 691bb95a77 | |||
| ac45050c4a | |||
| fd731f1f27 | |||
| 8af6ddcd8b | |||
| a5e2f3cc22 | |||
| fa8e44d0b2 | |||
| 651f994d6a | |||
| 9c8a03ecfb | |||
| 66cac800cb | |||
| 751aa5cf7e | |||
| e05df8f0fc | |||
| 5c059504ed | |||
| c187ea5986 | |||
| ec691a586a | |||
| f738ce6ec9 | |||
| dea170368e | |||
| 88558aa7a5 | |||
| bb535e797e | |||
| b01aa70635 | |||
| 7d86e2adef | |||
| 05fa8a5eda | |||
| db4ef15bed | |||
| 6365dbb34d | |||
| 854e662c57 | |||
| bd5db31b6a | |||
| 20e8d61f0c | |||
| 77460d8e7f | |||
| b2ef7ff80c | |||
| 01319c0251 | |||
| 0e249e2bed | |||
| d2a0782e1b | |||
| aa14e182af | |||
| 0a3a86637b | |||
| 03d8cf087b | |||
| 48c0937081 | |||
| 982b635653 | |||
| 3712ca6273 | |||
| 4c5ad29782 | |||
| 3d9596716b | |||
| c66b57daff | |||
| 8f8879eaac | |||
| c3f6af77ee | |||
| 652e1955b0 | |||
| 611172df48 | |||
| 4969ff7fbb | |||
| 66c08fb446 | |||
| dcc18e4e7c | |||
| bc8b6e7e6f | |||
| 05a3af4c39 | |||
| 62d499219a | |||
| 37d788449e | |||
| 2b746aa134 | |||
| 9a03511d2a | |||
| b0c7a50b06 | |||
| 31c65fa5e8 | |||
| a60dbb32df | |||
| 0ac693c74c | |||
| 321271c510 | |||
| f25ee81a81 | |||
| d232f16e07 | |||
| 2675651ca8 | |||
| aea6d53eaf | |||
| e0cbd452a0 | |||
| 4c3b24fcda | |||
| fb3e0969cc | |||
| 15ebf13cf1 | |||
| 71e9076e50 | |||
| 639a914846 | |||
| cff8a98850 | |||
| 999d157c75 | |||
| 9f414becd1 | |||
| 634de04d23 | |||
| b69089883f | |||
| 2474cd56cc | |||
| cf62e14547 | |||
| 261428ec98 | |||
| 5ecacfd879 | |||
| 2f6e0a59fd | |||
| e95ae50ab5 | |||
| b745bf1e5a | |||
| 8451eebe96 | |||
| 4f8b6f7b84 | |||
| cb47382c9d | |||
| c60e002440 | |||
| d727aea5ad | |||
| 851a5b2f44 | |||
| 0a208866ce | |||
| 0c26ac0da7 | |||
| 2d40ccfc16 | |||
| 1b06be660b | |||
| 8d5403b26a | |||
| 1150937f33 | |||
| 94d9ea0863 | |||
| 3ad47fb1d0 | |||
| 6bad4f56f7 | |||
| c041b0068c | |||
| d4bf69422c | |||
| e9c2249a81 | |||
| 63fa61ecd7 | |||
| 39808e3627 | |||
| ff717ae03e | |||
| 8bb3420b92 | |||
| 6365c3b17c | |||
| 8dd8f08d10 | |||
| 8d637c8e33 | |||
| 9f75a6b5a6 | |||
| 221e383f11 | |||
| 6b09953b09 | |||
| 255c58f6ba | |||
| 3fed5bfaf3 | |||
| 3543d4948c | |||
| 33b1bb50c1 | |||
| 42093dadd1 | |||
| 18eee85ff1 | |||
| 938b1aa189 | |||
| f362771af3 | |||
| 7251ea4ac6 | |||
| f85055a19c | |||
| 28ebecdbc5 | |||
| 7bc86efee9 | |||
| d60e071fa9 | |||
| b70289ce15 | |||
| be8cc7c15f | |||
| 589abe5519 | |||
| be622c7932 | |||
| 65a8f13d98 | |||
| 9a4eb3e0b0 | |||
| 3148499f69 | |||
| dca99bea38 | |||
| 392cf59937 | |||
| 0bf4dbc3b0 | |||
| 0a94454812 | |||
| 2a698bf73e | |||
| 64e6706a0b | |||
| 18e80ea755 | |||
| af7e33bae8 | |||
| 484fa1ac63 | |||
| 603af161fd | |||
| 42906ef1ae | |||
| c9a9d8bd97 | |||
| 91f0b5c6cd | |||
| e0eccb87b5 | |||
| 5b8976af61 | |||
| a7cf5c2cbb | |||
| 5fe6367d08 | |||
| 99ba8c8cc8 | |||
| 88213d0cfd | |||
| 66f2a6fe01 | |||
| 365f3bd4dc | |||
| a85488fbb8 | |||
| c5933c9d8d | |||
| de0ea4820c | |||
| 26e60a6b4b | |||
| e7d4197a08 | |||
| 0db8d26c12 | |||
| 26c583b5c4 | |||
| 181dba4514 | |||
| 5f5698900c | |||
| 1d0dc50f98 | |||
| 2890a4ede8 | |||
| 882eaf15bf | |||
| 6fba167ef9 | |||
| 65b8466f22 | |||
| 9c3ec2fd2d | |||
| a1d96b4d8a | |||
| 57bca3c658 | |||
| 40422ea5d6 | |||
| 7017f8ebf0 | |||
| 19660515b5 | |||
| d1fe6a9667 | |||
| c227f977e6 | |||
| b9cf00f4ce | |||
| d192b4fa8f | |||
| f760fa00ae | |||
| 83cbf29588 | |||
| 022b058bc5 | |||
| f789be8485 | |||
| 8310b01530 | |||
| d2f755286c | |||
| 8fbcaf423e | |||
| 6ff384ba3f | |||
| 9e2be16440 | |||
| 5dfc758d33 | |||
| 14894b4b66 | |||
| fdccc48bf7 | |||
| 8e491aaf58 | |||
| c46d931f40 | |||
| 6c3468b02f | |||
| d398ba2c62 | |||
| 8e346aa668 | |||
| 989f3c5ecc | |||
| 5806c90a3e | |||
| 2c081208eb | |||
| ef64a1bf5f | |||
| 278ce557da | |||
| 5ff4ff176b | |||
| 87b02db857 | |||
| c0929d6954 | |||
| 8ca37f5d44 | |||
| f43e347fbf | |||
| 32003bd048 | |||
| a326b4b4cd | |||
| bf1368b4cf | |||
| c3d5b9d62e | |||
| d5916b92d5 | |||
| 91dd484c27 | |||
| bfaf9e6f66 | |||
| 30eb131980 | |||
| 24d0084938 | |||
| a7cadcc390 | |||
| 8cfdc1cbc2 | |||
| 88dd52414f | |||
| 0b21c835a4 | |||
| 81f3709a9f | |||
| f6214eb932 | |||
| de3e265b36 | |||
| 3239f78e69 | |||
| d27257bbbb | |||
| 4631a7e81f | |||
| 53f2722a3d | |||
| 0d62ee7598 | |||
| 1efeded724 | |||
| 29aaade7ab | |||
| f7f91aec22 | |||
| 1d4c811611 | |||
| 421fe728f1 | |||
| 9683bccaf6 | |||
| 666826198f | |||
| fcbb07b1a0 | |||
| 9e067e91ee | |||
| c675c28356 | |||
| f2f7e8d516 | |||
| 8237b60749 | |||
| 7405041b42 | |||
| 4bc57a9792 | |||
| 851d6f1b96 | |||
| 4eeaaf1b08 | |||
| 243f10d5fb | |||
| 837809774b | |||
| 2100e46b60 | |||
| c7f9c1bd69 | |||
| 574fabf9ca | |||
| 00def2849c | |||
| 9df9019c1e | |||
| c818b6ada3 | |||
| be750af7ff | |||
| f8752fbe2c | |||
| fbbfcc5a74 | |||
| 67ccfb11c7 | |||
| 31d9f18fca | |||
| 02b6a7a82b | |||
| 3103b9bfea | |||
| fb470830ed | |||
| a988911e05 | |||
| 9abe003d1d | |||
| 81477e857a | |||
| 67669174f0 | |||
| e0d7ce9e57 | |||
| ec975a36cd | |||
| 65ca70c731 | |||
| 3dffd9a942 | |||
| 547c9eaad0 | |||
| 40c70cc865 | |||
| 112c02991d | |||
| bdc16ce545 | |||
| 5c041d3b78 | |||
| 97949b12b3 | |||
| fabf747d74 | |||
| 41b7ba1092 | |||
| f86b42cd81 | |||
| 3d0859dc39 | |||
| 1ad1340b58 | |||
| 05231722e5 |
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -118,6 +118,7 @@ keys = {
|
||||
"DragonSteeringMonitorTimer": [TxType.PERSISTENT],
|
||||
"DragonCameraOffset": [TxType.PERSISTENT],
|
||||
"DragonUIVolumeBoost": [TxType.PERSISTENT],
|
||||
"DragonGreyPandaMode": [TxType.PERSISTENT],
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/usr/bin/bash
|
||||
|
||||
# Anndroid system locale, zh-TW = Traditional Chinese, zh-CN = Simplified Chinese
|
||||
lang=en
|
||||
lang=zh-TW
|
||||
|
||||
update_font_reg=0
|
||||
update_font_bold=0
|
||||
|
||||
@@ -10,7 +10,7 @@ BO_ 550 BRAKE_MODULE: 8 XXX
|
||||
SG_ BRAKE_PRESSED : 37|1@0+ (1,0) [0|1] "" XXX
|
||||
|
||||
BO_ 608 STEER_TORQUE_SENSOR: 8 XXX
|
||||
SG_ STEER_TORQUE_EPS : 47|16@0- (0.66,0) [-20000|20000] "" XXX
|
||||
SG_ STEER_TORQUE_EPS : 47|16@0- (1.0,0) [-20000|20000] "" XXX
|
||||
SG_ STEER_TORQUE_DRIVER : 15|16@0- (1,0) [-32768|32767] "" XXX
|
||||
SG_ STEER_OVERRIDE : 0|1@0+ (1,0) [0|1] "" XXX
|
||||
SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX
|
||||
|
||||
@@ -357,7 +357,7 @@ BO_ 550 BRAKE_MODULE: 8 XXX
|
||||
SG_ BRAKE_PRESSED : 37|1@0+ (1,0) [0|1] "" XXX
|
||||
|
||||
BO_ 608 STEER_TORQUE_SENSOR: 8 XXX
|
||||
SG_ STEER_TORQUE_EPS : 47|16@0- (0.66,0) [-20000|20000] "" XXX
|
||||
SG_ STEER_TORQUE_EPS : 47|16@0- (1.0,0) [-20000|20000] "" XXX
|
||||
SG_ STEER_TORQUE_DRIVER : 15|16@0- (1,0) [-32768|32767] "" XXX
|
||||
SG_ STEER_OVERRIDE : 0|1@0+ (1,0) [0|1] "" XXX
|
||||
SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX
|
||||
|
||||
@@ -59,7 +59,14 @@ FINGERPRINTS = {
|
||||
148: 8, 228: 5, 304: 8, 330: 8, 344: 8, 380: 8, 399: 7, 401: 8, 420: 8, 427: 3, 432: 7, 441: 5, 446: 3, 450: 8, 464: 8, 477: 8, 479: 8, 495: 8, 545: 6, 662: 4, 773: 7, 777: 8, 780: 8, 804: 8, 806: 8, 808: 8, 829: 5, 862: 8, 884: 8, 891: 8, 927: 8, 929: 8, 1302: 8, 1600: 5, 1601: 8, 1652: 8
|
||||
}],
|
||||
CAR.ACCORDH: [{
|
||||
148: 8, 228: 5, 304: 8, 330: 8, 344: 8, 380: 8, 387: 8, 388: 8, 399: 7, 419: 8, 420: 8, 427: 3, 432: 7, 441: 5, 450: 8, 464: 8, 477: 8, 479: 8, 495: 8, 525: 8, 545: 6, 662: 4, 773: 7, 777: 8, 780: 8, 804: 8, 806: 8, 808: 8, 829: 5, 862: 8, 884: 8, 891: 8, 927: 8, 929: 8, 1302: 8, 1600: 5, 1601: 8, 1652: 8
|
||||
},
|
||||
{
|
||||
148: 8, 228: 5, 304: 8, 330: 8, 344: 8, 380: 8, 387: 8, 388: 8, 399: 7, 419: 8, 420: 8, 427: 3, 432: 7, 441: 5, 450: 8, 464: 8, 477: 8, 479: 8, 495: 8, 525: 8, 545: 6, 662: 4, 773: 7, 777: 8, 780: 8, 804: 8, 806: 8, 808: 8, 829: 5, 862: 8, 884: 8, 891: 8, 927: 8, 929: 8, 1302: 8, 1416: 5, 1600: 5, 1601: 8, 1652: 8
|
||||
},
|
||||
{
|
||||
# Honda Inspire Hybrid
|
||||
148: 8, 228: 5, 304: 8, 330: 8, 344: 8, 380: 8, 387: 8, 388: 8, 399: 7, 408: 6, 419: 8, 420: 8, 427: 3, 432: 7, 441: 5, 450: 8, 464: 8, 475: 8, 477: 8, 479: 8, 481: 8, 495: 8, 525: 8, 545: 6, 662: 4, 773: 7, 777: 8, 780: 8, 804: 8, 806: 8, 808: 8, 829: 5, 862: 8, 884: 8, 891: 8, 927: 8, 929: 8, 1302: 8, 1416: 5, 1600: 5, 1601: 8, 1652: 8
|
||||
}],
|
||||
CAR.ACURA_ILX: [{
|
||||
57: 3, 145: 8, 228: 5, 304: 8, 316: 8, 342: 6, 344: 8, 380: 8, 398: 3, 399: 7, 419: 8, 420: 8, 422: 8, 428: 8, 432: 7, 464: 8, 476: 4, 490: 8, 506: 8, 512: 6, 513: 6, 542: 7, 545: 4, 597: 8, 660: 8, 773: 7, 777: 8, 780: 8, 800: 8, 804: 8, 808: 8, 819: 7, 821: 5, 829: 5, 882: 2, 884: 7, 887: 8, 888: 8, 892: 8, 923: 2, 929: 4, 983: 8, 985: 3, 1024: 5, 1027: 5, 1029: 8, 1030: 5, 1034: 5, 1036: 8, 1039: 8, 1057: 5, 1064: 7, 1108: 8, 1365: 5,
|
||||
|
||||
@@ -41,25 +41,17 @@ def get_can_parser(CP):
|
||||
("STEER_RATE", "STEER_ANGLE_SENSOR", 0),
|
||||
("CRUISE_ACTIVE", "PCM_CRUISE", 0),
|
||||
("CRUISE_STATE", "PCM_CRUISE", 0),
|
||||
("MAIN_ON", "PCM_CRUISE_2", 0),
|
||||
("SET_SPEED", "PCM_CRUISE_2", 0),
|
||||
("LOW_SPEED_LOCKOUT", "PCM_CRUISE_2", 0),
|
||||
("STEER_TORQUE_DRIVER", "STEER_TORQUE_SENSOR", 0),
|
||||
("STEER_TORQUE_EPS", "STEER_TORQUE_SENSOR", 0),
|
||||
("TURN_SIGNALS", "STEERING_LEVERS", 3), # 3 is no blinkers
|
||||
("LKA_STATE", "EPS_STATUS", 0),
|
||||
("IPAS_STATE", "EPS_STATUS", 1),
|
||||
("BRAKE_LIGHTS_ACC", "ESP_CONTROL", 0),
|
||||
("AUTO_HIGH_BEAM", "LIGHT_STALK", 0),
|
||||
]
|
||||
|
||||
checks = [
|
||||
("BRAKE_MODULE", 40),
|
||||
("GAS_PEDAL", 33),
|
||||
("WHEEL_SPEEDS", 80),
|
||||
("STEER_ANGLE_SENSOR", 80),
|
||||
("PCM_CRUISE", 33),
|
||||
("PCM_CRUISE_2", 33),
|
||||
("STEER_TORQUE_SENSOR", 50),
|
||||
("EPS_STATUS", 25),
|
||||
]
|
||||
@@ -67,6 +59,32 @@ def get_can_parser(CP):
|
||||
if CP.carFingerprint in NO_DSU_CAR:
|
||||
signals += [("STEER_ANGLE", "STEER_TORQUE_SENSOR", 0)]
|
||||
|
||||
if CP.carFingerprint == CAR.LEXUS_ISH:
|
||||
checks += [
|
||||
("BRAKE_MODULE", 50),
|
||||
("GAS_PEDAL", 50),
|
||||
("PCM_CRUISE_ISH", 1),
|
||||
]
|
||||
|
||||
signals += [
|
||||
("MAIN_ON", "PCM_CRUISE_ISH", 0),
|
||||
("SET_SPEED", "PCM_CRUISE_ISH", 0),
|
||||
("AUTO_HIGH_BEAM", "LIGHT_STALK_ISH", 0),
|
||||
]
|
||||
else:
|
||||
checks += [
|
||||
("BRAKE_MODULE", 40),
|
||||
("GAS_PEDAL", 33),
|
||||
("PCM_CRUISE_2", 33),
|
||||
]
|
||||
signals += [
|
||||
("MAIN_ON", "PCM_CRUISE_2", 0),
|
||||
("SET_SPEED", "PCM_CRUISE_2", 0),
|
||||
("LOW_SPEED_LOCKOUT", "PCM_CRUISE_2", 0),
|
||||
("IPAS_STATE", "EPS_STATUS", 1),
|
||||
("AUTO_HIGH_BEAM", "LIGHT_STALK", 0),
|
||||
]
|
||||
|
||||
if CP.carFingerprint == CAR.PRIUS:
|
||||
signals += [("STATE", "AUTOPARK_STATUS", 0)]
|
||||
|
||||
@@ -171,14 +189,20 @@ class CarState(object):
|
||||
self.angle_steers_rate = cp.vl["STEER_ANGLE_SENSOR"]['STEER_RATE']
|
||||
can_gear = int(cp.vl["GEAR_PACKET"]['GEAR'])
|
||||
self.gear_shifter = parse_gear_shifter(can_gear, self.shifter_values)
|
||||
self.main_on = cp.vl["PCM_CRUISE_2"]['MAIN_ON']
|
||||
if self.CP.carFingerprint == CAR.LEXUS_ISH:
|
||||
self.main_on = cp.vl["PCM_CRUISE_ISH"]['MAIN_ON']
|
||||
else:
|
||||
self.main_on = cp.vl["PCM_CRUISE_2"]['MAIN_ON']
|
||||
self.left_blinker_on = cp.vl["STEERING_LEVERS"]['TURN_SIGNALS'] == 1
|
||||
self.right_blinker_on = cp.vl["STEERING_LEVERS"]['TURN_SIGNALS'] == 2
|
||||
|
||||
# 2 is standby, 10 is active. TODO: check that everything else is really a faulty state
|
||||
self.steer_state = cp.vl["EPS_STATUS"]['LKA_STATE']
|
||||
self.steer_error = cp.vl["EPS_STATUS"]['LKA_STATE'] not in [1, 5]
|
||||
self.ipas_active = cp.vl['EPS_STATUS']['IPAS_STATE'] == 3
|
||||
if self.CP.carFingerprint == CAR.LEXUS_ISH:
|
||||
self.ipas_active = False
|
||||
else:
|
||||
self.ipas_active = cp.vl['EPS_STATUS']['IPAS_STATE'] == 3
|
||||
self.brake_error = 0
|
||||
self.steer_torque_driver = cp.vl["STEER_TORQUE_SENSOR"]['STEER_TORQUE_DRIVER']
|
||||
self.steer_torque_motor = cp.vl["STEER_TORQUE_SENSOR"]['STEER_TORQUE_EPS']
|
||||
@@ -186,13 +210,21 @@ class CarState(object):
|
||||
self.steer_override = abs(self.steer_torque_driver) > STEER_THRESHOLD
|
||||
|
||||
self.user_brake = 0
|
||||
self.v_cruise_pcm = cp.vl["PCM_CRUISE_2"]['SET_SPEED']
|
||||
self.pcm_acc_status = cp.vl["PCM_CRUISE"]['CRUISE_STATE']
|
||||
if self.CP.carFingerprint == CAR.LEXUS_ISH:
|
||||
self.v_cruise_pcm = cp.vl["PCM_CRUISE_ISH"]['SET_SPEED']
|
||||
# ish does not have curise status value (always 0), so we use curise_active value instead
|
||||
self.pcm_acc_status = cp.vl["PCM_CRUISE"]['CRUISE_ACTIVE']
|
||||
self.low_speed_lockout = False
|
||||
else:
|
||||
self.v_cruise_pcm = cp.vl["PCM_CRUISE_2"]['SET_SPEED']
|
||||
self.pcm_acc_status = cp.vl["PCM_CRUISE"]['CRUISE_STATE']
|
||||
self.low_speed_lockout = cp.vl["PCM_CRUISE_2"]['LOW_SPEED_LOCKOUT'] == 2
|
||||
self.pcm_acc_active = bool(cp.vl["PCM_CRUISE"]['CRUISE_ACTIVE'])
|
||||
self.low_speed_lockout = cp.vl["PCM_CRUISE_2"]['LOW_SPEED_LOCKOUT'] == 2
|
||||
self.brake_lights = bool(cp.vl["ESP_CONTROL"]['BRAKE_LIGHTS_ACC'] or self.brake_pressed)
|
||||
if self.CP.carFingerprint == CAR.PRIUS:
|
||||
self.generic_toggle = cp.vl["AUTOPARK_STATUS"]['STATE'] != 0
|
||||
elif self.CP.carFingerprint == CAR.LEXUS_ISH:
|
||||
self.generic_toggle = bool(cp.vl["LIGHT_STALK_ISH"]['AUTO_HIGH_BEAM'])
|
||||
else:
|
||||
self.generic_toggle = bool(cp.vl["LIGHT_STALK"]['AUTO_HIGH_BEAM'])
|
||||
|
||||
|
||||
@@ -215,6 +215,16 @@ class CarInterface(object):
|
||||
ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.3], [0.05]]
|
||||
ret.lateralTuning.pid.kf = 0.00007818594
|
||||
|
||||
elif candidate == CAR.LEXUS_ISH:
|
||||
stop_and_go = True
|
||||
ret.safetyParam = 100
|
||||
ret.wheelbase = 2.80 # in spec
|
||||
ret.steerRatio = 13.3 # in spec
|
||||
tire_stiffness_factor = 0.444 # from camry
|
||||
ret.mass = 3736.8 * CV.LB_TO_KG + STD_CARGO_KG # in spec, mean of is300 (1680 kg) / is300h (1720 kg) / is350 (1685 kg)
|
||||
ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.19], [0.04]]
|
||||
ret.lateralTuning.pid.kf = 0.00006 # from camry
|
||||
|
||||
ret.steerRateCost = 1.
|
||||
ret.centerToFront = ret.wheelbase * 0.44
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ class CAR:
|
||||
COROLLA_TSS2 = "TOYOTA COROLLA TSS2 2019"
|
||||
LEXUS_ESH_TSS2 = "LEXUS ES 300H 2019"
|
||||
SIENNA = "TOYOTA SIENNA XLE 2018"
|
||||
|
||||
LEXUS_ISH = "LEXUS IS HYBRID 2017"
|
||||
|
||||
class ECU:
|
||||
CAM = 0 # camera
|
||||
@@ -28,19 +28,25 @@ class ECU:
|
||||
# addr: (ecu, cars, bus, 1/freq*100, vl)
|
||||
STATIC_MSGS = [
|
||||
(0x130, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON), 1, 100, '\x00\x00\x00\x00\x00\x00\x38'),
|
||||
(0x240, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON), 1, 5, '\x00\x10\x01\x00\x10\x01\x00'),
|
||||
(0x241, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON), 1, 5, '\x00\x10\x01\x00\x10\x01\x00'),
|
||||
(0x244, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON), 1, 5, '\x00\x10\x01\x00\x10\x01\x00'),
|
||||
(0x130, ECU.CAM, (CAR.LEXUS_ISH), 1, 100, '\x00\x00\x03\xff\x00\x00\x3a'),
|
||||
(0x240, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON, CAR.LEXUS_ISH), 1, 5, '\x00\x10\x01\x00\x10\x01\x00'),
|
||||
(0x241, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON, CAR.LEXUS_ISH), 1, 5, '\x00\x10\x01\x00\x10\x01\x00'),
|
||||
(0x244, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON, CAR.LEXUS_ISH), 1, 5, '\x00\x10\x01\x00\x10\x01\x00'),
|
||||
(0x245, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON), 1, 5, '\x00\x10\x01\x00\x10\x01\x00'),
|
||||
(0x245, ECU.CAM, (CAR.LEXUS_ISH), 1, 5, '\x00\x10\x01\x00'),
|
||||
(0x248, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON), 1, 5, '\x00\x00\x00\x00\x00\x00\x01'),
|
||||
(0x248, ECU.CAM, (CAR.LEXUS_ISH), 1, 5, '\x00\x01\x00\x00\x00\x00\x00'),
|
||||
(0x367, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON), 0, 40, '\x06\x00'),
|
||||
(0x414, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON), 0, 100, '\x00\x00\x00\x00\x00\x00\x17\x00'),
|
||||
(0x367, ECU.CAM, (CAR.LEXUS_ISH), 0, 40, '\x02\x00'),
|
||||
(0x414, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON, CAR.LEXUS_ISH), 0, 100, '\x00\x00\x00\x00\x00\x00\x17\x00'),
|
||||
(0x466, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.HIGHLANDER, CAR.HIGHLANDERH), 1, 100, '\x20\x20\xAD'),
|
||||
(0x466, ECU.CAM, (CAR.COROLLA, CAR.AVALON), 1, 100, '\x24\x20\xB1'),
|
||||
(0x489, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON), 0, 100, '\x00\x00\x00\x00\x00\x00\x00'),
|
||||
(0x48a, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON), 0, 100, '\x00\x00\x00\x00\x00\x00\x00'),
|
||||
(0x466, ECU.CAM, (CAR.LEXUS_ISH), 1, 100, '\x41\x20\xce'),
|
||||
(0x489, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON, CAR.LEXUS_ISH), 0, 100, '\x00\x00\x00\x00\x00\x00\x00'),
|
||||
(0x48a, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON, CAR.LEXUS_ISH), 0, 100, '\x00\x00\x00\x00\x00\x00\x00'),
|
||||
(0x48b, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.AVALON), 0, 100, '\x66\x06\x08\x0a\x02\x00\x00\x00'),
|
||||
(0x4d3, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.AVALON), 0, 100, '\x1C\x00\x00\x01\x00\x00\x00\x00'),
|
||||
(0x48b, ECU.CAM, (CAR.LEXUS_ISH), 0, 100, '\x66\x07\x0a\x0f\x01\x00\x00\x00'),
|
||||
(0x4d3, ECU.CAM, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.AVALON, CAR.LEXUS_ISH), 0, 100, '\x1C\x00\x00\x01\x00\x00\x00\x00'),
|
||||
|
||||
(0x128, ECU.DSU, (CAR.PRIUS, CAR.RAV4H, CAR.LEXUS_RXH, CAR.RAV4, CAR.COROLLA, CAR.AVALON), 1, 3, '\xf4\x01\x90\x83\x00\x37'),
|
||||
(0x128, ECU.DSU, (CAR.HIGHLANDER, CAR.HIGHLANDERH, CAR.SIENNA), 1, 3, '\x03\x00\x20\x00\x00\x52'),
|
||||
@@ -83,6 +89,9 @@ def check_ecu_msgs(fingerprint, ecu):
|
||||
|
||||
|
||||
FINGERPRINTS = {
|
||||
CAR.LEXUS_ISH: [{
|
||||
36: 8, 37: 8, 170: 8, 180: 8, 295: 8, 296: 8, 400: 6, 426: 6, 452: 8, 466: 8, 467: 8, 550: 8, 552: 4, 560: 7, 581: 5, 608: 8, 610: 5, 643: 7, 713: 8, 740: 5, 800: 8, 836: 8, 845: 5, 849: 4, 869: 7, 870: 7, 871: 2, 896: 8, 897: 8, 900: 6, 902: 6, 905: 8, 911: 8, 913: 8, 916: 3, 918: 7, 921: 7, 933: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 3, 955: 8, 956: 8, 979: 2, 992: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1009: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1043: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1112: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1168: 1, 1176: 8, 1177: 8, 1178: 8, 1179: 8, 1180: 8, 1181: 8, 1184: 8, 1185: 8, 1186: 8, 1187: 8, 1189: 8, 1190: 8, 1191: 8, 1192: 8, 1196: 8, 1197: 8, 1198: 8, 1199: 8, 1206: 8, 1208: 8, 1212: 8, 1227: 8, 1232: 8, 1235: 8, 1279: 8, 1408: 8, 1409: 8, 1410: 8, 1552: 8, 1553: 8, 1554: 8, 1555: 8, 1556: 8, 1557: 8, 1561: 8, 1568: 8, 1569: 8, 1570: 8, 1571: 8, 1572: 8, 1575: 8, 1584: 8, 1589: 8, 1592: 8, 1593: 8, 1595: 8, 1599: 8, 1728: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8
|
||||
}],
|
||||
CAR.RAV4: [{
|
||||
36: 8, 37: 8, 170: 8, 180: 8, 186: 4, 426: 6, 452: 8, 464: 8, 466: 8, 467: 8, 512: 6, 513: 6, 547: 8, 548: 8, 552: 4, 562: 4, 608: 8, 610: 5, 643: 7, 705: 8, 725: 2, 740: 5, 800: 8, 835: 8, 836: 8, 849: 4, 869: 7, 870: 7, 871: 2, 896: 8, 897: 8, 900: 6, 902: 6, 905: 8, 911: 8, 916: 3, 918: 7, 921: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 4, 956: 8, 979: 2, 998: 5, 999: 7, 1000: 8, 1001: 8, 1005: 2, 1008: 2, 1014: 8, 1017: 8, 1041: 8, 1042: 8, 1043: 8, 1044: 8, 1056: 8, 1059: 1, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1176: 8, 1177: 8, 1178: 8, 1179: 8, 1180: 8, 1181: 8, 1190: 8, 1191: 8, 1192: 8, 1196: 8, 1227: 8, 1228: 8, 1235: 8, 1237: 8, 1263: 8, 1264: 8, 1279: 8, 1408: 8, 1409: 8, 1410: 8, 1552: 8, 1553: 8, 1554: 8, 1555: 8, 1556: 8, 1557: 8, 1561: 8, 1562: 8, 1568: 8, 1569: 8, 1570: 8, 1571: 8, 1572: 8, 1584: 8, 1589: 8, 1592: 8, 1593: 8, 1595: 8, 1596: 8, 1597: 8, 1600: 8, 1656: 8, 1664: 8, 1728: 8, 1745: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8, 2015: 8, 2024: 8
|
||||
}],
|
||||
@@ -169,11 +178,22 @@ FINGERPRINTS = {
|
||||
# XLE, Limited, and AWD
|
||||
{
|
||||
36: 8, 37: 8, 170: 8, 180: 8, 186: 4, 401: 8, 426: 6, 452: 8, 464: 8, 466: 8, 467: 8, 544: 4, 550: 8, 552: 4, 562: 6, 565: 8, 608: 8, 610: 8, 643: 7, 658: 8, 705: 8, 728: 8, 740: 5, 742: 8, 743: 8, 761: 8, 764: 8, 765: 8, 800: 8, 810: 2, 812: 8, 814: 8, 818: 8, 822: 8, 824: 8, 829: 2, 830: 7, 835: 8, 836: 8, 865: 8, 869: 7, 870: 7, 871: 2, 877: 8, 881: 8, 882: 8, 885: 8, 889: 8, 891: 8, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 918: 8, 921: 8, 933: 8, 934: 8, 935: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 976: 1, 987: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1002: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1059: 1, 1063: 8, 1076: 8, 1077: 8, 1082: 8, 1084: 8, 1085: 8, 1086: 8, 1114: 8, 1132: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1172: 8, 1228: 8, 1235: 8, 1237: 8, 1263: 8, 1264: 8, 1279: 8, 1541: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1592: 8, 1594: 8, 1595: 8, 1649: 8, 1696: 8, 1745: 8, 1775: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8, 2015: 8, 2016: 8, 2024: 8
|
||||
}],
|
||||
CAR.COROLLA_TSS2: [
|
||||
# hatch 2019+ and sedan 2020+
|
||||
},
|
||||
# Taiwan 2019 RAV4H from Max Duan
|
||||
{
|
||||
36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 8, 401: 8, 426: 6, 452: 8, 466: 8, 467: 8, 550: 8, 552: 4, 560: 7, 562: 6, 581: 5, 608: 8, 610: 8, 643: 7, 713: 8, 728: 8, 740: 5, 742: 8, 743: 8, 761: 8, 765: 8, 800: 8, 810: 2, 812: 8, 829: 2, 830: 7, 835: 8, 836: 8, 863: 8, 865: 8, 869: 7, 870: 7, 871: 2, 877: 8, 881: 8, 882: 8, 885: 8, 896: 8, 898: 8, 913: 8, 921: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 975: 5, 993: 8, 1002: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1063: 8, 1071: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1172: 8, 1235: 8, 1237: 8, 1279: 8, 1541: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1592: 8, 1594: 8, 1595: 8, 1696: 8, 1745: 8, 1775: 8, 1779: 8
|
||||
}],
|
||||
CAR.COROLLA_TSS2: [{
|
||||
# hatch 2019+ and sedan 2020+
|
||||
36: 8, 37: 8, 114: 5, 170: 8, 180: 8, 186: 4, 401: 8, 426: 6, 452: 8, 464: 8, 466: 8, 467: 8, 544: 4, 550: 8, 552: 4, 562: 6, 608: 8, 610: 8, 643: 7, 705: 8, 728: 8, 740: 5, 742: 8, 743: 8, 761: 8, 764: 8, 765: 8, 800: 8, 810: 2, 812: 8, 824: 8, 829: 2, 830: 7, 835: 8, 836: 8, 865: 8, 869: 7, 870: 7, 871: 2, 877: 8, 881: 8, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 921: 8, 933: 8, 934: 8, 935: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 976: 1, 998: 5, 999: 7, 1000: 8, 1001: 8, 1002: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1059: 1, 1076: 8, 1077: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1172: 8, 1235: 8, 1237: 8, 1279: 8, 1541: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1592: 8, 1595: 8, 1649: 8, 1745: 8, 1775: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8, 1808: 8, 1809: 8, 1816: 8, 1817: 8, 1840: 8, 1848: 8, 1904: 8, 1912: 8, 1940: 8, 1941: 8, 1948: 8, 1949: 8, 1952: 8, 1960: 8, 1981: 8, 1986: 8, 1990: 8, 1994: 8, 1998: 8, 2004: 8
|
||||
},
|
||||
{
|
||||
# 2019 Taiwan Altis
|
||||
36: 8, 37: 8, 170: 8, 180: 8, 186: 4, 401: 8, 426: 6, 452: 8, 464: 8, 466: 8, 467: 8, 544: 4, 550: 8, 552: 4, 562: 6, 608: 8, 610: 8, 643: 7, 705: 8, 728: 8, 740: 5, 742: 8, 743: 8, 761: 8, 765: 8, 800: 8, 830: 7, 835: 8, 836: 8, 865: 8, 869: 7, 870: 7, 871: 2, 877: 8, 881: 8, 885: 8, 896: 8, 898: 8, 918: 7, 921: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 976: 1, 987: 8, 1002: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1059: 1, 1082: 8, 1112: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1172: 8, 1235: 8, 1279: 8, 1541: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1592: 8, 1594: 8, 1595: 8, 1745: 8, 1775: 8, 1779: 8
|
||||
},
|
||||
{
|
||||
# 2019 Taiwan Altis Hybrid (?)
|
||||
36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 8, 401: 8, 426: 6, 452: 8, 466: 8, 467: 8, 550: 8, 552: 4, 560: 7, 562: 6, 581: 5, 608: 8, 610: 8, 643: 7, 713: 8, 728: 8, 740: 5, 742: 8, 743: 8, 761: 8, 765: 8, 800: 8, 810: 2, 829: 2, 830: 7, 835: 8, 836: 8, 865: 8, 869: 7, 870: 7, 871: 2, 877: 8, 881: 8, 885: 8, 896: 8, 898: 8, 918: 7, 921: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 975: 5, 987: 8, 993: 8, 1002: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1071: 8, 1082: 8, 1112: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1172: 8, 1235: 8, 1237: 8, 1279: 8, 1541: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1592: 8, 1594: 8, 1595: 8, 1745: 8, 1775: 8, 1779: 8
|
||||
}],
|
||||
CAR.LEXUS_ESH_TSS2: [
|
||||
{
|
||||
@@ -201,10 +221,11 @@ DBC = {
|
||||
CAR.AVALON: dbc_dict('toyota_avalon_2017_pt_generated', 'toyota_adas'),
|
||||
CAR.RAV4_TSS2: dbc_dict('toyota_nodsu_pt_generated', 'toyota_tss2_adas'),
|
||||
CAR.COROLLA_TSS2: dbc_dict('toyota_nodsu_pt_generated', 'toyota_tss2_adas'),
|
||||
CAR.LEXUS_ESH_TSS2: dbc_dict('toyota_nodsu_pt_generated', 'toyota_tss2_adas'),
|
||||
CAR.LEXUS_ESH_TSS2: dbc_dict('toyota_nodsu_hybrid_pt_generated', 'toyota_tss2_adas'),
|
||||
CAR.SIENNA: dbc_dict('toyota_sienna_xle_2018_pt_generated', 'toyota_adas'),
|
||||
CAR.LEXUS_ISH: dbc_dict('lexus_is_hybrid_2017_pt_generated', 'toyota_adas'),
|
||||
}
|
||||
|
||||
NO_DSU_CAR = [CAR.CHR, CAR.CHRH, CAR.CAMRY, CAR.CAMRYH, CAR.RAV4_TSS2, CAR.COROLLA_TSS2, CAR.LEXUS_ESH_TSS2]
|
||||
TSS2_CAR = [CAR.RAV4_TSS2, CAR.COROLLA_TSS2, CAR.LEXUS_ESH_TSS2]
|
||||
NO_STOP_TIMER_CAR = [CAR.RAV4H, CAR.HIGHLANDERH, CAR.HIGHLANDER, CAR.RAV4_TSS2, CAR.COROLLA_TSS2, CAR.LEXUS_ESH_TSS2, CAR.SIENNA] # no resume button press required
|
||||
NO_STOP_TIMER_CAR = [CAR.RAV4H, CAR.HIGHLANDERH, CAR.HIGHLANDER, CAR.RAV4_TSS2, CAR.COROLLA_TSS2, CAR.LEXUS_ESH_TSS2, CAR.SIENNA, CAR.LEXUS_ISH] # no resume button press required
|
||||
|
||||
+163
-163
@@ -77,148 +77,148 @@ ALERTS = [
|
||||
|
||||
Alert(
|
||||
"fcw",
|
||||
"BRAKE!",
|
||||
"Risk of Collision",
|
||||
"剎車!",
|
||||
"有碰撞的風險",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGHEST, VisualAlert.fcw, AudibleAlert.chimeWarningRepeat, 1., 2., 2.),
|
||||
|
||||
Alert(
|
||||
"steerSaturated",
|
||||
"TAKE CONTROL",
|
||||
"Turn Exceeds Steering Limit",
|
||||
"接管控制",
|
||||
"彎道超過方向盤轉向限制",
|
||||
AlertStatus.userPrompt, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.steerRequired, AudibleAlert.chimePrompt, 1., 2., 3.),
|
||||
|
||||
Alert(
|
||||
"steerTempUnavailable",
|
||||
"TAKE CONTROL",
|
||||
"Steering Temporarily Unavailable",
|
||||
"接管控制",
|
||||
"轉向控制暫時失效",
|
||||
AlertStatus.userPrompt, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.steerRequired, AudibleAlert.chimeWarning1, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"steerTempUnavailableMute",
|
||||
"TAKE CONTROL",
|
||||
"Steering Temporarily Unavailable",
|
||||
"接管控制",
|
||||
"轉向控制暫時失效",
|
||||
AlertStatus.userPrompt, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.none, .2, .2, .2),
|
||||
|
||||
Alert(
|
||||
"preDriverDistracted",
|
||||
"KEEP EYES ON ROAD: User Appears Distracted",
|
||||
"注意路況:駕駛分心",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.small,
|
||||
Priority.LOW, VisualAlert.steerRequired, AudibleAlert.none, .0, .1, .1, alert_rate=0.75),
|
||||
|
||||
Alert(
|
||||
"promptDriverDistracted",
|
||||
"KEEP EYES ON ROAD",
|
||||
"User Appears Distracted",
|
||||
"注意路況",
|
||||
"駕駛分心",
|
||||
AlertStatus.userPrompt, AlertSize.mid,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarning2, .1, .1, .1),
|
||||
|
||||
Alert(
|
||||
"driverDistracted",
|
||||
"DISENGAGE IMMEDIATELY",
|
||||
"User Was Distracted",
|
||||
"立即解除",
|
||||
"駕駛分心",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGH, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, .1, .1),
|
||||
|
||||
Alert(
|
||||
"preDriverUnresponsive",
|
||||
"TOUCH STEERING WHEEL: No Driver Monitoring",
|
||||
"請觸碰方向盤:無駕駛監控",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.small,
|
||||
Priority.LOW, VisualAlert.steerRequired, AudibleAlert.none, .0, .1, .1, alert_rate=0.75),
|
||||
|
||||
Alert(
|
||||
"promptDriverUnresponsive",
|
||||
"TOUCH STEERING WHEEL",
|
||||
"User Is Unresponsive",
|
||||
"觸碰方向盤",
|
||||
"駕駛沒有反應",
|
||||
AlertStatus.userPrompt, AlertSize.mid,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarning2, .1, .1, .1),
|
||||
|
||||
Alert(
|
||||
"driverUnresponsive",
|
||||
"DISENGAGE IMMEDIATELY",
|
||||
"User Was Unresponsive",
|
||||
"立即解除",
|
||||
"駕駛沒有反應",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGH, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, .1, .1),
|
||||
|
||||
Alert(
|
||||
"driverMonitorOff",
|
||||
"DRIVER MONITOR IS UNAVAILABLE",
|
||||
"Accuracy Is Low",
|
||||
"駕駛監控暫時停用",
|
||||
"監控準確率:低",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.none, .4, 0., 4.),
|
||||
|
||||
Alert(
|
||||
"driverMonitorOn",
|
||||
"DRIVER MONITOR IS AVAILABLE",
|
||||
"Accuracy Is High",
|
||||
"駕駛監控已啟用",
|
||||
"監控準確率:高",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.none, .4, 0., 4.),
|
||||
|
||||
Alert(
|
||||
"geofence",
|
||||
"DISENGAGEMENT REQUIRED",
|
||||
"Not in Geofenced Area",
|
||||
"不在地理圍欄區域之內",
|
||||
AlertStatus.userPrompt, AlertSize.mid,
|
||||
Priority.HIGH, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, .1, .1),
|
||||
|
||||
Alert(
|
||||
"startup",
|
||||
"Be ready to take over at any time",
|
||||
"Always keep hands on wheel and eyes on road",
|
||||
"隨時準備好接管",
|
||||
"請您將手放在方向盤上並持續注意路況",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW_LOWEST, VisualAlert.none, AudibleAlert.none, 0., 0., 15.),
|
||||
|
||||
Alert(
|
||||
"startupNoControl",
|
||||
"Dashcam mode",
|
||||
"Always keep hands on wheel and eyes on road",
|
||||
"行車記錄模式",
|
||||
"請您將手放在方向盤上並持續注意路況",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW_LOWEST, VisualAlert.none, AudibleAlert.none, 0., 0., 15.),
|
||||
|
||||
Alert(
|
||||
"startupNoCar",
|
||||
"Dashcam mode with unsupported car",
|
||||
"Always keep hands on wheel and eyes on road",
|
||||
"行車記錄模式 (尚未支援車種)",
|
||||
"請您將手放在方向盤上並持續注意路況",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW_LOWEST, VisualAlert.none, AudibleAlert.none, 0., 0., 15.),
|
||||
|
||||
Alert(
|
||||
"ethicalDilemma",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"即刻接管控制",
|
||||
"Ethical Dilemma Detected",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGHEST, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, 1., 3., 3.),
|
||||
|
||||
Alert(
|
||||
"steerTempUnavailableNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Steering Temporarily Unavailable",
|
||||
"無法使用 openpilot",
|
||||
"轉向控制暫時失效",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 0., 3.),
|
||||
|
||||
Alert(
|
||||
"manualRestart",
|
||||
"TAKE CONTROL",
|
||||
"Resume Driving Manually",
|
||||
"接管控制",
|
||||
"請自行恢復駕駛",
|
||||
AlertStatus.userPrompt, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.none, 0., 0., .2),
|
||||
|
||||
Alert(
|
||||
"resumeRequired",
|
||||
"STOPPED",
|
||||
"Press Resume to Move",
|
||||
"已停止",
|
||||
"請按 RES 繼續",
|
||||
AlertStatus.userPrompt, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.none, 0., 0., .2),
|
||||
|
||||
Alert(
|
||||
"belowSteerSpeed",
|
||||
"TAKE CONTROL",
|
||||
"Steer Unavailable Below ",
|
||||
"接管控制",
|
||||
"轉向控制暫時失效,車速低於 ",
|
||||
AlertStatus.userPrompt, AlertSize.mid,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarning1, 0., 0., .1),
|
||||
|
||||
@@ -232,71 +232,71 @@ ALERTS = [
|
||||
# Non-entry only alerts
|
||||
Alert(
|
||||
"wrongCarModeNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Main Switch Off",
|
||||
"無法使用 dragonpilot",
|
||||
"主開關關閉",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 0., 3.),
|
||||
|
||||
Alert(
|
||||
"dataNeededNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Data Needed for Calibration. Upload Drive, Try Again",
|
||||
"無法使用 dragonpilot",
|
||||
"需要更多的數據來協助校準,請將行車記錄上傳後再試",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 0., 3.),
|
||||
|
||||
Alert(
|
||||
"outOfSpaceNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Out of Storage Space",
|
||||
"無法使用 dragonpilot",
|
||||
"儲存空間不足",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 0., 3.),
|
||||
|
||||
Alert(
|
||||
"pedalPressedNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"無法使用 dragonpilot",
|
||||
"Pedal Pressed During Attempt",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, "brakePressed", AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"speedTooLowNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Speed Too Low",
|
||||
"無法使用 dragonpilot",
|
||||
"車速過慢",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"brakeHoldNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Brake Hold Active",
|
||||
"無法使用 dragonpilot",
|
||||
"駐車煞車已啟用",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"parkBrakeNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Park Brake Engaged",
|
||||
"無法使用 dragonpilot",
|
||||
"電子駐車已啟動",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"lowSpeedLockoutNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Cruise Fault: Restart the Car",
|
||||
"無法使用 dragonpilot",
|
||||
"巡航系統錯誤:請重新發動車子",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"lowBatteryNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Low Battery",
|
||||
"無法使用 dragonpilot",
|
||||
"電池電量過低",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"sensorDataInvalidNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"No Data from EON Sensors",
|
||||
"無法使用 dragonpilot",
|
||||
"沒有收到任何來自 EON 傳感器的資料",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
@@ -309,377 +309,377 @@ ALERTS = [
|
||||
|
||||
Alert(
|
||||
"tooDistractedNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Distraction Level Too High",
|
||||
"無法使用 dragonpilot",
|
||||
"駕駛分心次數過高",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
# Cancellation alerts causing soft disabling
|
||||
Alert(
|
||||
"overheat",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"System Overheated",
|
||||
"即刻接管控制",
|
||||
"系統過熱",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.),
|
||||
|
||||
Alert(
|
||||
"wrongGear",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Gear not D",
|
||||
"即刻接管控制",
|
||||
"檔位不在 D 檔",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.),
|
||||
|
||||
Alert(
|
||||
"calibrationInvalid",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Calibration Invalid: Reposition EON and Recalibrate",
|
||||
"即刻接管控制",
|
||||
"校準無效:請將 EON 放於新的位置並重新校準",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.),
|
||||
|
||||
Alert(
|
||||
"calibrationIncomplete",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Calibration in Progress",
|
||||
"即刻接管控制",
|
||||
"正在校準相機中",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.),
|
||||
|
||||
Alert(
|
||||
"doorOpen",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Door Open",
|
||||
"即刻接管控制",
|
||||
"車門開啟",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.),
|
||||
|
||||
Alert(
|
||||
"seatbeltNotLatched",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Seatbelt Unlatched",
|
||||
"即刻接管控制",
|
||||
"安全帶未繫",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.),
|
||||
|
||||
Alert(
|
||||
"espDisabled",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"ESP Off",
|
||||
"即刻接管控制",
|
||||
"ESP 關閉",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.),
|
||||
|
||||
Alert(
|
||||
"lowBattery",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Low Battery",
|
||||
"即刻接管控制",
|
||||
"電池電量過低",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.),
|
||||
|
||||
Alert(
|
||||
"commIssue",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Communication Issue between Processes",
|
||||
"即刻接管控制",
|
||||
"雷達訊號錯誤:請重新發動車子",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.),
|
||||
|
||||
Alert(
|
||||
"radarCanError",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Radar Error: Restart the Car",
|
||||
"即刻接管控制",
|
||||
"雷達訊號錯誤:請重新發動車子",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.),
|
||||
|
||||
Alert(
|
||||
"radarFault",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Radar Error: Restart the Car",
|
||||
"即刻接管控制",
|
||||
"AI 模型錯誤:請檢查網路連線",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.),
|
||||
|
||||
Alert(
|
||||
"posenetInvalid",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Vision Failure: Check Camera View",
|
||||
"即刻接管控制",
|
||||
"視覺出現錯誤:請檢查相機",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.),
|
||||
|
||||
# Cancellation alerts causing immediate disabling
|
||||
Alert(
|
||||
"controlsFailed",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Controls Failed",
|
||||
"即刻接管控制",
|
||||
"控制發生錯誤",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGHEST, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, 1., 3., 4.),
|
||||
|
||||
Alert(
|
||||
"controlsMismatch",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Controls Mismatch",
|
||||
"即刻接管控制",
|
||||
"控制不匹配",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGHEST, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, 1., 3., 4.),
|
||||
|
||||
Alert(
|
||||
"canError",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"CAN Error: Check Connections",
|
||||
"即刻接管控制",
|
||||
"CAN 訊號錯誤:請檢查接線",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGHEST, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, 1., 3., 4.),
|
||||
|
||||
Alert(
|
||||
"steerUnavailable",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"LKAS Fault: Restart the Car",
|
||||
"即刻接管控制",
|
||||
"LKAS 錯誤:請重新發動車子",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGHEST, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, 1., 3., 4.),
|
||||
|
||||
Alert(
|
||||
"brakeUnavailable",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Cruise Fault: Restart the Car",
|
||||
"即刻接管控制",
|
||||
"巡航系統錯誤:請重新發動車子",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGHEST, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, 1., 3., 4.),
|
||||
|
||||
Alert(
|
||||
"gasUnavailable",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Gas Fault: Restart the Car",
|
||||
"即刻接管控制",
|
||||
"油門錯誤:請重新發動車子",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGHEST, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, 1., 3., 4.),
|
||||
|
||||
Alert(
|
||||
"reverseGear",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Reverse Gear",
|
||||
"即刻接管控制",
|
||||
"切換至倒車檔",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGHEST, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, 1., 3., 4.),
|
||||
|
||||
Alert(
|
||||
"cruiseDisabled",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Cruise Is Off",
|
||||
"即刻接管控制",
|
||||
"巡航系統關閉",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGHEST, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, 1., 3., 4.),
|
||||
|
||||
Alert(
|
||||
"plannerError",
|
||||
"TAKE CONTROL IMMEDIATELY",
|
||||
"Planner Solution Error",
|
||||
"即刻接管控制",
|
||||
"Planner Solution 錯誤",
|
||||
AlertStatus.critical, AlertSize.full,
|
||||
Priority.HIGHEST, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, 1., 3., 4.),
|
||||
|
||||
# not loud cancellations (user is in control)
|
||||
Alert(
|
||||
"noTarget",
|
||||
"openpilot Canceled",
|
||||
"No close lead car",
|
||||
"dragonpilot 已取消",
|
||||
"沒有偵測到前車",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.HIGH, VisualAlert.none, AudibleAlert.chimeDisengage, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"speedTooLow",
|
||||
"openpilot Canceled",
|
||||
"Speed too low",
|
||||
"dragonpilot 已取消",
|
||||
"車速過慢",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.HIGH, VisualAlert.none, AudibleAlert.chimeDisengage, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"invalidGiraffeHonda",
|
||||
"Invalid Giraffe Configuration",
|
||||
"Set 0111 for openpilot. 1011 for stock",
|
||||
"Giraffe 開關錯誤",
|
||||
"dragonpilot 模式為 0111,原廠模式為 1011",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.HIGH, VisualAlert.none, AudibleAlert.chimeDisengage, .4, 2., 3.),
|
||||
|
||||
# Cancellation alerts causing non-entry
|
||||
Alert(
|
||||
"overheatNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"System overheated",
|
||||
"無法使用 dragonpilot",
|
||||
"系統過熱",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"wrongGearNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Gear not D",
|
||||
"無法使用 dragonpilot",
|
||||
"車子不在 D 檔",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"calibrationInvalidNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Calibration Invalid: Reposition EON and Recalibrate",
|
||||
"無法使用 dragonpilot",
|
||||
"校準無效:請將 EON 放於新的位置並重新校準",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"calibrationIncompleteNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Calibration in Progress",
|
||||
"無法使用 dragonpilot",
|
||||
"正在校準相機中",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"doorOpenNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Door open",
|
||||
"無法使用 dragonpilot",
|
||||
"車門未關",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"seatbeltNotLatchedNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Seatbelt unlatched",
|
||||
"無法使用 dragonpilot",
|
||||
"安全帶未繫",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"espDisabledNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"ESP Off",
|
||||
"無法使用 dragonpilot",
|
||||
"ESP 關閉",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"geofenceNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Not in Geofenced Area",
|
||||
"無法使用 dragonpilot",
|
||||
"不在地理圍欄區域之內",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.MID, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"radarCanErrorNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Radar Error: Restart the Car",
|
||||
"無法使用 dragonpilot",
|
||||
"雷達訊號錯誤:請重新發動車子",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"radarFaultNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Radar Error: Restart the Car",
|
||||
"無法使用 dragonpilot",
|
||||
"雷達訊號錯誤:請重新發動車子",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"posenetInvalidNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Vision Failure: Check Camera View",
|
||||
"無法使用 dragonpilot",
|
||||
"視覺錯誤:請檢查相機",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"controlsFailedNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Controls Failed",
|
||||
"無法使用 dragonpilot",
|
||||
"控制發生錯誤",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"canErrorNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"CAN Error: Check Connections",
|
||||
"無法使用 dragonpilot",
|
||||
"CAN 訊號錯誤:請檢查接線",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"steerUnavailableNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"LKAS Fault: Restart the Car",
|
||||
"無法使用 dragonpilot",
|
||||
"LKAS 錯誤:請重新發動車子",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"brakeUnavailableNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Cruise Fault: Restart the Car",
|
||||
"無法使用 dragonpilot",
|
||||
"巡航系統錯誤:請重新發動車子",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"gasUnavailableNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Gas Error: Restart the Car",
|
||||
"無法使用 dragonpilot",
|
||||
"油門錯誤:請重新發動車子",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"reverseGearNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Reverse Gear",
|
||||
"無法使用 dragonpilot",
|
||||
"切換至倒車檔",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"cruiseDisabledNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Cruise is Off",
|
||||
"無法使用 dragonpilot",
|
||||
"巡航系統關閉",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"noTargetNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"No Close Lead Car",
|
||||
"無法使用 dragonpilot",
|
||||
"沒有偵測到前車",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"plannerErrorNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Planner Solution Error",
|
||||
"無法使用 dragonpilot",
|
||||
"Planner Solution 錯誤",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"invalidGiraffeHondaNoEntry",
|
||||
"openpilot Unavailable",
|
||||
"Set 0111 for openpilot. 1011 for stock",
|
||||
"無法使用 dragonpilot",
|
||||
"penpilot 模式為 0111,原廠模式為 1011",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeDisengage, .4, 2., 3.),
|
||||
|
||||
Alert(
|
||||
"commIssueNoEntry",
|
||||
"openpilot unavailable",
|
||||
"Communication Issue between Processes",
|
||||
"無法使用 dragonpilot",
|
||||
"程序間出現通訊問題",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.chimeDisengage, .4, 2., 3.),
|
||||
|
||||
# permanent alerts
|
||||
Alert(
|
||||
"steerUnavailablePermanent",
|
||||
"LKAS Fault: Restart the car to engage",
|
||||
"LKAS 錯誤:請重新發動車子",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.small,
|
||||
Priority.LOW_LOWEST, VisualAlert.none, AudibleAlert.none, 0., 0., .2),
|
||||
|
||||
Alert(
|
||||
"brakeUnavailablePermanent",
|
||||
"Cruise Fault: Restart the car to engage",
|
||||
"巡航系統錯誤:請重新發動車子",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.small,
|
||||
Priority.LOW_LOWEST, VisualAlert.none, AudibleAlert.none, 0., 0., .2),
|
||||
|
||||
Alert(
|
||||
"lowSpeedLockoutPermanent",
|
||||
"Cruise Fault: Restart the car to engage",
|
||||
"巡航系統錯誤:請重新發動車子",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.small,
|
||||
Priority.LOW_LOWEST, VisualAlert.none, AudibleAlert.none, 0., 0., .2),
|
||||
|
||||
Alert(
|
||||
"calibrationIncompletePermanent",
|
||||
"Calibration in Progress: ",
|
||||
"Drive Above ",
|
||||
"正在校準相機中:",
|
||||
"車速請高於 ",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOWEST, VisualAlert.none, AudibleAlert.none, 0., 0., .2),
|
||||
|
||||
Alert(
|
||||
"invalidGiraffeHondaPermanent",
|
||||
"Invalid Giraffe Configuration",
|
||||
"Set 0111 for openpilot. 1011 for stock",
|
||||
"Giraffe 開關錯誤",
|
||||
"dragonpilot 模式為 0111,原廠模式為 1011",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW_LOWEST, VisualAlert.none, AudibleAlert.none, 0., 0., .2),
|
||||
|
||||
Alert(
|
||||
"sensorDataInvalidPermanent",
|
||||
"No Data from EON Sensors",
|
||||
"Reboot your EON",
|
||||
"沒有收到任何來自 EON 傳感器的資料",
|
||||
"請重啟您的 EON",
|
||||
AlertStatus.normal, AlertSize.mid,
|
||||
Priority.LOW_LOWEST, VisualAlert.none, AudibleAlert.none, 0., 0., .2),
|
||||
|
||||
@@ -692,21 +692,21 @@ ALERTS = [
|
||||
|
||||
Alert(
|
||||
"vehicleModelInvalid",
|
||||
"Vehicle Parameter Identification Failed",
|
||||
"車子參數識別失敗",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.small,
|
||||
Priority.LOWEST, VisualAlert.steerRequired, AudibleAlert.none, .0, .0, .1),
|
||||
|
||||
Alert(
|
||||
"manualSteeringRequired",
|
||||
"STEERING REQUIRED: Lane Keeping OFF",
|
||||
"請接管方向盤:車道維持關閉",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.small,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.none, .0, .1, .1, alert_rate=0.25),
|
||||
|
||||
Alert(
|
||||
"manualSteeringRequiredBlinkersOn",
|
||||
"STEERING REQUIRED: Blinkers ON",
|
||||
"請接管方向盤:方向燈開啟",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.small,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.none, .0, .1, .1, alert_rate=0.25),
|
||||
|
||||
@@ -24,11 +24,12 @@ mixplorer_main = "com.mixplorer.activities.BrowseActivity"
|
||||
|
||||
def main(gctx=None):
|
||||
|
||||
dragon_enable_tomtom = False if params.get('DragonEnableTomTom') == "0" else True
|
||||
dragon_enable_autonavi = False if params.get('DragonEnableAutonavi') == "0" else True
|
||||
dragon_enable_mixplorer = False if params.get('DragonEnableMixplorer') == "0" else True
|
||||
dragon_boot_tomtom = False if params.get("DragonBootTomTom") == "0" else True
|
||||
dragon_boot_autonavi = False if params.get("DragonBootAutonavi") == "0" else True
|
||||
dragon_enable_tomtom = True if params.get('DragonEnableTomTom') == "1" else False
|
||||
dragon_enable_autonavi = True if params.get('DragonEnableAutonavi') == "1" else False
|
||||
dragon_enable_mixplorer = True if params.get('DragonEnableMixplorer') == "1" else False
|
||||
dragon_boot_tomtom = True if params.get("DragonBootTomTom") == "1" else False
|
||||
dragon_boot_autonavi = True if params.get("DragonBootAutonavi") == "1" else False
|
||||
dragon_greypanda_mode = True if params.get('DragonGreyPandaMode') == "1" else False
|
||||
tomtom_is_running = False
|
||||
autonavi_is_running = False
|
||||
mixplorer_is_running = False
|
||||
@@ -39,6 +40,7 @@ def main(gctx=None):
|
||||
frame = 0
|
||||
start_delay = None
|
||||
stop_delay = None
|
||||
high_accuracy_mode_enabled = False
|
||||
|
||||
params.put('DragonRunTomTom', '0')
|
||||
params.put('DragonRunAutonavi', '0')
|
||||
@@ -50,6 +52,13 @@ def main(gctx=None):
|
||||
thermal_sock = messaging.sub_sock(service_list['thermal'].port)
|
||||
|
||||
while dragon_enable_tomtom or dragon_enable_autonavi or dragon_enable_mixplorer:
|
||||
if (dragon_enable_tomtom or dragon_enable_autonavi) and not high_accuracy_mode_enabled:
|
||||
if dragon_greypanda_mode:
|
||||
system("settings put secure location_providers_allowed -gps,network,wifi")
|
||||
system("settings put secure location_providers_allowed +gps")
|
||||
else:
|
||||
system("settings put secure location_providers_allowed +gps,network,wifi")
|
||||
high_accuracy_mode_enabled = True
|
||||
|
||||
# allow user to manually start/stop app
|
||||
if dragon_enable_tomtom:
|
||||
|
||||
@@ -38,6 +38,7 @@ default_conf = {
|
||||
'DragonSteeringMonitorTimer': '3',
|
||||
'DragonCameraOffset': '6',
|
||||
'DragonUIVolumeBoost': '0',
|
||||
'DragonGreyPandaMode': '0',
|
||||
}
|
||||
|
||||
deprecated_conf = {
|
||||
|
||||
+4
-4
@@ -1597,7 +1597,7 @@ static void bb_ui_draw_measures_left(UIState *s, int bb_x, int bb_y, int bb_w )
|
||||
snprintf(val_str, sizeof(val_str), "-");
|
||||
}
|
||||
snprintf(uom_str, sizeof(uom_str), "m ");
|
||||
bb_h +=bb_ui_draw_measure(s, val_str, uom_str, "REL DIST",
|
||||
bb_h +=bb_ui_draw_measure(s, val_str, uom_str, "相對距離",
|
||||
bb_rx, bb_ry, bb_uom_dx,
|
||||
val_color, lab_color, uom_color,
|
||||
value_fontSize, label_fontSize, uom_fontSize );
|
||||
@@ -1632,7 +1632,7 @@ static void bb_ui_draw_measures_left(UIState *s, int bb_x, int bb_y, int bb_w )
|
||||
} else {
|
||||
snprintf(uom_str, sizeof(uom_str), "mph");
|
||||
}
|
||||
bb_h +=bb_ui_draw_measure(s, val_str, uom_str, "REL SPEED",
|
||||
bb_h +=bb_ui_draw_measure(s, val_str, uom_str, "相對速度",
|
||||
bb_rx, bb_ry, bb_uom_dx,
|
||||
val_color, lab_color, uom_color,
|
||||
value_fontSize, label_fontSize, uom_fontSize );
|
||||
@@ -1677,7 +1677,7 @@ static void bb_ui_draw_measures_right(UIState *s, int bb_x, int bb_y, int bb_w )
|
||||
snprintf(val_str, sizeof(val_str), "%.1f°",(scene->angleSteers));
|
||||
|
||||
snprintf(uom_str, sizeof(uom_str), "");
|
||||
bb_h +=bb_ui_draw_measure(s, val_str, uom_str, "REAL STEER",
|
||||
bb_h +=bb_ui_draw_measure(s, val_str, uom_str, "實際轉向",
|
||||
bb_rx, bb_ry, bb_uom_dx,
|
||||
val_color, lab_color, uom_color,
|
||||
value_fontSize, label_fontSize, uom_fontSize );
|
||||
@@ -1701,7 +1701,7 @@ static void bb_ui_draw_measures_right(UIState *s, int bb_x, int bb_y, int bb_w )
|
||||
snprintf(val_str, sizeof(val_str), "%.1f°",(scene->angleSteersDes));
|
||||
|
||||
snprintf(uom_str, sizeof(uom_str), "");
|
||||
bb_h +=bb_ui_draw_measure(s, val_str, uom_str, "DESIR STEER",
|
||||
bb_h +=bb_ui_draw_measure(s, val_str, uom_str, "所需轉向",
|
||||
bb_rx, bb_ry, bb_uom_dx,
|
||||
val_color, lab_color, uom_color,
|
||||
value_fontSize, label_fontSize, uom_fontSize );
|
||||
|
||||
Reference in New Issue
Block a user