diff --git a/CHANGELOGS-DEV.md b/CHANGELOGS-DEV.md new file mode 100644 index 00000000000000..00c328a0356db6 --- /dev/null +++ b/CHANGELOGS-DEV.md @@ -0,0 +1,602 @@ +dragonpilot 0.8.0 +======================== +* 基於最新 openpilot 0.8.0 devel. +* Based on latest openpilot 0.8.0 devel. +* 加入 git 錯誤修正。(感謝 @toyboxZ 提供) +* Added git error fix. (Thanks to @toyboxZ) + +dragonpilot 0.7.10.1 +======================== +* HYUNDAI_GENESIS 使用 INDI 控制器。(感謝 @donfyffe 提供) +* HYUNDAI_GENESIS uses INDI controller. (Thanks to @donfyffe) +* HYUNDAI_GENESIS 加入 Cruise 按紐 和 lkMode 支援。(感謝 @donfyffe 建議) +* HYUNDAI_GENESIS added Cruise button event and lkMode feature. (Thanks to @donfyffe) +* 支援台灣版 2018 Huyndai IONIQ + smart MDPS (dp_hkg_smart_mdps) (感謝 @andy741217 提供) +* Support 2018 Taiwan Hyundai IONIQ + smart MDPS (dp_hkg_smart_mdps) (Thanks to @andy741217) +* 使用 openpilot v0.8 的模型。(感謝 @eisenheim) +* Use openpilot v0.8 model. (Thanks to @eisenheim) +* 加入 0.8 測試版的部分優化。 +* Added optimizations from pre-0.8. +* 加入 dp_honda_eps_mod 設定來使用更高的扭力 (需 eps mod)。(感謝 @Wuxl_369 提供) +* Added dp_honda_eps_mod setting to enable higher torque (eps mod required). (Thanks to @Wuxl_369) +* 修正 VW 對白/灰熊的支援 (感謝 @lirudy 提供) +* Fixed issue with white/grey panda support for VW (Thanks to @lirudy) +* GENESIS_G70 優化 (感謝 @sebastian4k 提供) +* GENESIS_G70 Optimisation (Thanks to @sebastian4k) +* HYUNDAI_GENESIS 優化 (感謝 @donfyffe 提供) +* HYUNDAI_GENESIS Optimisation (Thanks to @donfyffe) +* 加入 Dynamic gas Lite。(感謝 @toyboxZ 提供) +* Added Dynamic Gas Lite. (Thanks to @toyboxZ) +* 加入來自 afa 的 Honda inspire, accord, crv SnG 優化。(感謝 @menwenliang 提供) +* Added Honda inspire, accord, crv SnG optimisation from afa fork. (Thanks to @menwenliang) +* 加入 dp_toyota_lowest_cruise_override_vego。(感謝 @toyboxZ 提供) +* Added dp_toyota_lowest_cruise_override_vego. (Thanks to @toyboxZ) + +dragonpilot 0.7.10.0 +======================== +* 基於最新 openpilot 0.7.10 devel. +* Based on latest openpilot 0.7.10 devel. +* 修正 Prius 特定情況下無法操控方向盤的問題。 +* Fixed unable to regain Prius steering control under certain condition. +* 更新 VW MQB 的支援。(需執行 scripts/vw.sh 腳本) +* Updated support of VW MQB. (scripts/vw.sh script required) +* 新增 2018 China Toyota CHR 指紋v2。(感謝 @xiaohongcheung 提供) +* Added 2018 China Toyota CHR FPv2. (Thanks to @xiaohongcheung) +* 加入 Headunit Reloaded Android Auto App 支援。(感謝 @Ninjaa 提供) +* Added Headunit Reloaded Android Auto App Support. (Thanks to @Ninjaa) +* 優化 nanovg。(感謝 @piggy 提供) +* Optomized nanovg. (Thanks to @piggy) +* 加入 complete_setup.sh (感謝 @深鲸希西 提供) +* Added complete_setup.sh (Thanks to @深鲸希西) +* Based on latest openpilot 0.7.10 devel. +* 修正 EON 接 PC/USB 充電器時仍會自動關機的錯誤。(感謝 @小愛 回報) +* Fixed auto shutdown issue when EON connect to PC/USB Charger. (Thanks to @LOVEChen) +* HYUNDAI_GENESIS 使用 INDI 控制器。(感謝 @donfyffe 提供) +* HYUNDAI_GENESIS uses INDI controller. (Thanks to @donfyffe) + +dragonpilot 0.7.8.3 +======================== +* VW 加入 6 分鐘時間方向盤控制限制輔助方案。(特別感謝 @actuallylemoncurd 提供代碼) +* VW added 6 minutes timebomb assist. (dp_timebomb_assist, special thanks to @actuallylemoncurd) + +dragonpilot 0.7.8.2 +======================== +* 修正在沒網路的情況下,開機超過五分鐘的問題。 +* Fixed 5+ minutes boot time issue when there is no internet connection. +* 錯誤回傳改使用 dp 的主機。 +* Used dp server for error reporting. +* 更新服務改使用 gitee 的 IP 檢查連線狀態。 +* updated service uses gitee IP address instead. + +dragonpilot 0.7.8.1 +======================== +* 加入 ko-KR 翻譯。 +* Added ko-KR translation. +* 加入 Honda Jade 支援。(感謝 @李俊灝) +* Added Honda Jade support. (Thanks to @lijunhao731) +* 修正 ui.cc 內存越界的問題。(感謝 @piggy 提供) +* Fixed ui.cc memory out of bound issue. (Thanks to @piggy) +* gpxd 記錄改自動存成 zip 格式。 +* gpxd now store in zip format. +* 強制關閉 panda 檢查 DOS 硬體。 +* Force disabled DOS hardware check in panda. + +dragonpilot 0.7.8.0 +======================== +* 基於最新 openpilot 0.7.8 devel. +* Based on latest openpilot 0.7.8 devel. +* 加入重置 DP 設定按鈕。(感謝 @LOVEChen 建議) +* Added "Reset DP Settings" button. (Thanks to @LOVEChen) +* 將警示訊息更改為類似於概念 UI 的設計。 +* Alert messages changed to concept UI alike design. +* 當 manager 出現錯誤後,按 Exit 按鈕會執行 reset_update 腳本。 +* Added ability to execute reset_update.sh when press "Exit" button once manager returned errors. + +dragonpilot 0.7.7.3 +======================== +* 修正方向盤監控。 +* Fixed steering monitor timer param. +* 修正行駛時關閉畫面導致當機的錯誤。(感謝 @salmankhan, @stevej99, @bobbydough 回報) +* Fixed screen frozen issue when "screen off while driving" toggle is enabled. (Thanks to @salmankhan, @stevej99, @bobbydough) +* 加回 Dev Mini UI 開關。(感謝 @Ninjaa 建議) +* Re-added Dev Mini UI. (Thanks to @Ninjaa) +* 新增 (dp_reset_live_parameters_on_start) 每次發車重設 LiveParameters 值。(感謝 @eisenheim) +* Added ability (dp_reset_live_param_on_start) to reset LiveParameters on each start. (Thanks @eisenheim) +* 修正同時開啟 dp_toyota_zss 和 dp_lqr 產生的錯誤。(感謝 @bobbydough) +* Fixed error cuased by enabling both dp_toyota_zss and dp_lqr at the same time. (Thanks to @bobbydough) +* 新增 (dp_gpxd) 將 GPS 軌跡導出至 GPX 格式 (/sdcard/gpx_logs/)的功能。 (感謝 @mageymoo1) +* Added ability (dp_gpxd) to export GPS track into GPX files (/sdcard/gpx_logs/). (Thanks to @mageymoo1) +* 使用德國的車道寬度估算值。 (感謝 @arne182) +* Used lane width estimate value from Germany. (Thanks to @arne182) + +dragonpilot 0.7.7.2 +======================== +* 加入 d_poly offset。 (感謝 @ShaneSmiskol) +* Added d_poly offset. (Thanks to @ShaneSmiskol) +* 加入 ZSS 支援。(感謝 @bobbydough, @WilliamPrius 建議, @bobbydough 測試) +* Added ZSS support. (Thanks to @bobbydough, @WilliamPrius for recommendation, @bobbydough for testing) +* 加入錯誤記錄至 /sdcard/crash_logs/ (感謝 @ShaneSmiskol 提供代碼) +* Added error logs to /sdcard/crash_logs/ (Special Thanks to @ShaneSmiskol) +* 加入 LQR 控制器開關進設定畫面。 +* Added LQR Controller toggle to settings. + +dragonpilot 0.7.7.1 +======================== +* 加入 C2 風扇靜音模式。(感謝 @dingliangxue) +* Added C2 quiet fan mode. (Thanks to @dingliangxue) +* 加入「輔助換道最低啟動速度」、「自動換道最低啟動速度」設定。 +* Added "Assisted Lane Change Min Engage Speed" and "Auto Lane Change Min Engage Speed" settings. +* 加入回調校介面。(感謝 @Kent) +* Re-added Dev UI. (Thanks to @Kent) +* 加入 "dp_lqr" 設定來強制使用 RAV4 的 lqr 調校。(感謝 @eisenheim) +* Added "dp_lqr" setting to force enable lqr tuning from RAV4. (Thanks to eisenheim) + +dragonpilot 0.7.7.0 +======================== +* 基於最新 openpilot 0.7.7 devel. +* Based on latest openpilot 0.7.7 devel. +* 當 Manager 出現錯誤時,顯示 IP 位置。(感謝 @dingliangxue) +* When Manager failed, display IP address. (Thanks to @dingliangxue) +* 加回 sr learner 開關。 +* Re-added sr learner toggle. +* 加回 加速模式 開關。 +* Re-added Accel Profile toggle. +* Toyota 加入改寫最低巡航速度功能。(感謝 @Mojo) +* Added Toyota to override lowerest cruise speed. (Thanks to @Mojo) +* 介面加入盲點偵測顯示。(感謝 @wabes) +* Added BSM indicator to UI. (Thanks to @wabes) +* 加回彎道減速功能。(感謝 @Mojo) +* re-added Slow On Curve functionality. (Thanks to @Mojo) + +dragonpilot 0.7.6.2 +======================== +* 修正無法正確關閉駕駛監控的問題。 +* Fixed unable to properly turn off driver monitor issue. + +dragonpilot 0.7.6.1 +======================== +* 基於最新 openpilot 0.7.6.1 devel. +* Based on latest openpilot 0.7.6.1 devel. +* 優化並整合 dp 服務。 (所有的設定檔已改名,請重新設定所有的功能) +* Optimized and integrated several dp services. (Settings have been renamed, please re-config all settings) +* 完全關閉 steer ratio learner。 +* Completely disabled steer ratio learner. +* 移除「加速模式」。 +* Removed Accel Profile. +* 加入本田皓影混電版指紋v1。(感謝 @劉駿) +* Added Honda Breeze Hybrid FPv1. (Thanks to @劉駿) +* 加入台灣版 Toyota Prius 4.5 指紋v1。(感謝 @jeekid) +* Added Taiwan Toyota Prius 4.5 FPv1. (Thanks to @jeekid) + +dragonpilot 0.7.5.4 +======================== +* Dynamic Follow 更新模型。(感謝 @ShaneSmiskol 提供代碼、 @cgw1968 測試) +* Updated Dynamic Follow model. (Special Thanks to @ShaneSmiskol for the feature and @cgw1968 for testing) + +dragonpilot 0.7.5.3 +======================== +* Dynamic Follow 更新至 ShaneSmiskol:stock_additions 0.7.5 版。(感謝 @ShaneSmiskol 提供代碼、 @Wei 測試) +* Updated Dynamic Follow to ShaneSmiskol:stock_additions 0.7.5. (Special Thanks to @ShaneSmiskol for the feature and @Wei for testing) +* 優化 Lexus GSH 轉向。(感謝 @簡銘佑 測試) +* Optimize Lexus GSH steering. (Thanks to @簡銘佑) +* C2 支援自動關機「DragonAutoShutdownAt」參數。(感謝 @cgw1968 建議) +* C2 to support auto shutdown "DragonAutoShutDownAt" param. (Thanks to @cgw1968) +* 修正出現「pedalPressed」的錯誤。(感謝 @Wei 回報) +* Fixed issue showing "pedalPressed" error. (Thanks to @Wei) +* 將剎車狀熊顯示於 dp 資訊欄。 +* Added brake indicator to dp infobar. +* 修正「溫度監控」燈示。 +* Fixed "Temp monitor" indicator. +* 加入「方向燈取消控制」延遲控制設。(感謝 @wabes 建議) +* Added delay config to "Disable Lat Control on Blinker". (Thanks to @wabes) +* 加入巴西版 2020 Corolla Hybrid 指紋v2。(感謝 @berno22 提供) +* Added Brazil 2020 Corolla Hybrid FPv2. (Thanks to @berno22) + +dragonpilot 0.7.5.2 +======================== +* 加入對 VW MQB/PQ 的支援。(感謝 @dingliangxue 移植) +* Added support to VW MQB/PQ platform. (Thanks to @dingliangxue) +* 修改成 3 小時後停止供電。(感謝 @Wei 建議) +* Updated to stop charging after 3 hrs. (Thanks to @Wei) +* 移除行車記錄下的「碰撞偵測」功能。 +* Removed Impact Detection in Dashcam. +* 修正開啟「Noctua 風扇」模式導致的錯誤。(感謝 @阿濤 回報) +* Fixed a bug caused by enabling "Noctua Mod". (Thanks to @阿濤) +* 修正「位智模式」無法顯示警示的問題。(感謝 @axandres 回報) +* Fixed alert issue in waze mode. (Thanks to @axandres) +* 修正無法顯示更新中圖示的問題。 +* Fixed unable to display "UPDATING" icon issue. +* 加入「允許多次自動換道」功能。(感謝 @阿濤 建議) +* Added "Allow Continuous Auto Lane Change" Toggle. (Thanks to @阿濤) +* 修正開機後設定頁面有時會錯誤的問題。(感謝 @salmankhan、@Wei 回報) +* Fixed setting page crash issue. (Thanks to @salmankhan, @Wei) +* 修正熄火後一直出現更新訊息的錯誤。(感謝 @Sky Chang 回報) +* Fixed issue that keep showing update prompt. (Thanks to @Sky Chang) + +dragonpilot 0.7.5.1 +======================== +* 修正因同時使用「社群功能」和「自定車型」造成的加減速問題。(特別感謝 @Wei、@Sky Chang、@Han9365、@鄧育林 的測試以及回報。) +* Fixed acceleration issue caused by used of both "Community Maintain Feature" and "Custom Car Model". (Special Thanks to @Wei, @Sky Chang, @Han9365, @鄧育林) +* 新增 DragonMaxSpeedLimit 設定值 (mph),當如果車速高於此值 op 將會停止操控。(感謝 @Anthony 建議) +* Added DragonMaxSpeedLimit parameter (mph), op will stop controlling when car speed is high than the value. (Thanks to @Anthony) +* 更新 appd 使用 cnpmjs 來下載 APKs。 +* Updated appd to use cnpmjs to download APKs. +* 修正更新服務。(感謝 @Wei) +* Fixed Update Service. (Thanks to @Wei) +* 新增加拿大版 2018 Toyota Sienna LTD 指紋(v2)。(感謝 明峰 提供) +* Added Canada 2018 Toyota Sienna LTD fingerprint (v2). (Thanks to 明峰) +* 新增「通過移動網路上傳」開關 +* Added Upload Over Mobile Network toggle. +* 新增「通過熱點上傳」開關 +* Added Upload Over Hotspot toggle. +* 新增加拿大版 2018 Toyota Sienna LTD 指紋(v1)。(感謝 明峰 提供) +* Added Canada 2018 Toyota Sienna LTD fingerprint (v1). (Thanks to 明峰) +* 新增大陸版 Volkswagen Golf GTI 指紋 (v1)。(感謝 easyeiji 提供) +* Added China Volkswagen Golf GTI fingerprint (v1). (Thanks to easyeiji) + +dragonpilot 0.7.5.0 +======================== +* 基於最新 openpilot 0.7.5 devel-staging. +* Based on latest openpilot 0.7.5 devel-staging. +* 更新 dp 圖示 (特別感謝 @wabes 的設計與提供)。 +* Updated dp logo, special thanks to @wabes for the design. +* 簡/繁中文版和 i18n 整合成為單一版本。 +* Merged zhs/zht/i18n versions into one. +* 新增大陸版 CAMRY HYBRID 指紋v2。(感謝 @杜子腾) +* Added China Camery Hybrid FPv2. (Thanks to @杜子腾) +* 新增台灣版 Altis HYBRID 指紋v1。(感謝 @Fish) +* Added Taiwan Altis Hybrid FPv1. (Thanks to @Fish) +* 新增行駛時關閉畫面功能。 +* Added Screen off while driving feature. +* 新增倒車時關閉畫面功能。 +* Added Screen off while reversing feature. +* 新增駕駛介面加入「加速模式」切換鈕。 +* Added acceleration profile toggle onto driving UI. +* 新增自定車型功能,取代指紋暫存功能。 +* Replaced fingerprint cache with custom car model selector. +* 新增可調亮度。 +* Added Brightness changer. +* 新增部分德語支持。(特別感謝 @arne182 提供) +* Added partial de_DE language support (Thanks to @arne182) +* 新增停車碰撞偵測記錄功能。 +* Added off road impact detection to dashcam. + +2020-05-06 +======================== +* 更新 dp 圖示 (特別感謝 @wabes 的設計與提供)。 +* 中文版整合進 i18n 版。 +* 刪除指紋暫存功能。 +* 新增 CAMERY HIBRID 指紋。(感謝 @杜子腾) +* 新增行駛時關閉畫面功能。 +* 新增倒車時關閉畫面功能。 +* 新增駕駛介面加入「加速模式」切換鈕。 +* 新增自定義車型。 + +2020-04-16 +======================== +* [DEVEL] 加入台灣版 2016 Lexus IS200t 指紋。(感謝 Philip / Cody Dai) +* [DEVEL] 加入台灣版 2016 Toyota Prius 4.5 代指紋。(感謝 Philip) +* [DEVEL] 加入台灣版 201x Toyota RAV4 4WD 指紋。(感謝 Philip) +* [DEVEL] 加入台灣版 2020 Toyota Auris w/ LTA 指紋。(感謝 Philip) +* [DEVEL] 修正 commIssue 錯誤。(感謝 Kent 協助) + +2020-04-13 +======================== +* [DEVEL] 加入可調整 Toyota Sng 起步反應值 (DragonToyotaSngResponse)。 (特別感謝 @Wei 提供 PR) +* [DEVEL] 駕駛介面加入「動態調整車距」按鈕。(感謝 @cgw1968-5779 建議) +* [DEVEL] 更新 update script。(感謝 深鯨希西 回報) + +2020-04-10 +======================== +* [DEVEL] 更新 panda 至最新的 comma:master 分支。 +* [DEVEL] 移除所有的第三方應用改為自動下載。 +* [DEVEL] 移除「啟用原廠 DSU 模式」、「安全帶檢查」、「車門檢查」開關。 + +2020-03-31 +======================== +* [DEVEL] 更新至 2020-03-31 testing 分支。 + +2020-03-27 +======================== +* [DEVEL] 更新至最新的 testing 分支: + * 加入波蘭版 2015 Lexus NX200T 支援。(感謝 wabes 提供) + * 調整「啟用原廠 DSU 模式」為不再需要 AHB 。(Enable Stock DSU Mode no longer requires "AHB" toggle) + * 加入「安全帶檢查」、「車門檢查」、「檔位檢查」、「溫度檢查」開關。 + * 加入曲率學習功能 - Curvature Learner 。(感謝 zorrobyte 提供) + * 加入大陸版 2018 Toyota Highlander 支援。(感謝 toyboxZ 提供) + * 加入大陸版 2018 Toyota Camry 2.0 支援。(感謝 Rming 提供) + * 加入韓文支持。(感謝 crwusiz 提供) + * 調整 OFFROAD 主頁翻譯將 "dragonpilot" 改回 "openpilot"。 + +2020-03-22 +======================== +* [DEVEL] 更新至最新的 testing 分支。 + +2020-03-17 +======================== +* [DEVEL] 更新至最新的 testing 分支 (commaai:devel-staging 0.7.4)。 +* [DEVEL] 加入動態調整車距功能。(特別感謝 @ShaneSmiskol 提供 PR) + +2020-03-14 +======================== +* [DEVEL] 更新 pt-Br (葡萄牙語) 翻譯。(感謝 berno22 提供) +* [DEVEL] 加入自動關機開關。(感謝 Rzxd 建議) +* [DEVEL] 調高 Toyota 扭力容錯值。 +* [DEVEL] 優化讀取 dp 設定值。 +* [DEVEL] 加入 2019 手動 Civic 指紋。感謝 (AlexNoop 提供) +* [DEVEL] dp 功能加入對 Subaru 車系的支援。 + +2020-03-06 +======================== +* [DEVEL] 加入葡萄牙語支持。(感謝 berno22 提供) +* [DEVEL] 加入大陸 2018 Camry、2020 RAV4 指紋。(感謝 笨木匠 提供) +* [DEVEL] 建立 devel-i18n 取代 devel-en。 +* [DEVEL] devel-en is deprecated, please switch to devel-i18n instead. + +2020-03-04 +======================== +* [DEVEL] 加入顯示駕駛監控畫面。 +* [DEVEL] 加入加速模式選項。(特別感謝 @arne182, @cgw1968-5779 提供 PR) +* [DEVEL] 修正 shutdownd 在 comma two 可能會不正常關機的錯誤。(感謝 @Wei, @Rzxd 回報) + +2020-02-25 +======================== +* [DEVEL] 更新至最新的 commaai:devel (0.7.3)。 + +2020-02-21 +======================== +* [DEVEL] 更新至最新的 commaai:devel (0.7.3)。 + +2020-02-14 +======================== +* [DEVEL] 更新至最新的 commaai:devel (0.7.2)。 +* [DEVEL] 修正錯誤。 + +2020-02-08 +======================== +* [DEVEL] 更新至最新的 commaai:devel (0.7.2)。 +* [DEVEL] dp 功能加入對現代 (Hyundai) 車系的支援。 +* [DEVEL] 加入神盾測速照相自動啟動的開關。 +* [DEVEL] 更新高德地圖至 v4.5.0.600053。 +* [DEVEL] 使用 0.6.6 版的更新系統。 +* [DEVEL] 修正急剎問題。(感謝 kumar 提供) + +2020-01-31 +======================== +* [DEVEL] 移除行車介面電量、溫度顯示,(修正畫面當機、黑屏問題) + +2020-01-29 +======================== +* [DEVEL] 修正行車介面錯誤。(感謝 深鲸希西 測試;eisenheim、HeatNation 反應) + +2020-01-23 +======================== +* [DEVEL] 加入 Steer Ratio Learner 關閉。(感謝 eisenheim 建議) +* [DEVEL] 行車介面加入電量、溫度。(感謝 eisenheim 建議) +* [DEVEL] 優化 appd。 + +2020-01-19 +======================== +* [DEVEL] 更新至最新的 commaai:devel (0.7.1)。 +* [DEVEL] 調整 appd 和 ALC 邏輯。 + +2020-01-14 +======================== +* [DEVEL] 加入開機啟動個人熱點。(感謝 eisenheim 建議) + +2020-01-08 +======================== +* [DEVEL] 加入大陸版 2018 Lexus RX300 支援。(感謝 cafe 提供) +* [DEVEL] 加入 DragonBTG 設定。(感謝 CloudJ、低調哥、歐姓Altis車主 提供) + +2019-12-31 +======================== +* [DEVEL-ZHS] 加回第三方應用。 + +2019-12-29 +======================== +* [DEVEL] 更新至最新的 commaai:devel (0.7.0)。 +* [DEVEL] 輔助/自動變道改為可調整參數 (進階用戶)。(DragonAssistedLCMinMPH、DragonAutoLCMinMPH、DragonAutoLCDelay) +* [DEVEL-ZHS] 修正無法運行第三方應用錯誤。(感謝 深鲸希西 反應) + +2019-12-18 +======================== +* [DEVEL] 修正自動換道邏輯。 +* [DEVEL] 更新 offroad 翻譯。 +* [DEVEL] 錯誤修正。 +* [DEVEL] 移除美版 2017 Civic Hatchback 指紋。(與其它車型衝突) + +2019-12-17 +======================== +* [DEVEL] 更新至最新的 commaai:devel (0.7.0)。 +* [DEVEL] 加入輔助換道開關。(24mph / 40kph 以上) +* [DEVEL] 加入自動換道開關。(40mph / 65kph 以上) +* [DEVEL] 加入大陸版 2019 雷凌汽油版指紋。 (感謝 Shell 提供) +* [DEVEL] 加入大陸版 2019 卡羅拉汽油版指紋。 (感謝 Shell 提供) +* [DEVEL] 加入美版 2017 Civic Hatchback 指紋。(感謝 CFranHonda 提供) + +2019-12-10 +======================== +* [DEVEL] 加入位智車機模式。 (Waze Mode) + +2019-11-21 +======================== +* [DEVEL] 修正 offroad 翻譯。(感謝 鄧育林 回報) +* [DEVEL] 調整前車靜止移動偵測參數。 +* [DEVEL] 前車靜止移動偵測可在未啟用 dp 時運作。 + +2019-11-18 +======================== +* [DEVEL] 修正 offroad 翻譯。(感謝 Cody、鄧育林 回報) + +2019-11-18 +======================== +* [DEVEL] 修正 frame 翻譯。 + +2019-11-15 +======================== +* [DEVEL] 修正不會充電的錯誤。 (感謝 袁昊 反應) + +2019-11-15 +======================== +* [DEVEL] 修正充電控制。 (感謝 KT 反應) +* [DEVEL] 更新 frame 翻譯,改為多語言版。 (感謝 深鲸希西、shaoching885、鄧育林 反應) +* [DEVEL] 更新至最新的 commaai:devel (0.6.6)。 + +2019-11-12 +======================== +* [DEVEL] 只顯示電量文字 (注意:有時不會更新,需要拔插 USB 線) +* [DEVEL] 自動偵測並鎖定硬體 (EON / UNO)。 + +2019-11-12 +======================== +* [DEVEL] 加入鎖定硬體 (EON / UNO) 的程式碼。 + +2019-11-11 +======================== +* [DEVEL] 更新高德地圖至 v4.3.0.600310 R2098NSLAE +* [DEVEL] 更新 MiXplorer 至 v6.40.3 +* [DEVEL] 更新至最新的 commaai:devel (0.6.6)。 +* [DEVEL] 前車靜止移動偵測加入偵測警示。 + +2019-11-07 +======================== +* [DEVEL] 讓 Bosch 系統顯示三角。 (感謝 ching885 回報) +* [DEVEL] 更新 offroad 多語言版簡體中文翻譯 (感謝 Rming 提供) + +2019-11-06 +======================== +* [DEVEL] 修正 0.6.6 appd 和 dashcamd 錯誤。 (感謝 鄧育林 回報) +* [DEVEL] 更新至最新的 commaai:devel (0.6.6)。 + +2019-11-05 +======================== +* [DEVEL] 加入台灣 Lexus 2017 GS450h 支援。 (感謝 簡銘佑 提供指紋) + +2019-11-01 +======================== +* [DEVEL] 新增神盾測速照相。 (感謝 Sky Chang 和 Wei Yi Chen) +* [DEVEL] 修正 offroad 翻譯。 (感謝 Leo Hsieh) + +2019-11-01 +======================== +* [DEVEL] 移除 Miui 字型,縮小 dp 使用空間。 +* [DEVEL] 更新 offroad 為多語言版 +* [DEVEL] 更新至最新的 commaai:devel (0.6.5)。 + +2019-10-29 +======================== +* [DEVEL] 加入 SnG 補丁。(感謝 楊雅智) + +2019-10-28 +======================== +* [DEVEL] 更新至最新的 commaai:devel (0.6.5)。 +* [DEVEL] 調整 dragon_allow_gas 邏輯 (請回報任何問題,需更新 Panda 韌體) + +2019-10-18 +======================== +* [DEVEL] 加入前車靜止移動偵測。(測試版,感謝 ucolchen) +* [DEVEL] 移除強迫網路連線提示。(感謝 Shell) +* [DEVEL] 修正 allow_gas 功能。 + +2019-10-18 +======================== +* [DEVEL] 加入彎道減速功能開關。 +* [DEVEL] 強迫使用 dp 版 Panda 韌體。 +* [DEVEL] 更新至最新的 commaai:devel (0.6.5)。 + +2019-10-17 +======================== +* [DEVEL] 加入「車型」顯示於 dp 設定畫面。 +* [DEVEL] 修正充電控制讀取預設值的錯誤。 +* [DEVEL] 修正無法顯示更新記錄的錯誤。 + +2019-10-16 +======================== +* [DEVEL] 刷新 Panda 韌體按鈕將會自動重啟 EON。(感謝 鄧育林 建議) +* [DEVEL] 下載更新記錄時使用 "no-cache" 標頭。 +* [DEVEL] 更新高德地圖至 v4.3.0 +* [DEVEL] 刪除 bs (Branch Switcher) + +2019-10-14 +======================== +* [DEVEL] 啟用自動更新功能。(感謝 鄧育林 提供) +* [DEVEL] 清除不再使用的 dp params。 +* [DEVEL] 加入數字電量指示。(感謝 鄧育林 建議) +* [DEVEL] 加入刷新 Panda 韌體按鈕。 + +2019-10-11 +======================== +* [DEVEL] 更新至最新的 commaai:devel (0.6.5)。 +* [DEVEL] 加入台灣 2019 RAV4 汽油版指紋。 (感謝 Max Duan / CloudJ 提供) + +2019-10-09 +======================== +* [DEVEL] 加入當 LatCtrl 關閉時,畫面顯示提示訊息。 + +2019-10-08 +======================== +* [DEVEL] 加回駕駛監控開關。 +* [DEVEL] 加入 bs (branch switcher) 程式。 + +2019-10-07 +======================== +* [DEVEL] 加入台灣版 2019 RAV4H 油電版指紋。(感謝 Max Duan 提供) + +2019-10-05 +======================== +* [DEVEL] 移除 curvature learner: 轉角明顯比原廠小。 +* [DEVEL] 更新至最新的 commaai:devel (0.6.4)。 + +2019-09-30 +======================== +* [DEVEL] 更新 curvature learner 版本至 v4。 +* [DEVEL] Lexus ISH 使用更精確的 EPS Steering Angle Sensor + +2019-09-27 +======================== +* [DEVEL] 加入 Zorrobyte 的 curvature learner (https://github.com/zorrobyte/openpilot) +* [DEVEL] 加入可開關駕駛監控的程式碼。 +* [DEVEL] 取消當 steering 出現錯誤時,自動切斷方向控制 2 秒的機制。 +* [DEVEL] 讓行車介面的「方向盤」/「轉彎」圖示半透明化。 + +2019-09-26 +======================== +* [DEVEL] 修正當「啟用記錄服務」關閉時,make 會有問題的錯誤。 (感謝 shaoching885 和 afa 回報) + +2019-09-24 +======================== +* [DEVEL] 行車介面加入可開關的「前車」、「路線」、「車道」設定。 +* [DEVEL] 行車介面加入可開關的「方向燈號」提示。 (感謝 CloudJ 建議,程式碼來源: https://github.com/kegman/openpilot) + +2019-09-23 +======================== +* [DEVEL] 優化讀取 params 的次數。 +* [DEVEL] 加入可開關的車道偏移警示。 +* [DEVEL] 修正充電控制邏輯。 +* [DEVEL] 加入台灣 Prius 4.5 指紋。 (感謝 Lin Hsin Hung 提供) + +2019-09-20 +======================== +* [DEVEL] 加入充電控制功能。 (感謝 loveloveses 和 KT 建議) + +2019-09-16 +======================== +* [DEVEL] 加入台灣 CT200h 指紋。 (感謝 CloudJ 提供) +* [DEVEL] 加入美版 CT200h 移植。 (感謝 thomaspich 提供) + +2019-09-13 +======================== +* [DEVEL] 行車介面加入可開關的「速度顯示」設定。 + +2019-09-09 +======================== +* [DEVEL] 加入 GreyPanda 模式。 + +2019-08-28 +======================== +* [DEVEL] 加入可調警示音量。 + +2019-08-27 +======================== +* [DEVEL] 自動關機改為可調時長。 diff --git a/CHANGELOGS-REL.md b/CHANGELOGS-REL.md new file mode 100644 index 00000000000000..0642e27b13b2d7 --- /dev/null +++ b/CHANGELOGS-REL.md @@ -0,0 +1,301 @@ +dragonpilot 0.8.0 +======================== +* 基於最新 openpilot 0.8.0 devel. +* Based on latest openpilot 0.8.0 devel. +* 加入 git 錯誤修正。(感謝 @toyboxZ 提供) +* Added git error fix. (Thanks to @toyboxZ) + +dragonpilot 0.7.10.0 +======================== +* 基於最新 openpilot 0.7.10 devel. +* Based on latest openpilot 0.7.10 devel. +* 修正 Prius 特定情況下無法操控方向盤的問題。 +* Fixed unable to regain Prius steering control under certain condition. +* 更新 VW MQB 的支援。(需執行 scripts/vw.sh 腳本) +* Updated support of VW MQB. (scripts/vw.sh script required) +* 新增 2018 China Toyota CHR 指紋v2。(感謝 @xiaohongcheung 提供) +* Added 2018 China Toyota CHR FPv2. (Thanks to @xiaohongcheung) +* 加入 Headunit Reloaded Android Auto App 支援。(感謝 @Ninjaa 提供) +* Added Headunit Reloaded Android Auto App Support. (Thanks to @Ninjaa) +* 優化 nanovg。(感謝 @piggy 提供) +* Optomized nanovg. (Thanks to @piggy) +* 加入 complete_setup.sh (感謝 @深鲸希西 提供) +* Added complete_setup.sh (Thanks to @深鲸希西) +* Based on latest openpilot 0.7.10 devel. +* 修正 EON 接 PC/USB 充電器時仍會自動關機的錯誤。(感謝 @小愛 回報) +* Fixed auto shutdown issue when EON connect to PC/USB Charger. (Thanks to @LOVEChen) +* HYUNDAI_GENESIS 使用 INDI 控制器。(感謝 @donfyffe 提供) +* HYUNDAI_GENESIS uses INDI controller. (Thanks to @donfyffe) +* HYUNDAI_GENESIS 加入 Cruise 按紐 和 lkMode 支援。(感謝 @donfyffe 建議) +* HYUNDAI_GENESIS added Cruise button event and lkMode feature. (Thanks to @donfyffe) +* 支援台灣版 2018 Huyndai IONIQ + smart MDPS (dp_hkg_smart_mdps) (感謝 @andy741217 提供) +* Support 2018 Taiwan Hyundai IONIQ + smart MDPS (dp_hkg_smart_mdps) (Thanks to @andy741217) +* 使用 openpilot v0.8 的模型。(感謝 @eisenheim) +* Use openpilot v0.8 model. (Thanks to @eisenheim) +* 加入 0.8 測試版的部分優化。 +* Added optimizations from pre-0.8. +* 加入 dp_honda_eps_mod 設定來使用更高的扭力 (需 eps mod)。(感謝 @Wuxl_369 提供) +* Added dp_honda_eps_mod setting to enable higher torque (eps mod required). (Thanks to @Wuxl_369) +* 修正 VW 對白/灰熊的支援 (感謝 @lirudy 提供) +* Fixed issue with white/grey panda support for VW (Thanks to @lirudy) +* GENESIS_G70 優化 (感謝 @sebastian4k 提供) +* GENESIS_G70 Optimisation (Thanks to @sebastian4k) +* HYUNDAI_GENESIS 優化 (感謝 @donfyffe 提供) +* HYUNDAI_GENESIS Optimisation (Thanks to @donfyffe) +* 加入 Dynamic gas Lite。(感謝 @toyboxZ 提供) +* Added Dynamic Gas Lite. (Thanks to @toyboxZ) +* 加入來自 afa 的 Honda inspire, accord, crv SnG 優化。(感謝 @menwenliang 提供) +* Added Honda inspire, accord, crv SnG optimisation from afa fork. (Thanks to @menwenliang) +* 加入 dp_toyota_lowest_cruise_override_vego。(感謝 @toyboxZ 提供) +* Added dp_toyota_lowest_cruise_override_vego. (Thanks to @toyboxZ) + +dragonpilot 0.7.8 +======================== +* 基於最新 openpilot 0.7.8 devel. +* Based on latest openpilot 0.7.8 devel. +* 加入重置 DP 設定按鈕。(感謝 @LOVEChen 建議) +* Added "Reset DP Settings" button. (Thanks to @LOVEChen) +* 將警示訊息更改為類似於概念 UI 的設計。 +* Alert messages changed to concept UI alike design. +* 當 manager 出現錯誤後,按 Exit 按鈕會執行 reset_update 腳本。 +* Added ability to execute reset_update.sh when press "Exit" button once manager returned errors. +* 加入 ko-KR 翻譯。 +* Added ko-KR translation. +* 加入 Honda Jade 支援。(感謝 @李俊灝) +* Added Honda Jade support. (Thanks to @lijunhao731) +* 修正 ui.cc 內存越界的問題。(感謝 @piggy 提供) +* Fixed ui.cc memory out of bound issue. (Thanks to @piggy) +* gpxd 記錄改自動存成 zip 格式。 +* gpxd now store in zip format. +* 強制關閉 panda 檢查 DOS 硬體。 +* Force disabled DOS hardware check in panda. +* 修正在沒網路的情況下,開機超過五分鐘的問題。 +* Fixed 5+ minutes boot time issue when there is no internet connection. +* 錯誤回傳改使用 dp 的主機。 +* Used dp server for error reporting. +* 更新服務改使用 gitee 的 IP 檢查連線狀態。 +* updated service uses gitee IP address instead. +* VW 加入 6 分鐘時間方向盤控制限制輔助方案。(特別感謝 @actuallylemoncurd 提供代碼) +* VW added 6 minutes timebomb assist. (dp_timebomb_assist, special thanks to @actuallylemoncurd) + +dragonpilot 0.7.7.0 +======================== +* 基於最新 openpilot 0.7.7 devel. +* Based on latest openpilot 0.7.7 devel. +* 當 Manager 出現錯誤時,顯示 IP 位置。(感謝 @dingliangxue) +* When Manager failed, display IP address. (Thanks to @dingliangxue) +* 加回 sr learner 開關。 +* Re-added sr learner toggle. + +dragonpilot 0.7.6 +======================== +* 基於最新 openpilot 0.7.6.1 devel. +* Based on latest openpilot 0.7.6.1 devel. +* 優化並整合 dp 服務。 (所有的設定檔已改名,請重新設定所有的功能) +* Optimized and integrated several dp services. (Settings have been renamed, please re-config all settings) +* 完全關閉 steer ratio learner。 +* Completely disabled steer ratio learner. +* 移除「加速模式」。 +* Removed Accel Profile. +* 加入本田皓影混電版指紋v1。(感謝 @劉駿) +* Added Honda Breeze Hybrid FPv1. (Thanks to @劉駿) +* 加入台灣版 Toyota Prius 4.5 指紋v1。(感謝 @jeekid) +* Added Taiwan Toyota Prius 4.5 FPv1. (Thanks to @jeekid) +* 加入 2020 Toyota Prius 指紋v2。(感謝 @Trae) +* Added Toyota Prius 2020 FPv2. (Thanks to @Trae) +* 優化 Honda CR-V Hybrid 轉向。(感謝 @martint1980) +× Optomised Honda CR-V Hybrid lateral control. (Thanks to @martint1980) + +dragonpilot 0.7.5 +======================== +* 優化 Lexus GSH 轉向。(感謝 @簡銘佑 測試) +* Optimize Lexus GSH steering. (Thanks to @簡銘佑) +* C2 支援自動關機「DragonAutoShutdownAt」參數。(感謝 @cgw1968 建議) +* C2 to support auto shutdown "DragonAutoShutDownAt" param. (Thanks to @cgw1968) +* 將剎車狀熊顯示於 dp 資訊欄。 +* Added brake indicator to dp infobar. +* 加入「方向燈取消控制」延遲控制設。(感謝 @wabes 建議) +* Added delay config to "Disable Lat Control on Blinker". (Thanks to @wabes) +* 加入巴西版 2020 Corolla Hybrid 指紋v2。(感謝 @berno22 提供) +* Added Brazil 2020 Corolla Hybrid FPv2. (Thanks to @berno22) +* 加入對 VW MQB/PQ 的支援。(感謝 @dingliangxue 移植) +* Added support to VW MQB/PQ platform. (Thanks to @dingliangxue) +* 加入「允許多次自動換道」功能。(感謝 @阿濤 建議) +* Added "Allow Continuous Auto Lane Change" Toggle. (Thanks to @阿濤) +* 新增 DragonMaxSpeedLimit 設定值 (mph),當如果車速高於此值 op 將會停止操控。(感謝 @Anthony 建議) +* Added DragonMaxSpeedLimit parameter (mph), op will stop controlling when car speed is high than the value. (Thanks to @Anthony) +* 新增加拿大版 2018 Toyota Sienna LTD 指紋(v2)。(感謝 明峰 提供) +* Added Canada 2018 Toyota Sienna LTD fingerprint (v2). (Thanks to 明峰) +* 新增「通過移動網路上傳」開關 +* Added Upload Over Mobile Network toggle. +* 新增「通過熱點上傳」開關 +* Added Upload Over Hotspot toggle. +* 新增加拿大版 2018 Toyota Sienna LTD 指紋(v1)。(感謝 明峰 提供) +* Added Canada 2018 Toyota Sienna LTD fingerprint (v1). (Thanks to 明峰) +* 新增大陸版 Volkswagen Golf GTI 指紋 (v1)。(感謝 easyeiji 提供) +* Added China Volkswagen Golf GTI fingerprint (v1). (Thanks to easyeiji) +* 更新 dp 圖示 (特別感謝 @wabes 的設計與提供)。 +* Updated dp logo, special thanks to @wabes for the design. +* 簡/繁中文版和 i18n 整合成為單一版本。 +* Merged zhs/zht/i18n versions into one. +* 新增大陸版 CAMRY HYBRID 指紋v2。(感謝 @杜子腾) +* Added China Camery Hybrid FPv2. (Thanks to @杜子腾) +* 新增台灣版 Altis HYBRID 指紋v1。(感謝 @Fish) +* Added Taiwan Altis Hybrid FPv1. (Thanks to @Fish) +* 新增行駛時關閉畫面功能。 +* Added Screen off while driving feature. +* 新增倒車時關閉畫面功能。 +* Added Screen off while reversing feature. +* 新增駕駛介面加入「加速模式」切換鈕。 +* Added acceleration profile toggle onto driving UI. +* 新增自定車型功能,取代指紋暫存功能。 +* Replaced fingerprint cache with custom car model selector. +* 新增可調亮度。 +* Added Brightness changer. +* 新增部分德語支持。(特別感謝 @arne182 提供) +* Added partial de_DE language support (Thanks to @arne182) + +dragonpilot 0.7.4 +======================== +* [2020-04-10] 移除所有的第三方應用改為自動下載。 +* [2020-04-10] 移除「啟用原廠 DSU 模式」、「安全帶檢查」、「車門檢查」開關。 +* [2020-03-31] 還原部分修改代碼以達到 comma ai 安全準則。 (Reverted changes to panda safety code to comply with comma ai safety guideline.) +* [2020-03-31] 調整「啟用原廠 DSU 模式」為踩剎車時會暫時斷開控制 。(Enable Stock DSU Mode will temporary disable controls when brake is pressed.) +* [2020-03-27] 加入波蘭版 2015 Lexus NX200T 支援。(感謝 wabes 提供) +* [2020-03-27] 調整「啟用原廠 DSU 模式」為不再需要 AHB 。(Enable Stock DSU Mode no longer requires "AHB" toggle) +* [2020-03-27] 加入「安全帶檢查」、「車門檢查」、「檔位檢查」、「溫度檢查」開關。 +* [2020-03-27] 加入曲率學習功能 - Curvature Learner 。(感謝 zorrobyte 提供) +* [2020-03-27] 加入大陸版 2018 Toyota Highlander 支援。(感謝 toyboxZ 提供) +* [2020-03-27] 加入大陸版 2018 Toyota Camry 2.0 支援。(感謝 Rming 提供) +* [2020-03-27] 加入韓文支持。(感謝 crwusiz 提供) +* [2020-03-27] 調整 OFFROAD 主頁翻譯將 "dragonpilot" 改回 "openpilot"。 + +dragonpilot 0.7.3 +======================== +* [2020-03-17] 加入動態調整車距功能。(特別感謝 @ShaneSmiskol 提供 PR) +* [2020-03-14] 更新 pt-Br (葡萄牙語) 翻譯。(感謝 berno22 提供) +* [2020-03-14] 加入自動關機開關。(感謝 Rzxd 建議) +* [2020-03-14] 調高 Toyota 扭力容錯值。 +* [2020-03-14] 優化讀取 dp 設定值。 +* [2020-03-14] 加入 2019 手動 Civic 指紋。感謝 (AlexNoop 提供) +* [2020-03-14] dp 功能加入對 Subaru 車系的支援。 +* [2020-03-06] 加入葡萄牙語支持。(感謝 berno22 提供) +* [2020-03-06] 加入大陸 2018 Camry、2020 RAV4 指紋。(感謝 笨木匠 提供) +* [2020-03-04] 加入顯示駕駛監控畫面。 +* [2020-03-04] 加入加速模式選項。(特別感謝 @arne182, @cgw1968-5779 提供 PR) +* [2020-03-04] 修正 shutdownd 在 comma two 可能會不正常關機的錯誤。(感謝 @Wei, @Rzxd 回報) + +dragonpilot 0.7.2 +======================== +* [2020-02-08] dp 功能加入對現代 (Hyundai) 車系的支援。 +* [2020-02-08] 加入神盾測速照相自動啟動的開關。 +* [2020-02-08] 更新高德地圖至 v4.5.0.600053。 +* [2020-02-08] 使用 0.6.6 版的更新系統。 +* [2020-02-08] 修正急剎問題。(感謝 kumar 提供) +* [2020-01-31] 移除行車介面電量、溫度顯示,(修正畫面當機、黑屏問題) +* [2020-01-29] 修正行車介面錯誤。(感謝 深鲸希西 測試;eisenheim、HeatNation 反應) +* [2020-01-23] 加入 Steer Ratio Learner 關閉。(感謝 eisenheim 建議) +* [2020-01-23] 行車介面加入電量、溫度。(感謝 eisenheim 建議) +* [2020-01-23] 優化 appd。 + +dragonpilot 0.7.1 +======================== +* [2020-01-19] 調整 appd 和 ALC 邏輯。 +* [2020-01-14] 加入開機啟動個人熱點。(感謝 eisenheim 建議) +* [2020-01-18] 加入大陸版 2018 Lexus RX300 支援。(感謝 cafe 提供) +* [2020-01-18] 加入 DragonBTG 設定。(感謝 CloudJ、低調哥、歐姓Altis車主 提供) + +dragonpilot 0.7.0 +======================== +* [DEVEL] 更新至最新的 commaai:devel (0.7.0)。 +* [2019-12-29] 輔助/自動變道改為可調整參數 (進階用戶)。(DragonAssistedLCMinMPH、DragonAutoLCMinMPH、DragonAutoLCDelay) +* [2019-12-29] 修正無法運行第三方應用錯誤。(感謝 深鲸希西 反應) +* [2019-12-18] 修正自動換道邏輯。 +* [2019-12-18] 更新 offroad 翻譯。 +* [2019-12-18] 錯誤修正。 +* [2019-12-18] 移除美版 2017 Civic Hatchback 指紋。(與其它車型衝突) +* [2019-12-17] 加入輔助換道開關。(24mph / 40kph 以上) +* [2019-12-17] 加入自動換道開關。(40mph / 65kph 以上) +* [2019-12-17] 加入大陸版 2019 雷凌汽油版指紋。 (感謝 Shell 提供) +* [2019-12-17] 加入大陸版 2019 卡羅拉汽油版指紋。 (感謝 Shell 提供) +* [2019-12-17] 加入美版 2017 Civic Hatchback 指紋。(感謝 CFranHonda 提供) +* [2019-12-10] 加入位智車機模式。 (Waze Mode) +* [2019-11-21] 修正 offroad 翻譯。(感謝 鄧育林 回報) +* [2019-11-21] 調整前車靜止移動偵測參數。 +* [2019-11-21] 前車靜止移動偵測可在未啟用 dp 時運作。 +* [2019-11-18] 修正 offroad 翻譯。(感謝 Cody、鄧育林 回報) +* [2019-11-18] 修正 frame 翻譯。 + +dragonpilot 0.6.6 +======================== +* [2019-11-15] 修正不會充電的錯誤。 (感謝 袁昊 反應) +* [2019-11-15] 修正充電控制。 (感謝 KT 反應) +* [2019-11-15] 更新 frame 翻譯,改為多語言版。 (感謝 深鲸希西、shaoching885、鄧育林 反應) +* [2019-11-12] 只顯示電量文字 (注意:有時不會更新,需要拔插 USB 線) +* [2019-11-12] 自動偵測並鎖定硬體 (EON / UNO)。 +* [2019-11-12] 加入鎖定硬體 (EON / UNO) 的程式碼。 +* [2019-11-11] 更新高德地圖至 v4.3.0.600310 R2098NSLAE +* [2019-11-11] 更新 MiXplorer 至 v6.40.3 +* [2019-11-11] 前車靜止移動偵測加入偵測警示。 +* [2019-11-07] 讓 Bosch 系統顯示三角。 (感謝 ching885 回報) +* [2019-11-07] 更新 offroad 多語言版簡體中文翻譯 (感謝 Rming 提供) +* [2019-11-06] 修正 0.6.6 appd 和 dashcamd 錯誤。 (感謝 鄧育林 回報) + +dragonpilot 0.6.5 +======================== +* [2019-11-05] 加入台灣 Lexus 2017 GS450h 支援。 (感謝 簡銘佑 提供指紋) +* [2019-11-01] 新增神盾測速照相。 (感謝 Sky Chang 和 Wei Yi Chen) +* [2019-11-01] 修正 offroad 翻譯。 (感謝 Leo Hsieh) +* [2019-11-01] 移除 Miui 字型,縮小 dp 使用空間。 +* [2019-11-01] 更新 offroad 為多語言版 +* [2019-10-29] 加入 SnG 補丁。(感謝 楊雅智) +* [2019-10-28] 調整 dragon_allow_gas 邏輯 (請回報任何問題,需更新 Panda 韌體) +* [2019-10-22] 移除強迫網路連線提示。(感謝 Shell) +* [2019-10-18] 加入前車靜止移動偵測。(測試版,感謝 ucolchen) +* [2019-10-18] 移除強迫網路連線提示。(感謝 Shell) +* [2019-10-18] 修正 allow_gas 功能。 +* [2019-10-18] 加入彎道減速功能開關。 +* [2019-10-18] 強迫使用 dp 版 Panda 韌體。 +* [2019-10-17] 加入「車型」顯示於 dp 設定畫面。 +* [2019-10-17] 修正充電控制讀取預設值的錯誤。 +* [2019-10-17] 修正無法顯示更新記錄的錯誤。 +* [2019-10-17] 刷新 Panda 韌體按鈕將會自動重啟 EON。(感謝 鄧育林 建議) +* [2019-10-17] 下載更新記錄時使用 "no-cache" 標頭。 +* [2019-10-17] 更新高德地圖至 v4.3.0 +* [2019-10-14] 啟用自動更新功能。(感謝 鄧育林 提供) +* [2019-10-14] 清除不再使用的 dp params。 +* [2019-10-14] 加入數字電量指示。(感謝 鄧育林 建議) +* [2019-10-14] 加入刷新 Panda 韌體按鈕。 +* [2019-10-11] 加入台灣 2019 RAV4 汽油版指紋。 (感謝 Max Duan / CloudJ 提供) +* [2019-10-11] 加入當 LatCtrl 關閉時,畫面顯示提示訊息。 + +dragonpilot 0.6.4 +======================== +* [2019-10-11] 加入台灣版 2019 RAV4H 油電版指紋。 +* [2019-10-08] 加回駕駛監控開關。 +* [2019-10-07] 加入台灣版 2019 RAV4H 油電版指紋。(感謝 Max Duan 提供) +* [2019-10-05] 移除 curvature learner: 轉角明顯比原廠小。 +* [2019-09-30] 更新 curvature learner 版本至 v4。 +* [2019-09-30] Lexus ISH 使用更精確的 EPS Steering Angle Sensor +* [2019-09-27] 加入 Zorrobyte 的 curvature learner (https://github.com/zorrobyte/openpilot) +* [2019-09-27] 加入可開關駕駛監控的程式碼。 +* [2019-09-27] 取消當 steering 出現錯誤時,自動切斷方向控制 2 秒的機制。 +* [2019-09-27] 讓行車介面的「方向盤」/「轉彎」圖示半透明化。 +* [2019-09-26] 修正當「啟用記錄服務」關閉時,make 會有問題的錯誤。 (感謝 shaoching885 和 afa 回報) +* [2019-09-24] 行車介面加入可開關的「前車」、「路線」、「車道」設定。 +* [2019-09-24] 行車介面加入可開關的「方向燈號」提示。 (感謝 CloudJ 建議,程式碼來源: https://github.com/kegman/openpilot) +* [2019-09-23] 優化讀取 params 的次數。 +* [2019-09-23] 加入可開關的車道偏移警示。 +* [2019-09-23] 修正充電控制邏輯。 +* [2019-09-23] 加入台灣 Prius 4.5 指紋。 (感謝 Lin Hsin Hung 提供) +* [2019-09-20] 加入充電控制功能。 (感謝 loveloveses 和 KT 建議) +* [2019-09-16] 加入台灣 CT200h 指紋。 (感謝 CloudJ 提供) +* [2019-09-16] 加入美版 CT200h 移植。 (感謝 thomaspich 提供) +* [2019-09-13] 行車介面加入可開關的「速度顯示」設定。 +* [2019-09-09] 加入 GreyPanda 模式。 +* [2019-08-28] 加入可調警示音量。 +* [2019-08-27] 自動關機改為可調時長。 + +dragonpilot 0.6.3 +======================== +* [2019-10-11] 加入台灣版 2019 RAV4H 油電版指紋。 \ No newline at end of file diff --git a/CHANGELOGS.md b/CHANGELOGS.md new file mode 100644 index 00000000000000..1414d07fa32095 --- /dev/null +++ b/CHANGELOGS.md @@ -0,0 +1,414 @@ +2020-12-07 (0.8.0.0) +======================== +* 錯誤修正。 +* Bug fixes. + +2020-12-04 (0.8.0.0) +======================== +* 加入 git 錯誤修正。(感謝 @toyboxZ 提供) +* Added git error fix. (Thanks to @toyboxZ) + +2020-12-02 (0.8.0.0) +======================== +* 基於最新 openpilot 0.8.0 devel. +* Based on latest openpilot 0.8.0 devel. + +2020-11-28 (0.7.10.0) +======================== +* 加入來自 afa 的 Honda inspire, accord, crv SnG 優化。(感謝 @menwenliang 提供) +* Added Honda inspire, accord, crv SnG optimisation from afa fork. (Thanks to @menwenliang) +* 加入 dp_toyota_lowest_cruise_override_vego。(感謝 @toyboxZ 提供) +* Added dp_toyota_lowest_cruise_override_vego. (Thanks to @toyboxZ) + +2020-11-20 (0.7.10.0) +======================== +* 加入 Dynamic gas Lite。(感謝 @toyboxZ 提供) +* Added Dynamic Gas Lite. (Thanks to @toyboxZ) + +2020-11-19 (0.7.10.0) +======================== +* 更新所有 honda/hyunda/toyota 指紋。 +* Updated all honda/hyunda/toyota fingerprints. + +2020-11-18 (0.7.10.0) +======================== +* 支援台灣版 2018 Huyndai IONIQ + smart MDPS (dp_hkg_smart_mdps) (感謝 @andy741217 提供) +* Support 2018 Taiwan Hyundai IONIQ + smart MDPS (dp_hkg_smart_mdps) (Thanks to @andy741217) +* 使用 openpilot v0.8 的模型。(感謝 @eisenheim) +* Use openpilot v0.8 model. (Thanks to @eisenheim) +* 加入 0.8 測試版的部分優化。 +* Added optimizations from pre-0.8. +* 加入 dp_honda_eps_mod 設定來使用更高的扭力 (需 eps mod)。(感謝 @Wuxl_369 提供) +* Added dp_honda_eps_mod setting to enable higher torque (eps mod required). (Thanks to @Wuxl_369) +* 修正 VW 對白/灰熊的支援 (感謝 @lirudy 提供) +* Fixed issue with white/grey panda support for VW (Thanks to @lirudy) +* GENESIS_G70 優化 (感謝 @sebastian4k 提供) +* GENESIS_G70 Optimisation (Thanks to @sebastian4k) +* HYUNDAI_GENESIS 優化 (感謝 @donfyffe 提供) +* HYUNDAI_GENESIS Optimisation (Thanks to @donfyffe) + +2020-11-05 (0.7.10.0) +======================== +* HYUNDAI_GENESIS 加入 Cruise 按紐 和 lkMode 支援。(感謝 @donfyffe 建議) +* HYUNDAI_GENESIS added Cruise button event and lkMode feature. (Thanks to @donfyffe) + +2020-11-04 (0.7.10.0) +======================== +* HYUNDAI_GENESIS 使用 INDI 控制器。(感謝 @donfyffe 提供) +* HYUNDAI_GENESIS uses INDI controller. (Thanks to @donfyffe) + +2020-10-30 (0.7.10.0) +======================== +* 基於最新 openpilot 0.7.10 devel. +* Based on latest openpilot 0.7.10 devel. +* 修正 EON 接 PC/USB 充電器時仍會自動關機的錯誤。(感謝 @小愛 回報) +* Fixed auto shutdown issue when EON connect to PC/USB Charger. (Thanks to @LOVEChen) +* 新增大陸版 2018 Inspire 指紋。(感謝 @) +* Added China Camry Hybrid FPv2. (Thanks to @杜子腾) + +2020-10-23 (0.7.9.0) +======================== +* 加入 Headunit Reloaded Android Auto 斷線偵側。 +* Added Disconnect detection for Headunit Reloaded Android Auto. +* 加入 complete_setup.sh (感謝 @深鲸希西 提供) +* Added complete_setup.sh (Thanks to @深鲸希西) + +2020-10-21 (0.7.9.0) +======================== +* 基於最新 openpilot 0.7.9 devel. +* Based on latest openpilot 0.7.9 devel. +* 修正 Prius 特定情況下無法操控方向盤的問題。 +* Fixed unable to regain Prius steering control under certain condition. +* 更新 VW MQB 的支援。(需執行 scripts/vw.sh 腳本) +* Updated support of VW MQB. (scripts/vw.sh script required) +* 加入 HKG mdps/sas 的支援。(需執行 scripts/hkg.sh 腳本) +* Added support to HKG mdps/sas. (scripts/hkg.sh script required) +* 新增 2018 China Toyota CHR 指紋v2。(感謝 @xiaohongcheung 提供) +* Added 2018 China Toyota CHR FPv2. (Thanks to @xiaohongcheung) +* 加入 Headunit Reloaded Android Auto App 支援。(感謝 @Ninjaa 提供) +* Added Headunit Reloaded Android Auto App Support. (Thanks to @Ninjaa) +* 優化 nanovg。(感謝 @piggy 提供) +* Optomized nanovg. (Thanks to @piggy) + +2020-09-25 (0.7.8.0) +======================== +* VW 加入 6 分鐘時間方向盤控制限制輔助方案。(特別感謝 @actuallylemoncurd 提供代碼) +* VW added 6 minutes timebomb assist. (dp_timebomb_assist, special thanks to @actuallylemoncurd) + +2020-09-23 (0.7.8.0) +======================== +* 修正在沒網路的情況下,開機超過五分鐘的問題。 +* Fixed 5+ minutes boot time issue when there is no internet connection. +* 錯誤回傳改使用 dp 的主機。 +* Used dp server for error reporting. +* 更新服務改使用 gitee 的 IP 檢查連線狀態。 +* updated service uses gitee IP address instead. + +2020-09-21 (0.7.8.0) +======================== +* 強制關閉 panda 檢查 DOS 硬體。 +* Force disabled DOS hardware check in panda. + +2020-09-18 (0.7.8.0) +======================== +* gpxd 記錄改自動存成 zip 格式。 +* gpxd now store in zip format. + +2020-09-15 (0.7.8.0) +======================== +* 加入 Honda Jade 支援。(感謝 @李俊灝) +* Added Honda Jade support. (Thanks to @lijunhao731) +* 修正 ui.cc 內存越界的問題。(感謝 @piggy 提供) +* Fixed ui.cc memory out of bound issue. (Thanks to @piggy) + +2020-09-01 (0.7.8.0) +======================== +* 加入 ko-KR 翻譯。 +* Added ko-KR translation. + +2020-08-21 (0.7.8.0) +======================== +* 基於最新 openpilot 0.7.8 devel. +* Based on latest openpilot 0.7.8 devel. +* 加入重置 DP 設定按鈕。(感謝 @LOVEChen 建議) +* Added "Reset DP Settings" button. (Thanks to @LOVEChen) +* 將警示訊息更改為類似於概念 UI 的設計。 +* Alert messages changed to concept UI alike design. +* 當 manager 出現錯誤後,按 Exit 按鈕會執行 reset_update 腳本。 +* Added ability to execute reset_update.sh when press "Exit" button once manager returned errors. + +2020-08-18 (0.7.7.0) +======================== +* gpxd 不再切換至 GCJ-02 格式。(感謝 @arne182 建議) +* gpxd no longer switch to GCJ-02 format automatically. (Thanks to @arne182) +* 修正方向盤監控。 +* Fixed steering monitor timer param. +* 修正行駛時關閉畫面導致當機的錯誤。(感謝 @salmankhan, @stevej99, @bobbydough 回報) +* Fixed screen frozen issue when "screen off while driving" toggle is enabled. (Thanks to @salmankhan, @stevej99, @bobbydough) +* 加回 Dev Mini UI 開關。(感謝 @Ninjaa 建議) +* Re-added Dev Mini UI. (Thanks to @Ninjaa) + +2020-08-17 (0.7.7.0) +======================== +* gpxd 只儲存高精度數據。(感謝 @arne182) +* gpxd now only stored high accuracy data. (Thanks to @arne182) +* gpxd 加入自動切換成 GCJ-02 格式。 +* added ability to switch to GCJ-02 format in gpxd. +* 新增 (dp_reset_live_parameters_on_start) 每次發車重設 LiveParameters 值。(感謝 @eisenheim) +* Added ability (dp_reset_live_param_on_start) to reset LiveParameters on each start. (Thanks @eisenheim) + +2020-08-12 (0.7.7.0) +======================== +* 修正同時開啟 dp_toyota_zss 和 dp_lqr 產生的錯誤。(感謝 @bobbydough) +* Fixed error cuased by enabling both dp_toyota_zss and dp_lqr at the same time. (Thanks to @bobbydough) + +2020-08-12 (0.7.7.0) +======================== +* 新增 (dp_gpxd) 將 GPS 軌跡導出至 GPX 格式 (/sdcard/gpx_logs/)的功能。 (感謝 @mageymoo1) +* Added ability (dp_gpxd) to export GPS track into GPX files (/sdcard/gpx_logs/). (Thanks to @mageymoo1) +* 使用德國的車道寬度估算值。 (感謝 @arne182) +* Used lane width estimate value from Germany. (Thanks to @arne182) + +2020-08-11 (0.7.7.0) +======================== +* 加入 d_poly offset。 (感謝 @ShaneSmiskol) +* Added d_poly offset. (Thanks to @ShaneSmiskol) + +2020-08-05 (0.7.7.0) +======================== +* 修正 Dev UI 顯示。 +* Fixed Dev UI display. +* 加入 LQR 控制器開關進設定畫面。 +* Added LQR Controller toggle to settings. + +2020-08-04 (0.7.7.0) +======================== +* 嘗試修正非 Toyota 使用 lqr 產生的錯誤。 +* Attempted to fix lqr issue on non-Toyota Cars. +* 加入錯誤記錄至 /sdcard/crash_logs/ (感謝 @ShaneSmiskol 提供代碼) +* Added error logs to /sdcard/crash_logs/ (Special Thanks to @ShaneSmiskol) + +2020-08-02 (0.7.7.0) +======================== +* 加入 ZSS 支援。(感謝 @bobbydough, @WilliamPrius 建議, @bobbydough 測試) +* Added ZSS support. (Thanks to @bobbydough, @WilliamPrius for recommendation, @bobbydough for testing) + +2020-07-28 (0.7.7.0) +======================== +* 修正 steer ratio learner 關閉。(感謝 @Mojo 回報, @ShaneSmiskol 提供代碼) +* Fixed steer ratio learner toggle. (Thanks to @Mojo, @ShaneSmiskol) +* 加入 "dp_lqr" 設定來強制使用 RAV4 的 lqr 調校。(感謝 @eisenheim) +* Added "dp_lqr" setting to force enable lqr tuning from RAV4. (Thanks to eisenheim) + +2020-07-28 (0.7.7.0) +======================== +* 修正無法上傳記錄的問題。(感謝 @Mojo) +* Fixed unable to upload log issue. (Thanks to @Mojo) +* 修正無法關閉警示音的問題。(感謝 @Mojo) +* Fixed unable to disable audio alert (-100%) issue. ($Thanks to @Mojo) + +2020-07-27 (0.7.7.0) +======================== +* 加入回調校介面。(感謝 @Kent) +* Re-added Dev UI. (Thanks to @Kent) + +2020-07-27 (0.7.7.0) +======================== +* 加入 C2 風扇靜音模式。(感謝 @dingliangxue) +* Added C2 quiet fan mode. (Thanks to @dingliangxue) +* 加入「輔助換道最低啟動速度」、「自動換道最低啟動速度」設定。 +* Added "Assisted Lane Change Min Engage Speed" and "Auto Lane Change Min Engage Speed" settings. + +2020-07-23 (0.7.7.0) +======================== +* 修正 appd。(感謝 @cgw1968) +* Fixed appd. (Thanks to @cgw1968) + +2020-07-22 (0.7.7.0) +======================== +* 修正 waze 顯示。(感謝 @Mojo) +* Fixed waze display. (Thanks to @Mojo) +* 加回彎道減速功能。(感謝 @Mojo) +* re-added Slow On Curve functionality. (Thanks to @Mojo) +* 加入日文支援。(特別感謝 @ponzu07 提供) +* Added Japanese support. (Special thanks to @ponzu07) +* 刪除部分設定對 dp_steering_on_signal 的依賴。 +* Removed dp_steering_on_signal dependencies. +* 介面加入盲點偵測顯示。(感謝 @wabes) +* Added BSM indicator to UI. (Thanks to @wabes) + +2020-07-21 (0.7.7.0) +======================== +* Toyota 加入改寫最低巡航速度功能。(感謝 @Mojo) +* Added Toyota to override lowest cruise speed. (Thanks to @Mojo) +* 修正 gm 錯誤。 +* Fixed bugs in gm cars. + +2020-07-20 (0.7.7.0) +======================== +* 加回 加速模式 開關。 +* Re-added Accel Profile toggle. +* 修正 gm 錯誤。 +* Fixed bugs in gm cars. + +2020-07-19 (0.7.7.0) +======================== +* 限制 dp_conf int / float 範圍。 +* Limited dp_conf int/float range. +* 修復行車記錄文件夾不存在的錯誤。 +* Fixed dashcam folder not exist error. + +2020-07-18 (0.7.7.0) +======================== +* 優化 camera offset 讀取。 +* optomised loading camera offset value. +* 更換模型延遲警示為一般警示。 +* Replaced model lagging loud alert to normal alert. + +2020-07-17 (0.7.7.0) +======================== +* 更新至最新 openpilot 0.7.7 devel。 +* Updated to latest openpilot 0.7.7 devel. + +2020-07-17 (0.7.7.0) +======================== +* 當 Manager 出現錯誤時,顯示 IP 位置。(感謝 @dingliangxue) +* When Manager failed, display IP address. (Thanks to @dingliangxue) +* 加回 sr learner 開關。 +* Re-added sr learner toggle. + +2020-07-13 (0.7.7.0) +======================== +* 基於最新 openpilot 0.7.7 devel. +* Based on latest openpilot 0.7.7 devel. + +2020-06-22 (0.7.6.1) +======================== +* 更新至 openpilot 0.7.6.1。 (特別感謝 @rockindy 協助更新) +* Updated to openpilot 0.7.6.1. (Special thanks to @rockindy for initial merge) +* 優化並整合 dp 服務。 (所有的設定檔已改名,請重新設定所有的功能) +* Optimized and integrated several dp services. (Settings have been renamed, please re-config all settings) +* 完全關閉 steer ratio learner。 +* Completely disabled steer ratio learner. +* 移除「加速模式」。 +* Removed Accel Profile. +* 加入本田皓影混電版指紋v1。(感謝 @劉駿) +* Added Honda Breeze Hybrid FPv1. (Thanks to @劉駿) +* 加入台灣版 Toyota Prius 4.5 指紋v1。(感謝 @jeekid) +* Added Taiwan Toyota Prius 4.5 FPv1. (Thanks to @jeekid) + +2020-06-18 (0.7.5) +======================== +* Dynamic Follow 更新模型。(感謝 @ShaneSmiskol 提供代碼、 @cgw1968 測試) +* Updated Dynamic Follow model. (Special Thanks to @ShaneSmiskol for the feature and @cgw1968 for testing) + +2020-05-30 (0.7.5) +======================== +* Dynamic Follow 更新至 ShaneSmiskol:stock_additions 0.7.5 版。(感謝 @ShaneSmiskol 提供代碼、 @Wei 測試) +* Updated Dynamic Follow to ShaneSmiskol:stock_additions 0.7.5. (Special Thanks to @ShaneSmiskol for the feature and @Wei for testing) + +2020-05-28 (0.7.5) +======================== +* 優化 Lexus GSH 轉向。(感謝 @簡銘佑 測試) +* Optimize Lexus GSH steering. (Thanks to @簡銘佑) +* C2 支援自動關機「DragonAutoShutdownAt」參數。(感謝 @cgw1968 建議) +* C2 to support auto shutdown "DragonAutoShutDownAt" param. (Thanks to @cgw1968) +* 修正出現「pedalPressed」的錯誤。(感謝 @Wei 回報) +* Fixed issue showing "pedalPressed" error. (Thanks to @Wei) + +2020-05-26 (0.7.5) +======================== +* 將剎車狀熊顯示於 dp 資訊欄。 +* Added brake indicator to dp infobar. +* 修正「溫度監控」燈示。 +* Fixed "Temp monitor" indicator. +* 加入「方向燈取消控制」延遲控制設。(感謝 @wabes 建議) +* Added delay config to "Disable Lat Control on Blinker". (Thanks to @wabes) +* 加入巴西版 2020 Corolla Hybrid 指紋v2。(感謝 @berno22 提供) +* Added Brazil 2020 Corolla Hybrid FPv2. (Thanks to @berno22) + +2020-05-25 (0.7.5) +======================== +* 加入對 VW MQB/PQ 的支援。(感謝 @dingliangxue 移植) +* Added support to VW MQB/PQ platform. (Thanks to @dingliangxue) + +2020-05-21 (0.7.5) +======================== +* 修改成 3 小時後停止供電。(感謝 @Wei 建議) +* Updated to stop charging after 3 hrs. (Thanks to @Wei) +* 移除行車記錄下的「碰撞偵測」功能。 +* Removed Impact Detection in Dashcam. +* 修正開啟「Noctua 風扇」模式導致的錯誤。(感謝 @阿濤 回報) +* Fixed a bug caused by enabling "Noctua Mod". (Thanks to @阿濤) +* 修正「位智模式」無法顯示警示的問題。(感謝 @axandres 回報) +* Fixed alert issue in waze mode. (Thanks to @axandres) +* 修正無法顯示更新中圖示的問題。 +* Fixed unable to display "UPDATING" icon issue. + +2020-05-20 (0.7.5) +======================== +* 加入「允許多次自動換道」功能。(感謝 @阿濤 建議) +* Added "Allow Continuous Auto Lane Change" Toggle. (Thanks to @阿濤) +* 修正開機後設定頁面有時會錯誤的問題。(感謝 @salmankhan、@Wei 回報) +* Fixed setting page crash issue. (Thanks to @salmankhan, @Wei) +* 修正熄火後一直出現更新訊息的錯誤。(感謝 @Sky Chang 回報) +* Fixed issue that keep showing update prompt. (Thanks to @Sky Chang) + +2020-05-19 (0.7.5) +======================== +* 加入 DragonEnableAutoUpdate 預設值。 +* Added DragonEnableAutoUpdate default value. + +2020-05-18 (0.7.5) +======================== +* 修正因同時使用「社群功能」和「自定車型」造成的加減速問題。(特別感謝 @Wei、@Sky Chang、@Han9365、@鄧育林 的測試以及回報。) +* Fixed acceleration issue caused by used of both "Community Maintain Feature" and "Custom Car Model" + +2020-05-16 (0.7.5) +======================== +* 新增 DragonMaxSpeedLimit 設定值 (mph),當如果車速高於此值 op 將會停止操控。(感謝 @Anthony 建議) +* Added DragonMaxSpeedLimit parameter (mph), op will stop controlling when car speed is high than the value. (Thanks to @Anthony) +* 更新 appd 使用 cnpmjs 來下載 APKs。 +* Updated appd to use cnpmjs to download APKs. +* 修正更新服務。(感謝 @Wei) +* Fixed Update Service. (Thanks to @Wei) +* 新增加拿大版 2018 Toyota Sienna LTD 指紋(v2)。(感謝 明峰 提供) +* Added Canada 2018 Toyota Sienna LTD fingerprint (v2). (Thanks to 明峰) + +2020-05-15 (0.7.5) +======================== +* 新增「通過移動網路上傳」開關 +* Added Upload Over Mobile Network toggle. +* 新增「通過熱點上傳」開關 +* Added Upload Over Hotspot toggle. +* 新增加拿大版 2018 Toyota Sienna LTD 指紋(v1)。(感謝 明峰 提供) +* Added Canada 2018 Toyota Sienna LTD fingerprint (v1). (Thanks to 明峰) +* 新增大陸版 Volkswagen Golf GTI 指紋 (v1)。(感謝 easyeiji 提供) +* Added China Volkswagen Golf GTI fingerprint (v1). (Thanks to easyeiji) + +2020-05-10 +======================== +* 基於最新 openpilot 0.7.5 devel-staging. +* Based on latest openpilot 0.7.5 devel-staging. +* 更新 dp 圖示 (特別感謝 @wabes 的設計與提供)。 +* Updated dp logo, special thanks to @wabes for the design. +* 簡/繁中文版和 i18n 整合成為單一版本。 +* Merged zhs/zht/i18n versions into one. +* 新增大陸版 CAMRY HYBRID 指紋v2。(感謝 @杜子腾) +* Added China Camry Hybrid FPv2. (Thanks to @杜子腾) +* 新增台灣版 Altis HYBRID 指紋v1。(感謝 @Fish) +* Added Taiwan Altis Hybrid FPv1. (Thanks to @Fish) +* 新增行駛時關閉畫面功能。 +* Added Screen off while driving feature. +* 新增倒車時關閉畫面功能。 +* Added Screen off while reversing feature. +* 新增駕駛介面加入「加速模式」切換鈕。 +* Added acceleration profile toggle onto driving UI. +* 新增自定車型功能,取代指紋暫存功能。 +* Replaced fingerprint cache with custom car model selector. +* 新增可調亮度。 +* Added Brightness changer. +* 新增部分德語支持。(特別感謝 @arne182 提供) +* Added partial de_DE language support (Thanks to @arne182) +* 新增停車碰撞偵測記錄功能。 +* Added off road impact detection to dashcam. \ No newline at end of file diff --git a/apk/ai.comma.plus.offroad.apk b/apk/ai.comma.plus.offroad.apk index 90570253edabdb..b26a5662d2208f 100644 Binary files a/apk/ai.comma.plus.offroad.apk and b/apk/ai.comma.plus.offroad.apk differ diff --git a/cereal/car.capnp b/cereal/car.capnp index 4e4f9e7564a6cd..8a443805ae4dd1 100644 --- a/cereal/car.capnp +++ b/cereal/car.capnp @@ -117,6 +117,18 @@ struct CarEvent @0x9b1657f34caf3ad3 { focusRecoverActiveDEPRECATED @86; neosUpdateRequiredDEPRECATED @88; modelLagWarningDEPRECATED @93; + + #dp + preLaneChangeLeftALC @94; + preLaneChangeRightALC @95; + manualSteeringRequired @96; + manualSteeringRequiredBlinkersOn @97; + leadCarMoving @98; + + # timebomb assist + timebombWarn @99; + timebombBypassing @100; + timebombBypassed @101; } } @@ -184,6 +196,10 @@ struct CarState { leftBlindspot @33 :Bool; # Is there something blocking the left lane change rightBlindspot @34 :Bool; # Is there something blocking the right lane change + # dp + lkMode @37 :Bool; + stopSteering @38 :Bool; # timebomb - stopSteering + struct WheelSpeeds { # optional wheel speeds fl @0 :Float32; diff --git a/cereal/log.capnp b/cereal/log.capnp index bbf6a6be0fae11..6128f788164d29 100644 --- a/cereal/log.capnp +++ b/cereal/log.capnp @@ -874,6 +874,9 @@ struct PathPlan { laneChangeState @18 :LaneChangeState; laneChangeDirection @19 :LaneChangeDirection; + # dp + dpALCAllowed @20 :Bool; + enum Desire { none @0; turnLeft @1; @@ -2138,5 +2141,84 @@ struct Event { modelV2 @75 :ModelDataV2; frontEncodeIdx @76 :EncodeIndex; # driver facing camera wideEncodeIdx @77 :EncodeIndex; + dragonConf @78 :DragonConf; } } + +struct DragonConf { + dpThermalStarted @0 :Bool; + dpThermalOverheat @1 :Bool; + dpVw @2 :Bool; + dpAtl @3 :Bool; + dpAppWaze @4 :Bool; + dpAppWazeManual @5 :Int8; + dpAppHr @6 :Bool; + dpAppHrManual @7 :Int8; + dpDashcam @8 :Bool; + dpDashcamHoursStored @9 :UInt8; + dpAutoShutdown @10 :Bool; + dpAthenad @11 :Bool; + dpUploader @12 :Bool; + dpLatCtrl @13 :Bool; + dpSteeringLimitAlert @14 :Bool; + dpSteeringOnSignal @15 :Bool; + dpSignalOffDelay @16 :UInt8; + dpAssistedLcMinMph @17 :Float32; + dpAutoLc @18 :Bool; + dpAutoLcCont @19 :Bool; + dpAutoLcMinMph @20 :Float32; + dpAutoLcDelay @21 :Float32; + dpSlowOnCurve @22 :Bool; + dpAllowGas @23 :Bool; + dpMaxCtrlSpeed @24 :Float32; + dpLeadCarAlert @25 :Bool; + dpDynamicFollow @26 :UInt8; + dpAccelProfile @27 :UInt8; + dpDriverMonitor @28 :Bool; + dpSteeringMonitor @29 :Bool; + dpSteeringMonitorTimer @30 :UInt8; + dpGearCheck @31 :Bool; + dpDrivingUi @32 :Bool; + dpUiScreenOffReversing @33 :Bool; + dpUiScreenOffDriving @34 :Bool; + dpUiSpeed @35 :Bool; + dpUiEvent @36 :Bool; + dpUiMaxSpeed @37 :Bool; + dpUiFace @38 :Bool; + dpUiLane @39 :Bool; + dpUiPath @40 :Bool; + dpUiLead @41 :Bool; + dpUiDev @42 :Bool; + dpUiDevMini @43 :Bool; + dpUiBlinker @44 :Bool; + dpUiBrightness @45 :UInt8; + dpUiVolumeBoost @46 :Int8; + dpAppAutoUpdate @47 :Bool; + dpAppExtGps @48 :Bool; + dpAppTomtom @49 :Bool; + dpAppTomtomAuto @50 :Bool; + dpAppTomtomManual @51 :Int8; + dpAppAutonavi @52 :Bool; + dpAppAutonaviAuto @53 :Bool; + dpAppAutonaviManual @54 :Int8; + dpAppAegis @55 :Bool; + dpAppAegisAuto @56 :Bool; + dpAppAegisManual @57 :Int8; + dpAppMixplorer @58 :Bool; + dpAppMixplorerManual @59 :Int8; + dpCarDetected @60 :Text; + dpToyotaLdw @61 :Bool; + dpToyotaSng @62 :Bool; + dpToyotaLowestCruiseOverride @63 :Bool; + dpToyotaLowestCruiseOverrideVego @64 :Bool; + dpToyotaLowestCruiseOverrideAt @65 :Float32; + dpToyotaLowestCruiseOverrideSpeed @66 :Float32; + dpIpAddr @67 :Text; + dpCameraOffset @68 :Int8; + dpLocale @69 :Text; + dpChargingCtrl @70 :Bool; + dpChargingAt @71 :UInt8; + dpDischargingAt @72 :UInt8; + dpIsUpdating @73 :Bool; + dpTimebombAssist @74 :Bool; +} \ No newline at end of file diff --git a/cereal/service_list.yaml b/cereal/service_list.yaml index b140251cf8ca71..b95ce6251e635d 100644 --- a/cereal/service_list.yaml +++ b/cereal/service_list.yaml @@ -81,6 +81,8 @@ wideEncodeIdx: [8075, true, 20.] wideFrame: [8076, true, 20.] modelV2: [8077, true, 20., 20] +dragonConf: [8088, false, 2.] + testModel: [8040, false, 0.] testLiveLocation: [8045, false, 0.] testJoystick: [8056, false, 0.] diff --git a/common/dp_common.py b/common/dp_common.py new file mode 100644 index 00000000000000..d5f53246a58923 --- /dev/null +++ b/common/dp_common.py @@ -0,0 +1,80 @@ +#!/usr/bin/env python3.7 +import subprocess +from cereal import car +from common.params import Params +from common.realtime import sec_since_boot +import os +params = Params() +PARAM_PATH = "/data/params/d/" +LAST_MODIFIED = PARAM_PATH + "dp_last_modified" + +def is_online(): + try: + return not subprocess.call(["ping", "-W", "4", "-c", "1", "117.28.245.92"]) + except ProcessLookupError: + return False + +def common_controller_ctrl(enabled, dragonconf, blinker_on, steer_req, v_ego): + if enabled: + if (dragonconf.dpSteeringOnSignal and blinker_on) or not dragonconf.dpLatCtrl: + steer_req = 0 if isinstance(steer_req, int) else False + return steer_req + +def common_interface_atl(ret, atl): + # dp + enable_acc = ret.cruiseState.enabled + if atl and ret.cruiseState.available: + enable_acc = True + if ret.gearShifter in [car.CarState.GearShifter.reverse, car.CarState.GearShifter.park]: + enable_acc = False + if ret.seatbeltUnlatched or ret.doorOpen: + enable_acc = False + return enable_acc + +def common_interface_get_params_lqr(ret): + if params.get('dp_lqr') == b'1': + ret.lateralTuning.init('lqr') + ret.lateralTuning.lqr.scale = 1500.0 + ret.lateralTuning.lqr.ki = 0.05 + + ret.lateralTuning.lqr.a = [0., 1., -0.22619643, 1.21822268] + ret.lateralTuning.lqr.b = [-1.92006585e-04, 3.95603032e-05] + ret.lateralTuning.lqr.c = [1., 0.] + ret.lateralTuning.lqr.k = [-110.73572306, 451.22718255] + ret.lateralTuning.lqr.l = [0.3233671, 0.3185757] + ret.lateralTuning.lqr.dcGain = 0.002237852961363602 + return ret + + +def get_last_modified(delay, old_check, old_modified): + new_check = sec_since_boot() + if old_check is None or new_check - old_check >= delay: + return new_check, os.stat(LAST_MODIFIED).st_mtime + else: + return old_check, old_modified + +def param_get_if_updated(param, type, old_val, old_modified): + try: + modified = os.stat(PARAM_PATH + param).st_mtime + except OSError: + return old_val, old_modified + if old_modified != modified: + new_val = param_get(param, type, old_val) + new_modified = modified + else: + new_val = old_val + new_modified = old_modified + return new_val, new_modified + +def param_get(param_name, type, default): + try: + val = params.get(param_name, encoding='utf8').rstrip('\x00') + if type == 'bool': + val = val == '1' + elif type == 'int': + val = int(val) + elif type == 'float': + val = float(val) + except (TypeError, ValueError): + val = default + return val diff --git a/common/dp_conf.py b/common/dp_conf.py new file mode 100644 index 00000000000000..4690f0601eac58 --- /dev/null +++ b/common/dp_conf.py @@ -0,0 +1,249 @@ +#!/usr/bin/env python3.7 +import os +import json +import time +from math import floor + +''' +* type: Bool, Int8, UInt8, UInt16, Float32 +* conf_type: param, struct +* dependencies needs to use struct and loaded prior so we don't have to read the param multiple times. +* update_once: True, False (the param will only load up once.) +''' +confs = [ + # thermald data + {'name': 'dp_thermal_started', 'default': False, 'type': 'Bool', 'conf_type': ['struct']}, + {'name': 'dp_thermal_overheat', 'default': False, 'type': 'Bool', 'conf_type': ['struct']}, + + # car specific + {'name': 'dp_vw', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct'], 'update_once': True}, + + {'name': 'dp_atl', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct'], 'update_once': True}, + # full screen apps + {'name': 'dp_app_waze', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_waze_manual', 'default': 0, 'type': 'Int8', 'min': -1, 'max': 1, 'depends': [{'name': 'dp_app_waze', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_hr', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_hr_manual', 'default': 0, 'type': 'Int8', 'min': -1, 'max': 1, 'depends': [{'name': 'dp_app_hr', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + # dashcam related + {'name': 'dp_dashcam', 'default': 0, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_dashcam_hours_stored', 'default': 24, 'type': 'UInt8', 'min': 1, 'max': 255, 'depends': [{'name': 'dp_dashcam', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + # auto shutdown + {'name': 'dp_auto_shutdown', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_auto_shutdown_in', 'default': 90, 'type': 'UInt16', 'min': 1, 'max': 65535, 'depends': [{'name': 'dp_auto_shutdown', 'vals': [True]}], 'conf_type': ['param']}, + # service + {'name': 'dp_logger', 'default': True, 'type': 'Bool', 'conf_type': ['param']}, + {'name': 'dp_athenad', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_uploader', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_upload_on_mobile', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_uploader', 'vals': [True]}], 'conf_type': ['param']}, + {'name': 'dp_upload_on_hotspot', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_uploader', 'vals': [True]}], 'conf_type': ['param']}, + {'name': 'dp_updated', 'default': True, 'type': 'Bool', 'conf_type': ['param']}, + {'name': 'dp_gpxd', 'default': False, 'type': 'Bool', 'conf_type': ['param']}, + {'name': 'dp_hotspot_on_boot', 'default': False, 'type': 'Bool', 'conf_type': ['param']}, + # lat ctrl + {'name': 'dp_lat_ctrl', 'default': True, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_steering_limit_alert', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_lat_ctrl', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_steering_on_signal', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_lat_ctrl', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_signal_off_delay', 'default': 0, 'type': 'UInt8', 'min': 0, 'max': 10, 'conf_type': ['param', 'struct']}, + # assist/auto lane change + {'name': 'dp_assisted_lc_min_mph', 'default': 45, 'type': 'Float32', 'min': 0, 'max': 255., 'conf_type': ['param', 'struct']}, + {'name': 'dp_auto_lc', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_auto_lc_cont', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_auto_lc', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_auto_lc_min_mph', 'default': 60, 'type': 'Float32', 'min': 0, 'max': 255., 'depends': [{'name': 'dp_auto_lc', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_auto_lc_delay', 'default': 3, 'type': 'Float32', 'min': 0, 'max': 10., 'depends': [{'name': 'dp_auto_lc', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + # long ctrl + {'name': 'dp_slow_on_curve', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_allow_gas', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_max_ctrl_speed', 'default': 92., 'type': 'Float32', 'conf_type': ['param', 'struct']}, + {'name': 'dp_lead_car_alert', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_lead_car_away_alert', 'default': True, 'type': 'Bool', 'conf_type': ['param']}, + {'name': 'dp_dynamic_follow', 'default': 0, 'type': 'UInt8', 'min': 0, 'max': 4, 'depends': [{'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_dynamic_follow_multiplier', 'default': 1., 'type': 'Float32', 'min': 0.85, 'max': 1.2, 'depends': [{'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param']}, + {'name': 'dp_dynamic_follow_min_tr', 'default': 0.9, 'type': 'Float32', 'min': 0.85, 'max': 1.6, 'depends': [{'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param']}, + {'name': 'dp_dynamic_gas', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param']}, + {'name': 'dp_accel_profile', 'default': 0, 'type': 'UInt8', 'min': 0, 'max': 3, 'depends': [{'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + # safety + {'name': 'dp_driver_monitor', 'default': True, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_steering_monitor', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_driver_monitor', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_steering_monitor_timer', 'default': 70, 'type': 'UInt8', 'min': 70, 'max': 360, 'depends': [{'name': 'dp_driver_monitor', 'vals': [False]}, {'name': 'dp_steering_monitor', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_gear_check', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_temp_monitor', 'default': True, 'type': 'Bool', 'conf_type': ['param']}, + # UIs + {'name': 'dp_driving_ui', 'default': True, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_screen_off_reversing', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_screen_off_driving', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_app_waze', 'vals': [False]}, {'name': 'dp_app_hr', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_speed', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_driving_ui', 'vals': [True]}, {'name': 'dp_ui_screen_off_driving', 'vals': [False]}, {'name': 'dp_app_waze', 'vals': [False]}, {'name': 'dp_app_hr', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_event', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_driving_ui', 'vals': [True]}, {'name': 'dp_ui_screen_off_driving', 'vals': [False]}, {'name': 'dp_app_waze', 'vals': [False]}, {'name': 'dp_app_hr', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_max_speed', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_driving_ui', 'vals': [True]}, {'name': 'dp_ui_screen_off_driving', 'vals': [False]}, {'name': 'dp_app_waze', 'vals': [False]}, {'name': 'dp_app_hr', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_face', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_driving_ui', 'vals': [True]}, {'name': 'dp_driver_monitor', 'vals': [True]}, {'name': 'dp_ui_screen_off_driving', 'vals': [False]}, {'name': 'dp_app_waze', 'vals': [False]}, {'name': 'dp_app_hr', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_lane', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_driving_ui', 'vals': [True]}, {'name': 'dp_ui_screen_off_driving', 'vals': [False]}, {'name': 'dp_app_waze', 'vals': [False]}, {'name': 'dp_app_hr', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_path', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_driving_ui', 'vals': [True]}, {'name': 'dp_ui_screen_off_driving', 'vals': [False]}, {'name': 'dp_app_waze', 'vals': [False]}, {'name': 'dp_app_hr', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_lead', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_driving_ui', 'vals': [True]}, {'name': 'dp_ui_screen_off_driving', 'vals': [False]}, {'name': 'dp_app_waze', 'vals': [False]}, {'name': 'dp_app_hr', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_dev', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_dev_mini', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_blinker', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_driving_ui', 'vals': [True]}, {'name': 'dp_ui_screen_off_driving', 'vals': [False]}, {'name': 'dp_app_waze', 'vals': [False]}, {'name': 'dp_app_hr', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_brightness', 'default': 0, 'type': 'UInt8', 'min': 0, 'max': 100, 'conf_type': ['param', 'struct']}, + {'name': 'dp_ui_volume_boost', 'default': 0, 'type': 'Int8', 'min': -100, 'max': 100, 'conf_type': ['param', 'struct']}, + # Apps + {'name': 'dp_app_auto_update', 'default': True, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_ext_gps', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_tomtom', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_tomtom_auto', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_app_tomtom', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_tomtom_manual', 'default': 0, 'type': 'Int8', 'min': -1, 'max': 1, 'depends': [{'name': 'dp_app_tomtom', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_autonavi', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_autonavi_auto', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_app_autonavi', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_autonavi_manual', 'default': 0, 'type': 'Int8', 'min': -1, 'max': 1, 'depends': [{'name': 'dp_app_autonavi', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_aegis', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_aegis_auto', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_app_aegis', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_aegis_manual', 'default': 0, 'type': 'Int8', 'min': -1, 'max': 1, 'depends': [{'name': 'dp_app_aegis', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_mixplorer', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_app_mixplorer_manual', 'default': 0, 'type': 'Int8', 'min': -1, 'max': 1, 'depends': [{'name': 'dp_app_mixplorer', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + # custom car + {'name': 'dp_car_selected', 'default': '', 'type': 'Text', 'conf_type': ['param']}, + {'name': 'dp_car_list', 'default': '', 'type': 'Text', 'conf_type': ['param']}, + {'name': 'dp_car_detected', 'default': '', 'type': 'Text', 'conf_type': ['param', 'struct']}, + # toyota + {'name': 'dp_toyota_ldw', 'default': True, 'type': 'Bool', 'depends': [{'name': 'dp_car_detected', 'vals': ['toyota']}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_toyota_sng', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_car_detected', 'vals': ['toyota']}, {'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_toyota_zss', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_car_detected', 'vals': ['toyota']}], 'conf_type': ['param']}, + {'name': 'dp_toyota_lowest_cruise_override', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_car_detected', 'vals': ['toyota']}, {'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_toyota_lowest_cruise_override_vego', 'default': False, 'type': 'Bool', 'depends': [{'name': 'dp_car_detected', 'vals': ['toyota']}, {'name': 'dp_atl', 'vals': [False]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_toyota_lowest_cruise_override_at', 'default': 44, 'type': 'Float32', 'depends': [{'name': 'dp_car_detected', 'vals': ['toyota']}, {'name': 'dp_toyota_lowest_cruise_override', 'vals': [True]}], 'min': 0, 'max': 255., 'conf_type': ['param', 'struct']}, + {'name': 'dp_toyota_lowest_cruise_override_speed', 'default': 32, 'type': 'Float32', 'depends': [{'name': 'dp_car_detected', 'vals': ['toyota']}, {'name': 'dp_toyota_lowest_cruise_override_speed', 'vals': [True]}], 'min': 0, 'max': 255., 'conf_type': ['param', 'struct']}, + # hyundai + {'name': 'dp_hkg_smart_mdps', 'default': False, 'type': 'Bool', 'conf_type': ['param']}, + # honda + {'name': 'dp_honda_eps_mod', 'default': False, 'type': 'Bool', 'conf_type': ['param']}, + #misc + {'name': 'dp_ip_addr', 'default': '', 'type': 'Text', 'conf_type': ['struct']}, + {'name': 'dp_full_speed_fan', 'default': False, 'type': 'Bool', 'conf_type': ['param']}, + {'name': 'dp_uno_fan_mode', 'default': False, 'type': 'Bool', 'conf_type': ['param']}, + {'name': 'dp_last_modified', 'default': str(floor(time.time())), 'type': 'Text', 'conf_type': ['param']}, + {'name': 'dp_camera_offset', 'default': 6, 'type': 'Int8', 'min': -255, 'max': 255, 'conf_type': ['param', 'struct']}, + + {'name': 'dp_locale', 'default': 'en-US', 'type': 'Text', 'conf_type': ['param', 'struct'], 'update_once': True}, + {'name': 'dp_disable_relay', 'default': False, 'type': 'Bool', 'conf_type': ['param']}, + {'name': 'dp_charging_ctrl', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + {'name': 'dp_charging_at', 'default': 60, 'type': 'UInt8', 'min': 0, 'max': 100, 'depends': [{'name': 'dp_charging_ctrl', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_discharging_at', 'default': 70, 'type': 'UInt8', 'min': 0, 'max': 100, 'depends': [{'name': 'dp_charging_ctrl', 'vals': [True]}], 'conf_type': ['param', 'struct']}, + {'name': 'dp_reg', 'default': True, 'type': 'Bool', 'conf_type': ['param']}, + {'name': 'dp_is_updating', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, + + {'name': 'dp_sr_learner', 'default': True, 'type': 'Bool', 'conf_type': ['param']}, + {'name': 'dp_lqr', 'default': False, 'type': 'Bool', 'conf_type': ['param']}, + {'name': 'dp_reset_live_param_on_start', 'default': False, 'type': 'Bool', 'conf_type': ['param']}, + {'name': 'dp_timebomb_assist', 'default': False, 'type': 'Bool', 'conf_type': ['param', 'struct']}, +] + +def get_definition(name): + for conf in confs: + if conf['name'] == name: + return conf + return None + +def to_param_val(name, val): + conf = get_definition(name) + if conf is not None: + type = conf['type'].lower() + try: + if 'bool' in type: + val = '1' if val else '0' + elif 'int' in type: + val = int(val) + elif 'float' in type: + val = float(val) + return str(val) + except (ValueError, TypeError): + return '' + return '' + +def to_struct_val(name, val): + conf = get_definition(name) + if conf is not None: + try: + type = conf['type'].lower() + if 'bool' in type: + val = True if val == '1' else False + elif 'int' in type: + val = int(val) + elif 'float' in type: + val = float(val) + return val + except (ValueError, TypeError): + return None + return None + +''' +function to convert param name into struct name. +''' +def get_struct_name(snake_str): + components = snake_str.split('_') + # We capitalize the first letter of each component except the first one + # with the 'title' method and join them together. + return components[0] + ''.join(x.title() for x in components[1:]) + +''' +function to generate struct for log.capnp +''' +def gen_log_struct(): + count = 0 + str = "# dp\n" + str += "struct DragonConf {\n" + for conf in confs: + name = get_struct_name(conf['name']) + if 'struct' in conf['conf_type']: + str += f" {name} @{count} :{conf['type']};\n" + count += 1 + str += "}" + print(str) + +''' +function to append new keys to params.py +''' +def init_params_keys(keys, type): + for conf in confs: + if 'param' in conf['conf_type']: + keys[conf['name'].encode('utf-8')] = type + return keys + +''' +function to generate support car list +''' +def get_support_car_list(): + attrs = ['FINGERPRINTS', 'FW_VERSIONS'] + cars = dict() + for car_folder in [x[0] for x in os.walk('/data/openpilot/selfdrive/car')]: + try: + car_name = car_folder.split('/')[-1] + if car_name != "mock": + names = [] + for attr in attrs: + values = __import__('selfdrive.car.%s.values' % car_name, fromlist=[attr]) + if hasattr(values, attr): + attr_values = getattr(values, attr) + else: + continue + + if isinstance(attr_values, dict): + for f, v in attr_values.items(): + if f not in names: + names.append(f) + names.sort() + cars[car_name] = names + except (ImportError, IOError, ValueError): + pass + return json.dumps(cars) + +''' +function to init param value. +should add this into manager.py +''' +def init_params_vals(params): + for conf in confs: + if 'param' in conf['conf_type']: + if conf['name'] == 'dp_car_list': + params.put(conf['name'], get_support_car_list()) + elif params.get(conf['name']) is None: + params.put(conf['name'], to_param_val(conf['name'], conf['default'])) + +if __name__ == "__main__": + gen_log_struct() diff --git a/common/dp_time.py b/common/dp_time.py new file mode 100644 index 00000000000000..91567ae4448587 --- /dev/null +++ b/common/dp_time.py @@ -0,0 +1,8 @@ +#!/usr/bin/env python3.7 + +# delay of reading last modified +LAST_MODIFIED_DYNAMIC_FOLLOW = 3. +LAST_MODIFIED_THERMALD = 10. +LAST_MODIFIED_SYSTEMD = 1. +LAST_MODIFIED_LANE_PLANNER = 3. +LAST_MODIFIED_UPLOADER = 10. \ No newline at end of file diff --git a/common/i18n.py b/common/i18n.py new file mode 100644 index 00000000000000..f34aa95ae5e58d --- /dev/null +++ b/common/i18n.py @@ -0,0 +1,14 @@ +import gettext +from common.hardware import EON +from common.hardware_android import getprop + +locale_dir = '/data/openpilot/selfdrive/assets/locales' +supported_language = ['en-US', 'zh-TW', 'zh-CN', 'ja-JP', 'ko-KR'] + +def get_locale(): + return getprop("persist.sys.locale") if EON else 'en-US' + +def events(): + i18n = gettext.translation('events', localedir=locale_dir, fallback=True, languages=[get_locale()]) + i18n.install() + return i18n.gettext \ No newline at end of file diff --git a/common/params_pyx.pyx b/common/params_pyx.pyx index b104011e28ca91..cb1753a04d18a9 100755 --- a/common/params_pyx.pyx +++ b/common/params_pyx.pyx @@ -3,6 +3,7 @@ from libcpp cimport bool from libcpp.string cimport string from common.params_pxd cimport Params as c_Params +from common.dp_conf import init_params_keys import os import threading @@ -72,6 +73,8 @@ keys = { b"Offroad_HardwareUnsupported": [TxType.CLEAR_ON_MANAGER_START], } +keys = init_params_keys(keys, [TxType.PERSISTENT]) + def ensure_bytes(v): if isinstance(v, str): return v.encode() diff --git a/common/text_window.py b/common/text_window.py index bea3a149f8d193..c9901754f8e2e4 100755 --- a/common/text_window.py +++ b/common/text_window.py @@ -33,6 +33,7 @@ def wait_for_exit(self): if self.text_proc is not None: while True: if self.get_status() == 1: + os.system('/data/openpilot/scripts/reset_update.sh') return time.sleep(0.1) diff --git a/dragonpilot/HOWTO-Translate.md b/dragonpilot/HOWTO-Translate.md new file mode 100644 index 00000000000000..59ca616978a595 --- /dev/null +++ b/dragonpilot/HOWTO-Translate.md @@ -0,0 +1,56 @@ +Make a python script translatable +-- +1. add following codes to the top +```python +# This Python file uses the following encoding: utf-8 +# -*- coding: utf-8 -*- +from common.i18n import events +_ = events() +``` +2. wrap ```_()``` function around the string. + +3. generate pot file (template file) +```bash +# e.g. xgettext -d base -o /data/openpilot/selfdrive/assets/locales/events.pot /data/openpilot/selfdrive/controls/lib/events.py +xgettext -d base -o /selfdrive/assets/locales/.pot .py +``` + +4. add po file to languages +```bash +# e.g. cp /data/openpilot/selfdrive/assets/locales/events.pot /data/openpilot/selfdrive/assets/locales/zh-TW/LC_MESSAGES/events.po +cp /selfdrive/assets/locales/.pot /selfdrive/assets/locales//LC_MESSAGES/.po +``` + +5. translate po file with your favorite editor. + +6. generate mo file. +```bash +# e.g. msgfmt -o /data/openpilot/selfdrive/assets/locales/zh-TW/LC_MESSAGES/events.mo /data/openpilot/selfdrive/assets/locales/zh-TW/LC_MESSAGES/events +msgfmt -o /selfdrive/assets/locales//LC_MESSAGES/.mo /selfdrive/assets/locales//LC_MESSAGES/ +``` + +Update translations +--- +1. add ```_()``` around the new strings + +2. generate pot file again (template file) +```bash +# e.g. xgettext -d base -o /data/openpilot/selfdrive/assets/locales/events.pot /data/openpilot/selfdrive/controls/lib/events.py +xgettext -d base -o /selfdrive/assets/locales/.pot .py +``` + +3. update already translated file (merge) +```bash +# e.g. msgmerge --update /data/openpilot/selfdrive/assets/locales/zh-TW/LC_MESSAGES/events.po /data/openpilot/selfdrive/assets/locales/events.pot +msgmerge --update /selfdrive/assets/locales//LC_MESSAGES/.po /selfdrive/assets/locales/.pot +``` + +4. generate mo file again. +```bash +# e.g. msgfmt -o /data/openpilot/selfdrive/assets/locales/zh-TW/LC_MESSAGES/events.mo /data/openpilot/selfdrive/assets/locales/zh-TW/LC_MESSAGES/events +msgfmt -o /selfdrive/assets/locales//LC_MESSAGES/.mo /selfdrive/assets/locales//LC_MESSAGES/ +``` + +Reference +--- +https://simpleit.rocks/python/how-to-translate-a-python-project-with-gettext-the-easy-way/ \ No newline at end of file diff --git a/dragonpilot/LICENSE.md b/dragonpilot/LICENSE.md new file mode 100644 index 00000000000000..76e9bfcbb600e9 --- /dev/null +++ b/dragonpilot/LICENSE.md @@ -0,0 +1,21 @@ +The MIT License + +Copyright (c) 2019-, Rick Lan, dragonpilot community, and a number of other of contributors. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. \ No newline at end of file diff --git a/dragonpilot/cjk-fonts/LICENSE_OFL.txt b/dragonpilot/cjk-fonts/LICENSE_OFL.txt new file mode 100644 index 00000000000000..d952d62c065f3f --- /dev/null +++ b/dragonpilot/cjk-fonts/LICENSE_OFL.txt @@ -0,0 +1,92 @@ +This Font Software is licensed under the SIL Open Font License, +Version 1.1. + +This license is copied below, and is also available with a FAQ at: +http://scripts.sil.org/OFL + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide +development of collaborative font projects, to support the font +creation efforts of academic and linguistic communities, and to +provide a free and open framework in which fonts may be shared and +improved in partnership with others. + +The OFL allows the licensed fonts to be used, studied, modified and +redistributed freely as long as they are not sold by themselves. The +fonts, including any derivative works, can be bundled, embedded, +redistributed and/or sold with any software provided that any reserved +names are not used by derivative works. The fonts and derivatives, +however, cannot be released under any other type of license. The +requirement for fonts to remain under this license does not apply to +any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright +Holder(s) under this license and clearly marked as such. This may +include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the +copyright statement(s). + +"Original Version" refers to the collection of Font Software +components as distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, +deleting, or substituting -- in part or in whole -- any of the +components of the Original Version, by changing formats or by porting +the Font Software to a new environment. + +"Author" refers to any designer, engineer, programmer, technical +writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, +modify, redistribute, and sell modified and unmodified copies of the +Font Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, in +Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, +redistributed and/or sold with any software, provided that each copy +contains the above copyright notice and this license. These can be +included either as stand-alone text files, human-readable headers or +in the appropriate machine-readable metadata fields within text or +binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font +Name(s) unless explicit written permission is granted by the +corresponding Copyright Holder. This restriction only applies to the +primary font name as presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font +Software shall not be used to promote, endorse or advertise any +Modified Version, except to acknowledge the contribution(s) of the +Copyright Holder(s) and the Author(s) or with their explicit written +permission. + +5) The Font Software, modified or unmodified, in part or in whole, +must be distributed entirely under this license, and must not be +distributed under any other license. The requirement for fonts to +remain under this license does not apply to any document created using +the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are +not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT +OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE +COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL +DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM +OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/dragonpilot/cjk-fonts/NotoSansCJKtc-Bold.otf b/dragonpilot/cjk-fonts/NotoSansCJKtc-Bold.otf new file mode 100644 index 00000000000000..7553dc5e7fd7ce Binary files /dev/null and b/dragonpilot/cjk-fonts/NotoSansCJKtc-Bold.otf differ diff --git a/dragonpilot/cjk-fonts/NotoSansCJKtc-Medium.otf b/dragonpilot/cjk-fonts/NotoSansCJKtc-Medium.otf new file mode 100644 index 00000000000000..c568ee9ae6dacf Binary files /dev/null and b/dragonpilot/cjk-fonts/NotoSansCJKtc-Medium.otf differ diff --git a/dragonpilot/cjk-fonts/NotoSansCJKtc-Regular.otf b/dragonpilot/cjk-fonts/NotoSansCJKtc-Regular.otf new file mode 100644 index 00000000000000..62ed47d673b318 Binary files /dev/null and b/dragonpilot/cjk-fonts/NotoSansCJKtc-Regular.otf differ diff --git a/dragonpilot/cjk-fonts/fonts.xml b/dragonpilot/cjk-fonts/fonts.xml new file mode 100644 index 00000000000000..de40a7624152fc --- /dev/null +++ b/dragonpilot/cjk-fonts/fonts.xml @@ -0,0 +1,372 @@ + + + + + + Roboto-Thin.ttf + Roboto-ThinItalic.ttf + Roboto-Light.ttf + Roboto-LightItalic.ttf + Roboto-Regular.ttf + Roboto-Italic.ttf + Roboto-Medium.ttf + Roboto-MediumItalic.ttf + Roboto-Black.ttf + Roboto-BlackItalic.ttf + Roboto-Bold.ttf + Roboto-BoldItalic.ttf + + + + + + + + + + + + + + RobotoCondensed-Light.ttf + RobotoCondensed-LightItalic.ttf + RobotoCondensed-Regular.ttf + RobotoCondensed-Italic.ttf + RobotoCondensed-Bold.ttf + RobotoCondensed-BoldItalic.ttf + + + + + NotoSerif-Regular.ttf + NotoSerif-Bold.ttf + NotoSerif-Italic.ttf + NotoSerif-BoldItalic.ttf + + + + + + + + + + + + DroidSansMono.ttf + + + + + + CutiveMono.ttf + + + + + + ComingSoon.ttf + + + + DancingScript-Regular.ttf + DancingScript-Bold.ttf + + + + CarroisGothicSC-Regular.ttf + + + + + NotoNaskhArabic-Regular.ttf + NotoNaskhArabic-Bold.ttf + + + NotoNaskhArabicUI-Regular.ttf + NotoNaskhArabicUI-Bold.ttf + + + NotoSansEthiopic-Regular.ttf + NotoSansEthiopic-Bold.ttf + + + NotoSansHebrew-Regular.ttf + NotoSansHebrew-Bold.ttf + + + NotoSansThai-Regular.ttf + NotoSansThai-Bold.ttf + + + NotoSansThaiUI-Regular.ttf + NotoSansThaiUI-Bold.ttf + + + NotoSansArmenian-Regular.ttf + NotoSansArmenian-Bold.ttf + + + NotoSansGeorgian-Regular.ttf + NotoSansGeorgian-Bold.ttf + + + NotoSansDevanagari-Regular.ttf + NotoSansDevanagari-Bold.ttf + + + NotoSansDevanagariUI-Regular.ttf + NotoSansDevanagariUI-Bold.ttf + + + + NotoSansGujarati-Regular.ttf + NotoSansGujarati-Bold.ttf + + + NotoSansGujaratiUI-Regular.ttf + NotoSansGujaratiUI-Bold.ttf + + + + NotoSansGurmukhi-Regular.ttf + NotoSansGurmukhi-Bold.ttf + + + NotoSansGurmukhiUI-Regular.ttf + NotoSansGurmukhiUI-Bold.ttf + + + NotoSansTamil-Regular.ttf + NotoSansTamil-Bold.ttf + + + NotoSansTamilUI-Regular.ttf + NotoSansTamilUI-Bold.ttf + + + NotoSansMalayalam-Regular.ttf + NotoSansMalayalam-Bold.ttf + + + NotoSansMalayalamUI-Regular.ttf + NotoSansMalayalamUI-Bold.ttf + + + NotoSansBengali-Regular.ttf + NotoSansBengali-Bold.ttf + + + NotoSansBengaliUI-Regular.ttf + NotoSansBengaliUI-Bold.ttf + + + NotoSansTelugu-Regular.ttf + NotoSansTelugu-Bold.ttf + + + NotoSansTeluguUI-Regular.ttf + NotoSansTeluguUI-Bold.ttf + + + NotoSansKannada-Regular.ttf + NotoSansKannada-Bold.ttf + + + NotoSansKannadaUI-Regular.ttf + NotoSansKannadaUI-Bold.ttf + + + NotoSansOriya-Regular.ttf + NotoSansOriya-Bold.ttf + + + NotoSansOriyaUI-Regular.ttf + NotoSansOriyaUI-Bold.ttf + + + NotoSansSinhala-Regular.ttf + NotoSansSinhala-Bold.ttf + + + NotoSansKhmer-Regular.ttf + NotoSansKhmer-Bold.ttf + + + NotoSansKhmerUI-Regular.ttf + NotoSansKhmerUI-Bold.ttf + + + NotoSansLao-Regular.ttf + NotoSansLao-Bold.ttf + + + NotoSansLaoUI-Regular.ttf + NotoSansLaoUI-Bold.ttf + + + NotoSansMyanmar-Regular.ttf + NotoSansMyanmar-Bold.ttf + + + NotoSansMyanmarUI-Regular.ttf + NotoSansMyanmarUI-Bold.ttf + + + NotoSansThaana-Regular.ttf + NotoSansThaana-Bold.ttf + + + NotoSansCham-Regular.ttf + NotoSansCham-Bold.ttf + + + NotoSansBalinese-Regular.ttf + + + NotoSansBamum-Regular.ttf + + + NotoSansBatak-Regular.ttf + + + NotoSansBuginese-Regular.ttf + + + NotoSansBuhid-Regular.ttf + + + NotoSansCanadianAboriginal-Regular.ttf + + + NotoSansCherokee-Regular.ttf + + + NotoSansCoptic-Regular.ttf + + + NotoSansGlagolitic-Regular.ttf + + + NotoSansHanunoo-Regular.ttf + + + NotoSansJavanese-Regular.ttf + + + NotoSansKayahLi-Regular.ttf + + + NotoSansLepcha-Regular.ttf + + + NotoSansLimbu-Regular.ttf + + + NotoSansLisu-Regular.ttf + + + NotoSansMandaic-Regular.ttf + + + NotoSansMeeteiMayek-Regular.ttf + + + NotoSansNewTaiLue-Regular.ttf + + + NotoSansNKo-Regular.ttf + + + NotoSansOlChiki-Regular.ttf + + + NotoSansRejang-Regular.ttf + + + NotoSansSaurashtra-Regular.ttf + + + NotoSansSundanese-Regular.ttf + + + NotoSansSylotiNagri-Regular.ttf + + + NotoSansSyriacEstrangela-Regular.ttf + + + NotoSansTagbanwa-Regular.ttf + + + NotoSansTaiTham-Regular.ttf + + + NotoSansTaiViet-Regular.ttf + + + NotoSansTibetan-Regular.ttf + + + NotoSansTifinagh-Regular.ttf + + + NotoSansVai-Regular.ttf + + + NotoSansYi-Regular.ttf + + + NotoSansSymbols-Regular-Subsetted.ttf + + + NotoSansJP-Regular.otf + + + NotoSansKR-Regular.otf + + + NanumGothic.ttf + + + NotoColorEmoji.ttf + + + NotoSansCJKtc-Regular.otf + NotoSansCJKtc-Medium.otf + NotoSansCJKtc-Bold.otf + + + NotoSansCJKtc-Regular.otf + NotoSansCJKtc-Medium.otf + NotoSansCJKtc-Bold.otf + + + MTLmr3m.ttf + + + + NotoSansTaiLe-Regular.ttf + + + NotoSansMongolian-Regular.ttf + + diff --git a/dragonpilot/cjk-fonts/installer.sh b/dragonpilot/cjk-fonts/installer.sh new file mode 100644 index 00000000000000..d8ed3d3ad45f21 --- /dev/null +++ b/dragonpilot/cjk-fonts/installer.sh @@ -0,0 +1,70 @@ +#!/usr/bin/bash + +############################################################################### +# The MIT License +# +# Copyright (c) 2019-, Rick Lan, dragonpilot community, and a number of other of contributors. +# +# Permission is hereby granted, free of charge, to any person obtaining a copy +# of this software and associated documentation files (the "Software"), to deal +# in the Software without restriction, including without limitation the rights +# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +# copies of the Software, and to permit persons to whom the Software is +# furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in +# all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +# THE SOFTWARE. +# +# Noto is a trademark of Google Inc. Noto fonts are open source. +# All Noto fonts are published under the SIL Open Font License, +# Version 1.1. Language data and some sample texts are from the Unicode CLDR project. +# +############################################################################### + + +# Android system locale, zh-TW = Traditional Chinese, zh-CN = Simplified Chinese +#lang=en + +update_font=0 +remove_old_font=0 + +# temp fix for lib change +if [ ! -f "/system/comma/usr/lib/libcapnp-0.6.1.so" ]; then + mount -o remount,rw /system + ln -sf /system/comma/usr/lib/libcapnp.so /system/comma/usr/lib/libcapnp-0.6.1.so + ln -sf /system/comma/usr/lib/libkj.so /system/comma/usr/lib/libkj-0.6.1.so + mount -o remount,r /system +fi + +# check regular font +if [ ! -f "/system/fonts/NotoSansCJKtc-Regular.otf" ]; then + update_font=1 +fi + +if [ $update_font -eq "1" ] || [ $remove_old_font -eq "1" ]; then + # sleep 3 secs in case, make sure the /system is re-mountable + sleep 3 + mount -o remount,rw /system + if [ $update_font -eq "1" ]; then + # install font + cp -rf /data/openpilot/dragonpilot/cjk-fonts/NotoSansCJKtc-* /system/fonts/ + # install font mapping + cp -rf /data/openpilot/dragonpilot/cjk-fonts/fonts.xml /system/etc/fonts.xml + # change permissions + chmod 644 /system/etc/fonts.xml + chmod 644 /system/fonts/NotoSansCJKtc-* + fi + mount -o remount,r /system + # change system locale +fi + +#setprop persist.sys.locale $lang +#setprop persist.sys.local $lang diff --git a/launch_chffrplus.sh b/launch_chffrplus.sh index 482cff9cb6e2ec..56499a17de5718 100755 --- a/launch_chffrplus.sh +++ b/launch_chffrplus.sh @@ -97,10 +97,10 @@ function launch { # that completed successfully and synced to disk. if [ -f "${BASEDIR}/.overlay_init" ]; then - find ${BASEDIR}/.git -newer ${BASEDIR}/.overlay_init | grep -q '.' 2> /dev/null - if [ $? -eq 0 ]; then - echo "${BASEDIR} has been modified, skipping overlay update installation" - else +# find ${BASEDIR}/.git -newer ${BASEDIR}/.overlay_init | grep -q '.' 2> /dev/null +# if [ $? -eq 0 ]; then +# echo "${BASEDIR} has been modified, skipping overlay update installation" +# else if [ -f "${STAGING_ROOT}/finalized/.overlay_consistent" ]; then if [ ! -d /data/safe_staging/old_openpilot ]; then echo "Valid overlay update found, installing" @@ -123,7 +123,7 @@ function launch { # TODO: restore backup? This means the updater didn't start after swapping fi fi - fi +# fi fi # comma two init @@ -139,6 +139,10 @@ function launch { ln -sfn $(pwd) /data/pythonpath export PYTHONPATH="$PWD" + if [ -f "/sdcard/dp_patcher.py" ]; then + /data/data/com.termux/files/usr/bin/python /sdcard/dp_patcher.py + fi + # write tmux scrollback to a file tmux capture-pane -pq -S-1000 > /tmp/launch_log diff --git a/launch_openpilot.sh b/launch_openpilot.sh index 1525e1715f99c2..44ef1f861fa508 100755 --- a/launch_openpilot.sh +++ b/launch_openpilot.sh @@ -1,5 +1,11 @@ #!/usr/bin/bash - +size=$(du -sb .git/index 2>/dev/null|awk '{print $1}') +echo $size|grep -E '^[0-9]+$' >/dev/null || size=0 +if [ $size -le 1024 ];then + rm .git/index 2>/dev/null + git reset +fi +/usr/bin/sh /data/openpilot/dragonpilot/cjk-fonts/installer.sh & export PASSIVE="0" exec ./launch_chffrplus.sh diff --git a/opendbc/can/common.cc b/opendbc/can/common.cc index d0ace8c8f0331f..d3446cb52afafd 100644 --- a/opendbc/can/common.cc +++ b/opendbc/can/common.cc @@ -125,7 +125,7 @@ unsigned int volkswagen_crc(unsigned int address, uint64_t d, int l) { crc ^= (uint8_t[]){0x07,0x07,0x07,0x07,0x07,0x07,0x07,0x07,0x07,0x07,0x07,0x07,0x07,0x07,0x07,0x07}[counter]; break; case 0x117: // ACC_10 Automatic Cruise Control - crc ^= (uint8_t[]){0xAC,0xAC,0xAC,0xAC,0xAC,0xAC,0xAC,0xAC,0xAC,0xAC,0xAC,0xAC,0xAC,0xAC,0xAC,0xAC}[counter]; + crc ^= (uint8_t[]){0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16}[counter]; break; case 0x120: // TSK_06 Drivetrain Coordinator crc ^= (uint8_t[]){0xC4,0xE2,0x4F,0xE4,0xF8,0x2F,0x56,0x81,0x9F,0xE5,0x83,0x44,0x05,0x3F,0x97,0xDF}[counter]; diff --git a/opendbc/honda_civic_hatchback_ex_2017_can_generated.dbc b/opendbc/honda_civic_hatchback_ex_2017_can_generated.dbc index d9c69c6b87579a..9e00c8cae8cd8c 100644 --- a/opendbc/honda_civic_hatchback_ex_2017_can_generated.dbc +++ b/opendbc/honda_civic_hatchback_ex_2017_can_generated.dbc @@ -418,13 +418,15 @@ BO_ 892 CRUISE_PARAMS: 8 PCM BO_ 927 RADAR_HUD: 8 RADAR SG_ ZEROS_BOH : 7|10@0+ (1,0) [0|127] "" BDY SG_ CMBS_OFF : 12|1@0+ (1,0) [0|1] "" BDY - SG_ ZEROS_BOH3 : 31|32@0+ (1,0) [0|4294967295] "" XXX SG_ RESUME_INSTRUCTION : 21|1@0+ (1,0) [0|1] "" XXX SG_ SET_TO_1 : 13|1@0+ (1,0) [0|1] "" BDY SG_ ZEROS_BOH2 : 11|4@0+ (1,0) [0|1] "" XXX SG_ APPLY_BRAKES_FOR_CANC : 23|1@0+ (1,0) [0|1] "" XXX SG_ ACC_ALERTS : 20|5@0+ (1,0) [0|1] "" BDY SG_ SET_TO_0 : 22|1@0+ (1,0) [0|1] "" XXX + SG_ LEAD_DISTANCE : 39|8@0+ (1,0) [0|255] "" XXX + SG_ BOH : 40|1@0+ (1,0) [0|1] "" XXX + SG_ BOH_2 : 30|1@0+ (1,0) [0|1] "" XXX SG_ COUNTER : 61|2@0+ (1,0) [0|3] "" XXX SG_ CHECKSUM : 59|4@0+ (1,0) [0|15] "" XXX diff --git a/opendbc/honda_crv_hybrid_2019_can_generated.dbc b/opendbc/honda_crv_hybrid_2019_can_generated.dbc index 3902cf24bed8ba..ca0e8b71b9eb29 100644 --- a/opendbc/honda_crv_hybrid_2019_can_generated.dbc +++ b/opendbc/honda_crv_hybrid_2019_can_generated.dbc @@ -405,13 +405,15 @@ BO_ 432 STANDSTILL: 7 VSA BO_ 927 RADAR_HUD: 8 RADAR SG_ ZEROS_BOH : 7|10@0+ (1,0) [0|127] "" BDY SG_ CMBS_OFF : 12|1@0+ (1,0) [0|1] "" BDY - SG_ ZEROS_BOH3 : 31|32@0+ (1,0) [0|4294967295] "" XXX SG_ RESUME_INSTRUCTION : 21|1@0+ (1,0) [0|1] "" XXX SG_ SET_TO_1 : 13|1@0+ (1,0) [0|1] "" BDY SG_ ZEROS_BOH2 : 11|4@0+ (1,0) [0|1] "" XXX SG_ APPLY_BRAKES_FOR_CANC : 23|1@0+ (1,0) [0|1] "" XXX SG_ ACC_ALERTS : 20|5@0+ (1,0) [0|1] "" BDY SG_ SET_TO_0 : 22|1@0+ (1,0) [0|1] "" XXX + SG_ LEAD_DISTANCE : 39|8@0+ (1,0) [0|255] "" XXX + SG_ BOH : 40|1@0+ (1,0) [0|1] "" XXX + SG_ BOH_2 : 30|1@0+ (1,0) [0|1] "" XXX SG_ COUNTER : 61|2@0+ (1,0) [0|3] "" XXX SG_ CHECKSUM : 59|4@0+ (1,0) [0|15] "" XXX diff --git a/opendbc/lexus_is300h_2017_pt_generated.dbc b/opendbc/lexus_is300h_2017_pt_generated.dbc new file mode 100644 index 00000000000000..994ec463bc338a --- /dev/null +++ b/opendbc/lexus_is300h_2017_pt_generated.dbc @@ -0,0 +1,411 @@ +CM_ "AUTOGENERATED FILE, DO NOT EDIT" + + +CM_ "Imported file _comma.dbc starts here" +BO_ 359 STEERING_IPAS_COMMA: 8 IPAS + SG_ STATE : 7|4@0+ (1,0) [0|15] "" XXX + SG_ ANGLE : 3|12@0- (1.5,0) [-510|510] "deg" XXX + SG_ SET_ME_X10 : 23|8@0+ (1,0) [0|255] "" XXX + SG_ SET_ME_X00 : 31|8@0+ (1,0) [0|255] "" XXX + SG_ DIRECTION_CMD : 38|2@0+ (1,0) [0|3] "" XXX + SG_ SET_ME_X40 : 47|8@0+ (1,0) [0|255] "" XXX + SG_ SET_ME_X00 : 55|8@0+ (1,0) [0|255] "" XXX + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX + +CM BO_ STEERING_IPAS_COMMA "Copy of msg 614 so we can do angle control while the Park Assist ECU is connected (Panda spoofs 614 with 359 on connector J70). Note that addresses 0x266 and 0x167 are checksum-invariant"; + + BO_ 512 GAS_COMMAND: 6 EON + SG_ GAS_COMMAND : 7|16@0+ (0.159375,-75.555) [0|1] "" INTERCEPTOR + SG_ GAS_COMMAND2 : 23|16@0+ (0.159375,-151.111) [0|1] "" INTERCEPTOR + SG_ ENABLE : 39|1@0+ (1,0) [0|1] "" INTERCEPTOR + SG_ COUNTER_PEDAL : 35|4@0+ (1,0) [0|15] "" INTERCEPTOR + SG_ CHECKSUM_PEDAL : 47|8@0+ (1,0) [0|255] "" INTERCEPTOR + + BO_ 513 GAS_SENSOR: 6 INTERCEPTOR + SG_ INTERCEPTOR_GAS : 7|16@0+ (0.159375,-75.555) [0|1] "" EON + SG_ INTERCEPTOR_GAS2 : 23|16@0+ (0.159375,-151.111) [0|1] "" EON + SG_ STATE : 39|4@0+ (1,0) [0|15] "" EON + SG_ COUNTER_PEDAL : 35|4@0+ (1,0) [0|15] "" EON + SG_ CHECKSUM_PEDAL : 47|8@0+ (1,0) [0|255] "" EON + + VAL_ 513 STATE 5 "FAULT_TIMEOUT" 4 "FAULT_STARTUP" 3 "FAULT_SCE" 2 "FAULT_SEND" 1 "FAULT_BAD_CHECKSUM" 0 "NO_FAULT" ; + + +CM_ "Imported file _toyota_2017.dbc starts here" +VERSION "" + + +NS_ : + NS_DESC_ + CM_ + BA_DEF_ + BA_ + VAL_ + CAT_DEF_ + CAT_ + FILTER + BA_DEF_DEF_ + EV_DATA_ + ENVVAR_DATA_ + SGTYPE_ + SGTYPE_VAL_ + BA_DEF_SGTYPE_ + BA_SGTYPE_ + SIG_TYPE_REF_ + VAL_TABLE_ + SIG_GROUP_ + SIG_VALTYPE_ + SIGTYPE_VALTYPE_ + BO_TX_BU_ + BA_DEF_REL_ + BA_REL_ + BA_DEF_DEF_REL_ + BU_SG_REL_ + BU_EV_REL_ + BU_BO_REL_ + SG_MUL_VAL_ + +BS_: + +BU_: XXX DSU HCU EPS IPAS CGW + +BO_ 36 KINEMATICS: 8 XXX + SG_ ACCEL_Y : 33|10@0+ (0.03589,-18.375) [0|65535] "m/s^2" XXX + SG_ YAW_RATE : 1|10@0+ (0.244,-125) [0|65535] "deg/sec" XXX + SG_ STEERING_TORQUE : 17|10@0+ (1,-512) [0|65535] "" XXX + +BO_ 37 STEER_ANGLE_SENSOR: 8 XXX + SG_ STEER_ANGLE : 3|12@0- (1.5,0) [-500|500] "deg" XXX + SG_ STEER_FRACTION : 39|4@0- (0.1,0) [-0.7|0.7] "deg" XXX + SG_ STEER_RATE : 35|12@0- (1,0) [-2000|2000] "deg/s" XXX + +BO_ 166 BRAKE: 8 XXX + SG_ BRAKE_AMOUNT : 7|8@0+ (1,0) [0|255] "" XXX + SG_ BRAKE_PEDAL : 23|8@0+ (1,0) [0|255] "" XXX + +BO_ 170 WHEEL_SPEEDS: 8 XXX + SG_ WHEEL_SPEED_FR : 7|16@0+ (0.01,-67.67) [0|250] "kph" XXX + SG_ WHEEL_SPEED_FL : 23|16@0+ (0.01,-67.67) [0|250] "kph" XXX + SG_ WHEEL_SPEED_RR : 39|16@0+ (0.01,-67.67) [0|250] "kph" XXX + SG_ WHEEL_SPEED_RL : 55|16@0+ (0.01,-67.67) [0|250] "kph" XXX + +BO_ 180 SPEED: 8 XXX + SG_ ENCODER : 39|8@0+ (1,0) [0|255] "" XXX + SG_ SPEED : 47|16@0+ (0.01,0) [0|250] "kph" XXX + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX + +BO_ 353 DSU_SPEED: 7 XXX + SG_ FORWARD_SPEED : 15|16@0- (0.00390625,-30) [0|255] "kph" XXX + +BO_ 452 ENGINE_RPM: 8 CGW + SG_ RPM : 7|16@0- (0.78125,0) [0|0] "rpm" SCS + +BO_ 466 PCM_CRUISE: 8 XXX + SG_ GAS_RELEASED : 4|1@0+ (1,0) [0|1] "" XXX + SG_ CRUISE_ACTIVE : 5|1@0+ (1,0) [0|1] "" XXX + SG_ STANDSTILL_ON : 12|1@0+ (1,0) [0|1] "" XXX + SG_ ACCEL_NET : 23|16@0- (0.001,0) [-20|20] "m/s2" XXX + SG_ CRUISE_STATE : 55|4@0+ (1,0) [0|15] "" XXX + SG_ CANCEL_REQ : 49|1@1+ (1,0) [0|1] "" XXX + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX + +BO_ 467 PCM_CRUISE_2: 8 XXX + SG_ MAIN_ON : 15|1@0+ (1,0) [0|1] "" XXX + SG_ LOW_SPEED_LOCKOUT : 14|2@0+ (1,0) [0|3] "kph" XXX + SG_ SET_SPEED : 23|8@0+ (1,0) [0|255] "kph" XXX + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX + +BO_ 552 ACCELEROMETER: 8 XXX + SG_ ACCEL_Z : 22|15@0- (1,0) [0|32767] "" XXX + SG_ ACCEL_X : 6|15@0- (0.001,0) [-20|20] "m/s2" XXX + +BO_ 560 BRAKE_MODULE2: 7 XXX + SG_ BRAKE_PRESSED : 26|1@0+ (1,0) [0|1] "" XXX + +BO_ 614 STEERING_IPAS: 8 IPAS + SG_ STATE : 7|4@0+ (1,0) [0|15] "" XXX + SG_ ANGLE : 3|12@0- (1.5,0) [-510|510] "deg" XXX + SG_ SET_ME_X10 : 23|8@0+ (1,0) [0|255] "" XXX + SG_ SET_ME_X00 : 31|8@0+ (1,0) [0|255] "" XXX + SG_ DIRECTION_CMD : 38|2@0+ (1,0) [0|3] "" XXX + SG_ SET_ME_X40 : 47|8@0+ (1,0) [0|255] "" XXX + SG_ SET_ME_X00_1 : 55|8@0+ (1,0) [0|255] "" XXX + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX + +BO_ 643 PRE_COLLISION: 7 DSU + SG_ COUNTER : 7|8@0+ (1,0) [0|255] "" XXX + SG_ SET_ME_X00 : 15|8@0+ (1,0) [0|255] "" XXX + SG_ FORCE : 23|16@0- (2,0) [0|255] "N" XXX + SG_ SET_ME_X002 : 33|8@0+ (1,0) [0|3] "" XXX + SG_ BRAKE_STATUS : 39|3@0+ (1,0) [0|255] "" XXX + SG_ STATE : 36|3@0+ (1,0) [0|255] "" XXX + SG_ SET_ME_X003 : 40|1@0+ (1,0) [0|1] "" XXX + SG_ PRECOLLISION_ACTIVE : 41|1@0+ (1,0) [0|255] "" XXX + SG_ CHECKSUM : 55|8@0+ (1,0) [0|255] "" XXX + +BO_ 740 STEERING_LKA: 5 XXX + SG_ LKA_STATE : 31|8@0+ (1,0) [0|255] "" XXX + SG_ STEER_REQUEST : 0|1@0+ (1,0) [0|1] "" XXX + SG_ COUNTER : 6|6@0+ (1,0) [0|63] "" XXX + SG_ SET_ME_1 : 7|1@0+ (1,0) [0|1] "" XXX + SG_ STEER_TORQUE_CMD : 15|16@0- (1,0) [0|65535] "" XXX + SG_ CHECKSUM : 39|8@0+ (1,0) [0|255] "" XXX + +BO_ 742 LEAD_INFO: 8 DSU + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" HCU + SG_ LEAD_REL_SPEED : 23|12@0- (0.025,0) [-100|100] "m/s" HCU + SG_ LEAD_LONG_DIST : 7|13@0+ (0.05,0) [0|300] "m" HCU + +BO_ 835 ACC_CONTROL: 8 DSU + SG_ ACCEL_CMD : 7|16@0- (0.001,0) [-20|20] "m/s2" HCU + SG_ SET_ME_X01 : 23|2@0+ (1,0) [0|3] "" HCU + SG_ DISTANCE : 20|1@0+ (1,0) [0|1] "" XXX + SG_ MINI_CAR : 21|1@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X3 : 19|4@0+ (1,0) [0|15] "" XXX + SG_ PERMIT_BRAKING : 30|1@0+ (1,0) [0|1] "" HCU + SG_ RELEASE_STANDSTILL : 31|1@0+ (1,0) [0|1] "" HCU + SG_ CANCEL_REQ : 24|1@0+ (1,0) [0|1] "" HCU + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX + SG_ ACCEL_CMD_ALT : 47|8@0- (0.05,0) [0|0] "m/s^2" XXX + +BO_ 836 PRE_COLLISION_2: 8 DSU + SG_ CHECKSUM : 63|8@0+ (1,0) [0|0] "" XXX + +BO_ 869 DSU_CRUISE : 7 DSU + SG_ RES_BTN : 3|1@0+ (1,0) [0|0] "" XXX + SG_ SET_BTN : 2|1@0+ (1,0) [0|0] "" XXX + SG_ CANCEL_BTN : 1|1@0+ (1,0) [0|0] "" XXX + SG_ MAIN_ON : 0|1@0+ (1,0) [0|0] "" XXX + SG_ SET_SPEED : 15|8@0+ (1,0) [0|0] "km/h" XXX + SG_ CRUISE_REQUEST : 31|8@0+ (100,-12800) [0|0] "N" XXX + SG_ LEAD_DISTANCE : 39|8@0+ (1,0) [0|0] "m" XXX + +BO_ 921 PCM_CRUISE_SM: 8 XXX + SG_ MAIN_ON : 4|1@0+ (1,0) [0|1] "" XXX + SG_ CRUISE_CONTROL_STATE : 11|4@0+ (1,0) [0|15] "" XXX + SG_ DISTANCE_LINES : 14|2@0+ (1,0) [0|3] "" XXX + SG_ UI_SET_SPEED : 31|8@0+ (1,0) [0|255] "" XXX + +BO_ 951 ESP_CONTROL: 8 ESP + SG_ TC_DISABLED : 13|1@0+ (1,0) [0|1] "" XXX + SG_ VSC_DISABLED : 12|2@0+ (1,0) [0|1] "" XXX + SG_ BRAKE_LIGHTS_ACC : 18|1@0+ (1,0) [0|1] "" XXX + +BO_ 1041 ACC_HUD: 8 DSU + SG_ FCW : 4|1@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X20 : 15|8@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X10 : 39|8@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X80 : 55|8@0+ (1,0) [0|1] "" XXX + +BO_ 1042 LKAS_HUD: 8 XXX + SG_ BARRIERS : 1|2@0+ (1,0) [0|3] "" XXX + SG_ RIGHT_LINE : 3|2@0+ (1,0) [0|3] "" XXX + SG_ LEFT_LINE : 5|2@0+ (1,0) [0|3] "" XXX + SG_ SET_ME_X01 : 7|2@0+ (1,0) [0|3] "" XXX + SG_ SET_ME_X01_2 : 11|2@0+ (1,0) [0|3] "" XXX + SG_ LDA_ALERT : 9|2@0+ (1,0) [0|3] "" XXX + SG_ TWO_BEEPS : 12|1@0+ (1,0) [0|1] "" XXX + SG_ ADJUSTING_CAMERA : 13|1@0+ (1,0) [0|1] "" XXX + SG_ LDA_MALFUNCTION : 15|1@0+ (1,0) [0|1] "" XXX + SG_ REPEATED_BEEPS : 32|1@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X0C : 23|8@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X2C : 47|8@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X38 : 55|8@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X02 : 63|8@0+ (1,0) [0|1] "" XXX + +BO_ 1043 TIME : 8 CGW + SG_ YEAR : 7|8@0+ (1,0) [0|0] "year" XXX + SG_ MONTH : 15|8@0+ (1,0) [0|0] "month" XXX + SG_ DAY : 23|8@0+ (1,0) [0|0] "day" XXX + SG_ HOUR : 31|8@0+ (1,0) [0|0] "hour" XXX + SG_ MINUTE : 39|8@0+ (1,0) [0|0] "minute" XXX + SG_ GMT_DIFF : 55|1@0+ (1,0) [0|0] "" XXX + SG_ GMTDIFF_HOURS : 54|4@0+ (1,0) [0|0] "hours" XXX + SG_ GMTDIFF_MINUTES : 50|6@0+ (1,0) [0|0] "minutes" XXX + SG_ SUMMER : 60|1@0+ (1,0) [0|0] "" XXX + +BO_ 1408 VIN_PART_1: 8 CGW + SG_ VIN_1 : 7|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_2 : 15|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_3 : 23|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_4 : 31|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_5 : 39|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_6 : 47|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_7 : 55|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_8 : 63|8@0+ (1,0) [0|0] "" XXX + +BO_ 1409 VIN_PART_2: 8 CGW + SG_ VIN_9 : 7|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_10 : 15|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_11 : 23|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_12 : 31|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_13 : 39|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_14 : 47|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_15 : 55|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_16 : 63|8@0+ (1,0) [0|0] "" XXX + +BO_ 1410 VIN_PART_3: 8 CGW + SG_ VIN_17 : 7|8@0+ (1,0) [0|0] "" XXX + +BO_ 1553 UI_SETTING: 8 XXX + SG_ UNITS : 26|2@0+ (1,0) [0|3] "" XXX + +BO_ 1556 STEERING_LEVERS: 8 XXX + SG_ TURN_SIGNALS : 29|2@0+ (1,0) [0|3] "" XXX + +BO_ 1568 SEATS_DOORS: 8 XXX + SG_ SEATBELT_DRIVER_UNLATCHED : 62|1@0+ (1,0) [0|1] "" XXX + SG_ DOOR_OPEN_FL : 45|1@0+ (1,0) [0|1] "" XXX + SG_ DOOR_OPEN_RL : 42|1@0+ (1,0) [0|1] "" XXX + SG_ DOOR_OPEN_RR : 43|1@0+ (1,0) [0|1] "" XXX + SG_ DOOR_OPEN_FR : 44|1@0+ (1,0) [0|1] "" XXX + +BO_ 1570 LIGHT_STALK: 8 SCM + SG_ AUTO_HIGH_BEAM : 37|1@0+ (1,0) [0|1] "" XXX + +BO_ 1161 RSA1: 8 FCM + SG_ TSGN1 : 7|8@0+ (1,0) [0|0] "" XXX + SG_ TSGNGRY1 : 12|3@0+ (1,0) [0|0] "" XXX + SG_ TSGNHLT1 : 9|2@0+ (1,0) [0|0] "" XXX + SG_ SPDVAL1 : 23|8@0+ (1,0) [0|0] "kph" XXX + SG_ SPLSGN1 : 31|4@0+ (1,0) [0|0] "" XXX + SG_ SPLSGN2 : 27|4@0+ (1,0) [0|0] "" XXX + SG_ TSGN2 : 39|8@0+ (1,0) [0|0] "" XXX + SG_ TSGNGRY2 : 44|3@0+ (1,0) [0|0] "" XXX + SG_ TSGNHLT2 : 41|2@0+ (1,0) [0|0] "" XXX + SG_ SPDVAL2 : 55|8@0+ (1,0) [0|0] "" XXX + SG_ BZRRQ_P : 63|2@0+ (1,0) [0|0] "" XXX + SG_ BZRRQ_A : 61|2@0+ (1,0) [0|0] "" XXX + SG_ SYNCID1 : 59|4@0+ (1,0) [0|0] "" XXX + +BO_ 1162 RSA2: 8 FCM + SG_ TSGN3 : 7|8@0+ (1,0) [0|0] "" XXX + SG_ TSGNGRY3 : 12|3@0+ (1,0) [0|0] "" XXX + SG_ TSGNHLT3 : 9|2@0+ (1,0) [0|0] "" XXX + SG_ SPLSGN3 : 31|4@0+ (1,0) [0|0] "" XXX + SG_ SPLSGN4 : 27|4@0+ (1,0) [0|0] "" XXX + SG_ TSGN4 : 39|8@0+ (1,0) [0|0] "" XXX + SG_ TSGNGRY4 : 44|3@0+ (1,0) [0|0] "" XXX + SG_ TSGNHLT4 : 41|2@0+ (1,0) [0|0] "" XXX + SG_ DPSGNREQ : 54|1@0+ (1,0) [0|0] "" XXX + SG_ SGNNUMP : 53|3@0+ (1,0) [0|0] "" XXX + SG_ SGNNUMA : 50|3@0+ (1,0) [0|0] "" XXX + SG_ SPDUNT : 63|2@0+ (1,0) [0|0] "" XXX + SG_ TSRWMSG : 61|2@0+ (1,0) [0|0] "" XXX + SG_ SYNCID2 : 59|4@0+ (1,0) [0|0] "" XXX + +BO_ 1163 RSA3: 8 FCM + SG_ TSREQPD : 7|1@0+ (1,0) [0|0] "" XXX + SG_ TSRMSW : 6|1@0+ (1,0) [0|0] "" XXX + SG_ OTSGNNTM : 5|2@0+ (1,0) [0|0] "" XXX + SG_ NTLVLSPD : 3|2@0+ (1,0) [0|0] "" XXX + SG_ OVSPNTM : 1|2@0+ (1,0) [0|0] "" XXX + SG_ OVSPVALL : 11|4@0+ (1,-5) [0|0] "" XXX + SG_ OVSPVALM : 19|4@0+ (1,-5) [0|0] "" XXX + SG_ OVSPVALH : 27|4@0+ (1,-5) [0|0] "" XXX + SG_ TSRSPU : 33|2@0+ (1,0) [0|0] "" XXX + +CM_ SG_ 36 ACCEL_Y "unit is tbd"; +CM_ SG_ 36 YAW_RATE "verify"; +CM_ SG_ 36 STEERING_TORQUE "does not seem the steer torque, tbd"; +CM_ SG_ 37 STEER_FRACTION "1/15th of the signal STEER_ANGLE, which is 1.5 deg; note that 0x8 is never set"; +CM_ SG_ 37 STEER_RATE "factor is tbd"; +CM_ SG_ 466 ACCEL_NET "net acceleration produced by the system, given ACCEL_CMD, road grade and other factors"; +CM_ SG_ 467 SET_SPEED "43 kph are shown as 28mph, so conversion isn't perfect"; +CM_ SG_ 467 LOW_SPEED_LOCKOUT "in low speed lockout, system would always disengage below 28mph"; +CM_ SG_ 560 BRAKE_PRESSED "another brake pressed?"; +CM_ SG_ 608 STEER_TORQUE_DRIVER "driver torque"; +CM_ SG_ 608 STEER_OVERRIDE "set when driver torque exceeds a certain value"; +CM_ SG_ 614 ANGLE "set to measured angle when ipas control isn't active"; +CM_ SG_ 643 COUNTER "only used on cars that use this msg for cruise control"; +CM_ SG_ 643 BRAKE_STATUS "only used on cars that use this msg for cruise control"; +CM_ SG_ 643 PRECOLLISION_ACTIVE "set 0.5s before any braking"; +CM_ SG_ 835 PERMIT_BRAKING "Original ACC has this going high when a car in front is detected. In openpilot and before the PERMIT_BRAKING name, this was "SET_ME_1" and is hardcoded to be high. Unsure if only informational or has an effect though existing usage in openpilot is to always set it to 1. Originally 'PMTBRKG' in the leaked toyota_2017_ref_pt.dbc file and name expansion speculated to be PerMiT BRaKinG."; +CM_ SG_ 835 ACCEL_CMD_ALT "Copy of main ACCEL_CMD, but across 8 bits instead of 16 bits like ACCEL_CMD. Unsure if only informational or has an effect. Likely informational as existing openpilot sets this to 0 and no loss of functionality observed. Originally 'AT_RAW' in leaked toyota_2017_ref_pt.dbc file."; +CM_ SG_ 921 UI_SET_SPEED "set speed shown in UI with user set unit"; +CM_ SG_ 951 BRAKE_LIGHTS_ACC "brake lights when ACC commands decel"; +CM_ SG_ 1042 SET_ME_1 "unclear what this is, but it's always 1 in drive traces"; +CM_ SG_ 1042 REPEATED_BEEPS "recommended for fcw and other important alerts"; +CM_ SG_ 1161 SPDVAL1 "Numbers 0-199 is displayed, 200-254 displays circle without number and 255 is for no limit."; +CM_ SG_ 1161 SYNCID1 "counter from 1 to f at 1 Hz"; +CM_ SG_ 1161 SPDVAL2 "conditional speed value 70" +CM_ SG_ 1162 SGNNUMP "1 if SPDVAL1 is set, otherwise 0"; +CM_ SG_ 1162 SYNCID2 "counter from 1 to f at 1 Hz"; +CM_ SG_ 1163 TSREQPD "always 1"; +CM_ SG_ 1163 TSRMSW "always 1"; +CM_ SG_ 1163 OTSGNNTM "always 3"; +CM_ SG_ 1163 NTLVLSPD "always 3"; +CM_ SG_ 1163 OVSPNTM "always 3"; +CM_ SG_ 1163 OVSPVALL "-5 at start then 2 after 2 seconds"; +CM_ SG_ 1163 OVSPVALM "-5 at start then 5 after 2 seconds"; +CM_ SG_ 1163 OVSPVALH "-5 at start then 10 after 2 seconds"; +CM_ SG_ 1163 TSRSPU "always 1"; + +VAL_ 466 CRUISE_STATE 8 "active" 7 "standstill" 1 "off"; +VAL_ 467 LOW_SPEED_LOCKOUT 2 "low speed locked" 1 "ok"; +VAL_ 614 STATE 3 "enabled" 1 "disabled"; +VAL_ 614 DIRECTION_CMD 3 "right" 2 "center" 1 "left"; +VAL_ 643 STATE 0 "normal" 1 "adaptive_cruise_control" 3 "emergency_braking"; +VAL_ 921 CRUISE_CONTROL_STATE 2 "disabled" 11 "hold" 10 "hold_waiting_user_cmd" 6 "enabled" 5 "faulted"; +VAL_ 1042 LDA_ALERT 3 "hold with continuous beep" 2 "LDA unavailable" 1 "hold" 0 "none"; +VAL_ 1042 BARRIERS 3 "both" 2 "right" 1 "left" 0 "none"; +VAL_ 1042 RIGHT_LINE 3 "orange" 2 "faded" 1 "solid" 0 "none"; +VAL_ 1042 LEFT_LINE 3 "orange" 2 "faded" 1 "solid" 0 "none"; +VAL_ 1553 UNITS 1 "km" 2 "miles"; +VAL_ 1556 TURN_SIGNALS 3 "none" 2 "right" 1 "left"; +VAL_ 1161 TSGN1 1 "speed sign" 0 "none"; +VAL_ 1161 TSGN2 1 "speed sign" 0 "none"; +VAL_ 1161 SPLSGN2 15 "conditional blank" 4 "wet road" 5 "rain" 0 "none"; +VAL_ 1162 TSGN3 0 "none" 1 "speed sign" 2 "0 unlimited" 7 "unlimited" 16 "highway" 17 "no highway" 18 "motorway" 19 "no motorway" 20 "in city" 21 "outside city" 22 "pedestrian area" 23 "no pedestrian area" 65 "no overtaking left" 66 "no overtaking right" 67 "overtaking allowed again" 129 "no entry"; +VAL_ 1162 SPLSGN3 15 "conditional blank" 4 "wet road" 5 "rain" 0 "none"; + + +CM_ "CHFFR_METRIC 37 STEER_ANGLE STEER_ANGLE 0.36 180"; + +CM_ "lexus_is_2018_pt.dbc starts here" + + + +BO_ 550 BRAKE_MODULE: 8 XXX + SG_ BRAKE_PRESSURE : 0|9@0+ (1,0) [0|511] "" XXX + SG_ BRAKE_POSITION : 16|9@0+ (1,0) [0|511] "" XXX + SG_ BRAKE_PRESSED : 37|1@0+ (1,0) [0|1] "" XXX + +BO_ 581 GAS_PEDAL_ALT: 5 XXX + SG_ GAS_PEDAL : 23|8@0+ (0.005,0) [0|1] "" XXX + +BO_ 705 GAS_PEDAL: 8 XXX + SG_ GAS_RELEASED : 3|1@0+ (1,0) [0|1] "" XXX + SG_ GAS_PEDAL : 55|8@0+ (0.005,0) [0|1] "" XXX + +BO_ 608 STEER_TORQUE_SENSOR: 8 XXX + SG_ STEER_TORQUE_EPS : 47|16@0- (1.30,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 + SG_ STEER_ANGLE : 31|16@0- (0.0573,0) [-500|500] "" XXX + +BO_ 610 EPS_STATUS: 5 EPS + SG_ IPAS_STATE : 3|4@0+ (1,0) [0|15] "" XXX + SG_ LKA_STATE : 31|7@0+ (1,0) [0|127] "" XXX + SG_ TYPE : 24|1@0+ (1,0) [0|1] "" XXX + SG_ CHECKSUM : 39|8@0+ (1,0) [0|255] "" XXX + +BO_ 956 GEAR_PACKET: 8 XXX + SG_ GEAR : 13|6@0+ (1,0) [0|63] "" XXX + +BO_ 1009 PCM_CRUISE_ALT: 8 XXX + SG_ MAIN_ON : 13|1@0+ (1,0) [0|3] "" XXX + SG_ CRUISE_STATE : 10|1@0+ (1,0) [0|1] "" XXX + SG_ SET_SPEED : 23|8@0+ (1,0) [0|255] "mph" XXX + +BO_ 1599 LIGHT_STALK_ISH: 8 SCM + SG_ AUTO_HIGH_BEAM : 19|1@0+ (1,0) [0|1] "" XXX + +CM_ SG_ 550 BRAKE_PRESSURE "seems prop to pedal force"; +CM_ SG_ 550 BRAKE_POSITION "seems proportional to pedal displacement, unclear the max value of 0x1c8"; +CM_ SG_ 610 TYPE "seems 1 on Corolla, 0 on all others"; +CM_ SG_ 1009 SET_SPEED "units seem to be whatever the car is set to"; +VAL_ 956 GEAR 0 "D" 1 "S" 8 "N" 16 "R" 32 "P"; +VAL_ 610 IPAS_STATE 5 "override" 3 "enabled" 1 "disabled"; +VAL_ 610 LKA_STATE 25 "temporary_fault" 9 "temporary_fault2" 5 "active" 1 "standby"; diff --git a/opendbc/lexus_nxt_2015_pt_generated.dbc b/opendbc/lexus_nxt_2015_pt_generated.dbc new file mode 100644 index 00000000000000..a3a0bccb3b06b4 --- /dev/null +++ b/opendbc/lexus_nxt_2015_pt_generated.dbc @@ -0,0 +1,408 @@ +CM_ "AUTOGENERATED FILE, DO NOT EDIT" + + +CM_ "Imported file _comma.dbc starts here" +BO_ 359 STEERING_IPAS_COMMA: 8 IPAS + SG_ STATE : 7|4@0+ (1,0) [0|15] "" XXX + SG_ ANGLE : 3|12@0- (1.5,0) [-510|510] "deg" XXX + SG_ SET_ME_X10 : 23|8@0+ (1,0) [0|255] "" XXX + SG_ SET_ME_X00 : 31|8@0+ (1,0) [0|255] "" XXX + SG_ DIRECTION_CMD : 38|2@0+ (1,0) [0|3] "" XXX + SG_ SET_ME_X40 : 47|8@0+ (1,0) [0|255] "" XXX + SG_ SET_ME_X00 : 55|8@0+ (1,0) [0|255] "" XXX + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX + +CM BO_ STEERING_IPAS_COMMA "Copy of msg 614 so we can do angle control while the Park Assist ECU is connected (Panda spoofs 614 with 359 on connector J70). Note that addresses 0x266 and 0x167 are checksum-invariant"; + + BO_ 512 GAS_COMMAND: 6 EON + SG_ GAS_COMMAND : 7|16@0+ (0.159375,-75.555) [0|1] "" INTERCEPTOR + SG_ GAS_COMMAND2 : 23|16@0+ (0.159375,-151.111) [0|1] "" INTERCEPTOR + SG_ ENABLE : 39|1@0+ (1,0) [0|1] "" INTERCEPTOR + SG_ COUNTER_PEDAL : 35|4@0+ (1,0) [0|15] "" INTERCEPTOR + SG_ CHECKSUM_PEDAL : 47|8@0+ (1,0) [0|255] "" INTERCEPTOR + + BO_ 513 GAS_SENSOR: 6 INTERCEPTOR + SG_ INTERCEPTOR_GAS : 7|16@0+ (0.159375,-75.555) [0|1] "" EON + SG_ INTERCEPTOR_GAS2 : 23|16@0+ (0.159375,-151.111) [0|1] "" EON + SG_ STATE : 39|4@0+ (1,0) [0|15] "" EON + SG_ COUNTER_PEDAL : 35|4@0+ (1,0) [0|15] "" EON + SG_ CHECKSUM_PEDAL : 47|8@0+ (1,0) [0|255] "" EON + + VAL_ 513 STATE 5 "FAULT_TIMEOUT" 4 "FAULT_STARTUP" 3 "FAULT_SCE" 2 "FAULT_SEND" 1 "FAULT_BAD_CHECKSUM" 0 "NO_FAULT" ; + + +CM_ "Imported file _toyota_2017.dbc starts here" +VERSION "" + + +NS_ : + NS_DESC_ + CM_ + BA_DEF_ + BA_ + VAL_ + CAT_DEF_ + CAT_ + FILTER + BA_DEF_DEF_ + EV_DATA_ + ENVVAR_DATA_ + SGTYPE_ + SGTYPE_VAL_ + BA_DEF_SGTYPE_ + BA_SGTYPE_ + SIG_TYPE_REF_ + VAL_TABLE_ + SIG_GROUP_ + SIG_VALTYPE_ + SIGTYPE_VALTYPE_ + BO_TX_BU_ + BA_DEF_REL_ + BA_REL_ + BA_DEF_DEF_REL_ + BU_SG_REL_ + BU_EV_REL_ + BU_BO_REL_ + SG_MUL_VAL_ + +BS_: + +BU_: XXX DSU HCU EPS IPAS CGW + +BO_ 36 KINEMATICS: 8 XXX + SG_ ACCEL_Y : 33|10@0+ (0.03589,-18.375) [0|65535] "m/s^2" XXX + SG_ YAW_RATE : 1|10@0+ (0.244,-125) [0|65535] "deg/sec" XXX + SG_ STEERING_TORQUE : 17|10@0+ (1,-512) [0|65535] "" XXX + +BO_ 37 STEER_ANGLE_SENSOR: 8 XXX + SG_ STEER_ANGLE : 3|12@0- (1.5,0) [-500|500] "deg" XXX + SG_ STEER_FRACTION : 39|4@0- (0.1,0) [-0.7|0.7] "deg" XXX + SG_ STEER_RATE : 35|12@0- (1,0) [-2000|2000] "deg/s" XXX + +BO_ 166 BRAKE: 8 XXX + SG_ BRAKE_AMOUNT : 7|8@0+ (1,0) [0|255] "" XXX + SG_ BRAKE_PEDAL : 23|8@0+ (1,0) [0|255] "" XXX + +BO_ 170 WHEEL_SPEEDS: 8 XXX + SG_ WHEEL_SPEED_FR : 7|16@0+ (0.01,-67.67) [0|250] "kph" XXX + SG_ WHEEL_SPEED_FL : 23|16@0+ (0.01,-67.67) [0|250] "kph" XXX + SG_ WHEEL_SPEED_RR : 39|16@0+ (0.01,-67.67) [0|250] "kph" XXX + SG_ WHEEL_SPEED_RL : 55|16@0+ (0.01,-67.67) [0|250] "kph" XXX + +BO_ 180 SPEED: 8 XXX + SG_ ENCODER : 39|8@0+ (1,0) [0|255] "" XXX + SG_ SPEED : 47|16@0+ (0.01,0) [0|250] "kph" XXX + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX + +BO_ 353 DSU_SPEED: 8 XXX + SG_ FORWARD_SPEED : 15|16@0- (0.00390625,-30) [0|255] "kph" XXX + +BO_ 452 ENGINE_RPM: 8 CGW + SG_ RPM : 7|16@0- (0.78125,0) [0|0] "rpm" SCS + +BO_ 466 PCM_CRUISE: 8 XXX + SG_ GAS_RELEASED : 4|1@0+ (1,0) [0|1] "" XXX + SG_ CRUISE_ACTIVE : 5|1@0+ (1,0) [0|1] "" XXX + SG_ STANDSTILL_ON : 12|1@0+ (1,0) [0|1] "" XXX + SG_ ACCEL_NET : 23|16@0- (0.001,0) [-20|20] "m/s2" XXX + SG_ CRUISE_STATE : 55|4@0+ (1,0) [0|15] "" XXX + SG_ CANCEL_REQ : 49|1@1+ (1,0) [0|1] "" XXX + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX + +BO_ 467 PCM_CRUISE_2: 8 XXX + SG_ MAIN_ON : 15|1@0+ (1,0) [0|1] "" XXX + SG_ LOW_SPEED_LOCKOUT : 14|2@0+ (1,0) [0|3] "kph" XXX + SG_ SET_SPEED : 23|8@0+ (1,0) [0|255] "kph" XXX + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX + +BO_ 552 ACCELEROMETER: 8 XXX + SG_ ACCEL_Z : 22|15@0- (1,0) [0|32767] "" XXX + SG_ ACCEL_X : 6|15@0- (0.001,0) [-20|20] "m/s2" XXX + +BO_ 560 BRAKE_MODULE2: 7 XXX + SG_ BRAKE_PRESSED : 26|1@0+ (1,0) [0|1] "" XXX + +BO_ 614 STEERING_IPAS: 8 IPAS + SG_ STATE : 7|4@0+ (1,0) [0|15] "" XXX + SG_ ANGLE : 3|12@0- (1.5,0) [-510|510] "deg" XXX + SG_ SET_ME_X10 : 23|8@0+ (1,0) [0|255] "" XXX + SG_ SET_ME_X00 : 31|8@0+ (1,0) [0|255] "" XXX + SG_ DIRECTION_CMD : 38|2@0+ (1,0) [0|3] "" XXX + SG_ SET_ME_X40 : 47|8@0+ (1,0) [0|255] "" XXX + SG_ SET_ME_X00_1 : 55|8@0+ (1,0) [0|255] "" XXX + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX + +BO_ 643 PRE_COLLISION: 7 DSU + SG_ COUNTER : 7|8@0+ (1,0) [0|255] "" XXX + SG_ SET_ME_X00 : 15|8@0+ (1,0) [0|255] "" XXX + SG_ FORCE : 23|16@0- (2,0) [0|255] "N" XXX + SG_ SET_ME_X002 : 33|8@0+ (1,0) [0|3] "" XXX + SG_ BRAKE_STATUS : 39|3@0+ (1,0) [0|255] "" XXX + SG_ STATE : 36|3@0+ (1,0) [0|255] "" XXX + SG_ SET_ME_X003 : 40|1@0+ (1,0) [0|1] "" XXX + SG_ PRECOLLISION_ACTIVE : 41|1@0+ (1,0) [0|255] "" XXX + SG_ CHECKSUM : 55|8@0+ (1,0) [0|255] "" XXX + +BO_ 740 STEERING_LKA: 5 XXX + SG_ LKA_STATE : 31|8@0+ (1,0) [0|255] "" XXX + SG_ STEER_REQUEST : 0|1@0+ (1,0) [0|1] "" XXX + SG_ COUNTER : 6|6@0+ (1,0) [0|63] "" XXX + SG_ SET_ME_1 : 7|1@0+ (1,0) [0|1] "" XXX + SG_ STEER_TORQUE_CMD : 15|16@0- (1,0) [0|65535] "" XXX + SG_ CHECKSUM : 39|8@0+ (1,0) [0|255] "" XXX + +BO_ 742 LEAD_INFO: 8 DSU + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" HCU + SG_ LEAD_REL_SPEED : 23|12@0- (0.025,0) [-100|100] "m/s" HCU + SG_ LEAD_LONG_DIST : 7|13@0+ (0.05,0) [0|300] "m" HCU + +BO_ 835 ACC_CONTROL: 8 DSU + SG_ ACCEL_CMD : 7|16@0- (0.001,0) [-20|20] "m/s2" HCU + SG_ SET_ME_X01 : 23|2@0+ (1,0) [0|3] "" HCU + SG_ DISTANCE : 20|1@0+ (1,0) [0|1] "" XXX + SG_ MINI_CAR : 21|1@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X3 : 19|4@0+ (1,0) [0|15] "" XXX + SG_ SET_ME_1 : 30|1@0+ (1,0) [0|1] "" HCU + SG_ RELEASE_STANDSTILL : 31|1@0+ (1,0) [0|1] "" HCU + SG_ CANCEL_REQ : 24|1@0+ (1,0) [0|1] "" HCU + SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX + +BO_ 836 PRE_COLLISION_2: 8 DSU + SG_ CHECKSUM : 63|8@0+ (1,0) [0|0] "" XXX + +BO_ 869 DSU_CRUISE : 7 DSU + SG_ RES_BTN : 3|1@0+ (1,0) [0|0] "" XXX + SG_ SET_BTN : 2|1@0+ (1,0) [0|0] "" XXX + SG_ CANCEL_BTN : 1|1@0+ (1,0) [0|0] "" XXX + SG_ MAIN_ON : 0|1@0+ (1,0) [0|0] "" XXX + SG_ SET_SPEED : 15|8@0+ (1,0) [0|0] "km/h" XXX + SG_ CRUISE_REQUEST : 31|8@0+ (100,-12800) [0|0] "N" XXX + SG_ LEAD_DISTANCE : 39|8@0+ (1,0) [0|0] "m" XXX + +BO_ 921 PCM_CRUISE_SM: 8 XXX + SG_ MAIN_ON : 4|1@0+ (1,0) [0|1] "" XXX + SG_ CRUISE_CONTROL_STATE : 11|4@0+ (1,0) [0|15] "" XXX + SG_ DISTANCE_LINES : 14|2@0+ (1,0) [0|3] "" XXX + SG_ UI_SET_SPEED : 31|8@0+ (1,0) [0|255] "" XXX + +BO_ 951 ESP_CONTROL: 8 ESP + SG_ TC_DISABLED : 13|1@0+ (1,0) [0|1] "" XXX + SG_ VSC_DISABLED : 12|2@0+ (1,0) [0|1] "" XXX + SG_ BRAKE_LIGHTS_ACC : 18|1@0+ (1,0) [0|1] "" XXX + +BO_ 1041 ACC_HUD: 8 DSU + SG_ FCW : 4|1@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X20 : 15|8@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X10 : 39|8@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X80 : 55|8@0+ (1,0) [0|1] "" XXX + +BO_ 1042 LKAS_HUD: 8 XXX + SG_ BARRIERS : 1|2@0+ (1,0) [0|3] "" XXX + SG_ RIGHT_LINE : 3|2@0+ (1,0) [0|3] "" XXX + SG_ LEFT_LINE : 5|2@0+ (1,0) [0|3] "" XXX + SG_ SET_ME_X01 : 7|2@0+ (1,0) [0|3] "" XXX + SG_ SET_ME_X01_2 : 11|2@0+ (1,0) [0|3] "" XXX + SG_ LDA_ALERT : 9|2@0+ (1,0) [0|3] "" XXX + SG_ TWO_BEEPS : 12|1@0+ (1,0) [0|1] "" XXX + SG_ ADJUSTING_CAMERA : 13|1@0+ (1,0) [0|1] "" XXX + SG_ LDA_MALFUNCTION : 15|1@0+ (1,0) [0|1] "" XXX + SG_ REPEATED_BEEPS : 32|1@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X0C : 23|8@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X2C : 47|8@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X38 : 55|8@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X02 : 63|8@0+ (1,0) [0|1] "" XXX + +BO_ 1043 TIME : 8 CGW + SG_ YEAR : 7|8@0+ (1,0) [0|0] "year" XXX + SG_ MONTH : 15|8@0+ (1,0) [0|0] "month" XXX + SG_ DAY : 23|8@0+ (1,0) [0|0] "day" XXX + SG_ HOUR : 31|8@0+ (1,0) [0|0] "hour" XXX + SG_ MINUTE : 39|8@0+ (1,0) [0|0] "minute" XXX + SG_ GMT_DIFF : 55|1@0+ (1,0) [0|0] "" XXX + SG_ GMTDIFF_HOURS : 54|4@0+ (1,0) [0|0] "hours" XXX + SG_ GMTDIFF_MINUTES : 50|6@0+ (1,0) [0|0] "minutes" XXX + SG_ SUMMER : 60|1@0+ (1,0) [0|0] "" XXX + +BO_ 1408 VIN_PART_1: 8 CGW + SG_ VIN_1 : 7|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_2 : 15|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_3 : 23|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_4 : 31|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_5 : 39|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_6 : 47|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_7 : 55|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_8 : 63|8@0+ (1,0) [0|0] "" XXX + +BO_ 1409 VIN_PART_2: 8 CGW + SG_ VIN_9 : 7|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_10 : 15|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_11 : 23|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_12 : 31|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_13 : 39|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_14 : 47|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_15 : 55|8@0+ (1,0) [0|0] "" XXX + SG_ VIN_16 : 63|8@0+ (1,0) [0|0] "" XXX + +BO_ 1410 VIN_PART_3: 8 CGW + SG_ VIN_17 : 7|8@0+ (1,0) [0|0] "" XXX + +BO_ 1553 UI_SETTING: 8 XXX + SG_ UNITS : 26|2@0+ (1,0) [0|3] "" XXX + +BO_ 1556 STEERING_LEVERS: 8 XXX + SG_ TURN_SIGNALS : 29|2@0+ (1,0) [0|3] "" XXX + +BO_ 1568 SEATS_DOORS: 8 XXX + SG_ SEATBELT_DRIVER_UNLATCHED : 62|1@0+ (1,0) [0|1] "" XXX + SG_ DOOR_OPEN_FL : 45|1@0+ (1,0) [0|1] "" XXX + SG_ DOOR_OPEN_RL : 42|1@0+ (1,0) [0|1] "" XXX + SG_ DOOR_OPEN_RR : 43|1@0+ (1,0) [0|1] "" XXX + SG_ DOOR_OPEN_FR : 44|1@0+ (1,0) [0|1] "" XXX + +BO_ 1570 LIGHT_STALK: 8 SCM + SG_ AUTO_HIGH_BEAM : 37|1@0+ (1,0) [0|1] "" XXX + +BO_ 1161 RSA1: 8 FCM + SG_ TSGN1 : 7|8@0+ (1,0) [0|0] "" XXX + SG_ TSGNGRY1 : 12|3@0+ (1,0) [0|0] "" XXX + SG_ TSGNHLT1 : 9|2@0+ (1,0) [0|0] "" XXX + SG_ SPDVAL1 : 23|8@0+ (1,0) [0|0] "kph" XXX + SG_ SPLSGN1 : 31|4@0+ (1,0) [0|0] "" XXX + SG_ SPLSGN2 : 27|4@0+ (1,0) [0|0] "" XXX + SG_ TSGN2 : 39|8@0+ (1,0) [0|0] "" XXX + SG_ TSGNGRY2 : 44|3@0+ (1,0) [0|0] "" XXX + SG_ TSGNHLT2 : 41|2@0+ (1,0) [0|0] "" XXX + SG_ SPDVAL2 : 55|8@0+ (1,0) [0|0] "" XXX + SG_ BZRRQ_P : 63|2@0+ (1,0) [0|0] "" XXX + SG_ BZRRQ_A : 61|2@0+ (1,0) [0|0] "" XXX + SG_ SYNCID1 : 59|4@0+ (1,0) [0|0] "" XXX + +BO_ 1162 RSA2: 8 FCM + SG_ TSGN3 : 7|8@0+ (1,0) [0|0] "" XXX + SG_ TSGNGRY3 : 12|3@0+ (1,0) [0|0] "" XXX + SG_ TSGNHLT3 : 9|2@0+ (1,0) [0|0] "" XXX + SG_ SPLSGN3 : 31|4@0+ (1,0) [0|0] "" XXX + SG_ SPLSGN4 : 27|4@0+ (1,0) [0|0] "" XXX + SG_ TSGN4 : 39|8@0+ (1,0) [0|0] "" XXX + SG_ TSGNGRY4 : 44|3@0+ (1,0) [0|0] "" XXX + SG_ TSGNHLT4 : 41|2@0+ (1,0) [0|0] "" XXX + SG_ DPSGNREQ : 54|1@0+ (1,0) [0|0] "" XXX + SG_ SGNNUMP : 53|3@0+ (1,0) [0|0] "" XXX + SG_ SGNNUMA : 50|3@0+ (1,0) [0|0] "" XXX + SG_ SPDUNT : 63|2@0+ (1,0) [0|0] "" XXX + SG_ TSRWMSG : 61|2@0+ (1,0) [0|0] "" XXX + SG_ SYNCID2 : 59|4@0+ (1,0) [0|0] "" XXX + +BO_ 1163 RSA3: 8 FCM + SG_ TSREQPD : 7|1@0+ (1,0) [0|0] "" XXX + SG_ TSRMSW : 6|1@0+ (1,0) [0|0] "" XXX + SG_ OTSGNNTM : 5|2@0+ (1,0) [0|0] "" XXX + SG_ NTLVLSPD : 3|2@0+ (1,0) [0|0] "" XXX + SG_ OVSPNTM : 1|2@0+ (1,0) [0|0] "" XXX + SG_ OVSPVALL : 11|4@0+ (1,-5) [0|0] "" XXX + SG_ OVSPVALM : 19|4@0+ (1,-5) [0|0] "" XXX + SG_ OVSPVALH : 27|4@0+ (1,-5) [0|0] "" XXX + SG_ TSRSPU : 33|2@0+ (1,0) [0|0] "" XXX + +CM_ SG_ 36 ACCEL_Y "unit is tbd"; +CM_ SG_ 36 YAW_RATE "verify"; +CM_ SG_ 36 STEERING_TORQUE "does not seem the steer torque, tbd"; +CM_ SG_ 37 STEER_FRACTION "1/15th of the signal STEER_ANGLE, which is 1.5 deg; note that 0x8 is never set"; +CM_ SG_ 37 STEER_RATE "factor is tbd"; +CM_ SG_ 466 ACCEL_NET "net acceleration produced by the system, given ACCEL_CMD, road grade and other factors"; +CM_ SG_ 467 SET_SPEED "43 kph are shown as 28mph, so conversion isn't perfect"; +CM_ SG_ 467 LOW_SPEED_LOCKOUT "in low speed lockout, system would always disengage below 28mph"; +CM_ SG_ 560 BRAKE_PRESSED "another brake pressed?"; +CM_ SG_ 608 STEER_TORQUE_DRIVER "driver torque"; +CM_ SG_ 608 STEER_OVERRIDE "set when driver torque exceeds a certain value"; +CM_ SG_ 614 ANGLE "set to measured angle when ipas control isn't active"; +CM_ SG_ 643 COUNTER "only used on cars that use this msg for cruise control"; +CM_ SG_ 643 BRAKE_STATUS "only used on cars that use this msg for cruise control"; +CM_ SG_ 643 PRECOLLISION_ACTIVE "set 0.5s before any braking"; +CM_ SG_ 921 UI_SET_SPEED "set speed shown in UI with user set unit"; +CM_ SG_ 951 BRAKE_LIGHTS_ACC "brake lights when ACC commands decel"; +CM_ SG_ 1042 SET_ME_1 "unclear what this is, but it's always 1 in drive traces"; +CM_ SG_ 1042 REPEATED_BEEPS "recommended for fcw and other important alerts"; +CM_ SG_ 1161 SPDVAL1 "Numbers 0-199 is displayed, 200-254 displays circle without number and 255 is for no limit."; +CM_ SG_ 1161 SYNCID1 "counter from 1 to f at 1 Hz"; +CM_ SG_ 1161 SPDVAL2 "conditional speed value 70" +CM_ SG_ 1162 SGNNUMP "1 if SPDVAL1 is set, otherwise 0"; +CM_ SG_ 1162 SYNCID2 "counter from 1 to f at 1 Hz"; +CM_ SG_ 1163 TSREQPD "always 1"; +CM_ SG_ 1163 TSRMSW "always 1"; +CM_ SG_ 1163 OTSGNNTM "always 3"; +CM_ SG_ 1163 NTLVLSPD "always 3"; +CM_ SG_ 1163 OVSPNTM "always 3"; +CM_ SG_ 1163 OVSPVALL "-5 at start then 2 after 2 seconds"; +CM_ SG_ 1163 OVSPVALM "-5 at start then 5 after 2 seconds"; +CM_ SG_ 1163 OVSPVALH "-5 at start then 10 after 2 seconds"; +CM_ SG_ 1163 TSRSPU "always 1"; + +VAL_ 466 CRUISE_STATE 8 "active" 7 "standstill" 1 "off"; +VAL_ 467 LOW_SPEED_LOCKOUT 2 "low speed locked" 1 "ok"; +VAL_ 614 STATE 3 "enabled" 1 "disabled"; +VAL_ 614 DIRECTION_CMD 3 "right" 2 "center" 1 "left"; +VAL_ 643 STATE 0 "normal" 1 "adaptive_cruise_control" 3 "emergency_braking"; +VAL_ 921 CRUISE_CONTROL_STATE 2 "disabled" 11 "hold" 10 "hold_waiting_user_cmd" 6 "enabled" 5 "faulted"; +VAL_ 1042 LDA_ALERT 3 "hold with continuous beep" 2 "LDA unavailable" 1 "hold" 0 "none"; +VAL_ 1042 BARRIERS 3 "both" 2 "right" 1 "left" 0 "none"; +VAL_ 1042 RIGHT_LINE 3 "orange" 2 "faded" 1 "solid" 0 "none"; +VAL_ 1042 LEFT_LINE 3 "orange" 2 "faded" 1 "solid" 0 "none"; +VAL_ 1553 UNITS 1 "km" 2 "miles"; +VAL_ 1556 TURN_SIGNALS 3 "none" 2 "right" 1 "left"; +VAL_ 1161 TSGN1 1 "speed sign" 0 "none"; +VAL_ 1161 TSGN2 1 "speed sign" 0 "none"; +VAL_ 1161 SPLSGN2 15 "conditional blank" 4 "wet road" 5 "rain" 0 "none"; +VAL_ 1162 TSGN3 0 "none" 1 "speed sign" 2 "0 unlimited" 7 "unlimited" 16 "highway" 17 "no highway" 18 "motorway" 19 "no motorway" 20 "in city" 21 "outside city" 22 "pedestrian area" 23 "no pedestrian area" 65 "no overtaking left" 66 "no overtaking right" 67 "overtaking allowed again" 129 "no entry"; +VAL_ 1162 SPLSGN3 15 "conditional blank" 4 "wet road" 5 "rain" 0 "none"; + + +CM_ "CHFFR_METRIC 37 STEER_ANGLE STEER_ANGLE 0.36 180"; + +CM_ "lexus_nxt_2015_pt.dbc starts here" + + + +BO_ 550 BRAKE_MODULE: 8 XXX + SG_ BRAKE_PRESSURE : 0|9@0+ (1,0) [0|511] "" XXX + SG_ BRAKE_POSITION : 16|9@0+ (1,0) [0|511] "" XXX + SG_ BRAKE_PRESSED : 37|1@0+ (1,0) [0|1] "" XXX + +BO_ 581 GAS_PEDAL_ALT: 5 XXX + SG_ GAS_PEDAL : 23|8@0+ (0.005,0) [0|1] "" XXX + +BO_ 705 GAS_PEDAL: 8 XXX + SG_ GAS_RELEASED : 3|1@0+ (1,0) [0|1] "" XXX + SG_ GAS_PEDAL : 55|8@0+ (0.005,0) [0|1] "" XXX + +BO_ 608 STEER_TORQUE_SENSOR: 8 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 + SG_ STEER_ANGLE : 31|16@0- (0.0573,0) [-500|500] "" XXX + +BO_ 610 EPS_STATUS: 5 EPS + SG_ IPAS_STATE : 3|4@0+ (1,0) [0|15] "" XXX + SG_ LKA_STATE : 31|7@0+ (1,0) [0|127] "" XXX + SG_ TYPE : 24|1@0+ (1,0) [0|1] "" XXX + SG_ CHECKSUM : 39|8@0+ (1,0) [0|255] "" XXX + +BO_ 956 GEAR_PACKET: 8 XXX + SG_ GEAR : 13|6@0+ (1,0) [0|63] "" XXX + +BO_ 1009 PCM_CRUISE_ALT: 8 XXX + SG_ MAIN_ON : 13|1@0+ (1,0) [0|3] "" XXX + SG_ CRUISE_STATE : 10|1@0+ (1,0) [0|1] "" XXX + SG_ SET_SPEED : 23|8@0+ (1,0) [0|255] "mph" XXX + +BO_ 1599 LIGHT_STALK_ISH: 8 SCM + SG_ AUTO_HIGH_BEAM : 19|1@0+ (1,0) [0|1] "" XXX + +CM_ SG_ 550 BRAKE_PRESSURE "seems prop to pedal force"; +CM_ SG_ 550 BRAKE_POSITION "seems proportional to pedal displacement, unclear the max value of 0x1c8"; +CM_ SG_ 610 TYPE "seems 1 on Corolla, 0 on all others"; +CM_ SG_ 1009 SET_SPEED "units seem to be whatever the car is set to"; +VAL_ 956 GEAR 0 "D" 1 "S" 8 "N" 16 "R" 32 "P"; +VAL_ 610 IPAS_STATE 5 "override" 3 "enabled" 1 "disabled"; +VAL_ 610 LKA_STATE 25 "temporary_fault" 9 "temporary_fault2" 5 "active" 1 "standby"; diff --git a/opendbc/toyota_prius_2017_pt_generated.dbc b/opendbc/toyota_prius_2017_pt_generated.dbc index aef24541c74f68..308261820374f0 100644 --- a/opendbc/toyota_prius_2017_pt_generated.dbc +++ b/opendbc/toyota_prius_2017_pt_generated.dbc @@ -132,6 +132,9 @@ BO_ 614 STEERING_IPAS: 8 IPAS SG_ SET_ME_X00_1 : 55|8@0+ (1,0) [0|255] "" XXX SG_ CHECKSUM : 63|8@0+ (1,0) [0|255] "" XXX +BO_ 35 SECONDARY_STEER_ANGLE: 8 XXX + SG_ ZORRO_STEER : 7|24@0- (0.004901594652,0) [-500|500] "" XXX + BO_ 643 PRE_COLLISION: 7 DSU SG_ COUNTER : 7|8@0+ (1,0) [0|255] "" XXX SG_ SET_ME_X00 : 15|8@0+ (1,0) [0|255] "" XXX diff --git a/opendbc/vw_golf_mk4.dbc b/opendbc/vw_golf_mk4.dbc new file mode 100644 index 00000000000000..b1dddeef27ecab --- /dev/null +++ b/opendbc/vw_golf_mk4.dbc @@ -0,0 +1,1400 @@ +VERSION "" + + +NS_ : + NS_DESC_ + CM_ + BA_DEF_ + BA_ + VAL_ + CAT_DEF_ + CAT_ + FILTER + BA_DEF_DEF_ + EV_DATA_ + ENVVAR_DATA_ + SGTYPE_ + SGTYPE_VAL_ + BA_DEF_SGTYPE_ + BA_SGTYPE_ + SIG_TYPE_REF_ + VAL_TABLE_ + SIG_GROUP_ + SIG_VALTYPE_ + SIGTYPE_VALTYPE_ + +BS_: + +BU_: XXX + + +BO_ 1394 ZAS_1: 2 XXX + SG_ Fehlerspeichereintrag__ZAS_ : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_ZAS_1_3 : 8|7@1+ (1,0) [0|0] "" XXX + SG_ Frei_ZAS_1_2 : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Klemme_15_SV : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_ZAS_1_1 : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Klemme_P__Parklichtstellung_ : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Klemme_50__Starten_ : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Klemme_X__Startvorgang_ : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Klemme_15__Z_ndung_ein_ : 1|1@1+ (1,0) [0|0] "" XXX + SG_ S_Kontakt__Schl_ssel_steckt_ : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1336 Wischer_1: 2 XXX + SG_ Blockierung_Heckwischer_erkannt : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Wischer_1_2 : 12|3@1+ (1,0) [0|0] "" XXX + SG_ Fehlerspeichereintrag__Wischer_ : 11|1@1+ (1,0) [0|0] "" XXX + SG_ Ansteuerung_Scheibenwischer_Hec : 10|1@1+ (1,0) [0|0] "" XXX + SG_ Ansteuerung_Wascher_Heck : 9|1@1+ (1,0) [0|0] "" XXX + SG_ Scheibenwischer_Heck_eingeschal : 8|1@1+ (1,0) [0|0] "" XXX + SG_ Blockierung_Frontwischer_erkann : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Wischer_1_1 : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Status_Waschduesenheizung : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Parklage_Frontwischer : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Ansteuerung_Frontwischer_Schnel : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Ansteuerung_Frontwischer_Normal : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Ansteuerung_Wascher_Front : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Frontwischer__eingeschaltet : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1464 WFS_1: 2 XXX + SG_ WFS_Textbits : 8|8@1+ (1,0) [0|0] "" XXX + SG_ Frei_WFS_1_1 : 1|7@1+ (1,0) [0|0] "" XXX + SG_ WFS_LED : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1096 Waehlhebel_1: 4 XXX + SG_ Frei_Waehlhebel_1_1 : 29|3@1+ (1,0) [0|0] "" XXX + SG_ Test_aktiv_Flag : 28|1@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_Waehlhebel_1 : 24|4@1+ (1,0) [0|15] "" XXX + SG_ Waehlhebel_Testergebnis : 16|8@1+ (1,0) [0|255] "" XXX + SG_ Fehler_Waehlhebel : 8|8@1+ (1,0) [0|0] "" XXX + SG_ Waehlhebelposition : 4|4@1+ (1,0) [0|0] "" XXX + SG_ Waehlhebel_Initialisierung : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Shiftlock_Position : 0|3@1+ (1,0) [0|0] "" XXX + +BO_ 1496 Verbauliste_1: 8 XXX + SG_ TV_Tuner : 63|1@1+ (1,0) [0|0] "" XXX + SG_ DSP : 62|1@1+ (1,0) [0|0] "" XXX + SG_ CD_Wechsler : 61|1@1+ (1,0) [0|0] "" XXX + SG_ Spracheingabe : 60|1@1+ (1,0) [0|0] "" XXX + SG_ Telematik : 59|1@1+ (1,0) [0|0] "" XXX + SG_ Navigation : 58|1@1+ (1,0) [0|0] "" XXX + SG_ Telefon : 57|1@1+ (1,0) [0|0] "" XXX + SG_ Radio : 56|1@1+ (1,0) [0|0] "" XXX + SG_ MMI_vorne : 55|1@1+ (1,0) [0|0] "" XXX + SG_ MMI_hinten : 54|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Verbauliste_1_11 : 53|1@1+ (1,0) [0|0] "" XXX + SG_ Klimabedienteil_HL : 52|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Verbauliste_1_10 : 50|2@1+ (1,0) [0|0] "" XXX + SG_ Tankgeber : 49|1@1+ (1,0) [0|0] "" XXX + SG_ Assistenzfahrlicht : 48|1@1+ (1,0) [0|0] "" XXX + SG_ Memory_hinter_Fahrer : 47|1@1+ (1,0) [0|0] "" XXX + SG_ Sitzmemory_hinten : 46|1@1+ (1,0) [0|0] "" XXX + SG_ Sitzmemory_Beifahrer : 45|1@1+ (1,0) [0|0] "" XXX + SG_ Anh_ngersteuergeraet : 44|1@1+ (1,0) [0|0] "" XXX + SG_ Energiemanagement : 43|1@1+ (1,0) [0|0] "" XXX + SG_ Wischermodul : 42|1@1+ (1,0) [0|0] "" XXX + SG_ EZS___Kessy__Komfort_ : 41|1@1+ (1,0) [0|0] "" XXX + SG_ Verdecksteuergeraet : 40|1@1+ (1,0) [0|0] "" XXX + SG_ Standheizung : 39|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Verbauliste_1_9 : 38|1@1+ (1,0) [0|0] "" XXX + SG_ Einparkhilfe : 37|1@1+ (1,0) [0|0] "" XXX + SG_ Klimasteuergeraet_Komfort : 36|1@1+ (1,0) [0|0] "" XXX + SG_ Gateway : 35|1@1+ (1,0) [0|0] "" XXX + SG_ Lenksaeulenmodul : 34|1@1+ (1,0) [0|0] "" XXX + SG_ Reifendruck : 33|1@1+ (1,0) [0|0] "" XXX + SG_ Kombiinstrument_Komfort : 32|1@1+ (1,0) [0|0] "" XXX + SG_ Dachmodul : 31|1@1+ (1,0) [0|0] "" XXX + SG_ Memory : 30|1@1+ (1,0) [0|0] "" XXX + SG_ TSG_HR : 29|1@1+ (1,0) [0|0] "" XXX + SG_ TSG_HL : 28|1@1+ (1,0) [0|0] "" XXX + SG_ TSG_BT : 27|1@1+ (1,0) [0|0] "" XXX + SG_ TSG_FT : 26|1@1+ (1,0) [0|0] "" XXX + SG_ ZKE : 25|1@1+ (1,0) [0|0] "" XXX + SG_ BSG_Komfort : 24|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Verbauliste_1_8 : 19|5@1+ (1,0) [0|0] "" XXX + SG_ Stabi_Entkopplung : 18|1@1+ (1,0) [0|0] "" XXX + SG_ Waehlhebel : 17|1@1+ (1,0) [0|0] "" XXX + SG_ Batteriemanager : 16|1@1+ (1,0) [0|0] "" XXX + SG_ Daempfer_SG : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Niveauregulierung : 14|1@1+ (1,0) [0|0] "" XXX + SG_ EZS___Kessy__Antrieb_ : 13|1@1+ (1,0) [0|0] "" XXX + SG_ Bremsbooster : 12|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfe : 11|1@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Antrieb : 10|1@1+ (1,0) [0|0] "" XXX + SG_ Einspritzpumpe : 9|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkwinkel : 8|1@1+ (1,0) [0|0] "" XXX + SG_ Allrad : 7|1@1+ (1,0) [0|0] "" XXX + SG_ BSG_Antrieb : 6|1@1+ (1,0) [0|0] "" XXX + SG_ ADR : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Airbag : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Climatronic_Antrieb : 3|1@1+ (1,0) [0|0] "" XXX + SG_ ABS : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Getriebesteuergeraet : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Motorsteuergeraet : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1488 Systeminfo_1: 6 XXX + SG_ CAN_Stand_4_1_Antrieb_Daten_Hau : 44|4@1+ (1,0) [0|15] "" XXX + SG_ CAN_Stand_4_1_Antrieb_Daten_Neb : 40|4@1+ (1,0) [0|15] "" XXX + SG_ CAN_Stand_4_1_Komfort_Daten_Hau : 36|4@1+ (1,0) [0|15] "" XXX + SG_ CAN_Stand_4_1_Komfort_Daten_Neb : 32|4@1+ (1,0) [0|15] "" XXX + SG_ Frei_Systeminfo_1_6 : 30|1@1+ (1,0) [0|0] "" XXX + SG_ Viertuerer : 29|1@1+ (1,0) [0|0] "" XXX + SG_ Rechtslenker : 28|1@1+ (1,0) [0|0] "" XXX + SG_ Fahrzeug_Index : 24|4@1+ (1,0) [0|0] "" XXX + SG_ Fahrzeug_Generation : 20|4@1+ (1,0) [0|15] "" XXX + SG_ Fahrzeug_Derivat : 16|4@1+ (1,0) [0|15] "" XXX + SG_ Fahrzeug_Marke_2 : 12|4@1+ (1,0) [0|15] "" XXX + SG_ Fahrzeug_Klasse : 8|4@1+ (1,0) [0|15] "" XXX + SG_ Verbauinformation_gueltig : 7|1@1+ (1,0) [0|0] "" XXX + SG_ CAN_Infotainment_verbaut : 6|1@1+ (1,0) [0|0] "" XXX + SG_ CAN_Infotainment_in_Diagnose : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Sleep_CAN_Infotainment : 4|1@1+ (1,0) [0|0] "" XXX + SG_ CAN_Komfort_in_Diagnose : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Sleep_CAN_Komfort : 2|1@1+ (1,0) [0|0] "" XXX + SG_ CAN_Antrieb_in_Diagnose : 1|1@1+ (1,0) [0|0] "" XXX + SG_ CAN_Extern_zugeschaltet : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 268 Slave_1: 8 XXX + SG_ Delta_reduziertes_Sollmoment : 48|1@1+ (1,0) [0|0] "" XXX + SG_ Delta_Drosselklappenwinkel : 32|16@1+ (1,0) [0|0] "" XXX + SG_ Frei_Slave_1_1 : 25|7@1+ (1,0) [0|0] "" XXX + SG_ Delta_Zuendwinkelausgabe : 24|1@1+ (1,0) [0|0] "" XXX + SG_ Ubat_Freigabe_DVE__Slave_ : 23|1@1+ (1,0) [0|0] "" XXX + SG_ Drosselklappe_Sollwertbegrenzun : 22|1@1+ (1,0) [0|0] "" XXX + SG_ Einspritzverbot_lernen__Slave_ : 21|1@1+ (1,0) [0|0] "" XXX + SG_ Master_erkannt__Slave_ : 20|1@1+ (1,0) [0|0] "" XXX + SG_ Fehler_Momentenausgabe : 19|1@1+ (1,0) [0|0] "" XXX + SG_ Fehler_Getriebe_Moment : 18|1@1+ (1,0) [0|0] "" XXX + SG_ Fehler_Bremsenbotschaft : 17|1@1+ (1,0) [0|0] "" XXX + SG_ Indiziertes_Istmoment__Slave_ : 0|16@1+ (0.0015259,0) [0|99.998] "%" XXX + SG_ Timeout_Bremsenbotschaft : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1332 Sitz_info: 2 XXX + SG_ Positionserkennung_Beifahrersit : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Beifahrersitz_im_vorderen_Dritt : 14|1@1+ (1,0) [0|0] "" XXX + SG_ Positionserkennung_Fahrersitz_u : 13|1@1+ (1,0) [0|0] "" XXX + SG_ Fahrersitz_im_vorderen_Drittel : 12|1@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_Sitzinfo : 8|4@1+ (1,0) [0|15] "" XXX + SG_ Checksumme_Sitzinfo : 0|8@1+ (1,0) [0|0] "" XXX + +BO_ 1810 PSG_3: 2 XXX + SG_ Selbsttestergebnis : 0|16@1+ (1,0) [0|0] "" XXX + +BO_ 1298 PSG_2: 8 XXX + SG_ RAM_Inhalt_4 : 48|16@1+ (1,0) [0|0] "" XXX + SG_ RAM_Inhalt_3 : 32|16@1+ (1,0) [0|0] "" XXX + SG_ RAM_Inhalt_2 : 16|16@1+ (1,0) [0|0] "" XXX + SG_ RAM_Inhalt_1 : 0|16@1+ (1,0) [0|0] "" XXX + +BO_ 274 PSG_1: 8 XXX + SG_ Pumpentemperatur__2_1_ : 48|16@1+ (0.0625,0) [0|4096] "K" XXX + SG_ Pumpentemperatur__3_2_2_ : 44|12@1+ (1,0) [0|0] "" XXX + SG_ Zylinderzaehler__3_2_2_ : 43|3@1+ (1,0) [1|8] "Zaehler" XXX + SG_ Ansteuerdauer__3_2_2_ : 32|11@1+ (0.0469,0) [0|96] "NW" XXX + SG_ Nockenwellendrehzahl__3_2_2_ : 20|12@1+ (4,0) [0|16380] "upm" XXX + SG_ Pumpen_Statuswort__3_2_2_ : 0|20@1+ (1,0) [0|0] "" XXX + +BO_ 1300 NOX_1: 8 XXX + SG_ OBD_fuer_NOX : 56|8@1+ (1,0) [0|0] "" XXX + SG_ Frei_NOX1_4 : 53|3@1+ (1,0) [0|0] "" XXX + SG_ IP2 : 52|1@1+ (1,0) [0|0] "" XXX + SG_ IP1 : 51|1@1+ (1,0) [0|0] "" XXX + SG_ IP0 : 50|1@1+ (1,0) [0|0] "" XXX + SG_ Sondenheizung_NOX : 49|1@1+ (1,0) [0|0] "" XXX + SG_ Offsetkorrektur_NOX : 48|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_NOX1_3 : 43|5@1+ (1,0) [0|0] "" XXX + SG_ Sauerstoff_binaer : 32|11@1+ (1,-200) [-200|1847] "mV" XXX + SG_ Frei_NOX1_2 : 27|5@1+ (1,0) [0|0] "" XXX + SG_ Sauerstoff_linear : 16|11@1+ (1,0) [0|2047] "1000/Lambd" XXX + SG_ Frei_NOX1_1 : 11|5@1+ (1,0) [0|0] "" XXX + SG_ NOX_Signal : 0|11@1+ (1,0) [0|2047] "ppm" XXX + +BO_ 1424 Niveau_1: 6 XXX + SG_ Beladungszustand : 40|8@1+ (1,0) [0|253] "Zuladung" XXX + SG_ Fehlerspeichereintrag__Niveau_1 : 39|1@1+ (1,0) [0|0] "" XXX + SG_ Systemstatus__Niveau_1_ : 38|1@1+ (1,0) [0|0] "" XXX + SG_ Reserve_Fahrzeugart : 37|1@1+ (1,0) [0|0] "" XXX + SG_ Fahrzeugart_Niveau : 36|1@1+ (1,0) [0|0] "" XXX + SG_ Textbits__Niveau_1_ : 32|4@1+ (1,0) [0|0] "" XXX + SG_ Verstellung_HL : 31|1@1+ (1,0) [0|0] "" XXX + SG_ Verstellung_HR : 30|1@1+ (1,0) [0|0] "" XXX + SG_ Verstellung_VL : 29|1@1+ (1,0) [0|0] "" XXX + SG_ Verstellung_VR : 28|1@1+ (1,0) [0|0] "" XXX + SG_ Absenkung_Fahrzeug : 27|1@1+ (1,0) [0|0] "" XXX + SG_ Anhebung_Fahrzeug : 26|1@1+ (1,0) [0|0] "" XXX + SG_ Verstellung_aktiv : 25|1@1+ (1,0) [0|0] "" XXX + SG_ Kompressorlauf_in_Kuerze : 24|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Niveau_1_5 : 23|1@1+ (1,0) [0|0] "" XXX + SG_ Taster_Niveau : 22|1@1+ (1,0) [0|0] "" XXX + SG_ Parkniveau : 21|1@1+ (1,0) [0|0] "" XXX + SG_ Zwischenniveau : 20|1@1+ (1,0) [0|0] "" XXX + SG_ Niveaustati : 16|4@1+ (1,0) [0|0] "" XXX + SG_ MSG_Einschraenkung : 15|1@1+ (1,0) [0|0] "" XXX + SG_ ESP_Beeinflussung : 14|1@1+ (1,0) [0|0] "" XXX + SG_ Warnlampe_Niveau_1 : 13|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Niveau_1_1 : 12|1@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_Niveau_1 : 8|4@1+ (1,0) [0|15] "Zaehler" XXX + SG_ Checksumme_Niveau_1 : 0|8@1+ (1,0) [0|0] "" XXX + +BO_ 1328 Navigation_1: 7 XXX + SG_ Kreuzungstyp : 54|2@1+ (1,0) [0|3] "" XXX + SG_ Entfernung_bis_Kreuzung : 48|6@1+ (5,0) [0|315] "m" XXX + SG_ Entfernung_bis_Kurvenanfang : 40|8@1+ (1,0) [0|255] "m" XXX + SG_ Voarusliegende_Kurvenrichtung : 39|1@1+ (1,0) [0|0] "" XXX + SG_ Vorausliegender_Kurvenverlauf : 32|7@1+ (50,0) [0|6350] "m" XXX + SG_ Fehler_Navigation : 31|1@1+ (1,0) [0|0] "" XXX + SG_ Anzahl_Fahrbahnen__0_ist_unguel : 28|3@1+ (1,0) [1|7] "" XXX + SG_ Strassentyp : 24|4@1+ (1,0) [0|15] "" XXX + SG_ Laenderkennung : 16|8@1+ (1,0) [0|0] "" XXX + SG_ Vorzeichen_Gierrate______ : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Gierratenfehler : 14|1@1+ (1,0) [0|0] "" XXX + SG_ Gierrate : 0|14@1+ (0.01,0) [0|100] "deg/sek" XXX + +BO_ 1792 MSG_3: 3 XXX + SG_ MSG_Konfiguration : 16|8@1+ (1,0) [0|0] "" XXX + SG_ Lage_des_OT_Impuls : 0|16@1+ (0.01172,-384) [-384|384] "KW" XXX + +BO_ 1280 MSG_2: 8 XXX + SG_ RAM_Adresse_4 : 48|16@1+ (1,0) [0|0] "" XXX + SG_ RAM_Adresse_3 : 32|16@1+ (1,0) [0|0] "" XXX + SG_ RAM_Adresse_2 : 16|16@1+ (1,0) [0|0] "" XXX + SG_ Ram_Adresse_1 : 0|16@1+ (1,0) [0|0] "" XXX + +BO_ 256 MSG_1: 8 XXX + SG_ Kurbelwellendrehzahl__3_2_2_ : 56|8@1+ (1,0) [0|0] "" XXX + SG_ Soll_Foerderbeginn_KW__3_2_2_ : 40|16@1+ (0.01172,-384) [-384|384] "KW" XXX + SG_ Soll_Foerderbeginn_NW__3_2_2_ : 28|12@1+ (0.01172,0) [0|768] "degNW" XXX + SG_ Soll_Voreinspritzung : 16|12@1+ (1,0) [0|0] "" XXX + SG_ Soll_Einspritzmenge : 0|16@1+ (0.03125,0) [0|2047] "mg/H" XXX + +BO_ 1796 Motor_NOX: 8 XXX + SG_ Frei_Motor_NOX_1_2 : 24|40@1+ (1,0) [0|0] "" XXX + SG_ Frei_Motor_NOX_1_1 : 19|5@1+ (1,0) [0|0] "" XXX + SG_ Heizleistungsanforderung : 18|1@1+ (1,0) [0|0] "" XXX + SG_ Offsetkorrektur_moeglich : 17|1@1+ (1,0) [0|0] "" XXX + SG_ Betriebsbereich : 16|1@1+ (1,0) [0|0] "" XXX + SG_ Abgastemperatur_NOX : 8|8@1+ (5,-40) [-40|1230] "C" XXX + SG_ Abgasdruck_NOX : 0|8@1+ (5,600) [600|1870] "mbar" XXX + +BO_ 900 Motor_Momente: 8 XXX + SG_ Momentenangaben_ungenau__Moment : 35|2@1+ (1,0) [0|0] "" XXX + +BO_ 1408 Motor_Flexia: 8 XXX + SG_ Ansaugsystem m0 : 63|1@1+ (1,0) [0|0] "" XXX + SG_ Hubraum m0 : 56|7@1+ (0.1,0) [0|12.7] "l" XXX + SG_ Steigung_der_Befuellungskennlin m1 : 56|8@1+ (0.001,0) [0|0.255] "l/mm" XXX + SG_ Anzahl_Zylinder m0 : 52|4@1+ (1,0) [0|15] "Vent./Zyl." XXX + SG_ Bewertungsfaktor_Russindex_Turb m1 : 50|6@1+ (0.1,0) [0|6.3] "" XXX + SG_ Anzahl_Ventile m0 : 49|3@1+ (1,0) [0|7] "Vent./Zyl." XXX + SG_ Bewertungsfaktor_Verschleissind m1 : 44|6@1+ (0.1,0) [0|6.3] "" XXX + SG_ Hersteller_Code m1 : 40|4@1+ (1,0) [0|15] "" XXX + SG_ Motorleistung m0 : 40|9@1+ (1,0) [0|512] "KW" XXX + SG_ Max_Drehmoment m0 : 32|8@1+ (10,0) [0|2550] "Nm" XXX + SG_ Normierter_Verbrauch m1 : 32|8@1+ (10,0) [0|2550] "l/Zyl." XXX + SG_ Oelniveauschwelle m1 : 24|8@1+ (0.25,0) [0|63.75] "cm" XXX + SG_ Drehzahl_MaxNorm m0 : 24|8@1+ (100,0) [0|25500] "U/min" XXX + SG_ Verschleissindex : 16|8@1+ (1,0) [0|254] "" XXX + SG_ Russindex : 8|8@1+ (1,0) [0|254] "" XXX + SG_ Verbrennungsart : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Motor_Flexia_1 : 4|3@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_Motor_Flexia : 1|3@1+ (1,0) [0|15] "" XXX + SG_ Multiplex_Schalter_Motor_Flexia M : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1416 Motor_7: 8 XXX + SG_ Frei_Motor_7_3 : 40|24@1+ (1,0) [0|0] "" XXX + SG_ Ladedruck : 32|8@1+ (0.01,0) [0|2.54] "bar" XXX + SG_ Vorzeichen_Motordrehzahlgradien : 31|1@1+ (1,0) [0|0] "" XXX + SG_ Motordrehzahlgradient : 24|7@1+ (1,0) [0|126] "U/min" XXX + SG_ Hoeheninfo__Motor_7_ : 16|8@1+ (0.00787,0) [0|2] "" XXX + SG_ Klemme_DFM : 8|8@1+ (0.4,0) [0|101.6] "%" XXX + SG_ PTC___Gluehstifte_ausgeschaltet : 5|3@1+ (1,0) [0|0] "" XXX + SG_ Frei_Motor_7_1 : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerspeichereintrag__Motor_7_ : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Statusbit_Geschwindikeitsbegren : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Geschwindigkegrenzung_aktivierb : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Leerlauf_Solldrehzahl_auf_Max_W : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1160 Motor_6: 8 XXX + SG_ Zaehler_Motor_6 : 60|4@1+ (1,0) [0|15] "" XXX + SG_ Frei_Motor_6_4 : 58|2@1+ (1,0) [0|0] "" XXX + SG_ ltemperaturschutz : 57|1@1+ (1,0) [0|0] "" XXX + SG_ GRA_Bremseingriff_Freigabe : 56|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Motor_6_3 : 40|16@1+ (1,0) [0|0] "" XXX + SG_ GRA_Sollbeschleunigung : 32|8@1+ (0.024,-3.984) [-3.984|2.112] "m/s2" XXX + SG_ Hoeheninfo__Motor_6_ : 24|8@1+ (0.00787,0) [0|2] "" XXX + SG_ Istmoment_f_r_Getriebe : 16|8@1+ (0.39,0) [0|99] "MDI" XXX + SG_ Sollmoment_f_r_Getriebe : 8|8@1+ (0.39,0) [0|99] "MDI" XXX + SG_ Checksumme_Motor_6 : 0|8@1+ (1,0) [0|0] "" XXX + +BO_ 1152 Motor_5: 8 XXX + SG_ Checksumme_Motor_5 : 56|8@1+ (1,0) [0|0] "" XXX + SG_ Motortext_Bits__4_1_ : 52|4@1+ (1,0) [0|0] "" XXX + SG_ Doppelte_Momente : 51|1@1+ (1,0) [0|0] "" XXX + SG_ GRA_Hauptschalter : 50|1@1+ (1,0) [0|0] "" XXX + SG_ Anlasser_Ausspuren : 49|1@1+ (1,0) [0|0] "" XXX + SG_ Anlasser_Freigabe : 48|1@1+ (1,0) [0|0] "" XXX + SG_ Klimadrucksignal__Motor_5_ : 40|8@1+ (0.2,0) [0|50.8] "bar" XXX + SG_ K_hlerluefteransteuerung : 32|8@1+ (0.4,0) [0|101.6] "%" XXX + SG_ Verbrauch_Ueberlauf : 31|1@1+ (1,0) [0|0] "" XXX + SG_ Kraftstoffverbrauchssignal : 16|15@1+ (1,0) [0|32767] "ul" XXX + SG_ Klimakompressor_Leistungsreduzi : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Kennfeldkuehlung : 14|1@1+ (1,0) [0|0] "" XXX + SG_ Klimakompressor_aus__Motor_5_ : 13|1@1+ (1,0) [0|0] "" XXX + SG_ CAT_Warnung : 12|1@1+ (1,0) [0|0] "" XXX + SG_ OBD_2_Lampe : 11|1@1+ (1,0) [0|0] "" XXX + SG_ E_Gas_Lampe : 10|1@1+ (1,0) [0|0] "" XXX + SG_ Vorgluehlampe__Motor_5_ : 9|1@1+ (1,0) [0|0] "" XXX + SG_ Ladekontroll_Lampe : 8|1@1+ (1,0) [0|0] "" XXX + SG_ Multiplex_Code M : 6|2@1+ (1,0) [0|0] "" XXX + SG_ Multiplex_Info_norm__Verbrauch m3 : 0|6@1+ (20,0) [0|1260] "l/Zyl" XXX + SG_ Multiplex_Info_Motortyp m2 : 0|6@1+ (1,0) [0|0] "" XXX + SG_ Multiplex_Info_Drehzahl_MD_Max m1 : 0|6@1+ (100,0) [0|6300] "U/min" XXX + SG_ Multiplex_Info_Max_Drehmoment m0 : 0|6@1+ (10,0) [0|630] "Nm" XXX + +BO_ 896 Motor_3: 8 XXX + SG_ Drosselklappenpoti : 56|8@1+ (0.4,0) [0|101.6] "%" XXX + SG_ Motor_Wunschdrehzahl : 48|8@1+ (25,0) [0|6350] "U/min" XXX + SG_ Motordrehzahlbeeinflussung : 40|8@1+ (0.392,0) [0|100] "%" XXX + SG_ Kein_Start_Stop : 39|1@1+ (1,0) [0|0] "" XXX + SG_ Kein_E_Gas : 38|1@1+ (1,0) [0|0] "" XXX + SG_ Reserviert_Motor_3_1 : 37|1@1+ (1,0) [0|0] "" XXX + SG_ Vorzeichen_Rad_Wunschmoment : 36|1@1+ (1,0) [0|0] "" XXX + SG_ Rad_Wunschmoment : 24|12@1+ (0.39,0) [0|1597] "MDI" XXX + SG_ Fahrpedal_Rohsignal : 16|8@1+ (0.4,0) [0|101.6] "%" XXX + SG_ Ansauglufttemperatur : 8|8@1+ (0.75,-48) [-48|142.5] "" XXX + SG_ Fehlerstatus_Ansauglufttemperat : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Motorsteuerger_t_gesperrt : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Drosselklappenwinkel_ungenau : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Fahrpedalwert_ungenau__Motor_3_ : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Motor_3_1 : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Motor_Wunschdrehzahl_Priorit_t : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Uebertemperaturschutz__Motor_3_ : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Vorgluehmeldung : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 648 Motor_2: 8 XXX + SG_ Minimales_Motormoment_bei_Zuend : 56|8@1+ (0.39,0) [0|99] "MDI" XXX + SG_ Begrenzungsmoment : 48|8@1+ (0.39,0) [0|99] "MDI" XXX + SG_ Leerlaufsolldrehzahl__Motor_2_ : 40|8@1+ (10,0) [0|2540] "U/min" XXX + SG_ Soll_Geschwindigkeit_bei_GRA_Be : 32|8@1+ (1.28,0) [0|325] "km/h" XXX + SG_ Fahrzeuggeschwindigkeit : 24|8@1+ (1.28,0) [0|325] "km/h" XXX + SG_ GRA_Status : 22|2@1+ (1,0) [0|0] "" XXX + SG_ OBD_2_freeze_frame : 21|1@1+ (1,0) [0|0] "" XXX + SG_ Status_Normalbetrieb : 20|1@1+ (1,0) [0|0] "" XXX + SG_ Ansteuerung_Klima__4_1_ : 19|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerstatus_Kuhlmitteltempera : 18|1@1+ (1,0) [0|0] "" XXX + SG_ Bremstestschalter : 17|1@1+ (1,0) [0|0] "" XXX + SG_ Bremslichtschalter : 16|1@1+ (1,0) [0|0] "" XXX + SG_ Kuehlmitteltemperatur__Motor_2_ : 8|8@1+ (0.75,-48) [-48|142.5] "" XXX + SG_ Multiplex_Code_Motor_2 M : 6|2@1+ (1,0) [0|0] "" XXX + SG_ Multiplex_Info_Motorcode__4_x_ m1 : 0|6@1+ (1,0) [0|0] "" XXX + SG_ Multiplex_Info_Getriebecode m2 : 0|6@1+ (1,0) [0|0] "" XXX + SG_ Multiplex_Info_Max_Moment__Norm m3 : 0|6@1+ (10,0) [0|630] "Nm" XXX + SG_ Multiplex_Info_CAN_Stand m0 : 0|6@1+ (1,0) [0|0] "" XXX + +BO_ 640 Motor_1: 8 XXX + SG_ Fahrerwunschmoment : 56|8@1+ (0.39,0) [0|99] "MDI" XXX + SG_ mechanisches_Motor_Verlustmomen : 48|8@1+ (0.39,0) [0|99] "MDI" XXX + SG_ Fahrpedalwert_oder_Drosselklapp : 40|8@1+ (0.4,0) [0|101.6] "%" XXX + SG_ inneres_Motor_Moment_ohne_exter : 32|8@1+ (0.39,0) [0|99] "MDI" XXX + SG_ Motordrehzahl : 16|16@1+ (0.25,0) [0|16256] "U/min" XXX + SG_ inneres_Motor_Moment : 8|8@1+ (0.39,0) [0|99] "MDI" XXX + SG_ Momentenangaben_ungenau : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerstatus_Getriebe_Momentene : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerstatus_Brems_Momenteneing : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Time_Out_Bremsen_Botschaft : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Kupplungsschalter : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Kickdownschalter : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Fahrpedalwert_ungenau__Motor_1_ M : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Leergasinformation : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 262 Master_3: 8 XXX + SG_ Frei_Master_3_1 : 56|8@1+ (1,0) [0|0] "" XXX + SG_ Motortemperatur_linearisiert : 48|8@1+ (0.75,-48) [-48|143.25] "" XXX + SG_ Indiziertes_Sollmoment_f_r_Vmax : 32|16@1+ (0.0015259,0) [0|100] "%" XXX + SG_ Relative_Momentenanforderung_de : 16|16@1+ (0.003052,0) [0|200] "%" XXX + SG_ Delta_Motormoment_aus_Verlustmo : 0|16@1+ (0.003052,-100) [-100|100] "%" XXX + +BO_ 260 Master_2: 8 XXX + SG_ Ubat_Freigabe_DVE : 45|1@1+ (1,0) [0|0] "" XXX + SG_ DK_Sollwertbegrenzung : 44|1@1+ (1,0) [0|0] "" XXX + SG_ Einspritzverbot_DV_E_lernen : 43|1@1+ (1,0) [0|0] "" XXX + SG_ Master_erkannt : 42|1@1+ (1,0) [0|0] "" XXX + SG_ Vmax_Begrenzung_aktiv : 41|1@1+ (1,0) [0|0] "" XXX + SG_ SA_Verbot_von_FGR : 40|1@1+ (1,0) [0|0] "" XXX + SG_ Pedalwert_Komplement : 24|16@1+ (1,0) [0|0] "" XXX + SG_ Zaehler__Master_2_ : 16|8@1+ (1,0) [0|255] "" XXX + SG_ Normierter_Fahrpedalwinkel : 0|16@1+ (0.001526,0) [0|100] "%" XXX + +BO_ 258 Master_1: 8 XXX + SG_ Stationaere_Solldrehzahl : 56|8@1+ (10,0) [0|2550] "Umin" XXX + SG_ Drehmoment_LLR__I_Anteil_ : 40|16@1+ (0.003052,-100) [-100|100] "%" XXX + SG_ Drehmoment_LLR__PD_Anteil_ : 24|16@1+ (0.003052,-100) [-100|100] "%" XXX + SG_ Drehmoment_LLR__Luftpfad_ : 8|16@1+ (0.003052,-100) [-100|100] "%" XXX + SG_ Frei_Master_1_1 : 4|4@1+ (1,0) [0|0] "" XXX + SG_ LLR_ist_aktiv : 3|1@1+ (1,0) [0|0] "" XXX + SG_ I_Anteil_der_LLR_aktiv : 2|1@1+ (1,0) [0|0] "" XXX + SG_ PD_Anteil_der_LLR_aktiv : 1|1@1+ (1,0) [0|0] "" XXX + SG_ LLR_Freigabe_nach_Start : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1984 LWS_Kalibrierung: 2 XXX + SG_ Frei_LWS_Kalibrierung_1_1 : 15|1@1+ (1,0) [0|0] "" XXX + SG_ LWS_Identifier : 8|7@1+ (1,0) [0|0] "" XXX + SG_ Frei_LWS_Kalibrierung_1_2 : 4|4@1+ (1,0) [0|0] "" XXX + SG_ Command_Dode_Word : 0|4@1+ (1,0) [0|0] "" XXX + +BO_ 1986 Lenkwinkel_Init: 4 XXX + SG_ Kodierbytes : 8|24@1+ (1,0) [0|0] "" XXX + SG_ Identiifier_f_r_LWS_Init : 0|8@1+ (1,0) [0|0] "" XXX + +BO_ 192 Lenkwinkel_1__RB_: 2 XXX + SG_ Vorzeichen__RB_ : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkwinkel__RB_ : 5|10@1+ (2.5,-720) [-720|720] "" XXX + SG_ LWS_OK__RB_ : 4|1@1+ (1,0) [0|0] "" XXX + SG_ LWS_Abgleich__RB_ : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Lenkwinkel_1_1__RB_ : 2|1@1+ (1,0) [0|0] "" XXX + SG_ FINE_CHECK__RB_ : 1|1@1+ (1,0) [0|0] "" XXX + SG_ COARSE_CHECK__RB_ : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 196 Lenkwinkel_1__ITT_: 2 XXX + SG_ Vorzeichen__ITT_ : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkwinkel__ITT_ : 5|10@1+ (1.5,-768) [-768|766.5] "" XXX + SG_ LWS_OK : 4|1@1+ (1,0) [0|0] "" XXX + SG_ LWS_Abgleich__ITT_ : 3|1@1+ (1,0) [0|0] "" XXX + SG_ LWS_Initialisierung__ITT_ : 2|1@1+ (1,0) [0|0] "" XXX + SG_ FINE_CHECK__ITT_ : 1|1@1+ (1,0) [0|0] "" XXX + SG_ COARSE_CHECK__ITT_ : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 194 Lenkwinkel_1: 8 XXX + SG_ Checksumme_Lenkwinkel_1 : 56|8@1+ (1,0) [0|0] "" XXX + SG_ Kodierdaten : 48|8@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_Lenkwinkel_1 : 44|4@1+ (1,0) [0|15] "" XXX + SG_ Status_KL30_Ausfall__z_Zt__nur : 43|1@1+ (1,0) [0|0] "" XXX + SG_ Interner_Status : 41|2@1+ (1,0) [0|0] "" XXX + SG_ Frei_Lenkwinkel_1_1 : 40|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkwinkel_ID : 32|8@1+ (1,0) [0|0] "" XXX + SG_ Lenkradwinkel_Geschwindigkeit_S : 31|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkradwinkel_Geschwindigkeit : 16|15@1+ (0.04375,0) [0|1433.6] "Grad/Sek" XXX + SG_ Lenkradwinkel_Sign : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkradwinkel : 0|15@1+ (0.04375,0) [0|1433.6] "Grad" XXX + +BO_ 1502 Lenkhilfe_Fehler: 7 XXX + SG_ Werkstattcode : 48|8@1+ (1,0) [0|0] "" XXX + SG_ Multiplex_Signal : 45|3@1+ (1,0) [0|7] "" XXX + SG_ Sensorcodierung_Lenkhilfe : 44|1@1+ (1,0) [0|0] "" XXX + SG_ Kennliniencodierung_Lenkhilfe : 40|4@1+ (1,0) [0|15] "Kennlinie" XXX + SG_ Geber_f__Lenkw__Speicher_ausles : 39|1@1+ (1,0) [0|0] "" XXX + SG_ Kombiinstr__Speicher_auslesen : 38|1@1+ (1,0) [0|0] "" XXX + SG_ Steuerger__Speicher_auslesen : 37|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfe_Steuergeraet_defekt : 36|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Lenkhilfe_1_3 : 32|4@1+ (1,0) [0|0] "" XXX + SG_ Frei_Lenkhilfe_1_4 : 30|2@1+ (1,0) [0|0] "" XXX + SG_ Geber_f__Lenkwi__k__CAN_Komm_sp : 29|1@1+ (1,0) [0|0] "" XXX + SG_ Geber_f__Lenkwinkel_k__CAN_Komm : 28|1@1+ (1,0) [0|0] "" XXX + SG_ Kombiinstr__k__CAN_Kommunik__sp : 27|1@1+ (1,0) [0|0] "" XXX + SG_ Kombiinstrument_k__CAN_Kommunik : 26|1@1+ (1,0) [0|0] "" XXX + SG_ Steuergeraet_k__CAN_Kommunik__S : 25|1@1+ (1,0) [0|0] "" XXX + SG_ Steuergeraet_keine_CAN_Kommunik : 24|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfe_Spannung_Ks__nach_Mas : 23|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfe_Spannung_Ks_nach_Mass : 22|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfe_Spannung_Ks__nach___s : 21|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfe_Spannung_Ks__nach__ : 20|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfe_Temperaturschutz_sp_ : 19|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfe_Temperaturschutz : 18|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfe_Betrieb_unpl__Sig__sp : 17|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfe_Betrieb_unpl__Signal : 16|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfesensor_k__Kommunik__sp : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfesensor_keine_Kommunik_ : 14|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfesensor_defekt_sp_ : 13|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfesensor_defekt : 12|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfesensor_Unterbrechung_s : 11|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfesensor_Unterbrechung : 10|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhilfesensor_Ks_nach_Masse_s : 9|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkhifesensor_Ks_nach_Masse : 8|1@1+ (1,0) [0|0] "" XXX + SG_ Spannung_Kl_15_zu_klein_sp_ : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Spannung_Kl_15_zu_klein : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Lenkhilfe_1_5 : 4|2@1+ (1,0) [0|0] "" XXX + SG_ Spannung_Kl_30_zu_klein_sp_ : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Spannung_Kl_30_zu_klein : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Spannung_Kl_30_zu_gro__sp_ : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Spannung_Kl_30_zu_gro_ : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 976 Lenkhilfe_1: 2 XXX + SG_ Fehlerspeichereintrag__Lenkhilf : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Lenkhilfe_1_2 : 9|6@1+ (1,0) [0|0] "" XXX + SG_ Fehlerlampe_Lenkhilfe : 8|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerstatus_Lastinformation : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Lastinformation : 0|7@1+ (1,0) [0|127] "A" XXX + +BO_ 1312 Kombi_3: 8 XXX + SG_ Frei_Kombi_3_2 : 60|4@1+ (1,0) [0|0] "" XXX + SG_ Kilometerstand : 40|20@1+ (1,0) [0|1000000] "km" XXX + SG_ Fehlerstatus_Standzeit : 39|1@1+ (1,0) [0|0] "" XXX + SG_ Standzeit : 24|15@1+ (4,0) [0|131068] "sec" XXX + SG_ Frei_Kombi_3_1 : 20|4@1+ (1,0) [0|0] "" XXX + SG_ Schluesselinfo : 16|4@1+ (1,0) [0|15] "" XXX + SG_ Kombi_Multiplex_Code M : 14|2@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Verbauliste_Niveauregulie m3 : 11|1@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Multiplex_Marke m1 : 11|3@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Verbauliste_Lenkhilfe m3 : 10|1@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Verbauliste_Dieselpumpe m3 : 9|1@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Verbauliste_Lenkwinkel m3 : 8|1@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Multiplex_Baureihe m1 : 8|3@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Multiplex_Laendervariante m0 : 8|6@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Verbauliste_Allrad m3 : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Verbauliste_Bordnetz m3 : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Verbauliste_ACC m3 : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Verbauliste_Airbag m3 : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Multiplex_Generation m1 : 4|4@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Verbauliste_Klima m3 : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Verbauliste_ABS m3 : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Verbauliste_Motor m3 : 0|1@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Multiplex_Derivat m1 : 0|4@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Multiplex_Sprachvariante m0 : 0|8@1+ (1,0) [0|0] "" XXX + SG_ Kombi_Multiplex_Reifenumfang m2 : 0|12@1+ (1,0) [0|4095] "mm" XXX + +BO_ 1056 Kombi_2: 8 XXX + SG_ Frei_Kombi_2_2 : 56|8@1+ (1,0) [0|0] "" XXX + SG_ Fehlerstatus_Kl__58_s : 55|1@1+ (1,0) [0|0] "" XXX + SG_ Klemme_58s__Kombi_2_ : 48|7@1+ (1,0) [0|100] "%" XXX + SG_ Fehlerstatus_Kl__58_d : 47|1@1+ (1,0) [0|0] "" XXX + SG_ Klemme_58d__Kombi_2_ : 40|7@1+ (1,0) [0|100] "%" XXX + SG_ Kuehlmitteltemp__4_1__Kombi_2_ : 32|8@1+ (0.75,-48) [-48|142.5] "C" XXX + SG_ Oeltemperatur_4_1 : 24|8@1+ (1,-60) [-60|194] "C" XXX + SG_ Aussentemp__ungefiltert_4_1__Ko : 16|8@1+ (0.5,-50) [-50|77] "C" XXX + SG_ Aussentemperatur_gefiltert : 8|8@1+ (0.5,-50) [-50|77] "C" XXX + SG_ Fehlerspeichereintrag__Kombi_ : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Kombi_2_1 : 4|3@1+ (1,0) [0|0] "" XXX + SG_ Anhaenger_erkannt : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerst__Kuehlmitteltemp__4_1 : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerstatus_Oeltemperatur_4_1 : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerstatus_Aussentemp__4_1 : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 800 Kombi_1: 8 XXX + SG_ Frei_Kombi_1_3 : 56|8@1+ (1,0) [0|0] "" XXX + SG_ Angezeigte_Geschwindigkeit : 46|10@1+ (0.32,0) [0|325] "km/h" XXX + SG_ Blinker_rechts_4_1 : 45|1@1+ (1,0) [0|0] "" XXX + SG_ Blinker_links_4_1 : 44|1@1+ (1,0) [0|0] "" XXX + SG_ Gesetzte_Zeitluecke__Kombi_1_ : 43|1@1+ (1,0) [0|0] "" XXX + SG_ ADR_Summer_abgeschaltet : 42|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Kombi_1_2 : 40|2@1+ (1,0) [0|0] "" XXX + SG_ Geschwindigkeit__Kombi_1_ : 25|15@1+ (0.01,0) [0|326] "km/h" XXX + SG_ Signalquelle_Geschwindigkeit_4_ : 24|1@1+ (1,0) [0|0] "" XXX + SG_ Tankwarnung : 23|1@1+ (1,0) [0|0] "" XXX + SG_ Tankinhalt : 16|7@1+ (1,0) [0|126] "l" XXX + SG_ Tankstop : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Kombi_1_7 : 12|3@1+ (1,0) [0|0] "" XXX + SG_ Kombi_im_Stellgliedtest : 11|1@1+ (1,0) [0|0] "" XXX + SG_ Ladekontroll_Lampe__Kombi_ : 10|1@1+ (1,0) [0|0] "" XXX + SG_ Bremsinfo : 8|2@1+ (1,0) [0|0] "" XXX + SG_ Vorgluehlampe__Kombi_1_ : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Tankwarnlampe : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Heissleuchten_Vorwarnung : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Kuehlmittelmangel : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Dynamische_Oeldruckwarnung : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Oeldruck : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerstatus_Tank : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Fahrertuer_4_1 : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1504 Klima_1: 8 XXX + SG_ Aussentemp__ungef__Sto_f__4_1 : 56|8@1+ (0.5,-50) [-50|77] "C" XXX + SG_ Fehlerspeichereintrag__Klima_ : 55|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Klima_1_5 : 50|5@1+ (1,0) [0|0] "" XXX + SG_ AC_Schalter : 49|1@1+ (1,0) [0|0] "" XXX + SG_ Temperatureinheit : 48|1@1+ (1,0) [0|0] "" XXX + SG_ Kuehlerluefteransteuerung__Klim : 40|8@1+ (0.4,0) [0|101.6] "%" XXX + SG_ Geblaeselast_4_1 : 32|8@1+ (0.4,0) [0|101.6] "%" XXX + SG_ Kompressorlast : 24|8@1+ (0.25,0) [0|63.5] "Nm" XXX + SG_ Klimadrucksignal__Klima_1_ : 16|8@1+ (0.2,0) [0|50.8] "bar" XXX + SG_ Aussentemp__ungef__4_1__Klima_1 : 8|8@1+ (0.5,-50) [-50|77] "C" XXX + SG_ Kaeltemitteldruck_veraltet : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Kompressormoment_veraltet_4_1 : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Keine_Heizleistg_gewuenscht_4_1 : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Kompressorzustand__4_1_ : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Heizbare_Frontscheibe : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Heizbare_Heckscheibe : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Fahrerwunsch_Zuheizer : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Drehzahlanhebung : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 906 GRA_Neu: 4 XXX + SG_ GRA_Checksum : 0|8@1+ (1,0) [0|255] "" XXX + SG_ GRA_Hauptschalt : 8|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Abbrechen : 9|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Down_kurz : 10|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Up_kurz : 11|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Down_lang : 12|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Up_lang : 13|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Fehler_Bed : 14|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Kodierinfo : 15|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Neu_Setzen : 16|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Recall : 17|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Sender : 18|2@1+ (1,0) [0|3] "" XXX + SG_ GRA_Neu_Zaehler : 20|4@1+ (1,0) [0|15] "" XXX + SG_ GRA_Tip_Down : 24|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Tip_Up : 25|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Zeitluecke : 26|2@1+ (1,0) [0|3] "" XXX + SG_ GRA_Sta_Limiter : 28|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Typ_Hauptschalt : 29|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Sportschalter : 30|1@1+ (1,0) [0|1] "" XXX + SG_ GRA_Fehler_Tip : 31|1@1+ (1,0) [0|1] "" XXX + +BO_ 904 GRA: 3 XXX + SG_ Checksumme_GRA_alt : 16|8@1+ (1,0) [0|0] "" XXX + SG_ Frei_GRA_alt : 15|1@1+ (1,0) [0|0] "" XXX + SG_ GRA_alt__ADR_Bedienteil_Fehler : 14|1@1+ (1,0) [0|0] "" XXX + SG_ GRA_alt__ADR_beschleunigen : 13|1@1+ (1,0) [0|0] "" XXX + SG_ GRA_alt__ADR_verzoegern : 12|1@1+ (1,0) [0|0] "" XXX + SG_ GRA_alt__ADR___Tipschalter__Wie : 11|1@1+ (1,0) [0|0] "" XXX + SG_ GRA_alt__ADR___Tipschalter__Set : 10|1@1+ (1,0) [0|0] "" XXX + SG_ GRA_alt__ADR___Tipschalter__Aus : 9|1@1+ (1,0) [0|0] "" XXX + SG_ GRA_alt__ADR___Hauptschalter : 8|1@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_GRA_alt : 0|8@1+ (1,0) [0|255] "" XXX + +BO_ 1352 Getriebe_4: 3 XXX + SG_ Testparameter_2 : 16|8@1+ (1,0) [0|255] "" XXX + SG_ Testparameter_1 : 8|8@1+ (1,0) [0|255] "" XXX + SG_ Waehlhebelausleuchtung : 4|4@1+ (1,0) [0|0] "" XXX + SG_ Frei_Getriebe_4_1 : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Testfreigabeflag : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Handbremserinnerung_s_Lampe : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Shiftlock_Getriebe_4 : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1344 Getriebe_2: 8 XXX + SG_ eingelegte_Fahrstufe : 60|4@1+ (1,0) [0|0] "" XXX + SG_ Ganganzeige_Kombi___Getriebe_Va : 56|4@1+ (1,0) [0|15] "" XXX + SG_ Fehlerlampe_f_r_Kupplung_bei_VL : 55|1@1+ (1,0) [0|0] "" XXX + SG_ Anforderung_Kriechadaption : 54|1@1+ (1,0) [0|0] "" XXX + SG_ ECO_Anzeige__4_1_ : 53|1@1+ (1,0) [0|0] "" XXX + SG_ Shift_Lock_Lampe : 52|1@1+ (1,0) [0|0] "" XXX + SG_ Unterdrueckung_von_Warnungen : 51|1@1+ (1,0) [0|0] "" XXX + SG_ Gong : 50|1@1+ (1,0) [0|0] "" XXX + SG_ Starter_wird_angesteuert : 49|1@1+ (1,0) [0|0] "" XXX + SG_ Hochschaltlampe : 48|1@1+ (1,0) [0|0] "" XXX + SG_ Synchronisationszeit : 40|8@1+ (20,0) [0|5080] "ms" XXX + SG_ invertierte_Synchronisations_Wu : 32|8@1+ (25,0) [0|6350] "U/min" XXX + SG_ Synchronisations_Wunschdrehzahl : 24|8@1+ (25,0) [0|6350] "U/min" XXX + SG_ Gradientenbegrenzung : 16|8@1+ (10,0) [0|2540] "Nm/s" XXX + SG_ Leerlaufsolldrehzahl__Getriebe : 8|8@1+ (10,0) [0|2540] "U/min" XXX + SG_ Zahler_Getriebe_2 : 4|4@1+ (1,0) [0|15] "" XXX + SG_ Zwischengasflag : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Ecomatic__4_1_ : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Schubabschaltunterstuetzung : 1|1@1+ (1,0) [0|0] "" XXX + SG_ LFR_Adaption_Freigabeflag : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1088 Getriebe_1: 8 XXX + SG_ Wandlerverlustmoment : 56|8@1+ (0.39,0) [0|99.06] "MDI" XXX + SG_ Fehlerspeichereintrag__Getriebe : 55|1@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_Getriebe_1 : 51|4@1+ (1,0) [0|15] "" XXX + SG_ Gang_eingelegt : 50|1@1+ (1,0) [0|0] "" XXX + SG_ Schaltabsicht : 49|1@1+ (1,0) [0|0] "" XXX + SG_ Motor_aus : 48|1@1+ (1,0) [0|0] "" XXX + SG_ OBD_Status__Getriebe_1___4_1_ : 46|2@1+ (1,0) [0|0] "" XXX + SG_ Kuehlleistung : 44|2@1+ (1,0) [0|0] "" XXX + SG_ Getriebe_Notlauf : 40|4@1+ (1,0) [0|0] "" XXX + SG_ Fahrwiderstandsindex : 32|8@1+ (0.249,-31.6) [-31.6|31.6] "" XXX + SG_ inneres_Soll_Motormoment : 24|8@1+ (0.39,0) [0|99.06] "MDI" XXX + SG_ Uebertragungsfunktion : 16|8@1+ (0.1,0) [0|25.4] "" XXX + SG_ Waehlhebelposition__Getriebe_1_ : 12|4@1+ (1,0) [0|0] "" XXX + SG_ Zielgang_oder_eingelegter_Gang : 8|4@1+ (1,0) [0|0] "" XXX + SG_ EGS_Anforderung : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Kodierung_im_MSG : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Leerlaufsolldrehzahlanhebung : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Wandlerkupplung : 3|2@1+ (1,0) [0|0] "" XXX + SG_ Klimakompressor_aus__Getriebe_1 : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Status_Getriebe_und_Wandlerschu : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Schaltung_aktiv__Getriebe_1_ : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 912 Gate_Komf_1: 8 XXX + SG_ GK1_Sta_RDK_Warn : 0|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Sta_Anhaen : 1|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Sta_Licht1 : 2|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Sta_Licht3 : 3|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Sta_Tuerkont : 4|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Sta_Li_vorn : 5|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_SleepAckn : 7|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_CharismaModus m1 : 8|4@1+ (1,0) [0|15] "" XXX + SG_ GK1_SamFktNr M : 12|4@1+ (1,0) [0|15] "" XXX + SG_ GK1_Fa_Tuerkont : 16|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_RueckfahrSch : 17|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_ELV_verrieg : 18|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Sta_Kessy_2 : 19|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Sta_Stdhzg : 20|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_SH_Verbau : 21|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_ParkFrontWi : 22|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_KW_Warm : 23|1@1+ (1,0) [0|1] "" XXX + SG_ BCM_Remotestart_Betrieb : 24|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Rueckfahr : 28|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_BrLi_links : 29|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_BrLi_rechts : 30|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_BrLi_mitte : 31|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_BLS_ILM : 32|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_EDC_ILM : 33|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Blinker_li : 34|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Blinker_re : 35|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_def_P_verr : 36|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_LS1_Fernlicht : 37|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Sta_Licht2 : 38|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Sta_LSM : 39|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Count_Anhaen : 40|4@1+ (1,0) [0|15] "" XXX + SG_ GK1_BLS_AAG : 44|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_EDC_AAG : 45|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Anhaenger : 46|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_BrLi_Anhaen : 47|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Abblendlicht : 48|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Fernlicht : 49|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Wischer_vorn : 50|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Sta_ILM_F_1 : 51|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Abbl_VL_def : 52|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Abbl_VR_def : 53|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Blink_Autob : 54|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Warnblk_Status : 55|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_SH_laeuft : 56|1@1+ (1,0) [0|1] "" XXX + SG_ SH1_ein_Wasserpumpe : 57|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Nebel_ein : 58|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Bremslicht : 59|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_Anh_abgesteckt : 60|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_AnhKonLamp : 61|1@1+ (1,0) [0|1] "" XXX + SG_ LDS_Stellung_AFL : 62|1@1+ (1,0) [0|1] "" XXX + SG_ GK1_SH_Zusatzfkt : 63|1@1+ (1,0) [0|1] "" XXX + +BO_ 1340 Fahrwerk_1: 1 XXX + SG_ Frei_Fahrwerk_1_2 : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Fahrwerk_1_1 : 6|2@1+ (1,0) [0|0] "" XXX + SG_ Einstellung_Fahrwerkdaempfung_4 : 4|3@1+ (1,0) [0|7] "" XXX + SG_ Ansteuererung_Fahrzeugniveau : 0|4@1+ (1,0) [0|15] "" XXX + +BO_ 1472 EPB_1: 8 XXX + SG_ Textmeldungen_EPB : 52|4@1+ (1,0) [0|0] "" XXX + SG_ Aufmerksamkeits_Gtong_EPB : 51|1@1+ (1,0) [0|0] "" XXX + SG_ Fehler_Gong_EBP : 50|1@1+ (1,0) [0|0] "" XXX + SG_ Warnton_EPB : 49|1@1+ (1,0) [0|0] "" XXX + SG_ Funktionslampe_EPB : 48|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_EPB_1_1 : 33|15@1+ (1,0) [0|0] "" XXX + SG_ Fehlerspeichereintrag_EPB : 32|1@1+ (1,0) [0|0] "" XXX + SG_ Neigungswinkel : 24|8@1+ (1,-128) [-128|127] "g" XXX + SG_ Verzoegerungsanforderung__EPB_ : 24|8@1+ (0.5,0) [0|255] "g" XXX + SG_ Status_Neigungswinkelgeber : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Schalterinfo_Parkbremse : 13|2@1+ (1,0) [0|0] "" XXX + SG_ Erreichte_Spannkraft : 8|5@1+ (1,0) [0|30] "kN" XXX + SG_ Checksumme_Parkbremse : 8|8@1+ (1,0) [0|255] "" XXX + SG_ Schalterstatus_Parkbremse : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Status_Parkbremse : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerstatus_Parkbremse : 4|2@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_Parkbremse : 0|4@1+ (1,0) [0|0] "" XXX + +BO_ 1326 Diag_Lenkhilfe: 3 XXX + SG_ Werkstattcode__Diag_ : 16|8@1+ (1,0) [0|0] "" XXX + SG_ Multiplex_Signal__Diag_ : 13|3@1+ (1,0) [0|7] "" XXX + SG_ Befehl_Sensorcodierung_Lenkhilf : 12|1@1+ (1,0) [0|0] "" XXX + SG_ Befehl_Kennliniencodierung_Lenk : 8|4@1+ (1,0) [0|0] "" XXX + SG_ Befehl_Fehlerspeicher_loeschen : 0|8@1+ (1,0) [0|0] "" XXX + +BO_ 1432 Daempfer_1: 2 XXX + SG_ Frei_Daempfer_1_4 : 12|4@1+ (1,0) [0|0] "" XXX + SG_ Textbits_Daempfer : 8|4@1+ (1,0) [0|0] "" XXX + SG_ Fehlerspeicherbit__Daempfer_1_ : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Systemstatus__Daempfer_1_ : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Daempfer_1_3 : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Status_CDC_Taster : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Daempfer_1_2 : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Status_Daempferregelung_4_1 : 0|3@1+ (1,0) [0|7] "" XXX + +BO_ 1392 BSG_Last: 4 XXX + SG_ Klimaanlage_abschalten : 31|1@1+ (1,0) [0|0] "" XXX + SG_ Sitzbelueftung_abschalten : 30|1@1+ (1,0) [0|0] "" XXX + SG_ Wischwasserheizung_abschalten : 29|1@1+ (1,0) [0|0] "" XXX + SG_ Lenkradheizung_abschalten : 28|1@1+ (1,0) [0|0] "" XXX + SG_ Heizbare_Sitze_abschalten : 27|1@1+ (1,0) [0|0] "" XXX + SG_ Heizbare_Aussenspiegel_abschalt : 26|1@1+ (1,0) [0|0] "" XXX + SG_ Heizbare_Frontscheibe_abschalte : 25|1@1+ (1,0) [0|0] "" XXX + SG_ Heizbare_Heckscheibe_abschalten : 24|1@1+ (1,0) [0|0] "" XXX + SG_ Batteriespannung_Bordnetzbatter : 16|8@1+ (0.05,5) [5|17.7] "V" XXX + SG_ Motorhaubenkontakt : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Leuchtweitenregulierung : 14|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerspeichereintrag__BSG_Last : 13|1@1+ (1,0) [0|0] "" XXX + SG_ Zustand_der_Starterbatterie : 11|2@1+ (1,0) [0|0] "" XXX + SG_ Zustand_der_Bordnetzbatterie : 9|2@1+ (1,0) [0|0] "" XXX + SG_ LL_Drehzahlanhebung : 8|1@1+ (1,0) [0|0] "" XXX + SG_ Klemme_L : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_BSG_Last_1_1 : 4|3@1+ (1,0) [0|0] "" XXX + SG_ ZAS_Klemme_50 : 3|1@1+ (1,0) [0|0] "" XXX + SG_ ZAS_Klemme_X : 2|1@1+ (1,0) [0|0] "" XXX + SG_ ZAS_Klemme_15 : 1|1@1+ (1,0) [0|0] "" XXX + SG_ ZAS_Klemme_S : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1136 BSG_Kombi: 5 XXX + SG_ Frei_BSG_Kombi_1_3 : 36|4@1+ (1,0) [0|0] "" XXX + SG_ Ruecksitzlehne_HR_verr__4_1 : 35|1@1+ (1,0) [0|0] "" XXX + SG_ Ruecksitzlehne_HL_verr__4_1 : 34|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerlampe_Lenkhilfe_veraltet : 33|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerlampe_Lenkhilfe__BSG_Komb : 32|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerstatus_Kl__58s : 31|1@1+ (1,0) [0|0] "" XXX + SG_ Klemme_58s__BSG_Kombi_ : 24|7@1+ (1,0) [0|100] "%" XXX + SG_ Fehlerstatus_Kl__58d : 23|1@1+ (1,0) [0|0] "" XXX + SG_ Klemme_58d__BSG_Kombi_ : 16|7@1+ (1,0) [0|100] "%" XXX + SG_ Unterspannung : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_BSG_Kombi_1_2 : 14|1@1+ (1,0) [0|0] "" XXX + SG_ Heckdeckel_geoeffnet : 13|1@1+ (1,0) [0|0] "" XXX + SG_ Motorhaube_geoeffnet : 12|1@1+ (1,0) [0|0] "" XXX + SG_ Tuer_hinten_rechts_geoeffnet : 11|1@1+ (1,0) [0|0] "" XXX + SG_ Tuer_hinten_links_geoeffnet : 10|1@1+ (1,0) [0|0] "" XXX + SG_ Beifahrertuer_geoeffnet : 9|1@1+ (1,0) [0|0] "" XXX + SG_ Fahrertuer_geoeffnet : 8|1@1+ (1,0) [0|0] "" XXX + SG_ Lade_Kontrollampe : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_BSG_Kombi_1_1 : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Rueckfahrlicht : 5|1@1+ (1,0) [0|0] "" XXX + SG_ DWA_Akku : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Warnblink_Mode : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Anhaenger_Kontrollampe : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Blinker_rechts_Kontrollampe : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Blinker_links_Kontrollampe : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 424 Bremse_6: 3 XXX + SG_ Checksumme_Bremse_6 : 16|8@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_Bremse_6 : 12|4@1+ (1,0) [0|15] "" XXX + SG_ Status_Bremsdruck__Bremse_6__du : 11|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Bremse_6_1 : 10|1@1+ (1,0) [0|0] "" XXX + SG_ Bremsdruck__Bremse_6_ : 0|10@1+ (0.3255,-40) [-40|293] "bar" XXX + +BO_ 1192 Bremse_5: 8 XXX + SG_ Checksumme_Bremse_5 : 56|8@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_Bremse_5 : 52|4@1+ (1,0) [0|15] "" XXX + SG_ Bremslicht_ECD : 51|1@1+ (1,0) [0|0] "" XXX + SG_ Bremsentemperatur_vorn : 48|3@1+ (125,125) [125|1000] "C" XXX + SG_ Frei_Bremse_5_5 : 40|8@1+ (1,0) [0|0] "" XXX + SG_ Offset_Gierrate : 32|8@1+ (0.05,-6.375) [-6.375|6.375] "deg/s" XXX + SG_ Vorzeichen_Bremsdruck : 31|1@1+ (1,0) [0|0] "" XXX + SG_ Status_Bremsdruck_durch_ESP_Sys : 30|1@1+ (1,0) [0|0] "" XXX + SG_ Bremsdruck_ungueltig : 29|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Bremse_5_3 : 28|1@1+ (1,0) [0|0] "" XXX + SG_ Bremsdruck : 16|12@1+ (0.1,0) [0|250] "bar" XXX + SG_ Vorzeichen_der_Giergeschwindigk : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Gierrate_ungueltig : 14|1@1+ (1,0) [0|0] "" XXX + SG_ Giergeschwindigkeit : 0|14@1+ (0.01,0) [0|100] "Grad/sec" XXX + +BO_ 672 Bremse_4: 3 XXX + SG_ Frei_Bremse_4_1 : 17|7@1+ (1,0) [0|0] "" XXX + SG_ Einheit_Kupplungssteifigkeit : 16|1@1+ (1,0) [0|0] "" XXX + SG_ ABS_Vorgabewert_hinten_Kupplung : 8|8@1+ (0.7874,0) [0|100] "%" XXX + SG_ ABS_Vorgabewert_mitte_Kupplungs : 0|8@1+ (3,-381) [-381|378] "Nm/min" XXX + +BO_ 1184 Bremse_3: 8 XXX + SG_ Radgeschw__HR_4_1 : 49|15@1+ (0.01,0) [0|326] "km/h" XXX + SG_ Frei_Bremse_3_4 : 48|1@1+ (1,0) [0|0] "" XXX + SG_ Radgeschw__HL_4_1 : 33|15@1+ (0.01,0) [0|326] "km/h" XXX + SG_ Frei_Bremse_3_3 : 32|1@1+ (1,0) [0|0] "" XXX + SG_ Radgeschw__VR_4_1 : 17|15@1+ (0.01,0) [0|326] "km/h" XXX + SG_ Frei_Bremse_3_2 : 16|1@1+ (0.01,0) [0|325] "km/h" XXX + SG_ Radgeschw__VL_4_1 : 1|15@1+ (0.01,0) [0|326] "km/h" XXX + SG_ Frei_Bremse_3_1 : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1440 Bremse_2: 8 XXX + SG_ gemessene_Querbeschleunigung : 63|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Bremse_2_2 : 62|1@1+ (1,0) [0|0] "" XXX + SG_ Impulszahl : 56|6@1+ (1,0) [0|63] "" XXX + SG_ Fehlerstatus_Wegimpulse_4_1 : 55|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Bremse_2_5 : 54|1@1+ (1,0) [0|0] "" XXX + SG_ Warnlampe_DDS : 53|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerspeichereintrag_Bremse : 52|1@1+ (1,0) [0|0] "" XXX + SG_ Wegimpulszaehlerstatus : 51|1@1+ (1,0) [0|0] "" XXX + SG_ Wegimpulse_Vorderachse : 40|11@1+ (1,0) [0|2047] "" XXX + SG_ Zeitstempel : 24|16@1+ (1,0) [0|65535] "tics" XXX + SG_ mittlere_Raddrehzahl__Bremse_2 : 9|15@1+ (0.002,0) [0|65.278] "U/sec" XXX + SG_ Querbeschl__TimerTic M : 8|1@1+ (1,0) [0|0] "" XXX + SG_ Timer m1 : 0|8@1+ (0.04,0) [0|10.2] "usec" XXX + SG_ Querbeschleunigung m0 : 0|8@1+ (0.01,-1.27) [-1.27|1.27] "g" XXX + +BO_ 416 Bremse_1: 8 XXX + SG_ Geschwindigkeitsersatzwert : 63|1@1+ (1,0) [0|0] "" XXX + SG_ ESP_Systemstatus_4_1 : 62|1@1+ (1,0) [0|0] "" XXX + SG_ ESP_Passiv_getastet : 61|1@1+ (1,0) [0|0] "" XXX + SG_ ASR_Steuerger_t : 60|1@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_Bremse_1 : 56|4@1+ (1,0) [0|15] "" XXX + SG_ MSR_Eingriffsmoment : 48|8@1+ (0.39,0) [0|99.06] "MDI" XXX + SG_ ASR_Eingriffsmoment_schnell : 40|8@1+ (0.39,0) [0|99.06] "MDI" XXX + SG_ ASR_Eingriffsmoment_langsam : 32|8@1+ (0.39,0) [0|99.06] "MDI" XXX + SG_ Geschwindigkeit_neu__Bremse_1_ : 17|15@1+ (0.01,0) [0|326.39] "km/h" XXX + SG_ Aktiver_Bremskraftverstaerker : 16|1@1+ (1,0) [0|0] "" XXX + SG_ ABS_in_Diagnose : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerstatus_Schlechtwegausblen : 14|1@1+ (1,0) [0|0] "" XXX + SG_ Schlechtwegausblendung : 13|1@1+ (1,0) [0|0] "" XXX + SG_ Fahrer_bremst__Bremse_1___4_1_ : 11|1@1+ (1,0) [0|0] "" XXX + SG_ Bremskontroll_Lampe : 10|1@1+ (1,0) [0|0] "" XXX + SG_ Lampe_ASR___ESP : 9|1@1+ (1,0) [0|0] "" XXX + SG_ Lampe_ABS : 8|1@1+ (1,0) [0|0] "" XXX + SG_ EBV_Eingriff : 7|1@1+ (1,0) [0|0] "" XXX + SG_ ASR_Schaltbeeinflussung : 5|2@1+ (1,0) [0|0] "" XXX + SG_ ESP_Eingriff : 4|1@1+ (1,0) [0|0] "" XXX + SG_ EDS_Eingriff : 3|1@1+ (1,0) [0|0] "" XXX + SG_ ABS_Bremsung__4_1_ : 2|1@1+ (1,0) [0|0] "" XXX + SG_ MSR_Anforderung : 1|1@1+ (1,0) [0|0] "" XXX + SG_ ASR_Anforderung : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 680 Bremsbooster_1: 3 XXX + SG_ Fehlerspeichereintrag_Booster : 23|1@1+ (1,0) [0|0] "" XXX + SG_ Loseschalter_unplausibel_Boost : 22|1@1+ (1,0) [0|0] "" XXX + SG_ Position_Standby : 21|1@1+ (1,0) [0|0] "" XXX + SG_ ADR_Relais_ge_ffnet : 20|1@1+ (1,0) [0|0] "" XXX + SG_ Status_Bremsbooster_Steuerung : 19|1@1+ (1,0) [0|0] "" XXX + SG_ Bremsbooster_verf_gbar : 18|1@1+ (1,0) [0|0] "" XXX + SG_ Eingriff_Bremsbooster : 17|1@1+ (1,0) [0|0] "" XXX + SG_ Bremseingriff_Fahrer : 16|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Bremsbooster_1_1 : 12|4@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_Booster_1 : 8|4@1+ (1,0) [0|15] "" XXX + SG_ Checksumme_Booster_1 : 0|8@1+ (1,0) [0|0] "" XXX + +BO_ 1400 BatMan_1: 1 XXX + SG_ Fehlerspeichereintrag__BatMan_ : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Leistungsrelais : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Messung_Starterleitung : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Zustand_Starterleitung : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Umschaltrelais_Bordnetzbatterie : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Ladung_Starterbatterie : 1|2@1+ (1,0) [0|0] "" XXX + SG_ Startmodus : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 704 Allrad_1: 5 XXX + SG_ Kupplungssteifigkeit_Hinten__Is : 32|8@1+ (0.7874,0) [0|100] "%" XXX + SG_ Fehlerspeichereintrag_Allrad_1 : 31|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Allrad_1_1 : 26|5@1+ (1,0) [0|0] "" XXX + SG_ Schaltung_Vorwarnung : 25|1@1+ (1,0) [0|0] "" XXX + SG_ Schaltung_aktiv__Allrad_1_ : 24|1@1+ (1,0) [0|0] "" XXX + SG_ Ganginfo__PNG_ : 20|4@1+ (1,0) [0|0] "" XXX + SG_ PNG_Anzeige_blinkend : 19|1@1+ (1,0) [0|0] "" XXX + SG_ PNG_Status_4_1 : 16|3@1+ (1,0) [0|0] "" XXX + SG_ Kupplungssteifigkeit_Mitte__Ist : 8|8@1+ (3,-381) [-381|378] "Nm/min" XXX + SG_ Einheit_der_Kupplungssteifigkei : 7|1@1+ (1,0) [0|0] "" XXX + SG_ Geschwindigkeitsbegrenzung : 6|1@1+ (1,0) [0|0] "" XXX + SG_ Allrad_Warnlampe : 5|1@1+ (1,0) [0|0] "" XXX + SG_ Notlauf : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Kupplung_komplett_offen : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Fehlerstatus_Kupplungssteifigke : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Ubertemperaturschutz__Allrad_1_ : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Fehler_Allrad_Kupplung : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 1360 Airbag_2: 2 XXX + SG_ OOP_Beifahrer : 14|2@1+ (1,0) [0|0] "" XXX + SG_ OOP_Fahrer : 12|2@1+ (1,0) [0|0] "" XXX + SG_ Belegungserkennung_hinten_mitte : 11|1@1+ (1,0) [0|0] "" XXX + SG_ Belegungserkennung_hinten_recht : 10|1@1+ (1,0) [0|0] "" XXX + SG_ Belegungserkennung_hinten_links : 9|1@1+ (1,0) [0|0] "" XXX + SG_ Belegungserkennung_Beifahrersit : 8|1@1+ (1,0) [0|0] "" XXX + SG_ Checksumme_Airbag_2__reserviert : 0|8@1+ (1,0) [0|0] "" XXX + +BO_ 80 Airbag_1: 4 XXX + SG_ Checksumme_Airbag_1 : 24|8@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_Airbag_1 : 20|4@1+ (1,0) [0|15] "" XXX + SG_ Fehlerspeichereintrag : 19|1@1+ (1,0) [0|0] "" XXX + SG_ Frei_Airbag_1_2 : 18|1@1+ (1,0) [0|0] "" XXX + SG_ Airbag_im_Stellgliedtest : 17|1@1+ (1,0) [0|0] "" XXX + SG_ Airbag_in_Diagnose : 16|1@1+ (1,0) [0|0] "" XXX + SG_ Gurtwarnung_Beifahrer : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Gurtschalter_Beifahrer : 14|1@1+ (1,0) [0|0] "" XXX + SG_ Gurtwarnung_Fahrer : 13|1@1+ (1,0) [0|0] "" XXX + SG_ Gurtschalter_Fahrer : 12|1@1+ (1,0) [0|0] "" XXX + SG_ Airbag_Systemfehler : 11|1@1+ (1,0) [0|0] "" XXX + SG_ Kindersitzerkennung : 10|1@1+ (1,0) [0|0] "" XXX + SG_ Airbag_deaktiviert : 9|1@1+ (1,0) [0|0] "" XXX + SG_ Airbag_Lampe : 8|1@1+ (1,0) [0|0] "" XXX + SG_ Crash_Intensitaet : 5|3@1+ (1,0) [0|111] "B" XXX + SG_ Rollover : 4|1@1+ (1,0) [0|0] "" XXX + SG_ Seiten_Crash_Beifahrer : 3|1@1+ (1,0) [0|0] "" XXX + SG_ Seiten_Crash_Fahrer : 2|1@1+ (1,0) [0|0] "" XXX + SG_ Heck_Crash : 1|1@1+ (1,0) [0|0] "" XXX + SG_ Front_Crash : 0|1@1+ (1,0) [0|0] "" XXX + +BO_ 864 ADR_System: 8 XXX + SG_ S_Checksumme_ADR_1 : 56|8@1+ (1,0) [0|0] "" XXX + SG_ S_Frei_ADR_1_1 : 52|4@1+ (1,0) [0|0] "" XXX + SG_ S_Zeitluecke_gemessen : 48|4@1+ (1,0) [0|15] "" XXX + SG_ S_Fehlerspeichereintrag_ADR : 47|1@1+ (1,0) [0|0] "" XXX + SG_ S_Fehlerspeichereintrag_Bremsbo : 46|1@1+ (1,0) [0|0] "" XXX + SG_ S_ADR_Relais_geoeffnet : 45|1@1+ (1,0) [0|0] "" XXX + SG_ S_Bremsbooster_Status : 43|2@1+ (1,0) [0|0] "" XXX + SG_ S_Eingriff_Bremsbooster : 42|1@1+ (1,0) [0|0] "" XXX + SG_ S_Loeseschalter_unplausibel : 41|1@1+ (1,0) [0|0] "" XXX + SG_ S_Bremseingriff_Fahrer : 40|1@1+ (1,0) [0|0] "" XXX + SG_ S_Anzeige_Sensor_blind : 39|1@1+ (1,0) [0|0] "" XXX + SG_ S_Ansteuerung_optischer_Fahrerh : 38|1@1+ (1,0) [0|0] "" XXX + SG_ S_Ansteuerung_Gong_2 : 37|1@1+ (1,0) [0|0] "" XXX + SG_ S_Ansteuerung_Gong_1 : 36|1@1+ (1,0) [0|0] "" XXX + SG_ S_Schaltaufforderung : 34|2@1+ (1,0) [0|0] "" XXX + SG_ S_Anzeige_Prioritaet : 33|1@1+ (1,0) [0|0] "" XXX + SG_ S_Anzeige_Zeitluecke : 32|1@1+ (1,0) [0|0] "" XXX + SG_ S_Wunschgeschwindigkeit : 24|8@1+ (1,0) [0|254] "km/h" XXX + SG_ S_Objekt_erfasst : 22|2@1+ (1,0) [0|0] "" XXX + SG_ S_Gesetzte_Zeitluecke__ADR_1_ : 18|4@1+ (1,0) [0|15] "" XXX + SG_ S_Synchronisation_Bremsbooster : 17|1@1+ (1,0) [0|0] "" XXX + SG_ S_Momentenanforderung_Freigabe : 16|1@1+ (1,0) [0|0] "" XXX + SG_ S_Verhinderung_Schubabschaltung : 15|1@1+ (1,0) [0|0] "" XXX + SG_ S_Status_ADR_1__S_ : 13|2@1+ (1,0) [0|0] "" XXX + SG_ S_Fehler_ADR_1__S_ : 12|1@1+ (1,0) [0|0] "" XXX + SG_ S_Zaehler_ADR_1 : 8|4@1+ (1,0) [0|15] "" XXX + SG_ S_Momentenanforderung_ADR : 0|8@1+ (0.39,0) [0|99] "MDI" XXX + +BO_ 608 ADR_2: 4 XXX + SG_ Frei_ADR_2_2 : 27|5@1+ (1,0) [0|0] "" XXX + SG_ Anforderung_Bremsdruck : 16|11@1+ (0.0625,0) [0|127.9375] "bar" XXX + SG_ Frei_ADR_2_1 : 14|2@1+ (1,0) [0|0] "" XXX + SG_ Relais_Test_Fehler : 13|1@1+ (1,0) [0|0] "" XXX + SG_ Standby : 12|1@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_ADR_2 : 8|4@1+ (1,0) [0|15] "" XXX + SG_ Checksumme_ADR_2 : 0|8@1+ (1,0) [0|0] "" XXX + +BO_ 1324 ADR_1: 8 XXX + SG_ Checksumme_ADR_1 : 56|8@1+ (1,0) [0|0] "" XXX + SG_ Frei_ADR_1_5 : 52|4@1+ (1,0) [0|0] "" XXX + SG_ Zeitluecke_gemessen : 48|4@1+ (1,0) [0|15] "" XXX + SG_ Fehlerspeichereintrag_ADR : 47|1@1+ (1,0) [0|0] "" XXX + SG_ Reserviert_ADR_1_1 : 40|7@1+ (1,0) [0|0] "" XXX + SG_ Anzeige_Sensor_blind : 39|1@1+ (1,0) [0|0] "" XXX + SG_ Ansteuerung_optischer_Fahrerhin : 38|1@1+ (1,0) [0|0] "" XXX + SG_ Ansteuerung_Gong_2 : 37|1@1+ (1,0) [0|0] "" XXX + SG_ Ansteuerung_Gong_1 : 36|1@1+ (1,0) [0|0] "" XXX + SG_ Schaltaufforderung : 34|2@1+ (1,0) [0|0] "" XXX + SG_ Anzeige_Prioritaet : 33|1@1+ (1,0) [0|0] "" XXX + SG_ Anzeige_Zeitluecke : 32|1@1+ (1,0) [0|0] "" XXX + SG_ Wunschgeschwindigkeit : 24|8@1+ (1,0) [0|254] "km/h" XXX + SG_ Objekt_erfasst : 22|2@1+ (1,0) [0|0] "" XXX + SG_ Gesetzte_Zeitluecke__ADR_1_ : 18|4@1+ (1,0) [0|15] "" XXX + SG_ Synchronisation_Bremsbooster : 17|1@1+ (1,0) [0|0] "" XXX + SG_ Momentenanforderung_Freigabe : 16|1@1+ (1,0) [0|0] "" XXX + SG_ Verhinderung_Schubabschaltung : 15|1@1+ (1,0) [0|0] "" XXX + SG_ Status_ADR_1 : 13|2@1+ (1,0) [0|0] "" XXX + SG_ Fehler_ADR_1 : 12|1@1+ (1,0) [0|0] "" XXX + SG_ Zaehler_ADR_1 : 8|4@1+ (1,0) [0|15] "" XXX + SG_ Momentenanforderung_ADR : 0|8@1+ (0.39,0) [0|99] "MDI" XXX + +BO_ 1550 Einheiten_1: 2 XXX + SG_ MFA_v_Einheit_02 : 0|1@1+ (1,0) [0|1] "" XXX + +BO_ 872 ACC_System: 8 XXX + SG_ ACS_Checksum : 0|8@1+ (1,0) [0|255] "" XXX + SG_ ACS_Zaehler : 8|4@1+ (1,0) [0|15] "" XXX + SG_ ACS_Sta_ADR : 12|2@1+ (1,0) [0|3] "" XXX + SG_ ACS_ADR_Schub : 14|1@1+ (1,0) [0|1] "" XXX + SG_ ACS_Schubabsch : 15|1@1+ (1,0) [0|1] "" XXX + SG_ ACS_StSt_Info : 16|2@1+ (1,0) [0|3] "" XXX + SG_ ACS_MomEingriff : 18|1@1+ (1,0) [0|1] "" XXX + SG_ ACS_Typ_ACC : 19|2@1+ (1,0) [0|3] "" XXX + SG_ ACS_FreigSollB : 23|1@1+ (1,0) [0|1] "" XXX + SG_ ACS_Sollbeschl : 24|11@1+ (0.005,-7.22) [-7.22|3.005] "Unit_MeterPerSeconSquar" XXX + SG_ ACS_Anhaltewunsch : 38|1@1+ (1,0) [0|1] "" XXX + SG_ ACS_Fehler : 39|1@1+ (1,0) [0|1] "" XXX + SG_ ACS_zul_Regelabw : 40|8@1+ (1,0.005) [0|1.265] "Unit_MeterPerSeconSquar" XXX + SG_ ACS_max_AendGrad : 48|8@1+ (1,0.02) [0.02|5.06] "Unit_MeterPerSeconSquar" XXX + +BO_ 1386 ACC_GRA_Anziege: 8 XXX + SG_ ACA_Checksum : 0|8@1+ (1,0) [0|255] "" XXX + SG_ ACA_StaACC : 8|3@1+ (1,0) [0|7] "" XXX + SG_ ACA_ID_StaACC : 11|5@1+ (1,0) [0|31] "" XXX + SG_ ACA_Fahrerhinw : 16|1@1+ (1,0) [0|1] "" XXX + SG_ ACA_AnzDisplay : 17|1@1+ (1,0) [0|1] "" XXX + SG_ ACA_Zeitluecke : 18|4@1+ (1,0) [0|15] "" XXX + SG_ ACA_V_Wunsch : 24|8@1+ (1,0) [0|255] "Unit_KiloMeterPerHour" XXX + SG_ ACA_kmh_mph : 32|1@1+ (1,0) [0|1] "" XXX + SG_ ACA_Akustik1 : 33|1@1+ (1,0) [0|1] "" XXX + SG_ ACA_Akustik2 : 34|1@1+ (1,0) [0|1] "" XXX + SG_ ACA_PrioDisp : 35|1@1+ (1,0) [0|1] "" XXX + SG_ ACA_gemZeitl : 40|4@1+ (1,0) [0|15] "" XXX + SG_ ACA_ACC_Verz : 44|1@1+ (1,0) [0|1] "" XXX + SG_ ACA_StaGRA : 48|3@1+ (1,0) [0|7] "" XXX + SG_ ACA_ID_StaGRA : 51|5@1+ (1,0) [0|31] "" XXX + SG_ ACA_Codierung : 56|1@1+ (1,0) [0|1] "" XXX + SG_ ACA_Tachokranz : 57|1@1+ (1,0) [0|1] "" XXX + SG_ ACA_Aend_Zeitluecke : 58|1@1+ (1,0) [0|1] "" XXX + SG_ ACA_Zaehler : 60|4@1+ (1,0) [0|15] "" XXX + +BO_ 208 Lenkhilfe_3: 8 XXX + SG_ LH3_Checksumme : 0|8@1+ (1,0) [0|255] "" XXX + SG_ LH3_BS_Spiegel : 8|4@1+ (1,0) [0|15] "" XXX + SG_ LH3_Zaehler : 12|4@4+ (1,0) [0|15] "" XXX + SG_ LH3_LM : 16|10@1+ (1,0) [0|1023] "" XXX + SG_ LH3_LMSign : 26|1@1+ (1,0) [0|1] "" XXX + SG_ LH3_LMValid : 27|1@1+ (1,0) [0|1] "" XXX + SG_ LH3_Sta_DSR : 28|4@1+ (1,0) [0|15] "" XXX + SG_ LH3_BLW : 32|12@1+ (0.15,0) [0|615] "" XXX + SG_ LH3_BLWSign : 44|1@1+ (1,0) [0|1] "" XXX + SG_ LH3_BLWValid : 45|1@1+ (1,0) [0|1] "" XXX + SG_ LH3_Lenkungstyp : 46|2@1+ (1,0) [0|3] "" XXX + +BO_ 978 Lenkhilfe_2: 8 XXX + SG_ LH2_Checksumme : 0|8@1+ (1,0) [0|255] "" XXX + SG_ LH2_Zaehler : 8|4@1+ (1,0) [0|15] "" XXX + SG_ LH2_Geradeaus : 12|1@1+ (1,0) [0|1] "" XXX + SG_ LH2_Sta_Charisma : 13|3@1+ (1,0) [0|7] "" XXX + SG_ LH2_Sta_HCA : 16|4@1+ (1,0) [0|15] "" XXX + SG_ LH2_Ausg_LW1 : 20|1@1+ (1,0) [0|1] "" XXX + SG_ LH2_Ausg_LW1_gue : 21|1@1+ (1,0) [0|1] "" XXX + SG_ LH2_StatEPS_PLA : 24|4@1+ (1,0) [0|15] "" XXX + SG_ LH2_aktLenkeingriff : 32|8@1+ (1,0) [0|255] "" XXX + SG_ LH2_PLA_Err : 48|4@1+ (1,0) [0|15] "" XXX + SG_ LH2_PLA_Abbr : 52|4@1+ (1,0) [0|15] "" XXX + +BO_ 210 HCA_1: 5 XXX + SG_ HCA_Checksumme : 0|8@1+ (1,0) [0|15] "" XXX + SG_ HCA_Zaehler : 8|4@1+ (1,0) [0|15] "" XXX + SG_ HCA_Status : 12|4@1+ (1,0) [0|15] "" XXX + SG_ LM_Offset : 16|15@1+ (0.03125,0) [0|300] "cNm" XXX + SG_ LM_OffSign : 31|1@1+ (1,0) [0|1] "" XXX + SG_ Vib_Freq : 32|4@1+ (4,0) [0|60] "Hz" XXX + SG_ Vib_Amp : 36|4@1+ (0.5,0) [0|7.5] "Nm" XXX + +BO_ 1470 LDW_1: 8 XXX + SG_ Right_Lane_Status : 0|2@1+ (1,0) [0|3] "" XXX + SG_ Left_Lane_Status : 2|2@1+ (1,0) [0|3] "" XXX + SG_ LDW_Direction : 14|1@0+ (1,0) [0|1] "" XXX + SG_ SET_ME_X1 : 18|1@0+ (1,0) [0|1] "" XXX + SG_ Kombi_Lamp_Orange : 19|1@0+ (1,0) [0|1] "" XXX + SG_ Kombi_Lamp_Green : 20|1@0+ (1,0) [0|1] "" XXX + SG_ XX_LDW_Maybe_Warning : 16|1@0+ (1,0) [0|1] "" XXX + SG_ XX_DLCORTLC1 : 24|8@1+ (1,0) [0|255] "" XXX + SG_ XX_DLCORTLC2 : 32|8@1+ (1,0) [0|255] "" XXX + +BO_ 428 Bremse_8: 8 XXX + SG_ BR8_Checksumme : 0|8@1+ (1,0) [0|255] "" XXX + SG_ BR8_Zaehler : 8|4@1+ (1,0) [0|15] "" XXX + SG_ BR8_Sta_ACC_Anf : 12|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_Verz_EPB_akt : 13|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_Sta_Br_temp : 14|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_Sta_Br_Druck : 15|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_TolAbgl_HL : 16|8@1+ (0.048828125,-6.201171875) [-6.201171875|6.15234375] "Unit_PerCent" XXX + SG_ BR8_TolAbgl_HR : 24|8@1+ (0.048828125,-6.201171875) [-6.201171875|6.15234375] "Unit_PerCent" XXX + SG_ BR8_Istbeschl : 32|9@1+ (0.02,-7.22) [-7.22|2.98] "Unit_MeterPerSeconSquar" XXX + SG_ BR8_Sta_HW_BLS : 41|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_QB_LBeschl : 42|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_ESC_Mode : 43|2@1+ (1,0) [0|3] "" XXX + SG_ BR8_aktBrSyst : 45|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_Fa_bremst : 46|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_StaBrSyst : 47|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_Laengsbeschl : 48|10@1+ (0.03125,-16) [-15.96875|15.9375] "Unit_MeterPerSeconSquar" XXX + SG_ BR8_Sta_ADR_BR : 58|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_Quattro : 59|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_Sta_VerzReg : 60|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_Sta_BLS : 61|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_Verz_EPB : 62|1@1+ (1,0) [0|1] "" XXX + SG_ BR8_Check_EPB : 63|1@1+ (1,0) [0|1] "" XXX + + BO_ 928 Bremse_10: 8 XXX + SG_ B10_Checksumme : 0|8@1+ (1,0) [0|255] "" XXX + SG_ B10_Zaehler : 8|4@1+ (1,0) [0|15] "" XXX + SG_ B10_QB_Wegimp_VL : 12|1@1+ (1,0) [0|1] "" XXX + SG_ B10_QB_Wegimp_VR : 13|1@1+ (1,0) [0|1] "" XXX + SG_ B10_QB_Wegimp_HL : 14|1@1+ (1,0) [0|1] "" XXX + SG_ B10_QB_Wegimp_HR : 15|1@1+ (1,0) [0|1] "" XXX + SG_ B10_Wegimp_VL : 16|10@1+ (1,0) [0|1000] "" XXX + SG_ B10_Wegimp_VR : 26|10@1+ (1,0) [0|1000] "" XXX + SG_ B10_Wegimp_HL : 36|10@1+ (1,0) [0|1000] "" XXX + SG_ B10_Wegimp_HR : 46|10@1+ (1,0) [0|1000] "" XXX + SG_ B10_QB_Fahrtr_VL : 56|1@1+ (1,0) [0|1] "" XXX + SG_ B10_QB_Fahrtr_VR : 57|1@1+ (1,0) [0|1] "" XXX + SG_ B10_QB_Fahrtr_HL : 58|1@1+ (1,0) [0|1] "" XXX + SG_ B10_QB_Fahrtr_HR : 59|1@1+ (1,0) [0|1] "" XXX + SG_ B10_Fahrtr_VL : 60|1@1+ (1,0) [0|1] "" XXX + SG_ B10_Fahrtr_VR : 61|1@1+ (1,0) [0|1] "" XXX + SG_ B10_Fahrtr_HL : 62|1@1+ (1,0) [0|1] "" XXX + SG_ B10_Fahrtr_HR : 63|1@1+ (1,0) [0|1] "" XXX + + BO_ 835 RDK_Status: 3 XXX + SG_ RKS_Reifen_VL : 0|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Reifen_VR : 1|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Reifen_HL : 2|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Reifen_HR : 3|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Reifen_RR : 4|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Warnung_2 : 5|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Warnung_1 : 6|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Systemfehler : 7|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Kalibrier_abgew : 8|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Druckdiff_Vorn : 9|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Druckdiff_Hinten : 10|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Befuellung_RR_low : 11|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Funkstoerung : 12|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_System_Aus : 13|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_KD_Fehler : 15|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Lampe : 16|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Ton : 17|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Gong : 18|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_RDK_Blinkbit : 19|1@1+ (1,0) [0|1] "" XXX + SG_ RKS_Teillast : 20|1@1+ (1,0) [0|1] "" XXX + + BO_ 914 Gate_Komf_2: 8 XXX + SG_ GK2_Sta_LSM : 0|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Sta_Lichtsensor : 1|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Sta_Licht1 : 2|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Sta_VSG : 3|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Sta_Schluessel : 4|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Sta_Profil : 5|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Sta_Clima2 : 6|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Sta_BSG4 : 7|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Sta_Kessy_4 : 8|1@1+ (1,0) [0|1] "" XXX + SG_ BS4_Gleitende_Leuchtw_Anf : 9|1@1+ (1,0) [0|1] "" XXX + SG_ BS4_GLW_Fernlicht_Anf : 10|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Blk_L_Kontrolle : 11|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Blk_R_Kontrolle : 12|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_LS_KomFehler : 14|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_LS_def : 15|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Helligkeit : 16|3@1+ (714.286,0) [0|5000.002] "Unit_Lux" XXX + SG_ GK2_VD_zu_ver : 19|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_VD_entriegelt : 20|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_VD_offen_ver : 21|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Verdeck_Anf : 22|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_VDKD_auf : 23|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Schluessel : 24|4@1+ (1,0) [0|15] "" XXX + SG_ GK2_Hardtop : 28|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_AFL_Schalter : 29|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Nebelschluss : 30|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_EM_LIN_ungueltig : 31|1@1+ (1,0) [0|1] "" XXX + SG_ GK2_Profil : 32|4@1+ (1,0) [0|15] "" XXX + SG_ GK2_Kl_StSt_Info : 36|2@1+ (1,0) [0|3] "" XXX + SG_ GK2_BSG_StSt_Info : 38|2@1+ (1,0) [0|3] "" XXX + SG_ GK2_BEM_P_Generator : 40|8@1+ (50,0) [0|12700] "Unit_Watt" XXX + SG_ GK2_BEM_Abschaltstufen : 48|3@1+ (1,0) [0|7] "" XXX + SG_ GK2_BEM_DFM : 51|5@1+ (3.225,0.025) [0.025|100] "Unit_PerCent" XXX + SG_ GK2_Kessy_StSt_Info : 56|2@1+ (1,0) [0|3] "" XXX + SG_ GK2_BEM_StSt_Info : 58|2@1+ (1,0) [0|3] "" XXX + + BO_ 1175 Parkhilfe_01: 8 XXX + SG_ PH_Abschaltursache : 13|3@1+ (1,0) [0|7] "" XXX + SG_ PH_Opt_Anzeige_V_ein : 16|1@1+ (1,0) [0|1] "" XXX + SG_ PH_Opt_Anzeige_H_ein : 17|1@1+ (1,0) [0|1] "" XXX + SG_ PH_Opt_Anz_V_Hindernis : 18|1@1+ (1,0) [0|1] "" XXX + SG_ PH_Opt_Anz_H_Hindernis : 19|1@1+ (1,0) [0|1] "" XXX + SG_ PH_Tongeber_V_aktiv : 20|1@1+ (1,0) [0|1] "" XXX + SG_ PH_Tongeber_H_aktiv : 21|1@1+ (1,0) [0|1] "" XXX + SG_ PH_Tongeber_mute : 22|1@1+ (1,0) [0|1] "" XXX + SG_ PH_Anf_Audioabsenkung : 23|1@1+ (1,0) [0|1] "" XXX + SG_ PH_Frequenz_hinten : 32|4@1+ (1,0) [0|15] "" XXX + SG_ PH_Lautstaerke_hinten : 36|4@1+ (1,0) [0|15] "" XXX + SG_ PH_Frequenz_vorn : 40|4@1+ (1,0) [0|15] "" XXX + SG_ PH_Lautstaerke_vorn : 44|4@1+ (1,0) [0|15] "" XXX + SG_ PH_Trigger_Bildaufschaltung : 48|1@1+ (1,0) [0|1] "" XXX + SG_ PH_StartStopp_Info : 49|2@1+ (1,0) [0|3] "" XXX + SG_ PH_Aufbauten_erk : 51|1@1+ (1,0) [0|1] "" XXX + SG_ PH_BerErk_vorn : 52|2@1+ (1,0) [0|3] "" XXX + SG_ PH_BerErk_hinten : 54|2@1+ (1,0) [0|3] "" XXX + SG_ PH_defekt : 56|1@1+ (1,0) [0|1] "" XXX + SG_ PH_gestoert : 57|1@1+ (1,0) [0|1] "" XXX + SG_ PH_Systemzustand : 58|3@1+ (1,0) [0|7] "" XXX + SG_ PH_Display_Kundenwunsch : 61|2@1+ (1,0) [0|3] "" XXX + SG_ PH_KD_Fehler : 63|1@1+ (1,0) [0|1] "" XXX + + BO_ 1463 Bremse_11: 8 XXX + SG_ B11_HydHalten : 13|1@1+ (1,0) [0|1] "" XXX + SG_ B11_Br_StSt_Info : 14|2@1+ (1,0) [0|3] "" XXX + SG_ B11_OBD_Nib_VL : 16|4@1+ (1,0) [0|15] "" XXX + SG_ B11_OBD_Nib_VR : 20|4@1+ (1,0) [0|15] "" XXX + SG_ B11_OBD_Nib_HL : 24|4@1+ (1,0) [0|15] "" XXX + SG_ B11_OBD_Nib_HR : 28|4@1+ (1,0) [0|15] "" XXX + SG_ B11_EPB_Steller_akt : 32|1@1+ (1,0) [0|1] "" XXX + SG_ B11_EPB_Steller_gue : 33|1@1+ (1,0) [0|1] "" XXX + + BO_ 1500 Soll_Verbauliste_neu: 8 XXX + SG_ VL1_Motor_SG : 0|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Getr_SG : 1|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_ABS : 2|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Kombi : 3|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_LSM : 4|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Airbag : 5|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Lenkhilfe : 6|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_dyn_LWR : 7|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_res_08 : 8|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Allrad : 9|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_ADR : 10|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_ADR_getrennt : 11|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_EPB : 12|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_res_13 : 13|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Daempfer : 14|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Quersperre : 15|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_MotorSlave : 16|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_SWA : 17|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_HCA : 18|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_RKA_Plus : 19|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_PLA : 20|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_WFS_KBI : 21|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Kombi_KBI : 22|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Soll_eq_Ist : 23|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_BSG_Komf : 24|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_ZKE : 25|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_TSG_FT : 26|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_TSG_BT : 27|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_TSG_HL : 28|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_TSG_HR : 29|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Memory : 30|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Dachmodul_K : 31|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Zentralelektrik_II : 32|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_RDK : 33|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Lenksaeule : 34|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Gateway : 35|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Clima_Komf : 36|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Einparkhilfe : 37|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_PTC_Heizung : 38|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Standheiz : 39|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Verdeck : 40|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_RSE_I : 41|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_res_42 : 42|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_MDI_I : 43|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Anhaenger : 44|1@1+ (1,0) [0|1] "" SWA + SG_ VL1_Memory_BF : 45|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Easy_Entry_VF : 46|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Easy_Entry_VB : 47|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Heckdeckel : 48|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Rearview : 49|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Sonderfzg_SG : 50|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Tastenmodul : 51|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Kompass : 52|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_WFS_K : 53|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_GSM_Pager : 54|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_InfoElektronik : 55|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_DSP : 56|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_DAB : 57|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Telematik : 58|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Navigation : 59|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_TV_Tuner : 60|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Neigungsmodul_I : 61|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Radio : 62|1@1+ (1,0) [0|1] "" XXX + SG_ VL1_Telefon : 63|1@1+ (1,0) [0|1] "" XXX + + BO_ 1490 Ident: 8 XXX + SG_ IDT_Mux M : 0|2@1+ (1,0) [0|2] "" XXX + SG_ IDT_Geheimnis_1 m0 : 8|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_4 m1 : 8|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_11 m2 : 8|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_Geheimnis_2 m0 : 16|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_5 m1 : 16|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_12 m2 : 16|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_Geheimnis_3 m0 : 24|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_6 m1 : 24|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_13 m2 : 24|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_Geheimnis_4 m0 : 32|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_7 m1 : 32|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_14 m2 : 32|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_1 m0 : 40|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_8 m1 : 40|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_15 m2 : 40|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_2 m0 : 48|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_9 m1 : 48|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_16 m2 : 48|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_3 m0 : 56|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_10 m1 : 56|8@1+ (1,0) [0|255] "" XXX + SG_ IDT_VIN_17 m2 : 56|8@1+ (1,0) [0|255] "" XXX + +BO_ 2000 Diagnose_1: 8 XXX + SG_ DI1_VerlernZaehl : 0|8@1+ (1,0) [0|254] "" XXX + SG_ DI1_km_Stand : 8|20@1+ (1,0) [0|1048575] "Unit_KiloMeter" XXX + SG_ DI1_Jahr : 28|7@1+ (1,2000) [2000|2127] "Unit_Year" XXX + SG_ DI1_Monat : 35|4@1+ (1,0) [1|12] "Unit_Month" XXX + SG_ DI1_Tag : 39|5@1+ (1,0) [0|31] "Unit_Day" XXX + SG_ DI1_Stunde : 44|5@1+ (1,0) [0|23] "Unit_Hours" XXX + SG_ DI1_Minute : 49|6@1+ (1,0) [0|59] "Unit_Minut" XXX + SG_ DI1_Sekunde : 55|6@1+ (1,0) [0|59] "Unit_Secon" XXX + SG_ DI1_KM_Stand_alt : 62|1@1+ (1,0) [0|1] "" XXX + SG_ DI1_Zeit_alt : 63|1@1+ (1,0) [0|1] "" XXX + +CM_ SG_ 210 LM_Offset "centiNewton-meters for ease of calculation without FP math in Panda"; +CM_ SG_ 210 Vib_Amp "Steering wheel haptic, amplitude"; +CM_ SG_ 210 Vib_Freq "Steering wheel haptic, frequency"; +CM_ SG_ 1386 ACA_V_Wunsch "255=unset"; +CM_ SG_ 1470 LDW_Direction "0=right,1=left"; +CM_ SG_ 1470 XX_DLCORTLC1 "Might be DLC or TLC"; +CM_ SG_ 1470 XX_DLCORTLC2 "Might be DLC or TLC, might have wrong size"; +CM_ SG_ 1550 MFA_v_Signal_02 "0=km/h, 1=mph"; + +VAL_ 1088 Waehlhebelposition__Getriebe_1_ 8 "P" 7 "R" 6 "N" 5 "D" 9 "U"; diff --git a/opendbc/vw_mqb_2010.dbc b/opendbc/vw_mqb_2010.dbc index c542b31f4f6602..c3ee3c29dac527 100644 --- a/opendbc/vw_mqb_2010.dbc +++ b/opendbc/vw_mqb_2010.dbc @@ -1,1145 +1,1145 @@ -VERSION "" - - -NS_ : - NS_DESC_ - CM_ - BA_DEF_ - BA_ - VAL_ - CAT_DEF_ - CAT_ - FILTER - BA_DEF_DEF_ - EV_DATA_ - ENVVAR_DATA_ - SGTYPE_ - SGTYPE_VAL_ - BA_DEF_SGTYPE_ - BA_SGTYPE_ - SIG_TYPE_REF_ - VAL_TABLE_ - SIG_GROUP_ - SIG_VALTYPE_ - SIGTYPE_VALTYPE_ - BO_TX_BU_ - BA_DEF_REL_ - BA_REL_ - BA_DEF_DEF_REL_ - BU_SG_REL_ - BU_EV_REL_ - BU_BO_REL_ - SG_MUL_VAL_ +VERSION "2" + + +NS_ : + NS_DESC_ + CM_ + BA_DEF_ + BA_ + VAL_ + CAT_DEF_ + CAT_ + FILTER + BA_DEF_DEF_ + EV_DATA_ + ENVVAR_DATA_ + SGTYPE_ + SGTYPE_VAL_ + BA_DEF_SGTYPE_ + BA_SGTYPE_ + SIG_TYPE_REF_ + VAL_TABLE_ + SIG_GROUP_ + SIG_VALTYPE_ + SIGTYPE_VALTYPE_ + BO_TX_BU_ + BA_DEF_REL_ + BA_REL_ + BA_DEF_DEF_REL_ + BU_SG_REL_ + BU_EV_REL_ + BU_BO_REL_ + SG_MUL_VAL_ BS_: -BU_: Airbag_MQB BAP_Tester_MQB BMS_MQB Datenlogger_MQB Gateway_MQB Getriebe_DQ_Hybrid_MQB Getriebe_DQ_MQB LEH_MQB Motor_Diesel_MQB Motor_Hybrid_MQB Motor_Otto_MQB SAK_MQB Waehlhebel_MQB Vector__XXX 9 l c i XXX - - -BO_ 290 ACC_06: 8 Gateway_MQB - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ACC_limitierte_Anfahrdyn : 12|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ACC_zul_Regelabw_unten : 16|6@1+ (0.024,0) [0|1.512] "Unit_MeterPerSeconSquar" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ACC_StartStopp_Info : 22|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ ACC_Sollbeschleunigung_02 : 24|11@1+ (0.005,-7.22) [-7.22|3.005] "Unit_MeterPerSeconSquar" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ACC_zul_Regelabw_oben : 35|5@1+ (0.0625,0) [0|1.9375] "Unit_MeterPerSeconSquar" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ACC_neg_Sollbeschl_Grad_02 : 40|8@1+ (0.05,0) [0|12.75] "Unit_MeterPerCubicSecon" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ACC_pos_Sollbeschl_Grad_02 : 48|8@1+ (0.05,0) [0|12.75] "Unit_MeterPerCubicSecon" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ACC_Anfahren : 56|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ACC_Anhalten : 57|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ACC_Typ : 58|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ACC_Status_ACC : 60|3@1+ (1,0) [0|7] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ACC_Minimale_Bremsung : 63|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - -BO_ 279 ACC_10: 8 Gateway_MQB - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Airbag_MQB - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Airbag_MQB - SG_ AWV1_Anf_Prefill : 16|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ ANB_CM_Info : 17|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ AWV2_Freigabe : 18|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ AWV1_HBA_Param : 19|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ AWV2_Ruckprofil : 21|3@1+ (1,0) [0|7] "" Vector__XXX - SG_ AWV2_Priowarnung : 24|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ANB_CM_Anforderung : 25|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ ANB_Info_Teilbremsung : 26|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ANB_Notfallblinken : 27|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ANB_Teilbremsung_Freigabe : 28|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ ANB_Zielbrems_Teilbrems_Verz_Anf : 29|10@1+ (0.024,-20.016) [-20.016|4.536] "Unit_MeterPerSeconSquar" Airbag_MQB - SG_ ANB_Zielbremsung_Freigabe : 39|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ AWV_Vorstufe : 40|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ AWV_Halten : 41|1@1+ (1,0) [0|1] "" Vector__XXX +BU_: Kessy_MQB Anhaenger_MQB LCM_MQB EPS_MQB BCM_MQB DCC_MQB ESP_MQB Front_Multifunction_Camera_MQB Rear_Radar_MQB Navigation_MQB Front_Radar_MQB Airbag_MQB BAP_Tester_MQB BMS_MQB Gateway_MQB Getriebe_DQ_Hybrid_MQB Getriebe_DQ_MQB LEH_MQB Motor_Diesel_MQB Motor_Hybrid_MQB Motor_Otto_MQB SAK_MQB Waehlhebel_MQB XXX Parkhilfe_MQB HUD_MQB Kombi_MQB Klima_MQB Standheater_MQB + + +BO_ 290 ACC_06: 8 Front_Radar_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ACC_limitierte_Anfahrdyn : 12|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ACC_zul_Regelabw_unten : 16|6@1+ (0.024,0) [0|1.512] "Unit_MeterPerSeconSquar" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ACC_StartStopp_Info : 22|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ ACC_Sollbeschleunigung_02 : 24|11@1+ (0.005,-7.22) [-7.22|3.005] "Unit_MeterPerSeconSquar" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ACC_zul_Regelabw_oben : 35|5@1+ (0.0625,0) [0|1.9375] "Unit_MeterPerSeconSquar" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ACC_neg_Sollbeschl_Grad_02 : 40|8@1+ (0.05,0) [0|12.75] "Unit_MeterPerCubicSecon" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ACC_pos_Sollbeschl_Grad_02 : 48|8@1+ (0.05,0) [0|12.75] "Unit_MeterPerCubicSecon" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ACC_Anfahren : 56|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ACC_Anhalten : 57|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ACC_Typ : 58|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ACC_Status_ACC : 60|3@1+ (1,0) [0|7] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ACC_Minimale_Bremsung : 63|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + +BO_ 279 ACC_10: 8 Front_Radar_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Airbag_MQB + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Airbag_MQB + SG_ AWV1_Anf_Prefill : 16|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ ANB_CM_Info : 17|1@1+ (1,0) [0|1] "" XXX + SG_ AWV2_Freigabe : 18|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ AWV1_HBA_Param : 19|2@1+ (1,0) [0|3] "" XXX + SG_ AWV2_Ruckprofil : 21|3@1+ (1,0) [0|7] "" XXX + SG_ AWV2_Priowarnung : 24|1@1+ (1,0) [0|1] "" XXX + SG_ ANB_CM_Anforderung : 25|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ ANB_Info_Teilbremsung : 26|1@1+ (1,0) [0|1] "" XXX + SG_ ANB_Notfallblinken : 27|1@1+ (1,0) [0|1] "" XXX + SG_ ANB_Teilbremsung_Freigabe : 28|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ ANB_Zielbrems_Teilbrems_Verz_Anf : 29|10@1+ (0.024,-20.016) [-20.016|4.536] "Unit_MeterPerSeconSquar" Airbag_MQB + SG_ ANB_Zielbremsung_Freigabe : 39|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ AWV_Vorstufe : 40|1@1+ (1,0) [0|1] "" XXX + SG_ AWV_Halten : 41|1@1+ (1,0) [0|1] "" XXX BO_ 64 Airbag_01: 8 Airbag_MQB - SG_ Airbag_01_CRC : 0|8@1+ (1,0) [0|255] "" BMS_MQB,Gateway_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ Airbag_01_BZ : 8|4@1+ (1,0) [0|15] "" BMS_MQB,Gateway_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ AB_RGS_Anst : 12|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ AB_Front_Crash : 16|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_Heck_Crash : 17|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_SF_Crash : 18|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_SB_Crash : 19|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_Rollover_Crash : 20|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_Crash_Int : 21|3@1+ (1,0) [0|7] "" BMS_MQB,Gateway_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ AB_Lampe : 24|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_Deaktiviert : 25|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_VB_deaktiviert : 26|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_Systemfehler : 27|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB,LEH_MQB - SG_ AB_Diagnose : 28|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_Stellgliedtest : 29|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ AB_Erh_Auf_VB : 30|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ AB_Gurtwarn_VF : 32|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_Gurtwarn_VB : 33|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_Anzeige_Fussg : 34|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ AB_Texte_AKS : 36|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ AB_PAO_Leuchte_Anf : 38|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_MKB_gueltig : 39|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_MKB_Anforderung : 40|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ AB_Versorgungsspannung : 41|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ Airbag_01_CRC : 0|8@1+ (1,0) [0|255] "" BMS_MQB,Gateway_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ Airbag_01_BZ : 8|4@1+ (1,0) [0|15] "" BMS_MQB,Gateway_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ AB_RGS_Anst : 12|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ AB_Front_Crash : 16|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_Heck_Crash : 17|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_SF_Crash : 18|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_SB_Crash : 19|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_Rollover_Crash : 20|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_Crash_Int : 21|3@1+ (1,0) [0|7] "" BMS_MQB,Gateway_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ AB_Lampe : 24|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_Deaktiviert : 25|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_VB_deaktiviert : 26|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_Systemfehler : 27|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB,LEH_MQB + SG_ AB_Diagnose : 28|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_Stellgliedtest : 29|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ AB_Erh_Auf_VB : 30|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_Gurtwarn_VF : 32|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_Gurtwarn_VB : 33|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_Anzeige_Fussg : 34|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_Texte_AKS : 36|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_PAO_Leuchte_Anf : 38|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_MKB_gueltig : 39|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_MKB_Anforderung : 40|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ AB_Versorgungsspannung : 41|1@1+ (1,0) [0|1] "" Gateway_MQB BO_ 1312 Airbag_02: 8 Airbag_MQB - SG_ AB_Belegung_VB : 26|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ AB_Gurtschloss_FA : 40|2@1+ (1,0) [0|3] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Otto_MQB - SG_ AB_Gurtschloss_BF : 42|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ AB_Gurtschloss_Reihe2_FA : 44|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ AB_Gurtschloss_Reihe2_MI : 46|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ AB_Gurtschloss_Reihe2_BF : 48|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ AB_Gurtschloss_Reihe3_FA : 50|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ AB_Gurtschloss_Reihe3_MI : 52|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ AB_Gurtschloss_Reihe3_BF : 54|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ AB_Sitzpos_Sens_FA : 56|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ AB_Sitzpos_Sens_BF : 58|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_Belegung_VB : 26|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_Gurtschloss_FA : 40|2@1+ (1,0) [0|3] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Otto_MQB + SG_ AB_Gurtschloss_BF : 42|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_Gurtschloss_Reihe2_FA : 44|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_Gurtschloss_Reihe2_MI : 46|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_Gurtschloss_Reihe2_BF : 48|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_Gurtschloss_Reihe3_FA : 50|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_Gurtschloss_Reihe3_MI : 52|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_Gurtschloss_Reihe3_BF : 54|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_Sitzpos_Sens_FA : 56|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ AB_Sitzpos_Sens_BF : 58|2@1+ (1,0) [0|3] "" Gateway_MQB BO_ 65 Airbag_03: 8 Airbag_MQB - SG_ Airbag_03_CRC : 0|8@1+ (1,0) [0|255] "" Gateway_MQB - SG_ Airbag_03_BZ : 8|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ AB_MKB_Safing : 63|1@1+ (1,0) [0|1] "" Gateway_MQB - -BO_ 1633 Anhaenger_01: 8 Gateway_MQB - SG_ AAG_BZ : 0|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ AAG_Bremsl_durch_ECD : 5|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ AAG_Anhaenger_abgesteckt : 6|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ AAG_NSL_aktiv : 7|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ AAG_Anhaenger_erkannt : 8|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ AAG_Blinker_H_aktiv : 9|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ AAG_Blinker_HL_def : 10|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ AAG_Blinker_HR_def : 11|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ AAG_Bremslicht_H_def : 12|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ AAG_Schlusslicht_HL_def : 13|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ AAG_Schlusslicht_HR_def : 14|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ AAG_AVS_Fehler_02 : 18|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ AAG_AVS_Stati : 20|4@1+ (1,0) [0|15] "" Vector__XXX - -BO_ 1626 BCM_01: 8 Gateway_MQB - SG_ BCM_Bremsbelag_Sensor : 12|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM_Bremsfluessigkeit_Sensor : 13|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM1_Licht_Warn : 14|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM_Waschwasser_Sensor : 15|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM_Kuehlmittel_Sensor : 16|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ BCM1_Kl_15_HW_erkannt : 17|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM_Eis_Offroad_Taste : 18|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Otto_MQB - SG_ ZZH_Endlage_oben : 19|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ZZH_Endlage_unten : 20|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ZZH_Endlage_unplausibel : 21|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM2_EZS_gedrueckt : 22|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM2_SST_gedrueckt : 23|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM_Hybrid_StartStopp_Taste : 24|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BCM1_Warnblink_Taster : 25|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM1_Valet_Parking_Taster : 26|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM_Remotestart_Betrieb : 27|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ BCM1_HSK_Taster : 28|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM1_Heckrollo_Taster : 29|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM1_Rueckfahrlicht_Schalter : 30|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BCM1_MH_Schalter : 31|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ BCM1_MH_WIV_Schalter : 32|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BCM_Eco_Charisma_Taste : 33|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ BCM_Thermomanagement : 34|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BCM_Thermomanagement_Fehler : 36|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BCM_Thermomanagement_gueltig : 37|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BCM1_Lichtwarn_Texte : 38|2@1+ (1,0) [0|3] "" Vector__XXX + SG_ Airbag_03_CRC : 0|8@1+ (1,0) [0|255] "" Gateway_MQB + SG_ Airbag_03_BZ : 8|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ AB_MKB_Safing : 63|1@1+ (1,0) [0|1] "" Gateway_MQB + +BO_ 1633 Anhaenger_01: 8 Anhaenger_MQB + SG_ AAG_BZ : 0|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ AAG_Bremsl_durch_ECD : 5|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ AAG_Anhaenger_abgesteckt : 6|1@1+ (1,0) [0|1] "" XXX + SG_ AAG_NSL_aktiv : 7|1@1+ (1,0) [0|1] "" XXX + SG_ AAG_Anhaenger_erkannt : 8|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ AAG_Blinker_H_aktiv : 9|1@1+ (1,0) [0|1] "" XXX + SG_ AAG_Blinker_HL_def : 10|1@1+ (1,0) [0|1] "" XXX + SG_ AAG_Blinker_HR_def : 11|1@1+ (1,0) [0|1] "" XXX + SG_ AAG_Bremslicht_H_def : 12|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ AAG_Schlusslicht_HL_def : 13|1@1+ (1,0) [0|1] "" XXX + SG_ AAG_Schlusslicht_HR_def : 14|1@1+ (1,0) [0|1] "" XXX + SG_ AAG_AVS_Fehler_02 : 18|1@1+ (1,0) [0|1] "" XXX + SG_ AAG_AVS_Stati : 20|4@1+ (1,0) [0|15] "" XXX + +BO_ 1626 BCM_01: 8 BCM_MQB + SG_ BCM_Bremsbelag_Sensor : 12|1@1+ (1,0) [0|1] "" XXX + SG_ BCM_Bremsfluessigkeit_Sensor : 13|1@1+ (1,0) [0|1] "" XXX + SG_ BCM1_Licht_Warn : 14|1@1+ (1,0) [0|1] "" XXX + SG_ BCM_Waschwasser_Sensor : 15|1@1+ (1,0) [0|1] "" XXX + SG_ BCM_Kuehlmittel_Sensor : 16|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ BCM1_Kl_15_HW_erkannt : 17|1@1+ (1,0) [0|1] "" XXX + SG_ BCM_Eis_Offroad_Taste : 18|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Otto_MQB + SG_ ZZH_Endlage_oben : 19|1@1+ (1,0) [0|1] "" XXX + SG_ ZZH_Endlage_unten : 20|1@1+ (1,0) [0|1] "" XXX + SG_ ZZH_Endlage_unplausibel : 21|1@1+ (1,0) [0|1] "" XXX + SG_ BCM2_EZS_gedrueckt : 22|1@1+ (1,0) [0|1] "" XXX + SG_ BCM2_SST_gedrueckt : 23|1@1+ (1,0) [0|1] "" XXX + SG_ BCM_Hybrid_StartStopp_Taste : 24|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BCM1_Warnblink_Taster : 25|1@1+ (1,0) [0|1] "" XXX + SG_ BCM1_Valet_Parking_Taster : 26|1@1+ (1,0) [0|1] "" XXX + SG_ BCM_Remotestart_Betrieb : 27|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ BCM1_HSK_Taster : 28|1@1+ (1,0) [0|1] "" XXX + SG_ BCM1_Heckrollo_Taster : 29|1@1+ (1,0) [0|1] "" XXX + SG_ BCM1_Rueckfahrlicht_Schalter : 30|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BCM1_MH_Schalter : 31|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ BCM1_MH_WIV_Schalter : 32|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BCM_Eco_Charisma_Taste : 33|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ BCM_Thermomanagement : 34|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BCM_Thermomanagement_Fehler : 36|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BCM_Thermomanagement_gueltig : 37|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BCM1_Lichtwarn_Texte : 38|2@1+ (1,0) [0|3] "" XXX BO_ 869 BEM_05: 8 Gateway_MQB - SG_ BEM_P_Generator : 16|8@1+ (50,0) [0|12700] "Unit_Watt" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BEM_n_LLA : 24|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BEM_01_Abschaltstufen : 26|3@1+ (1,0) [0|7] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BEM_Anf_KL : 29|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BEM_StartStopp_Info : 30|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ BEM_DFM : 32|5@1+ (3.225,0.025) [0.025|100] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BEM_EMLIN_ungueltig : 37|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BEM_Batt_Ab : 38|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BEM_Segel_Info : 48|2@1+ (1,0) [0|3] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BEM_HYB_DC_uSollLV : 50|6@1+ (0.1,10.6) [10.6|16] "Unit_Volt" LEH_MQB - SG_ BEM_HYB_DC_uMinLV : 56|8@1+ (0.1,0) [0|25.3] "Unit_Volt" LEH_MQB + SG_ BEM_P_Generator : 16|8@1+ (50,0) [0|12700] "Unit_Watt" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BEM_n_LLA : 24|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BEM_01_Abschaltstufen : 26|3@1+ (1,0) [0|7] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BEM_Anf_KL : 29|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BEM_StartStopp_Info : 30|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ BEM_DFM : 32|5@1+ (3.225,0.025) [0.025|100] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BEM_EMLIN_ungueltig : 37|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BEM_Batt_Ab : 38|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BEM_Segel_Info : 48|2@1+ (1,0) [0|3] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BEM_HYB_DC_uSollLV : 50|6@1+ (0.1,10.6) [10.6|16] "Unit_Volt" LEH_MQB + SG_ BEM_HYB_DC_uMinLV : 56|8@1+ (0.1,0) [0|25.3] "Unit_Volt" LEH_MQB BO_ 1628 BMS_Hybrid_01: 8 BMS_MQB - SG_ BMS_HYB_ASV_hinten_Status : 13|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ BMS_HYB_ASV_vorne_Status : 14|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ BMS_HYB_KD_Fehler : 15|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ BMS_HYB_BattFanSpd : 16|4@1+ (10,0) [0|100] "Unit_PerCent" Gateway_MQB - SG_ BMS_HYB_VentilationReq : 20|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ BMS_HYB_Spuelbetrieb_Status : 21|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ BMS_HYB_Kuehlung_Anf : 22|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ BMS_HYB_Temp_vor_Verd : 24|8@1+ (0.5,-40) [-40|86.5] "Unit_DegreCelsi" Gateway_MQB - SG_ BMS_HYB_Temp_nach_Verd : 32|8@1+ (0.5,-40) [-40|86.5] "Unit_DegreCelsi" Gateway_MQB - SG_ BMS_Temperatur : 40|8@1+ (0.5,-40) [-40|86.5] "Unit_DegreCelsi" Gateway_MQB - SG_ BMS_Temperatur_Ansaugluft : 48|8@1+ (0.5,-40) [-40|86.5] "Unit_DegreCelsi" Gateway_MQB - SG_ BMS_IstSpannung_HV : 56|8@1+ (1,100) [100|350] "Unit_Volt" Gateway_MQB + SG_ BMS_HYB_ASV_hinten_Status : 13|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ BMS_HYB_ASV_vorne_Status : 14|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ BMS_HYB_KD_Fehler : 15|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ BMS_HYB_BattFanSpd : 16|4@1+ (10,0) [0|100] "Unit_PerCent" Gateway_MQB + SG_ BMS_HYB_VentilationReq : 20|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ BMS_HYB_Spuelbetrieb_Status : 21|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ BMS_HYB_Kuehlung_Anf : 22|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ BMS_HYB_Temp_vor_Verd : 24|8@1+ (0.5,-40) [-40|86.5] "Unit_DegreCelsi" Gateway_MQB + SG_ BMS_HYB_Temp_nach_Verd : 32|8@1+ (0.5,-40) [-40|86.5] "Unit_DegreCelsi" Gateway_MQB + SG_ BMS_Temperatur : 40|8@1+ (0.5,-40) [-40|86.5] "Unit_DegreCelsi" Gateway_MQB + SG_ BMS_Temperatur_Ansaugluft : 48|8@1+ (0.5,-40) [-40|86.5] "Unit_DegreCelsi" Gateway_MQB + SG_ BMS_IstSpannung_HV : 56|8@1+ (1,100) [100|350] "Unit_Volt" Gateway_MQB BO_ 901 Charisma_01: 8 Gateway_MQB - SG_ CHA_Ziel_FahrPr_ALR : 0|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ CHA_Ziel_FahrPr_ESP : 4|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ CHA_Ziel_FahrPr_FL : 8|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ CHA_Fahrer_Umschaltung : 14|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB - SG_ CHA_Ziel_FahrPr_MO : 16|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ CHA_Ziel_FahrPr_GE : 20|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ CHA_Ziel_FahrPr_ST : 24|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ CHA_Ziel_FahrPr_SCU : 28|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ CHA_Ziel_FahrPr_DR : 32|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ CHA_Ziel_FahrPr_QS : 36|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ CHA_Ziel_FahrPr_AFS : 40|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ CHA_Ziel_FahrPr_RGS : 44|4@1+ (1,0) [0|15] "" Airbag_MQB - SG_ CHA_Ziel_FahrPr_EPS : 48|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ CHA_Ziel_FahrPr_ACC : 52|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ CHA_Ziel_FahrPr_SAK : 56|4@1+ (1,0) [0|15] "" SAK_MQB - SG_ CHA_Ziel_FahrPr_MStSt : 60|4@1+ (1,0) [0|15] "" Vector__XXX + SG_ CHA_Ziel_FahrPr_ALR : 0|4@1+ (1,0) [0|15] "" XXX + SG_ CHA_Ziel_FahrPr_ESP : 4|4@1+ (1,0) [0|15] "" XXX + SG_ CHA_Ziel_FahrPr_FL : 8|4@1+ (1,0) [0|15] "" XXX + SG_ CHA_Fahrer_Umschaltung : 14|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB + SG_ CHA_Ziel_FahrPr_MO : 16|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ CHA_Ziel_FahrPr_GE : 20|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ CHA_Ziel_FahrPr_ST : 24|4@1+ (1,0) [0|15] "" XXX + SG_ CHA_Ziel_FahrPr_SCU : 28|4@1+ (1,0) [0|15] "" XXX + SG_ CHA_Ziel_FahrPr_DR : 32|4@1+ (1,0) [0|15] "" XXX + SG_ CHA_Ziel_FahrPr_QS : 36|4@1+ (1,0) [0|15] "" XXX + SG_ CHA_Ziel_FahrPr_AFS : 40|4@1+ (1,0) [0|15] "" XXX + SG_ CHA_Ziel_FahrPr_RGS : 44|4@1+ (1,0) [0|15] "" Airbag_MQB + SG_ CHA_Ziel_FahrPr_EPS : 48|4@1+ (1,0) [0|15] "" XXX + SG_ CHA_Ziel_FahrPr_ACC : 52|4@1+ (1,0) [0|15] "" XXX + SG_ CHA_Ziel_FahrPr_SAK : 56|4@1+ (1,0) [0|15] "" SAK_MQB + SG_ CHA_Ziel_FahrPr_MStSt : 60|4@1+ (1,0) [0|15] "" XXX BO_ 945 DC_Hybrid_01: 8 LEH_MQB - SG_ DC_HYB_iAktLV : 12|10@1+ (1,-511) [-511|510] "Unit_Amper" Gateway_MQB - SG_ DC_HYB_iAktReserveLV : 22|10@1+ (1,-511) [-511|510] "Unit_Amper" Gateway_MQB - SG_ DC_HYB_uAktLV : 32|8@1+ (0.1,0) [0|25.3] "Unit_Volt" Gateway_MQB - SG_ DC_HYB_LangsRegelung : 40|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ DC_HYB_Abregelung_Temperatur : 41|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ DC_HYB_Fehler_RedLeistung : 42|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ DC_HYB_Fehler_intern : 43|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ DC_HYB_Fehler_Spannung : 44|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ DC_HYB_Auslastungsgrad : 56|8@1+ (0.4,0) [0|100] "Unit_PerCent" Gateway_MQB + SG_ DC_HYB_iAktLV : 12|10@1+ (1,-511) [-511|510] "Unit_Amper" Gateway_MQB + SG_ DC_HYB_iAktReserveLV : 22|10@1+ (1,-511) [-511|510] "Unit_Amper" Gateway_MQB + SG_ DC_HYB_uAktLV : 32|8@1+ (0.1,0) [0|25.3] "Unit_Volt" Gateway_MQB + SG_ DC_HYB_LangsRegelung : 40|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ DC_HYB_Abregelung_Temperatur : 41|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ DC_HYB_Fehler_RedLeistung : 42|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ DC_HYB_Fehler_intern : 43|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ DC_HYB_Fehler_Spannung : 44|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ DC_HYB_Auslastungsgrad : 56|8@1+ (0.4,0) [0|100] "Unit_PerCent" Gateway_MQB BO_ 1714 Diagnose_01: 8 Gateway_MQB - SG_ DGN_Verlernzaehler : 0|8@1+ (1,0) [0|254] "" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,SAK_MQB - SG_ KBI_Kilometerstand : 8|20@1+ (1,0) [0|1048573] "Unit_KiloMeter" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB - SG_ UH_Jahr : 28|7@1+ (1,2000) [2000|2127] "Unit_Year" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB - SG_ UH_Monat : 35|4@1+ (1,0) [1|12] "Unit_Month" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB - SG_ UH_Tag : 39|5@1+ (1,0) [1|31] "Unit_Day" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB - SG_ UH_Stunde : 44|5@1+ (1,0) [0|23] "Unit_Hours" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB - SG_ UH_Minute : 49|6@1+ (1,0) [0|59] "Unit_Minut" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB - SG_ UH_Sekunde : 55|6@1+ (1,0) [0|59] "Unit_Secon" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB - SG_ Kombi_02_alt : 62|1@1+ (1,0) [0|1] "" Airbag_MQB,BMS_MQB,LEH_MQB - SG_ Uhrzeit_01_alt : 63|1@1+ (1,0) [0|1] "" Airbag_MQB,BMS_MQB,LEH_MQB + SG_ DGN_Verlernzaehler : 0|8@1+ (1,0) [0|254] "" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,SAK_MQB + SG_ KBI_Kilometerstand : 8|20@1+ (1,0) [0|1048573] "Unit_KiloMeter" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB + SG_ UH_Jahr : 28|7@1+ (1,2000) [2000|2127] "Unit_Year" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB + SG_ UH_Monat : 35|4@1+ (1,0) [1|12] "Unit_Month" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB + SG_ UH_Tag : 39|5@1+ (1,0) [1|31] "Unit_Day" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB + SG_ UH_Stunde : 44|5@1+ (1,0) [0|23] "Unit_Hours" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB + SG_ UH_Minute : 49|6@1+ (1,0) [0|59] "Unit_Minut" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB + SG_ UH_Sekunde : 55|6@1+ (1,0) [0|59] "Unit_Secon" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB + SG_ Kombi_02_alt : 62|1@1+ (1,0) [0|1] "" Airbag_MQB,BMS_MQB,LEH_MQB + SG_ Uhrzeit_01_alt : 63|1@1+ (1,0) [0|1] "" Airbag_MQB,BMS_MQB,LEH_MQB BO_ 1520 Dimmung_01: 8 Gateway_MQB - SG_ DI_KL_58xd : 0|8@1+ (1,0) [0|253] "" Airbag_MQB - SG_ DI_KL_58xs : 8|7@1+ (1,0) [0|100] "Unit_PerCent" Vector__XXX - SG_ DI_Display_Nachtdesign : 15|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ DI_KL_58xt : 16|7@1+ (1,0) [0|100] "Unit_PerCent" Vector__XXX - SG_ DI_Fotosensor : 24|16@1+ (1,0) [0|65535] "" Vector__XXX + SG_ DI_KL_58xd : 0|8@1+ (1,0) [0|253] "" Airbag_MQB + SG_ DI_KL_58xs : 8|7@1+ (1,0) [0|100] "Unit_PerCent" XXX + SG_ DI_Display_Nachtdesign : 15|1@1+ (1,0) [0|1] "" XXX + SG_ DI_KL_58xt : 16|7@1+ (1,0) [0|100] "Unit_PerCent" XXX + SG_ DI_Fotosensor : 24|16@1+ (1,0) [0|65535] "" XXX BO_ 1603 Einheiten_01: 8 Gateway_MQB - SG_ KBI_Einheit_Datum : 0|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ KBI_Einheit_Druck : 2|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ KBI_Einheit_Streckenanz : 4|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB - SG_ KBI_MFA_v_Einheit_02 : 5|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Einheit_Temp : 6|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Einheit_Uhrzeit : 7|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Einheit_Verbrauch : 8|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ KBI_Einheit_Volumen : 10|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ KBI_Einheit_Sprache : 16|8@1+ (1,0) [0|255] "" Vector__XXX - -BO_ 260 EPB_01: 8 Gateway_MQB - SG_ EPB_01_CRC : 0|8@1+ (1,0) [0|255] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ EPB_01_BZ : 8|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ EPB_QBit_Laengsbeschleunigung : 12|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ EPB_QBit_Pedalweg_Kuppl : 13|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ EPB_BCM2_Motor_Wakeup : 14|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ EPB_Freig_Verzoeg_Anf : 15|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ EPB_Verzoeg_Anf : 16|8@1+ (0.048,-7.968) [-7.968|4.224] "Unit_MeterPerSeconSquar" Vector__XXX - SG_ EPB_Laengsbeschleunigung : 24|8@1+ (1,-128) [-128|126] "Unit_PerCentOfForceOfGravi" Vector__XXX - SG_ EPB_Pedalweg_Kuppl : 32|8@1+ (0.4,0) [8|92] "Unit_PerCent" Vector__XXX - SG_ EPB_Anfahrwunsch_erkannt : 48|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ EPB_DAA_Randbed_erf : 49|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ EPB_Fehlerstatus : 50|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ EPB_Schalterposition : 52|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ EPB_QBit_Schalterpos : 54|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ EPB_Konsistenz_ACC : 55|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ EPB_Spannkraft : 56|5@1+ (1,0) [0|29] "Unit_KiloNewto" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ EPB_Status : 61|2@1+ (1,0) [0|3] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - -BO_ 257 ESP_02: 8 Gateway_MQB - SG_ ESP_02_CRC : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_02_BZ : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_QBit_Gierrate : 12|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ ESP_QBit_Laengsbeschl : 13|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_QBit_Querb : 14|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Stillstandsflag : 15|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_Querbeschleunigung : 16|8@1+ (0.01,-1.27) [-1.27|1.27] "Unit_ForceOfGravi" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Laengsbeschl : 24|10@1+ (0.03125,-16) [-16|15.90625] "Unit_MeterPerSeconSquar" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Verteil_Wankmom : 34|5@1+ (0.1,-1) [-1|1] "" Vector__XXX - SG_ ESP_QBit_Anf_Vert_Wank : 39|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_Gierrate : 40|14@1+ (0.01,0) [0|163.82] "Unit_DegreOfArcPerSecon" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ ESP_VZ_Gierrate : 54|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ ESP_Notbremsanzeige : 55|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ ESP_SpannungsAnf : 56|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_PLA_Abbruch : 57|3@1+ (1,0) [0|7] "" Vector__XXX - SG_ ESP_Status_ESP_PLA : 60|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - -BO_ 262 ESP_05: 8 Gateway_MQB - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_QBit_Bremsdruck : 12|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_QBit_Fahrer_bremst : 13|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Schwelle_Unterdruck : 14|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Bremsdruck : 16|10@1+ (0.3,-30) [-30|276.6] "Unit_Bar" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Fahrer_bremst : 26|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Verz_TSK_aktiv : 27|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Lenkeingriff_ADS : 28|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Konsistenz_TSK : 29|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Bremsruck_AWV2 : 30|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Konsistenz_AWV2 : 31|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ECD_Fehler : 32|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ECD_nicht_verfuegbar : 33|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Status_Bremsentemp : 34|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Autohold_Standby : 35|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_HDC_Standby : 36|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ ESP_HBA_aktiv : 37|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_Prefill_ausgeloest : 38|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Rueckwaertsfahrt_erkannt : 39|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_Status_Anfahrhilfe : 40|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_HDC_aktiv : 41|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ ESP_StartStopp_Info : 42|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ ESP_Eingr_HL : 44|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_Eingr_HR : 45|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_Eingr_VL : 46|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_Eingr_VR : 47|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_BKV_Unterdruck : 48|8@1+ (4,0) [0|1012] "Unit_MilliBar" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Autohold_aktiv : 56|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_FStatus_Anfahrhilfe : 57|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ ESP_Verz_EPB_aktiv : 58|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ECD_Bremslicht : 59|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Verzoeg_EPB_verf : 60|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_Status_Bremsdruck : 61|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Anforderung_EPB : 62|2@1+ (1,0) [0|3] "" Vector__XXX - -BO_ 914 ESP_07: 8 Gateway_MQB - SG_ ESP_07_CRC : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_07_BZ : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_ACC_LDE : 12|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_Quattro_Antrieb : 13|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_Codierung_ADS : 14|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ ESP_RTA_HL : 16|8@1+ (0.048828125,-6.20117) [-6.20117|6.152345625] "Unit_PerCent" Vector__XXX - SG_ ESP_RTA_HR : 24|8@1+ (0.048828125,-6.20117) [-6.20117|6.152345625] "Unit_PerCent" Vector__XXX - SG_ ESP_RTA_VR : 32|8@1+ (0.048828125,-6.20117) [-6.20117|6.152345625] "Unit_PerCent" Vector__XXX - SG_ OBD_Fehler_Radsensor_HL : 40|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ OBD_Fehler_Radsensor_HR : 44|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ OBD_Fehler_Radsensor_VL : 48|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ OBD_Fehler_Radsensor_VR : 52|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Qualifizierung_Antriebsart : 56|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_Offroad_Modus : 57|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_MKB_ausloesbar : 58|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ ESP_MKB_Status : 59|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ ESP_CM_Variante : 60|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ESP_OBD_Status : 61|1@1+ (1,0) [0|1] "" Vector__XXX - -BO_ 278 ESP_10: 8 Gateway_MQB - SG_ ESP_10_CRC : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_10_BZ : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_QBit_Wegimpuls_VL : 12|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_QBit_Wegimpuls_VR : 13|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_QBit_Wegimpuls_HL : 14|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_QBit_Wegimpuls_HR : 15|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Wegimpuls_VL : 16|10@1+ (1,0) [0|1000] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Wegimpuls_VR : 26|10@1+ (1,0) [0|1000] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Wegimpuls_HL : 36|10@1+ (1,0) [0|1000] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Wegimpuls_HR : 46|10@1+ (1,0) [0|1000] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_VL_Fahrtrichtung : 56|2@1+ (1,0) [0|3] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_VR_Fahrtrichtung : 58|2@1+ (1,0) [0|3] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_HL_Fahrtrichtung : 60|2@1+ (1,0) [0|3] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_HR_Fahrtrichtung : 62|2@1+ (1,0) [0|3] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - -BO_ 178 ESP_19: 8 Gateway_MQB - SG_ ESP_HL_Radgeschw_02 : 0|16@1+ (0.0075,0) [0|491.49] "Unit_KiloMeterPerHour" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_HR_Radgeschw_02 : 16|16@1+ (0.0075,0) [0|491.49] "Unit_KiloMeterPerHour" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_VL_Radgeschw_02 : 32|16@1+ (0.0075,0) [0|491.49] "Unit_KiloMeterPerHour" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_VR_Radgeschw_02 : 48|16@1+ (0.0075,0) [0|491.49] "Unit_KiloMeterPerHour" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - -BO_ 1629 ESP_20: 8 Gateway_MQB - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ BR_Systemart : 12|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ ESP_Zaehnezahl : 16|8@1+ (1,0) [0|255] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ ESP_Charisma_FahrPr : 24|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ ESP_Charisma_Status : 28|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ BR_QBit_Reifenumfang : 51|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ BR_Reifenumfang : 52|12@1+ (1,0) [0|4095] "Unit_MilliMeter" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - -BO_ 253 ESP_21: 8 Gateway_MQB - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BR_Eingriffsmoment : 12|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_v_Signal : 32|16@1+ (0.01,0) [0|655.32] "Unit_KiloMeterPerHour" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB - SG_ ASR_Tastung_passiv : 48|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Tastung_passiv : 49|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Systemstatus : 50|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ASR_Schalteingriff : 51|2@1+ (1,0) [0|3] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ ESP_Haltebestaetigung : 53|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_QBit_v_Signal : 55|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ABS_Bremsung : 56|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ASR_Anf : 57|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ MSR_Anf : 58|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ EBV_Eingriff : 59|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ EDS_Eingriff : 60|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Eingriff : 61|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_ASP : 62|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ESP_Anhaltevorgang_ACC_aktiv : 63|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KBI_Einheit_Datum : 0|2@1+ (1,0) [0|3] "" XXX + SG_ KBI_Einheit_Druck : 2|2@1+ (1,0) [0|3] "" XXX + SG_ KBI_Einheit_Streckenanz : 4|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB + SG_ KBI_MFA_v_Einheit_02 : 5|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Einheit_Temp : 6|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Einheit_Uhrzeit : 7|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Einheit_Verbrauch : 8|2@1+ (1,0) [0|3] "" XXX + SG_ KBI_Einheit_Volumen : 10|2@1+ (1,0) [0|3] "" XXX + SG_ KBI_Einheit_Sprache : 16|8@1+ (1,0) [0|255] "" XXX + +BO_ 260 EPB_01: 8 ESP_MQB + SG_ EPB_01_CRC : 0|8@1+ (1,0) [0|255] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ EPB_01_BZ : 8|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ EPB_QBit_Laengsbeschleunigung : 12|1@1+ (1,0) [0|1] "" XXX + SG_ EPB_QBit_Pedalweg_Kuppl : 13|1@1+ (1,0) [0|1] "" XXX + SG_ EPB_BCM2_Motor_Wakeup : 14|1@1+ (1,0) [0|1] "" XXX + SG_ EPB_Freig_Verzoeg_Anf : 15|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ EPB_Verzoeg_Anf : 16|8@1+ (0.048,-7.968) [-7.968|4.224] "Unit_MeterPerSeconSquar" XXX + SG_ EPB_Laengsbeschleunigung : 24|8@1+ (1,-128) [-128|126] "Unit_PerCentOfForceOfGravi" XXX + SG_ EPB_Pedalweg_Kuppl : 32|8@1+ (0.4,0) [8|92] "Unit_PerCent" XXX + SG_ EPB_Anfahrwunsch_erkannt : 48|1@1+ (1,0) [0|1] "" XXX + SG_ EPB_DAA_Randbed_erf : 49|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ EPB_Fehlerstatus : 50|2@1+ (1,0) [0|3] "" XXX + SG_ EPB_Schalterposition : 52|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ EPB_QBit_Schalterpos : 54|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ EPB_Konsistenz_ACC : 55|1@1+ (1,0) [0|1] "" XXX + SG_ EPB_Spannkraft : 56|5@1+ (1,0) [0|29] "Unit_KiloNewto" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ EPB_Status : 61|2@1+ (1,0) [0|3] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + +BO_ 257 ESP_02: 8 ESP_MQB + SG_ ESP_02_CRC : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_02_BZ : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_QBit_Gierrate : 12|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ ESP_QBit_Laengsbeschl : 13|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_QBit_Querb : 14|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Stillstandsflag : 15|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_Querbeschleunigung : 16|8@1+ (0.01,-1.27) [-1.27|1.27] "Unit_ForceOfGravi" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Laengsbeschl : 24|10@1+ (0.03125,-16) [-16|15.90625] "Unit_MeterPerSeconSquar" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Verteil_Wankmom : 34|5@1+ (0.1,-1) [-1|1] "" XXX + SG_ ESP_QBit_Anf_Vert_Wank : 39|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_Gierrate : 40|14@1+ (0.01,0) [0|163.82] "Unit_DegreOfArcPerSecon" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ ESP_VZ_Gierrate : 54|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ ESP_Notbremsanzeige : 55|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ ESP_SpannungsAnf : 56|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_PLA_Abbruch : 57|3@1+ (1,0) [0|7] "" XXX + SG_ ESP_Status_ESP_PLA : 60|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + +BO_ 262 ESP_05: 8 ESP_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_QBit_Bremsdruck : 12|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_QBit_Fahrer_bremst : 13|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Schwelle_Unterdruck : 14|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Bremsdruck : 16|10@1+ (0.3,-30) [-30|276.6] "Unit_Bar" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Fahrer_bremst : 26|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Verz_TSK_aktiv : 27|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Lenkeingriff_ADS : 28|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Konsistenz_TSK : 29|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Bremsruck_AWV2 : 30|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Konsistenz_AWV2 : 31|1@1+ (1,0) [0|1] "" XXX + SG_ ECD_Fehler : 32|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ECD_nicht_verfuegbar : 33|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Status_Bremsentemp : 34|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Autohold_Standby : 35|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_HDC_Standby : 36|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ ESP_HBA_aktiv : 37|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_Prefill_ausgeloest : 38|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Rueckwaertsfahrt_erkannt : 39|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_Status_Anfahrhilfe : 40|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_HDC_aktiv : 41|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ ESP_StartStopp_Info : 42|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ ESP_Eingr_HL : 44|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_Eingr_HR : 45|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_Eingr_VL : 46|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_Eingr_VR : 47|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_BKV_Unterdruck : 48|8@1+ (4,0) [0|1012] "Unit_MilliBar" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Autohold_aktiv : 56|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_FStatus_Anfahrhilfe : 57|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ ESP_Verz_EPB_aktiv : 58|1@1+ (1,0) [0|1] "" XXX + SG_ ECD_Bremslicht : 59|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Verzoeg_EPB_verf : 60|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_Status_Bremsdruck : 61|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Anforderung_EPB : 62|2@1+ (1,0) [0|3] "" XXX + +BO_ 914 ESP_07: 8 ESP_MQB + SG_ ESP_07_CRC : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_07_BZ : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_ACC_LDE : 12|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_Quattro_Antrieb : 13|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_Codierung_ADS : 14|2@1+ (1,0) [0|3] "" XXX + SG_ ESP_RTA_HL : 16|8@1+ (0.048828125,-6.20117) [-6.20117|6.152345625] "Unit_PerCent" XXX + SG_ ESP_RTA_HR : 24|8@1+ (0.048828125,-6.20117) [-6.20117|6.152345625] "Unit_PerCent" XXX + SG_ ESP_RTA_VR : 32|8@1+ (0.048828125,-6.20117) [-6.20117|6.152345625] "Unit_PerCent" XXX + SG_ OBD_Fehler_Radsensor_HL : 40|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ OBD_Fehler_Radsensor_HR : 44|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ OBD_Fehler_Radsensor_VL : 48|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ OBD_Fehler_Radsensor_VR : 52|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Qualifizierung_Antriebsart : 56|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_Offroad_Modus : 57|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_MKB_ausloesbar : 58|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ ESP_MKB_Status : 59|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ ESP_CM_Variante : 60|1@1+ (1,0) [0|1] "" XXX + SG_ ESP_OBD_Status : 61|1@1+ (1,0) [0|1] "" XXX + +BO_ 278 ESP_10: 8 ESP_MQB + SG_ ESP_10_CRC : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_10_BZ : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_QBit_Wegimpuls_VL : 12|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_QBit_Wegimpuls_VR : 13|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_QBit_Wegimpuls_HL : 14|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_QBit_Wegimpuls_HR : 15|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Wegimpuls_VL : 16|10@1+ (1,0) [0|1000] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Wegimpuls_VR : 26|10@1+ (1,0) [0|1000] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Wegimpuls_HL : 36|10@1+ (1,0) [0|1000] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Wegimpuls_HR : 46|10@1+ (1,0) [0|1000] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_VL_Fahrtrichtung : 56|2@1+ (1,0) [0|3] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_VR_Fahrtrichtung : 58|2@1+ (1,0) [0|3] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_HL_Fahrtrichtung : 60|2@1+ (1,0) [0|3] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_HR_Fahrtrichtung : 62|2@1+ (1,0) [0|3] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + +BO_ 178 ESP_19: 8 ESP_MQB + SG_ ESP_HL_Radgeschw_02 : 0|16@1+ (0.0075,0) [0|491.49] "Unit_KiloMeterPerHour" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_HR_Radgeschw_02 : 16|16@1+ (0.0075,0) [0|491.49] "Unit_KiloMeterPerHour" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_VL_Radgeschw_02 : 32|16@1+ (0.0075,0) [0|491.49] "Unit_KiloMeterPerHour" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_VR_Radgeschw_02 : 48|16@1+ (0.0075,0) [0|491.49] "Unit_KiloMeterPerHour" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + +BO_ 1629 ESP_20: 8 ESP_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" XXX + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" XXX + SG_ BR_Systemart : 12|2@1+ (1,0) [0|3] "" XXX + SG_ ESP_Zaehnezahl : 16|8@1+ (1,0) [0|255] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ ESP_Charisma_FahrPr : 24|4@1+ (1,0) [0|15] "" XXX + SG_ ESP_Charisma_Status : 28|2@1+ (1,0) [0|3] "" XXX + SG_ BR_QBit_Reifenumfang : 51|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ BR_Reifenumfang : 52|12@1+ (1,0) [0|4095] "Unit_MilliMeter" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + +BO_ 253 ESP_21: 8 ESP_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BR_Eingriffsmoment : 12|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_v_Signal : 32|16@1+ (0.01,0) [0|655.32] "Unit_KiloMeterPerHour" Airbag_MQB,BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB,SAK_MQB + SG_ ASR_Tastung_passiv : 48|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Tastung_passiv : 49|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Systemstatus : 50|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ASR_Schalteingriff : 51|2@1+ (1,0) [0|3] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ ESP_Haltebestaetigung : 53|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_QBit_v_Signal : 55|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ABS_Bremsung : 56|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ASR_Anf : 57|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ MSR_Anf : 58|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ EBV_Eingriff : 59|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ EDS_Eingriff : 60|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Eingriff : 61|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_ASP : 62|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ESP_Anhaltevorgang_ACC_aktiv : 63|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB BO_ 987 Gateway_72: 8 Gateway_MQB - SG_ BCM_01_alt : 0|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ SMLS_01_alt : 1|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ ZV_02_alt : 2|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ Wischer_01_alt : 3|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ Anhaenger_01_alt : 4|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ Klima_Sensor_02_alt : 5|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ VSG_01_alt : 6|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ Klima_01_alt : 7|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ WFS_01_alt : 8|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ Licht_Anf_01_alt : 9|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ZV_HFS_offen : 20|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ZV_HBFS_offen : 21|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ VS_VD_offen_ver : 22|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ VS_VD_zu_ver : 23|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ZV_BT_offen : 24|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM1_Rueckfahrlicht_Schalter : 25|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ ZV_FT_offen : 26|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ Wischer_vorne_aktiv : 27|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ AAG_Anhaenger_erkannt : 28|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ BCM1_MH_Schalter : 29|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ZV_HD_offen : 30|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ Waschen_vorne_aktiv : 31|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KL_Thermomanagement : 32|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ WFS_Schluessel_Fahrberecht : 34|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ BCM1_RFahrlicht_Fzg_Anf : 38|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BCM1_RFahrlicht_Ahg_Anf : 39|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BH_Fernlicht : 49|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ BH_Blinker_li : 50|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ BH_Blinker_re : 51|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ BCM1_OBD_FStatus_ATemp : 52|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BCM1_Aussen_Temp_ungef : 56|8@1+ (0.5,-50) [-50|76] "Unit_DegreCelsi" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BCM_01_alt : 0|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ SMLS_01_alt : 1|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ ZV_02_alt : 2|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ Wischer_01_alt : 3|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ Anhaenger_01_alt : 4|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ Klima_Sensor_02_alt : 5|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ VSG_01_alt : 6|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ Klima_01_alt : 7|1@1+ (1,0) [0|1] "" XXX + SG_ WFS_01_alt : 8|1@1+ (1,0) [0|1] "" XXX + SG_ Licht_Anf_01_alt : 9|1@1+ (1,0) [0|1] "" XXX + SG_ ZV_HFS_offen : 20|1@1+ (1,0) [0|1] "" XXX + SG_ ZV_HBFS_offen : 21|1@1+ (1,0) [0|1] "" XXX + SG_ VS_VD_offen_ver : 22|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ VS_VD_zu_ver : 23|1@1+ (1,0) [0|1] "" XXX + SG_ ZV_BT_offen : 24|1@1+ (1,0) [0|1] "" XXX + SG_ BCM1_Rueckfahrlicht_Schalter : 25|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ ZV_FT_offen : 26|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ Wischer_vorne_aktiv : 27|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ AAG_Anhaenger_erkannt : 28|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ BCM1_MH_Schalter : 29|1@1+ (1,0) [0|1] "" XXX + SG_ ZV_HD_offen : 30|1@1+ (1,0) [0|1] "" XXX + SG_ Waschen_vorne_aktiv : 31|1@1+ (1,0) [0|1] "" XXX + SG_ KL_Thermomanagement : 32|2@1+ (1,0) [0|3] "" XXX + SG_ WFS_Schluessel_Fahrberecht : 34|4@1+ (1,0) [0|15] "" XXX + SG_ BCM1_RFahrlicht_Fzg_Anf : 38|1@1+ (1,0) [0|1] "" XXX + SG_ BCM1_RFahrlicht_Ahg_Anf : 39|1@1+ (1,0) [0|1] "" XXX + SG_ BH_Fernlicht : 49|1@1+ (1,0) [0|1] "" XXX + SG_ BH_Blinker_li : 50|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ BH_Blinker_re : 51|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ BCM1_OBD_FStatus_ATemp : 52|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BCM1_Aussen_Temp_ungef : 56|8@1+ (0.5,-50) [-50|76] "Unit_DegreCelsi" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB BO_ 989 Gateway_74: 8 Gateway_MQB - SG_ LH_EPS_01_alt : 0|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB - SG_ Kessy_04_alt : 1|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ LIN_2_alt : 2|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MFG_01_alt : 3|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ GW_74_va_14 : 4|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ Klima_02_alt : 5|1@1+ (1,0) [0|1] "" BMS_MQB - SG_ Parkhilfe_01_alt : 6|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ ELV_01_alt : 7|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KY_StartStopp_Info : 16|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ PH_StartStopp_Info : 18|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ EPS_Lenkerposition : 20|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB - SG_ ELV_Anf_Klemme_50 : 22|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ MF_StartStopp_Info : 25|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ KL_Geblaesespannung_Soll : 40|8@1+ (0.05,0.5) [2|13] "Unit_Volt" BMS_MQB - SG_ KL_Umluftklappe_Status : 48|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ MFL_Tip_Down : 56|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MFL_Tip_Up : 57|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ LS_Tiptronic_Fehler : 58|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ LH_EPS_01_alt : 0|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB + SG_ Kessy_04_alt : 1|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ LIN_2_alt : 2|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MFG_01_alt : 3|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ GW_74_va_14 : 4|1@1+ (1,0) [0|1] "" XXX + SG_ Klima_02_alt : 5|1@1+ (1,0) [0|1] "" BMS_MQB + SG_ Parkhilfe_01_alt : 6|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ ELV_01_alt : 7|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KY_StartStopp_Info : 16|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ PH_StartStopp_Info : 18|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ EPS_Lenkerposition : 20|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB + SG_ ELV_Anf_Klemme_50 : 22|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ MF_StartStopp_Info : 25|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ KL_Geblaesespannung_Soll : 40|8@1+ (0.05,0.5) [2|13] "Unit_Volt" BMS_MQB + SG_ KL_Umluftklappe_Status : 48|4@1+ (1,0) [0|15] "" XXX + SG_ MFL_Tip_Down : 56|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MFL_Tip_Up : 57|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ LS_Tiptronic_Fehler : 58|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB BO_ 296 Getriebe_06: 3 Getriebe_DQ_Hybrid_MQB - SG_ GE_WH_Sperre : 0|1@1+ (1,0) [0|1] "" Waehlhebel_MQB - SG_ GE_Ausleuchtungsmode : 1|1@1+ (1,0) [0|1] "" Waehlhebel_MQB - SG_ GE_Test_Freigabe : 2|1@1+ (1,0) [0|1] "" Waehlhebel_MQB - SG_ GE_Ist_Fahrstufe : 4|4@1+ (1,0) [0|15] "" Waehlhebel_MQB - SG_ GE_Testparameter_1 : 8|8@1+ (1,0) [0|255] "" Waehlhebel_MQB - SG_ GE_Testparameter_2 : 16|8@1+ (1,0) [0|255] "" Waehlhebel_MQB + SG_ GE_WH_Sperre : 0|1@1+ (1,0) [0|1] "" Waehlhebel_MQB + SG_ GE_Ausleuchtungsmode : 1|1@1+ (1,0) [0|1] "" Waehlhebel_MQB + SG_ GE_Test_Freigabe : 2|1@1+ (1,0) [0|1] "" Waehlhebel_MQB + SG_ GE_Ist_Fahrstufe : 4|4@1+ (1,0) [0|15] "" Waehlhebel_MQB + SG_ GE_Testparameter_1 : 8|8@1+ (1,0) [0|255] "" Waehlhebel_MQB + SG_ GE_Testparameter_2 : 16|8@1+ (1,0) [0|255] "" Waehlhebel_MQB BO_ 173 Getriebe_11: 8 Getriebe_DQ_Hybrid_MQB - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ COUNTERXX : 8|4@1+ (1,0) [0|15] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_MMom_Soll_02 : 12|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_MMom_Vorhalt_02 : 22|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Uefkt : 32|10@1+ (0.1,0) [0|102.2] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Fahrstufe : 42|5@1+ (1,0) [0|31] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Schaltvorgang : 47|1@1+ (1,0) [0|1] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Status_Kupplung : 54|2@1+ (1,0) [0|3] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_MMom_Status : 56|2@1+ (1,0) [0|3] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Freig_MMom_Vorhalt : 58|1@1+ (1,0) [0|1] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Verbot_Ausblendung : 59|1@1+ (1,0) [0|1] "" Gateway_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Zielgang : 60|4@1+ (1,0) [0|15] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ COUNTERXX : 8|4@1+ (1,0) [0|15] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_MMom_Soll_02 : 12|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_MMom_Vorhalt_02 : 22|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Uefkt : 32|10@1+ (0.1,0) [0|102.2] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Fahrstufe : 42|5@1+ (1,0) [0|31] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Schaltvorgang : 47|1@1+ (1,0) [0|1] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Status_Kupplung : 54|2@1+ (1,0) [0|3] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_MMom_Status : 56|2@1+ (1,0) [0|3] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Freig_MMom_Vorhalt : 58|1@1+ (1,0) [0|1] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Verbot_Ausblendung : 59|1@1+ (1,0) [0|1] "" Gateway_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Zielgang : 60|4@1+ (1,0) [0|15] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB BO_ 174 Getriebe_12: 8 Getriebe_DQ_Hybrid_MQB - SG_ Getriebe_12_CRC : 0|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ Getriebe_12_BZ : 8|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Drehzahlmesser_Daempfung : 12|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Schubabschalt_Unt : 13|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Freigabe_Synchro : 14|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Synchro_Wunschdrehz : 15|9@1+ (25,0) [0|12750] "Unit_MinutInver" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Synchro_Zeit : 24|8@1+ (20,0) [0|5080] "Unit_MilliSecon" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Mom_Begr_Gradient : 32|8@1+ (10,0) [0|2540] "Unit_NewtoMeterPerSecon" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Anheb_Solldrehz_Leerlauf : 40|8@1+ (10,0) [0|2540] "Unit_MinutInver" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Aufnahmemoment : 48|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Anf_Zylabsch : 58|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ GE_HYB_DZ_Eingriff : 62|2@1+ (1,0) [0|3] "" Motor_Hybrid_MQB + SG_ Getriebe_12_CRC : 0|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ Getriebe_12_BZ : 8|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Drehzahlmesser_Daempfung : 12|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Schubabschalt_Unt : 13|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Freigabe_Synchro : 14|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Synchro_Wunschdrehz : 15|9@1+ (25,0) [0|12750] "Unit_MinutInver" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Synchro_Zeit : 24|8@1+ (20,0) [0|5080] "Unit_MilliSecon" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Mom_Begr_Gradient : 32|8@1+ (10,0) [0|2540] "Unit_NewtoMeterPerSecon" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Anheb_Solldrehz_Leerlauf : 40|8@1+ (10,0) [0|2540] "Unit_MinutInver" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Aufnahmemoment : 48|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Anf_Zylabsch : 58|2@1+ (1,0) [0|3] "" XXX + SG_ GE_HYB_DZ_Eingriff : 62|2@1+ (1,0) [0|3] "" Motor_Hybrid_MQB BO_ 301 Getriebe_13: 8 Getriebe_DQ_Hybrid_MQB - SG_ Getriebe_13_CRC : 0|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ Getriebe_13_BZ : 8|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_StartStopp_Info : 12|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ GE_Langfr_Schutzmom_02 : 14|9@1+ (1,0) [0|509] "Unit_NewtoMeter" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Eingangsdrehz : 48|14@1+ (1,0) [0|16381] "Unit_MinutInver" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Notlauf : 62|1@1+ (1,0) [0|1] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Freig_Langfr_Schutzmom : 63|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ Getriebe_13_CRC : 0|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ Getriebe_13_BZ : 8|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_StartStopp_Info : 12|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ GE_Langfr_Schutzmom_02 : 14|9@1+ (1,0) [0|509] "Unit_NewtoMeter" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Eingangsdrehz : 48|14@1+ (1,0) [0|16381] "Unit_MinutInver" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Notlauf : 62|1@1+ (1,0) [0|1] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Freig_Langfr_Schutzmom : 63|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB BO_ 968 Getriebe_14: 8 Getriebe_DQ_Hybrid_MQB - SG_ GE_OBD_AbsperrVent : 12|4@1+ (1,0) [0|15] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_amax_moeglich : 16|9@1+ (0.024,-2.016) [-2.016|10.224] "Unit_MeterPerSeconSquar" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Charisma_FahrPr : 25|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ GE_Charisma_Status : 29|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ GE_Verlustmoment : 32|8@1+ (1,0) [0|254] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Freigabe_Verfallsinfo_WFS : 49|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ GE_Codierung_MSG : 50|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ GE_LaunchControl : 51|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ GE_Heizwunsch : 52|2@1+ (1,0) [0|3] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_OBD_Status : 54|1@1+ (1,0) [0|1] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_LFR_Adaption : 55|1@1+ (1,0) [0|1] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GE_Sumpftemperatur : 56|8@1+ (1,-58) [-58|196] "Unit_DegreCelsi" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_OBD_AbsperrVent : 12|4@1+ (1,0) [0|15] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_amax_moeglich : 16|9@1+ (0.024,-2.016) [-2.016|10.224] "Unit_MeterPerSeconSquar" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Charisma_FahrPr : 25|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ GE_Charisma_Status : 29|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ GE_Verlustmoment : 32|8@1+ (1,0) [0|254] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Freigabe_Verfallsinfo_WFS : 49|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ GE_Codierung_MSG : 50|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ GE_LaunchControl : 51|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ GE_Heizwunsch : 52|2@1+ (1,0) [0|3] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_OBD_Status : 54|1@1+ (1,0) [0|1] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_LFR_Adaption : 55|1@1+ (1,0) [0|1] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GE_Sumpftemperatur : 56|8@1+ (1,-58) [-58|196] "Unit_DegreCelsi" Gateway_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB BO_ 158 Getriebe_Hybrid_01: 8 Getriebe_DQ_Hybrid_MQB - SG_ Getriebe_Hybrid_01_CRC : 0|8@1+ (1,0) [0|255] "" Motor_Hybrid_MQB - SG_ Getriebe_Hybrid_01_BZ : 8|4@1+ (1,0) [0|15] "" Motor_Hybrid_MQB - SG_ GE_HYB_Fehlerstatus : 12|2@1+ (1,0) [0|3] "" Motor_Hybrid_MQB - SG_ GE_HYB_Freigabe_K0 : 16|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB - SG_ GE_HYB_Freigabe_LL_Reg : 17|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB - SG_ GE_HYB_Freig_sSchl_K0 : 18|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB - SG_ GE_HYB_Freig_VM_EM_Stop : 19|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB - SG_ GE_HYB_Wiederstart : 20|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB - SG_ GE_HYB_Filt_MomAufbau : 21|3@1+ (1,0) [0|7] "" Motor_Hybrid_MQB - SG_ GE_HYB_nK0 : 24|8@1+ (25,0) [0|6350] "Unit_MinutInver" Vector__XXX - SG_ GE_HYB_MomEingriff_EM : 32|6@1+ (0.5,0) [0|31.5] "Unit_NewtoMeter" LEH_MQB - SG_ GE_HYB_VZ_MomEingriff_EM : 38|1@1+ (1,0) [0|1] "" LEH_MQB - SG_ GE_HYB_Sportfaktor : 56|4@1+ (1,0) [0|15] "" Motor_Hybrid_MQB - SG_ GE_HYB_VM_akt_halten : 61|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB - SG_ GE_HYB_StartAnf : 62|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB - SG_ GE_HYB_VM_Startkontr : 63|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB + SG_ Getriebe_Hybrid_01_CRC : 0|8@1+ (1,0) [0|255] "" Motor_Hybrid_MQB + SG_ Getriebe_Hybrid_01_BZ : 8|4@1+ (1,0) [0|15] "" Motor_Hybrid_MQB + SG_ GE_HYB_Fehlerstatus : 12|2@1+ (1,0) [0|3] "" Motor_Hybrid_MQB + SG_ GE_HYB_Freigabe_K0 : 16|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB + SG_ GE_HYB_Freigabe_LL_Reg : 17|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB + SG_ GE_HYB_Freig_sSchl_K0 : 18|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB + SG_ GE_HYB_Freig_VM_EM_Stop : 19|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB + SG_ GE_HYB_Wiederstart : 20|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB + SG_ GE_HYB_Filt_MomAufbau : 21|3@1+ (1,0) [0|7] "" Motor_Hybrid_MQB + SG_ GE_HYB_nK0 : 24|8@1+ (25,0) [0|6350] "Unit_MinutInver" XXX + SG_ GE_HYB_MomEingriff_EM : 32|6@1+ (0.5,0) [0|31.5] "Unit_NewtoMeter" LEH_MQB + SG_ GE_HYB_VZ_MomEingriff_EM : 38|1@1+ (1,0) [0|1] "" LEH_MQB + SG_ GE_HYB_Sportfaktor : 56|4@1+ (1,0) [0|15] "" Motor_Hybrid_MQB + SG_ GE_HYB_VM_akt_halten : 61|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB + SG_ GE_HYB_StartAnf : 62|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB + SG_ GE_HYB_VM_Startkontr : 63|1@1+ (1,0) [0|1] "" Motor_Hybrid_MQB BO_ 299 GRA_ACC_01: 8 Gateway_MQB - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Hauptschalter : 12|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Abbrechen : 13|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Typ_Hauptschalter : 14|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Limiter : 15|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Tip_Setzen : 16|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Tip_Hoch : 17|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Tip_Runter : 18|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Tip_Wiederaufnahme : 19|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Verstellung_Zeitluecke : 20|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Codierung : 22|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Fehler : 24|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Typ468 : 25|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_Tip_Stufe_2 : 27|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ GRA_ButtonTypeInfo : 28|2@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Hauptschalter : 12|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Abbrechen : 13|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Typ_Hauptschalter : 14|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Limiter : 15|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Tip_Setzen : 16|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Tip_Hoch : 17|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Tip_Runter : 18|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Tip_Wiederaufnahme : 19|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Verstellung_Zeitluecke : 20|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Codierung : 22|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Fehler : 24|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Typ468 : 25|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_Tip_Stufe_2 : 27|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ GRA_ButtonTypeInfo : 28|2@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB BO_ 960 Klemmen_Status_01: 4 Gateway_MQB - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,BMS_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,BMS_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ZAS_Kl_S : 16|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ZAS_Kl_15 : 17|1@1+ (1,0) [0|1] "" Airbag_MQB,BMS_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ ZAS_Kl_X : 18|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ ZAS_Kl_50 : 19|1@1+ (1,0) [0|1] "" Vector__XXX - -BO_ 949 Klima_11: 8 Gateway_MQB - SG_ KL_Drehz_Anh : 0|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KL_Vorwarn_Komp_ein : 1|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KL_AC_Schalter : 2|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KL_Komp_Moment_alt : 3|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KL_Zonen : 4|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KL_Vorwarn_Zuheizer_ein : 6|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KL_Zustand : 7|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KL_Comp_rev_rq : 8|8@1+ (50,0) [0|8600] "Unit_MinutInver" Vector__XXX - SG_ KL_Charisma_FahrPr : 16|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ KL_Charisma_Status : 20|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ KL_Comp_enable : 23|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KL_Last_Kompr : 24|8@1+ (0.25,0) [0|63.5] "Unit_NewtoMeter" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KL_Spannungs_Anf : 32|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ KL_Thermomanagement : 34|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KL_StartStopp_Info : 36|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ KL_Anf_KL : 40|8@1+ (0.4,0) [0|101.6] "Unit_PerCent" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KL_el_Zuheizer_Stufe : 48|3@1+ (1,0) [0|7] "" Motor_Diesel_MQB - -BO_ 1625 Klimakomp_01: 8 Gateway_MQB - SG_ EKL_KD_Fehler : 15|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ EKL_Comp_SCI_com_stat : 16|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ EKL_Comp_output_stat : 18|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ EKL_Comp_main_stat : 20|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ EKL_Comp_ovld_stat : 21|3@1+ (1,0) [0|7] "" Vector__XXX - SG_ EKL_Comp_Inv_stat : 24|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ EKL_Comp_photo_temp_stat : 30|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ EKL_Comp_photo_temp : 32|8@1+ (1,0) [0|254] "Unit_DegreCelsi" Vector__XXX - SG_ EKL_Comp_current : 40|8@1+ (0.1,0) [0|25.4] "Unit_Amper" Motor_Hybrid_MQB - SG_ EKL_Comp_rev_stat : 48|8@1+ (50,0) [0|8600] "Unit_MinutInver" Vector__XXX + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,BMS_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,BMS_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ZAS_Kl_S : 16|1@1+ (1,0) [0|1] "" XXX + SG_ ZAS_Kl_15 : 17|1@1+ (1,0) [0|1] "" Airbag_MQB,BMS_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ ZAS_Kl_X : 18|1@1+ (1,0) [0|1] "" XXX + SG_ ZAS_Kl_50 : 19|1@1+ (1,0) [0|1] "" XXX + +BO_ 949 Klima_11: 8 Klima_MQB + SG_ KL_Drehz_Anh : 0|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KL_Vorwarn_Komp_ein : 1|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KL_AC_Schalter : 2|1@1+ (1,0) [0|1] "" XXX + SG_ KL_Komp_Moment_alt : 3|1@1+ (1,0) [0|1] "" XXX + SG_ KL_Zonen : 4|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KL_Vorwarn_Zuheizer_ein : 6|1@1+ (1,0) [0|1] "" XXX + SG_ KL_Zustand : 7|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KL_Comp_rev_rq : 8|8@1+ (50,0) [0|8600] "Unit_MinutInver" XXX + SG_ KL_Charisma_FahrPr : 16|4@1+ (1,0) [0|15] "" XXX + SG_ KL_Charisma_Status : 20|2@1+ (1,0) [0|3] "" XXX + SG_ KL_Comp_enable : 23|1@1+ (1,0) [0|1] "" XXX + SG_ KL_Last_Kompr : 24|8@1+ (0.25,0) [0|63.5] "Unit_NewtoMeter" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KL_Spannungs_Anf : 32|2@1+ (1,0) [0|3] "" XXX + SG_ KL_Thermomanagement : 34|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KL_StartStopp_Info : 36|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ KL_Anf_KL : 40|8@1+ (0.4,0) [0|101.6] "Unit_PerCent" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KL_el_Zuheizer_Stufe : 48|3@1+ (1,0) [0|7] "" Motor_Diesel_MQB + +BO_ 1625 Klimakomp_01: 8 Klima_MQB + SG_ EKL_KD_Fehler : 15|1@1+ (1,0) [0|1] "" XXX + SG_ EKL_Comp_SCI_com_stat : 16|2@1+ (1,0) [0|3] "" XXX + SG_ EKL_Comp_output_stat : 18|2@1+ (1,0) [0|3] "" XXX + SG_ EKL_Comp_main_stat : 20|1@1+ (1,0) [0|1] "" XXX + SG_ EKL_Comp_ovld_stat : 21|3@1+ (1,0) [0|7] "" XXX + SG_ EKL_Comp_Inv_stat : 24|2@1+ (1,0) [0|3] "" XXX + SG_ EKL_Comp_photo_temp_stat : 30|2@1+ (1,0) [0|3] "" XXX + SG_ EKL_Comp_photo_temp : 32|8@1+ (1,0) [0|254] "Unit_DegreCelsi" XXX + SG_ EKL_Comp_current : 40|8@1+ (0.1,0) [0|25.4] "Unit_Amper" Motor_Hybrid_MQB + SG_ EKL_Comp_rev_stat : 48|8@1+ (50,0) [0|8600] "Unit_MinutInver" XXX BO_ 2549088277 KN_Airbag_01: 8 Airbag_MQB - SG_ Airbag_01_KompSchutz : 0|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ Airbag_01_Nachlauftyp : 4|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ AB_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ Airbag_01_KompSchutz : 0|1@1+ (1,0) [0|1] "" XXX + SG_ Airbag_01_Nachlauftyp : 4|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ AB_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Gateway_MQB BO_ 2549088380 KN_EMotor_01: 8 LEH_MQB - SG_ EMotor_KompSchutz : 0|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ EMotor_Nachlauftyp : 4|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ EM_HYB_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ EMotor_KompSchutz : 0|1@1+ (1,0) [0|1] "" XXX + SG_ EMotor_Nachlauftyp : 4|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ EM_HYB_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Gateway_MQB BO_ 2549088375 KN_Getriebe_01: 8 Getriebe_DQ_Hybrid_MQB - SG_ Getriebe_KompSchutz : 0|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ Getriebe_Nachlauftyp : 4|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ GE_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ Getriebe_KompSchutz : 0|1@1+ (1,0) [0|1] "" XXX + SG_ Getriebe_Nachlauftyp : 4|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ GE_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Gateway_MQB BO_ 2549088379 KN_Hybrid_01: 8 BMS_MQB - SG_ Hybrid_KompSchutz : 0|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ Hybrid_Nachlauftyp : 4|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ BMS_HYB_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ Hybrid_KompSchutz : 0|1@1+ (1,0) [0|1] "" XXX + SG_ Hybrid_Nachlauftyp : 4|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ BMS_HYB_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Gateway_MQB BO_ 2549088374 KN_MO_01: 8 Motor_Diesel_MQB - SG_ Motor_KompSchutz : 0|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ Motor_Nachlauftyp : 4|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ MO_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ Motor_KompSchutz : 0|1@1+ (1,0) [0|1] "" XXX + SG_ Motor_Nachlauftyp : 4|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ MO_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Gateway_MQB BO_ 2549088284 KN_SAK: 8 SAK_MQB - SG_ SAK_KompSchutz : 0|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SAK_Nachlauftyp : 4|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ SAK_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Gateway_MQB - -BO_ 779 Kombi_01: 8 Gateway_MQB - SG_ KBI_ABS_Lampe : 0|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_ESP_Lampe : 1|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_BKL_Lampe : 2|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Airbag_Lampe : 3|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ KBI_SILA_gueltig : 4|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ KBI_Lenkung_Lampe : 5|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Vorglueh_System_Lampe : 6|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB - SG_ KBI_NV_in_Anzeige : 7|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ Kombi_01_BZ : 8|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KBI_Anzeigestatus_ACC : 12|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Anzeigestatus_GRA : 13|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KBI_Oeldruck_Schalter : 15|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Tankwarnung : 16|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KBI_MFA_v_Einheit_01 : 17|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KBI_im_Stellgliedtest : 18|1@1+ (1,0) [0|1] "" Airbag_MQB - SG_ KBI_Anzeigefehler_LDW : 19|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ KBI_Variante_USA : 21|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Oeldruckwarnung : 22|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Handbremse : 23|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ KBI_V_Digital : 24|9@1+ (1,0) [0|511] "" Vector__XXX - SG_ KBI_PLA_in_Anzeige : 33|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Anzeigefehler_NV : 34|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Anzeigestatus_LIM : 35|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KBI_angez_Geschw : 48|10@1+ (0.32,0) [0|325.12] "Unit_KiloMeterPerHour" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KBI_Einheit_Tacho : 58|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KBI_Konsistenz_ACC : 59|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Fehler_Anzeige_ACC : 60|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ KBI_Anzeigefehler_SWA : 61|2@1+ (1,0) [0|3] "" Vector__XXX - -BO_ 1719 Kombi_02: 8 Gateway_MQB - SG_ KBI_Kilometerstand : 0|20@1+ (1,0) [0|1048573] "Unit_KiloMeter" Vector__XXX - SG_ KBI_Standzeit_02 : 20|17@1+ (1,0) [0|131068] "Unit_Secon" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KBI_Inhalt_Tank : 40|7@1+ (1,0) [0|125] "Unit_Liter" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KBI_FStatus_Tank : 47|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KBI_QBit_Aussen_Temp_gef : 55|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ KBI_Aussen_Temp_gef : 56|8@1+ (0.5,-50) [-50|75] "Unit_DegreCelsi" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - -BO_ 982 Licht_hinten_01: 8 Gateway_MQB - SG_ Licht_hinten_01_BZ : 0|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ BCM2_Bremsl_durch_ECD : 5|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ LH_Aussenlicht_def : 7|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Standlicht_H_aktiv : 8|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Parklicht_HL_aktiv : 9|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Parklicht_HR_aktiv : 10|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Bremslicht_H_aktiv : 11|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Nebelschluss_aktiv : 12|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Rueckfahrlicht_aktiv : 13|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Blinker_HL_akt : 14|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Blinker_HR_akt : 15|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Blinker_li_def : 16|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Bremsl_li_def : 17|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Schlusslicht_li_def : 18|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Rueckf_li_def : 19|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Nebel_li_def : 20|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Schluss_Brems_Nebel_li_def : 21|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Schluss_Brems_Nebel_re_def : 22|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Schluss_Brems_li_def : 24|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Schluss_Nebel_li_def : 25|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_SL_BRL_BLK_li_def : 26|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Brems_Blk_li_def : 27|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Blinker_re_def : 32|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Bremsl_re_def : 33|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Schlusslicht_re_def : 34|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Rueckf_re_def : 35|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Nebel_re_def : 36|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Schluss_Brems_re_def : 40|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Schluss_Nebel_re_def : 41|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_SL_BRL_BLK_re_def : 42|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Brems_Blk_re_def : 43|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Kennzl_def : 48|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_3_Bremsl_def : 49|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ LH_Nebel_mi_def : 50|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Rueckf_mi_def : 51|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LH_Bremsl_li_ges_def : 54|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ LH_Bremsl_re_ges_def : 55|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - -BO_ 134 LWI_01: 8 Gateway_MQB - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ LWI_Sensorstatus : 12|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ LWI_QBit_Sub_Daten : 13|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LWI_QBit_Lenkradwinkel : 15|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ LWI_Lenkradwinkel : 16|13@1+ (0.1,0) [0|800] "Unit_DegreOfArc" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ LWI_VZ_Lenkradwinkel : 29|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ LWI_VZ_Lenkradw_Geschw : 30|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ LWI_Lenkradw_Geschw : 31|9@1+ (5,0) [0|2500] "Unit_DegreOfArcPerSecon" Vector__XXX - SG_ LWI_Sub_Daten : 40|16@1+ (1,0) [0|65535] "" Vector__XXX + SG_ SAK_KompSchutz : 0|1@1+ (1,0) [0|1] "" XXX + SG_ SAK_Nachlauftyp : 4|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ SAK_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Gateway_MQB + +BO_ 779 Kombi_01: 8 Kombi_MQB + SG_ KBI_ABS_Lampe : 0|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_ESP_Lampe : 1|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_BKL_Lampe : 2|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Airbag_Lampe : 3|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ KBI_SILA_gueltig : 4|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ KBI_Lenkung_Lampe : 5|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Vorglueh_System_Lampe : 6|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB + SG_ KBI_NV_in_Anzeige : 7|1@1+ (1,0) [0|1] "" XXX + SG_ Kombi_01_BZ : 8|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KBI_Anzeigestatus_ACC : 12|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Anzeigestatus_GRA : 13|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KBI_Oeldruck_Schalter : 15|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Tankwarnung : 16|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KBI_MFA_v_Einheit_01 : 17|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KBI_im_Stellgliedtest : 18|1@1+ (1,0) [0|1] "" Airbag_MQB + SG_ KBI_Anzeigefehler_LDW : 19|2@1+ (1,0) [0|3] "" XXX + SG_ KBI_Variante_USA : 21|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Oeldruckwarnung : 22|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Handbremse : 23|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ KBI_V_Digital : 24|9@1+ (1,0) [0|511] "" XXX + SG_ KBI_PLA_in_Anzeige : 33|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Anzeigefehler_NV : 34|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Anzeigestatus_LIM : 35|2@1+ (1,0) [0|3] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KBI_angez_Geschw : 48|10@1+ (0.32,0) [0|325.12] "Unit_KiloMeterPerHour" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KBI_Einheit_Tacho : 58|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KBI_Konsistenz_ACC : 59|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Fehler_Anzeige_ACC : 60|1@1+ (1,0) [0|1] "" XXX + SG_ KBI_Anzeigefehler_SWA : 61|2@1+ (1,0) [0|3] "" XXX + +BO_ 1719 Kombi_02: 8 Kombi_MQB + SG_ KBI_Kilometerstand : 0|20@1+ (1,0) [0|1048573] "Unit_KiloMeter" XXX + SG_ KBI_Standzeit_02 : 20|17@1+ (1,0) [0|131068] "Unit_Secon" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KBI_Inhalt_Tank : 40|7@1+ (1,0) [0|125] "Unit_Liter" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KBI_FStatus_Tank : 47|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KBI_QBit_Aussen_Temp_gef : 55|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ KBI_Aussen_Temp_gef : 56|8@1+ (0.5,-50) [-50|75] "Unit_DegreCelsi" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + +BO_ 982 Licht_hinten_01: 8 BCM_MQB + SG_ Licht_hinten_01_BZ : 0|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ BCM2_Bremsl_durch_ECD : 5|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ LH_Aussenlicht_def : 7|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Standlicht_H_aktiv : 8|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Parklicht_HL_aktiv : 9|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Parklicht_HR_aktiv : 10|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Bremslicht_H_aktiv : 11|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Nebelschluss_aktiv : 12|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Rueckfahrlicht_aktiv : 13|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Blinker_HL_akt : 14|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Blinker_HR_akt : 15|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Blinker_li_def : 16|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Bremsl_li_def : 17|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Schlusslicht_li_def : 18|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Rueckf_li_def : 19|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Nebel_li_def : 20|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Schluss_Brems_Nebel_li_def : 21|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Schluss_Brems_Nebel_re_def : 22|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Schluss_Brems_li_def : 24|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Schluss_Nebel_li_def : 25|1@1+ (1,0) [0|1] "" XXX + SG_ LH_SL_BRL_BLK_li_def : 26|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Brems_Blk_li_def : 27|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Blinker_re_def : 32|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Bremsl_re_def : 33|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Schlusslicht_re_def : 34|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Rueckf_re_def : 35|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Nebel_re_def : 36|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Schluss_Brems_re_def : 40|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Schluss_Nebel_re_def : 41|1@1+ (1,0) [0|1] "" XXX + SG_ LH_SL_BRL_BLK_re_def : 42|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Brems_Blk_re_def : 43|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Kennzl_def : 48|1@1+ (1,0) [0|1] "" XXX + SG_ LH_3_Bremsl_def : 49|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ LH_Nebel_mi_def : 50|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Rueckf_mi_def : 51|1@1+ (1,0) [0|1] "" XXX + SG_ LH_Bremsl_li_ges_def : 54|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ LH_Bremsl_re_ges_def : 55|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + +BO_ 134 LWI_01: 8 EPS_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ LWI_Sensorstatus : 12|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ LWI_QBit_Sub_Daten : 13|1@1+ (1,0) [0|1] "" XXX + SG_ LWI_QBit_Lenkradwinkel : 15|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ LWI_Lenkradwinkel : 16|13@1+ (0.1,0) [0|800] "Unit_DegreOfArc" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ LWI_VZ_Lenkradwinkel : 29|1@1+ (1,0) [0|1] "" Airbag_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ LWI_VZ_Lenkradw_Geschw : 30|1@1+ (1,0) [0|1] "" XXX + SG_ LWI_Lenkradw_Geschw : 31|9@1+ (5,0) [0|2500] "Unit_DegreOfArcPerSecon" XXX + SG_ LWI_Sub_Daten : 40|16@1+ (1,0) [0|65535] "" XXX BO_ 263 Motor_04: 8 Motor_Diesel_MQB - SG_ MO_Istgang : 8|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ MO_Sollgang : 12|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ MO_Oeldruck : 16|8@1+ (0.04,0) [0|10] "Unit_Bar" Gateway_MQB - SG_ MO_Anzeigedrehz : 24|12@1+ (3,0) [0|12282] "Unit_MinutInver" Gateway_MQB - SG_ MO_Schaltempf_verfbar : 38|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Ladedruck : 39|9@1+ (0.01,0) [0|5.1] "Unit_Bar" Gateway_MQB - SG_ MO_KVS : 48|15@1+ (1,0) [0|32767] "Unit_MicroLiter" Gateway_MQB - SG_ MO_KVS_Ueberlauf : 63|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Istgang : 8|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ MO_Sollgang : 12|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ MO_Oeldruck : 16|8@1+ (0.04,0) [0|10] "Unit_Bar" Gateway_MQB + SG_ MO_Anzeigedrehz : 24|12@1+ (3,0) [0|12282] "Unit_MinutInver" Gateway_MQB + SG_ MO_Schaltempf_verfbar : 38|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Ladedruck : 39|9@1+ (0.01,0) [0|5.1] "Unit_Bar" Gateway_MQB + SG_ MO_KVS : 48|15@1+ (1,0) [0|32767] "Unit_MicroLiter" Gateway_MQB + SG_ MO_KVS_Ueberlauf : 63|1@1+ (1,0) [0|1] "" Gateway_MQB BO_ 1600 Motor_07: 8 Motor_Diesel_MQB - SG_ MO_QBit_Ansaugluft_Temp : 0|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_QBit_Oel_Temp : 1|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_QBit_Kuehlmittel_Temp : 2|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ MO_Stellgliedtest_Soundaktuator : 3|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_HYB_Fehler_HV_Netz : 4|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_aktives_Getriebeheizen : 5|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Absperrventil_oeffnen : 6|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ MO_Ansaugluft_Temp : 8|8@1+ (0.75,-48) [-48|141.75] "Unit_DegreCelsi" Gateway_MQB - SG_ MO_Oel_Temp : 16|8@1+ (1,-60) [-60|192] "Unit_DegreCelsi" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Kuehlmittel_Temp : 24|8@1+ (0.75,-48) [-48|141.75] "Unit_DegreCelsi" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ MO_Hoeheninfo : 32|8@1+ (0.00781,0) [0|1.98374] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Kennfeldk : 40|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Versionsinfo : 41|6@1+ (1,0) [0|63] "" Gateway_MQB - SG_ MO_Getriebe_kuehlen : 47|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Mom_Traegheit_02 : 48|5@1+ (0.01,0) [0|0.31] "Unit_KiloGramMeterSquar" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Heizungspumpenansteuerung : 53|4@1+ (10,0) [0|100] "Unit_PerCent" Gateway_MQB - SG_ MO_SpannungsAnf : 57|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Nachlaufzeit_Heizungspumpe : 58|6@1+ (15,0) [0|945] "Unit_Secon" Gateway_MQB + SG_ MO_QBit_Ansaugluft_Temp : 0|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_QBit_Oel_Temp : 1|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_QBit_Kuehlmittel_Temp : 2|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ MO_Stellgliedtest_Soundaktuator : 3|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_HYB_Fehler_HV_Netz : 4|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_aktives_Getriebeheizen : 5|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Absperrventil_oeffnen : 6|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ MO_Ansaugluft_Temp : 8|8@1+ (0.75,-48) [-48|141.75] "Unit_DegreCelsi" Gateway_MQB + SG_ MO_Oel_Temp : 16|8@1+ (1,-60) [-60|192] "Unit_DegreCelsi" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Kuehlmittel_Temp : 24|8@1+ (0.75,-48) [-48|141.75] "Unit_DegreCelsi" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ MO_Hoeheninfo : 32|8@1+ (0.00781,0) [0|1.98374] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Kennfeldk : 40|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Versionsinfo : 41|6@1+ (1,0) [0|63] "" Gateway_MQB + SG_ MO_Getriebe_kuehlen : 47|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Mom_Traegheit_02 : 48|5@1+ (0.01,0) [0|0.31] "Unit_KiloGramMeterSquar" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Heizungspumpenansteuerung : 53|4@1+ (10,0) [0|100] "Unit_PerCent" Gateway_MQB + SG_ MO_SpannungsAnf : 57|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Nachlaufzeit_Heizungspumpe : 58|6@1+ (15,0) [0|945] "Unit_Secon" Gateway_MQB BO_ 1607 Motor_09: 8 Motor_Diesel_MQB - SG_ MO_ITM_Kuehlmittel_Temp : 0|8@1+ (0.75,-48) [-45.75|143.25] "Unit_DegreCelsi" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_E85_Sensor : 8|4@1+ (10,0) [0|100] "Unit_PerCent" Gateway_MQB - SG_ SCR_Anz_Motorstarts : 12|4@1+ (1,0) [0|8] "" Gateway_MQB - SG_ SCR_Reichweite : 16|15@1+ (1,0) [0|32766] "" Gateway_MQB - SG_ SCR_Warnstufe_1 : 32|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ SCR_Warnstufe_2 : 33|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ SCR_Text : 34|3@1+ (1,0) [0|7] "" Gateway_MQB - SG_ SCR_Akustik : 37|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ MO_Kraftstofffilter_Wasser : 40|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ SCR_Systemfehler : 41|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ SCR_Inducement_Strategie : 42|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ MO_CO2_Faktor : 44|12@1+ (1,0) [1|4094] "Unit_GramPerLiter" Gateway_MQB + SG_ MO_ITM_Kuehlmittel_Temp : 0|8@1+ (0.75,-48) [-45.75|143.25] "Unit_DegreCelsi" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_E85_Sensor : 8|4@1+ (10,0) [0|100] "Unit_PerCent" Gateway_MQB + SG_ SCR_Anz_Motorstarts : 12|4@1+ (1,0) [0|8] "" Gateway_MQB + SG_ SCR_Reichweite : 16|15@1+ (1,0) [0|32766] "" Gateway_MQB + SG_ SCR_Warnstufe_1 : 32|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ SCR_Warnstufe_2 : 33|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ SCR_Text : 34|3@1+ (1,0) [0|7] "" Gateway_MQB + SG_ SCR_Akustik : 37|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ MO_Kraftstofffilter_Wasser : 40|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ SCR_Systemfehler : 41|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ SCR_Inducement_Strategie : 42|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ MO_CO2_Faktor : 44|12@1+ (1,0) [1|4094] "Unit_GramPerLiter" Gateway_MQB BO_ 167 Motor_11: 8 Motor_Diesel_MQB - SG_ Motor_11_CRC : 0|8@1+ (1,0) [0|255] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ Motor_11_BZ : 8|4@1+ (1,0) [0|15] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Mom_Soll_Roh : 12|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Mom_Ist_Summe : 22|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,SAK_MQB - SG_ MO_Mom_Traegheit_Summe : 32|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Mom_Soll_gefiltert : 42|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Mom_Schub : 52|9@1+ (1,-509) [-509|0] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Status_Normalbetrieb_01 : 61|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_erste_Ungenauschwelle : 62|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_QBit_Motormomente : 63|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ Motor_11_CRC : 0|8@1+ (1,0) [0|255] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ Motor_11_BZ : 8|4@1+ (1,0) [0|15] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Mom_Soll_Roh : 12|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Mom_Ist_Summe : 22|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,SAK_MQB + SG_ MO_Mom_Traegheit_Summe : 32|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Mom_Soll_gefiltert : 42|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Mom_Schub : 52|9@1+ (1,-509) [-509|0] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Status_Normalbetrieb_01 : 61|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_erste_Ungenauschwelle : 62|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_QBit_Motormomente : 63|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB BO_ 168 Motor_12: 8 Motor_Diesel_MQB - SG_ Motor_12_CRC : 0|8@1+ (1,0) [0|255] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ Motor_12_BZ : 8|4@1+ (1,0) [0|15] "" BMS_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ MO_Mom_neg_verfuegbar : 12|9@1+ (1,-509) [-509|0] "Unit_NewtoMeter" Gateway_MQB - SG_ MO_Mom_Begr_stat : 21|9@1+ (1,0) [0|509] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Mom_Begr_dyn : 30|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB - SG_ MO_Momentenintegral_02 : 40|7@1+ (1,0) [0|100] "Unit_PerCent" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_QBit_Drehzahl_01 : 47|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ MO_Drehzahl_01 : 48|16@1+ (0.25,0) [0|16383] "Unit_MinutInver" BMS_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,SAK_MQB + SG_ Motor_12_CRC : 0|8@1+ (1,0) [0|255] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ Motor_12_BZ : 8|4@1+ (1,0) [0|15] "" BMS_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ MO_Mom_neg_verfuegbar : 12|9@1+ (1,-509) [-509|0] "Unit_NewtoMeter" Gateway_MQB + SG_ MO_Mom_Begr_stat : 21|9@1+ (1,0) [0|509] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Mom_Begr_dyn : 30|10@1+ (1,-509) [-509|509] "Unit_NewtoMeter" Gateway_MQB + SG_ MO_Momentenintegral_02 : 40|7@1+ (1,0) [0|100] "Unit_PerCent" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_QBit_Drehzahl_01 : 47|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ MO_Drehzahl_01 : 48|16@1+ (0.25,0) [0|16383] "Unit_MinutInver" BMS_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,SAK_MQB BO_ 958 Motor_14: 8 Motor_Diesel_MQB - SG_ MO_StartStopp_Status : 12|2@1+ (1,0) [0|3] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_StartStopp_Wiederstart : 14|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_StartStopp_Motorstopp : 15|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Freig_Reku : 16|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ MO_Kl_75 : 18|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Kl_50 : 19|1@1+ (1,0) [0|1] "" Gateway_MQB,LEH_MQB - SG_ MO_Gangposition : 20|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ MO_StartStopp_Fahrerwunsch : 24|2@1+ (1,0) [0|3] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_HYB_Fahrbereitschaft : 26|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB - SG_ MO_Ext_E_Fahrt_aktiv : 27|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Fahrer_bremst : 28|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_QBit_Fahrer_bremst : 29|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_BLS : 30|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Konsistenz_Bremsped : 31|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Timeout_ESP : 32|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Klima_Eingr : 33|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ MO_Aussp_Anlass : 35|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Freig_Anlass : 36|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Kuppl_schalter : 37|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Interlock : 38|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Motor_laeuft : 39|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Kickdown : 40|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Status_Zylabschalt_01 : 41|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_EKlKomLeiRed : 42|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ MO_Handshake_STH : 44|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_BKV_Unterdruckwarnung : 45|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Freigabe_Segeln : 46|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_PTC_Status : 47|3@1+ (1,0) [0|7] "" Gateway_MQB - SG_ MO_QBit_Gangposition : 50|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Signalquelle_Gangposition : 51|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Remotestart_Betrieb : 52|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_StartStopp_Status : 12|2@1+ (1,0) [0|3] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_StartStopp_Wiederstart : 14|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_StartStopp_Motorstopp : 15|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Freig_Reku : 16|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ MO_Kl_75 : 18|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Kl_50 : 19|1@1+ (1,0) [0|1] "" Gateway_MQB,LEH_MQB + SG_ MO_Gangposition : 20|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ MO_StartStopp_Fahrerwunsch : 24|2@1+ (1,0) [0|3] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_HYB_Fahrbereitschaft : 26|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB + SG_ MO_Ext_E_Fahrt_aktiv : 27|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Fahrer_bremst : 28|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_QBit_Fahrer_bremst : 29|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_BLS : 30|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Konsistenz_Bremsped : 31|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Timeout_ESP : 32|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Klima_Eingr : 33|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ MO_Aussp_Anlass : 35|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Freig_Anlass : 36|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Kuppl_schalter : 37|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Interlock : 38|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Motor_laeuft : 39|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Kickdown : 40|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Status_Zylabschalt_01 : 41|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_EKlKomLeiRed : 42|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ MO_Handshake_STH : 44|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_BKV_Unterdruckwarnung : 45|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Freigabe_Segeln : 46|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_PTC_Status : 47|3@1+ (1,0) [0|7] "" Gateway_MQB + SG_ MO_QBit_Gangposition : 50|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Signalquelle_Gangposition : 51|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Remotestart_Betrieb : 52|1@1+ (1,0) [0|1] "" Gateway_MQB BO_ 1631 Motor_16: 8 Motor_Diesel_MQB - SG_ TSK_QBit_Steigung : 12|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ TSK_QBit_Fahrzeugmasse : 13|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_SpannungsAnf_02 : 14|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ MO_DPF_reg : 16|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Heizstrom_EKAT : 17|7@1+ (1,0) [0|126] "Unit_Amper" Gateway_MQB - SG_ MO_Heizstrom_SCR : 24|6@1+ (1,0) [0|62] "Unit_Amper" Gateway_MQB - SG_ TSK_Fahrzeugmasse_02 : 48|8@1+ (32,0) [0|8128] "Unit_KiloGram" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ TSK_Steigung : 56|8@1+ (0.8,-101.6) [-101.6|101.6] "Unit_PerCent" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ TSK_QBit_Steigung : 12|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ TSK_QBit_Fahrzeugmasse : 13|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_SpannungsAnf_02 : 14|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ MO_DPF_reg : 16|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Heizstrom_EKAT : 17|7@1+ (1,0) [0|126] "Unit_Amper" Gateway_MQB + SG_ MO_Heizstrom_SCR : 24|6@1+ (1,0) [0|62] "Unit_Amper" Gateway_MQB + SG_ TSK_Fahrzeugmasse_02 : 48|8@1+ (32,0) [0|8128] "Unit_KiloGram" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ TSK_Steigung : 56|8@1+ (0.8,-101.6) [-101.6|101.6] "Unit_PerCent" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB BO_ 812 Motor_17: 8 Motor_Diesel_MQB - SG_ MO_Prio_MAX_Wunschdrehzahl : 12|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Prio_MIN_Wunschdrehzahl : 13|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Luftpfad_aktiv : 14|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ MO_v_Begrenz_Aktivierbar : 15|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ MO_Drehzahlbeeinflussung : 16|8@1+ (0.39,0) [0|99.45] "Unit_PerCent" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_MIN_Wunschdrehzahl : 24|8@1+ (25,0) [0|6350] "Unit_MinutInver" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_MAX_Wunschdrehzahl : 32|9@1+ (25,0) [0|12750] "Unit_MinutInver" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Charisma_FahrPr : 41|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ MO_Charisma_Status : 45|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ MO_Prio_MAX_Wunschdrehzahl : 12|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Prio_MIN_Wunschdrehzahl : 13|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Luftpfad_aktiv : 14|1@1+ (1,0) [0|1] "" XXX + SG_ MO_v_Begrenz_Aktivierbar : 15|1@1+ (1,0) [0|1] "" XXX + SG_ MO_Drehzahlbeeinflussung : 16|8@1+ (0.39,0) [0|99.45] "Unit_PerCent" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_MIN_Wunschdrehzahl : 24|8@1+ (25,0) [0|6350] "Unit_MinutInver" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_MAX_Wunschdrehzahl : 32|9@1+ (25,0) [0|12750] "Unit_MinutInver" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Charisma_FahrPr : 41|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ MO_Charisma_Status : 45|2@1+ (1,0) [0|3] "" Gateway_MQB BO_ 1648 Motor_18: 8 Motor_Diesel_MQB - SG_ MO_Hybrid_StartStopp_LED : 43|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ MO_Eis_Offroad_LED : 45|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ MO_Anzahl_Abgesch_Zyl : 47|3@1+ (1,0) [0|7] "" Gateway_MQB - SG_ MO_Zylabsch_Texte : 50|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ MO_E85_BS_Texte : 52|3@1+ (1,0) [0|7] "" Gateway_MQB - SG_ MO_Drehzahl_Warnung : 55|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_obere_Drehzahlgrenze : 56|8@1+ (50,0) [50|12750] "Unit_MinutInver" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Hybrid_StartStopp_LED : 43|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ MO_Eis_Offroad_LED : 45|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ MO_Anzahl_Abgesch_Zyl : 47|3@1+ (1,0) [0|7] "" Gateway_MQB + SG_ MO_Zylabsch_Texte : 50|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ MO_E85_BS_Texte : 52|3@1+ (1,0) [0|7] "" Gateway_MQB + SG_ MO_Drehzahl_Warnung : 55|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_obere_Drehzahlgrenze : 56|8@1+ (50,0) [50|12750] "Unit_MinutInver" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB BO_ 289 Motor_20: 8 Motor_Diesel_MQB - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" XXX - SG_ COUNTER : 8|4@1+ (1,0) [0|255] "" XXX - SG_ MO_Fahrpedalrohwert_01 : 12|8@1+ (0.4,0) [0|101.6] "Unit_PerCent" Airbag_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_QBit_Fahrpedalwerte_01 : 20|1@1+ (1,0) [0|1] "" Airbag_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Fahrpedalgradient : 21|8@1+ (25,0) [0|6350] "Unit_PerCentPerSecon" Airbag_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Sig_Fahrpedalgradient : 29|1@1+ (1,0) [0|1] "" Airbag_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_rel_Saugrohrdruck : 30|6@1+ (18,0) [0|1116] "Unit_MilliBar" Gateway_MQB - SG_ MO_rel_Saugrohrdruck_gem_err : 36|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Moment_im_Leerlauf : 37|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Schubabschaltung : 38|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Solldrehz_Leerlauf : 40|8@1+ (10,0) [0|2540] "Unit_MinutInver" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" XXX + SG_ COUNTER : 8|4@1+ (1,0) [0|255] "" XXX + SG_ MO_Fahrpedalrohwert_01 : 12|8@1+ (0.4,0) [0|101.6] "Unit_PerCent" Airbag_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_QBit_Fahrpedalwerte_01 : 20|1@1+ (1,0) [0|1] "" Airbag_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Fahrpedalgradient : 21|8@1+ (25,0) [0|6350] "Unit_PerCentPerSecon" Airbag_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Sig_Fahrpedalgradient : 29|1@1+ (1,0) [0|1] "" Airbag_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_rel_Saugrohrdruck : 30|6@1+ (18,0) [0|1116] "Unit_MilliBar" Gateway_MQB + SG_ MO_rel_Saugrohrdruck_gem_err : 36|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Moment_im_Leerlauf : 37|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Schubabschaltung : 38|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Solldrehz_Leerlauf : 40|8@1+ (10,0) [0|2540] "Unit_MinutInver" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB BO_ 967 Motor_26: 8 Motor_Diesel_MQB - SG_ MO_HYB_Status_HV_Ladung : 8|3@1+ (1,0) [0|7] "" Gateway_MQB - SG_ WIV_Anzeige_aktiv : 12|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WIV_Oelmin_Warn : 13|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WIV_Sensorfehler : 14|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WIV_Schieflage : 15|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WIV_Oelstand : 16|4@1+ (12.5,0) [0|100] "Unit_PerCent" Gateway_MQB - SG_ MO_Zustand_HWP : 20|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ WIV_Oelsystem_aktiv : 24|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WIV_nicht_betriebswarm : 25|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WIV_Ueberfuell_Warn : 26|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WIV_laufender_Motor : 27|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_HYB_Text_1 : 28|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_HYB_Text_2 : 29|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_HYB_Text_3 : 30|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_HYB_Text_4 : 31|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Text_Motorstart : 32|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ MO_HYB_Text_5 : 36|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_HYB_Text_6 : 37|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_HYB_Text_7 : 38|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Text_Partikelfil_Reg : 41|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WIV_Oelmenge : 43|5@1+ (125,0) [0|3875] "Unit_MilliLiter" Gateway_MQB - SG_ MO_Systemlampe : 48|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_OBD2_Lampe : 49|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Heissleuchte : 50|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Partikel_Lampe : 51|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Winterfahrprog : 52|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ WIV_Oelstand_nicht_vorhanden : 53|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WIV_nachfuellanzeige_ein : 54|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WIV_Ueberfuell_deaktiv : 55|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WIV_Unterfuell_Warn : 56|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Tankdeckel_Lampe : 57|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Text_Tankdeckelwarn : 58|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WIV_Oeldr_Warn_Motor : 60|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_HYB_Status_HV_Ladung : 8|3@1+ (1,0) [0|7] "" Gateway_MQB + SG_ WIV_Anzeige_aktiv : 12|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WIV_Oelmin_Warn : 13|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WIV_Sensorfehler : 14|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WIV_Schieflage : 15|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WIV_Oelstand : 16|4@1+ (12.5,0) [0|100] "Unit_PerCent" Gateway_MQB + SG_ MO_Zustand_HWP : 20|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ WIV_Oelsystem_aktiv : 24|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WIV_nicht_betriebswarm : 25|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WIV_Ueberfuell_Warn : 26|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WIV_laufender_Motor : 27|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_HYB_Text_1 : 28|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_HYB_Text_2 : 29|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_HYB_Text_3 : 30|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_HYB_Text_4 : 31|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Text_Motorstart : 32|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ MO_HYB_Text_5 : 36|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_HYB_Text_6 : 37|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_HYB_Text_7 : 38|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Text_Partikelfil_Reg : 41|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WIV_Oelmenge : 43|5@1+ (125,0) [0|3875] "Unit_MilliLiter" Gateway_MQB + SG_ MO_Systemlampe : 48|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_OBD2_Lampe : 49|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Heissleuchte : 50|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Partikel_Lampe : 51|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Winterfahrprog : 52|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ WIV_Oelstand_nicht_vorhanden : 53|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WIV_nachfuellanzeige_ein : 54|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WIV_Ueberfuell_deaktiv : 55|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WIV_Unterfuell_Warn : 56|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Tankdeckel_Lampe : 57|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Text_Tankdeckelwarn : 58|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WIV_Oeldr_Warn_Motor : 60|1@1+ (1,0) [0|1] "" Gateway_MQB BO_ 1601 Motor_Code_01: 8 Motor_Diesel_MQB - SG_ Motor_Code_01_CRC : 0|8@1+ (1,0) [0|255] "" Gateway_MQB - SG_ Motor_Code_01_BZ : 8|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ MO_Faktor_Momente_02 : 12|2@1+ (1,0) [0|3] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Hybridfahrzeug : 14|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ MO_Code : 16|8@1+ (1,0) [0|255] "" Gateway_MQB,SAK_MQB - SG_ MO_Getriebe_Code : 24|6@1+ (1,0) [0|63] "" Gateway_MQB - SG_ MO_StartStopp_Codiert : 30|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Anzahl_Zyl : 32|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ MO_Kraftstoffart : 36|4@1+ (1,0) [0|15] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Hubraum : 40|7@1+ (0.1,0) [0|12.7] "Unit_Liter" Gateway_MQB - SG_ MO_Ansaugsystem : 47|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ MO_Leistung : 48|9@1+ (1,0) [0|511] "Unit_KiloWatt" Gateway_MQB - SG_ MO_Abgastyp_EOBD : 57|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB,LEH_MQB - SG_ MO_Abgastyp_OBD : 58|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB,LEH_MQB - SG_ MO_DPF_verbaut : 59|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ TSK_Codierung : 60|3@1+ (1,0) [0|7] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ MO_Einspritzart : 63|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ Motor_Code_01_CRC : 0|8@1+ (1,0) [0|255] "" Gateway_MQB + SG_ Motor_Code_01_BZ : 8|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ MO_Faktor_Momente_02 : 12|2@1+ (1,0) [0|3] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Hybridfahrzeug : 14|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ MO_Code : 16|8@1+ (1,0) [0|255] "" Gateway_MQB,SAK_MQB + SG_ MO_Getriebe_Code : 24|6@1+ (1,0) [0|63] "" Gateway_MQB + SG_ MO_StartStopp_Codiert : 30|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Anzahl_Zyl : 32|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ MO_Kraftstoffart : 36|4@1+ (1,0) [0|15] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Hubraum : 40|7@1+ (0.1,0) [0|12.7] "Unit_Liter" Gateway_MQB + SG_ MO_Ansaugsystem : 47|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ MO_Leistung : 48|9@1+ (1,0) [0|511] "Unit_KiloWatt" Gateway_MQB + SG_ MO_Abgastyp_EOBD : 57|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB,LEH_MQB + SG_ MO_Abgastyp_OBD : 58|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB,LEH_MQB + SG_ MO_DPF_verbaut : 59|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ TSK_Codierung : 60|3@1+ (1,0) [0|7] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ MO_Einspritzart : 63|1@1+ (1,0) [0|1] "" Gateway_MQB BO_ 157 Motor_Hybrid_01: 8 Motor_Hybrid_MQB - SG_ Motor_Hybrid_01_CRC : 0|8@1+ (1,0) [0|255] "" Getriebe_DQ_Hybrid_MQB - SG_ Motor_Hybrid_01_BZ : 8|4@1+ (1,0) [0|15] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB - SG_ MO_HYB_IstStatusK0 : 12|2@1+ (1,0) [0|3] "" Getriebe_DQ_Hybrid_MQB - SG_ MO_HYB_max_ind_VM_Mom : 16|10@1+ (1,0) [0|1021] "Unit_NewtoMeter" Getriebe_DQ_Hybrid_MQB - SG_ MO_HYB_Zielzustand : 26|3@1+ (1,0) [0|7] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB - SG_ MO_HYB_Startmodus : 29|3@1+ (1,0) [0|7] "" Vector__XXX - SG_ MO_HYB_Startmodus_PQ3x : 32|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB - SG_ MO_HYB_Stoppmodus : 33|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB - SG_ MO_HYB_VM_Mom_oE : 40|10@1+ (1,-100) [-100|922] "Unit_NewtoMeter" Getriebe_DQ_Hybrid_MQB - SG_ MO_HYB_VM_aktiv : 50|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB - SG_ MO_HYB_Schaltverhinderung : 51|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB + SG_ Motor_Hybrid_01_CRC : 0|8@1+ (1,0) [0|255] "" Getriebe_DQ_Hybrid_MQB + SG_ Motor_Hybrid_01_BZ : 8|4@1+ (1,0) [0|15] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB + SG_ MO_HYB_IstStatusK0 : 12|2@1+ (1,0) [0|3] "" Getriebe_DQ_Hybrid_MQB + SG_ MO_HYB_max_ind_VM_Mom : 16|10@1+ (1,0) [0|1021] "Unit_NewtoMeter" Getriebe_DQ_Hybrid_MQB + SG_ MO_HYB_Zielzustand : 26|3@1+ (1,0) [0|7] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB + SG_ MO_HYB_Startmodus : 29|3@1+ (1,0) [0|7] "" XXX + SG_ MO_HYB_Startmodus_PQ3x : 32|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB + SG_ MO_HYB_Stoppmodus : 33|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB + SG_ MO_HYB_VM_Mom_oE : 40|10@1+ (1,-100) [-100|922] "Unit_NewtoMeter" Getriebe_DQ_Hybrid_MQB + SG_ MO_HYB_VM_aktiv : 50|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB + SG_ MO_HYB_Schaltverhinderung : 51|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB BO_ 811 Motor_Hybrid_02: 8 Motor_Hybrid_MQB - SG_ MO_HYB_E_Faktor : 12|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB - SG_ MO_HYB_Drehzahl_VM : 16|16@1+ (0.25,0) [0|16256] "Unit_MinutInver" Getriebe_DQ_Hybrid_MQB - SG_ MO_HYB_LowSpeedModus : 32|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB + SG_ MO_HYB_E_Faktor : 12|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB + SG_ MO_HYB_Drehzahl_VM : 16|16@1+ (0.25,0) [0|16256] "Unit_MinutInver" Getriebe_DQ_Hybrid_MQB + SG_ MO_HYB_LowSpeedModus : 32|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB BO_ 2600468501 NMH_Airbag_01: 8 Airbag_MQB - SG_ NM_Airbag_01_SNI : 0|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ NM_Airbag_01_NM_State : 16|6@1+ (1,0) [0|63] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ NM_Airbag_01_Car_Wakeup : 22|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ NM_Airbag_01_Wakeup : 24|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ NM_Airbag_01_NM_aktiv_KL15 : 32|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Airbag_01_NM_aktiv_Diagnose : 33|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Airbag_01_NM_aktiv_Tmin : 34|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Airbag_01_UDS_CC : 63|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ NM_Airbag_01_SNI : 0|8@1+ (1,0) [0|255] "" XXX + SG_ NM_Airbag_01_NM_State : 16|6@1+ (1,0) [0|63] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ NM_Airbag_01_Car_Wakeup : 22|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ NM_Airbag_01_Wakeup : 24|8@1+ (1,0) [0|255] "" XXX + SG_ NM_Airbag_01_NM_aktiv_KL15 : 32|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Airbag_01_NM_aktiv_Diagnose : 33|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Airbag_01_NM_aktiv_Tmin : 34|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Airbag_01_UDS_CC : 63|1@1+ (1,0) [0|1] "" XXX BO_ 2600468604 NMH_EMotor_01: 8 LEH_MQB - SG_ NM_EMotor_01_SNI : 0|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ NM_EMotor_01_NM_State : 16|6@1+ (1,0) [0|63] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ NM_EMotor_01_Car_Wakeup : 22|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ NM_EMotor_01_Wakeup : 24|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ NM_EMotor_01_NM_aktiv_KL15 : 32|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_EMotor_01_NM_aktiv_Diagnose : 33|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_EMotor_01_NM_aktiv_Tmin : 34|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_EMotor_01_NL_Daten_EEPROM : 48|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_EMotor_01_UDS_CC : 63|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ NM_EMotor_01_SNI : 0|8@1+ (1,0) [0|255] "" XXX + SG_ NM_EMotor_01_NM_State : 16|6@1+ (1,0) [0|63] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ NM_EMotor_01_Car_Wakeup : 22|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ NM_EMotor_01_Wakeup : 24|8@1+ (1,0) [0|255] "" XXX + SG_ NM_EMotor_01_NM_aktiv_KL15 : 32|1@1+ (1,0) [0|1] "" XXX + SG_ NM_EMotor_01_NM_aktiv_Diagnose : 33|1@1+ (1,0) [0|1] "" XXX + SG_ NM_EMotor_01_NM_aktiv_Tmin : 34|1@1+ (1,0) [0|1] "" XXX + SG_ NM_EMotor_01_NL_Daten_EEPROM : 48|1@1+ (1,0) [0|1] "" XXX + SG_ NM_EMotor_01_UDS_CC : 63|1@1+ (1,0) [0|1] "" XXX BO_ 2600468496 NMH_Gateway: 8 Gateway_MQB - SG_ NM_Gateway_SNI : 0|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ NM_Gateway_NM_State : 16|6@1+ (1,0) [0|63] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ NM_Gateway_Car_Wakeup : 22|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_Wakeup : 24|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ NM_Gateway_NM_aktiv_KL15 : 32|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_NM_aktiv_Diagnose : 33|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_NM_aktiv_Tmin : 34|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_ACAN_Aktivitaet : 35|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_FCAN_Aktivitaet : 36|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_KCAN_Aktivitaet : 37|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_ICAN_Aktivitaet : 38|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_DiagCAN_Aktivitaet : 39|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_ECAN_Aktivitaet : 40|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_Energie_LIN_Aktivi000 : 41|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_Bedien_LIN_Aktivitaet : 42|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_EM_Aktivitaet : 43|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_NL_EM : 48|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_NL_Shutdown : 49|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_NL_Spg_Messung : 50|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_NL_Wakeup_Monitor : 51|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Gateway_UDS_CC : 63|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ NM_Gateway_SNI : 0|8@1+ (1,0) [0|255] "" XXX + SG_ NM_Gateway_NM_State : 16|6@1+ (1,0) [0|63] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ NM_Gateway_Car_Wakeup : 22|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_Wakeup : 24|8@1+ (1,0) [0|255] "" XXX + SG_ NM_Gateway_NM_aktiv_KL15 : 32|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_NM_aktiv_Diagnose : 33|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_NM_aktiv_Tmin : 34|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_ACAN_Aktivitaet : 35|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_FCAN_Aktivitaet : 36|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_KCAN_Aktivitaet : 37|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_ICAN_Aktivitaet : 38|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_DiagCAN_Aktivitaet : 39|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_ECAN_Aktivitaet : 40|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_Energie_LIN_Aktivi000 : 41|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_Bedien_LIN_Aktivitaet : 42|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_EM_Aktivitaet : 43|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_NL_EM : 48|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_NL_Shutdown : 49|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_NL_Spg_Messung : 50|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_NL_Wakeup_Monitor : 51|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Gateway_UDS_CC : 63|1@1+ (1,0) [0|1] "" XXX BO_ 2600468599 NMH_Getriebe_01: 8 Getriebe_DQ_Hybrid_MQB - SG_ NM_Getriebe_01_SNI : 0|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ NM_Getriebe_01_NM_State : 16|6@1+ (1,0) [0|63] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ NM_Getriebe_01_Car_Wakeup : 22|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ NM_Getriebe_01_Wakeup : 24|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ NM_Getriebe_01_NM_aktiv_KL15 : 32|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Getriebe_01_NM_aktiv_Diagnose : 33|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Getriebe_01_NM_aktiv_Tmin : 34|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Getriebe_01_NM_aktiv_v_gr_0 : 35|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Getriebe_01_NM_aktiv_Pos_Erk : 36|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Getriebe_01_NM_aktiv_Umg_Bed : 37|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Getriebe_01_NL_Daten_EEPROM : 48|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Getriebe_01_UDS_CC : 63|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ NM_Getriebe_01_SNI : 0|8@1+ (1,0) [0|255] "" XXX + SG_ NM_Getriebe_01_NM_State : 16|6@1+ (1,0) [0|63] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ NM_Getriebe_01_Car_Wakeup : 22|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ NM_Getriebe_01_Wakeup : 24|8@1+ (1,0) [0|255] "" XXX + SG_ NM_Getriebe_01_NM_aktiv_KL15 : 32|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Getriebe_01_NM_aktiv_Diagnose : 33|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Getriebe_01_NM_aktiv_Tmin : 34|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Getriebe_01_NM_aktiv_v_gr_0 : 35|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Getriebe_01_NM_aktiv_Pos_Erk : 36|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Getriebe_01_NM_aktiv_Umg_Bed : 37|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Getriebe_01_NL_Daten_EEPROM : 48|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Getriebe_01_UDS_CC : 63|1@1+ (1,0) [0|1] "" XXX BO_ 2600468603 NMH_Hybrid_01: 8 BMS_MQB - SG_ NM_Hybrid_01_SNI : 0|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ NM_Hybrid_01_NM_State : 16|6@1+ (1,0) [0|63] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ NM_Hybrid_01_Car_Wakeup : 22|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ NM_Hybrid_01_Wakeup : 24|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ NM_Hybrid_01_NM_aktiv_KL15 : 32|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Hybrid_01_NM_aktiv_Diagnose : 33|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Hybrid_01_NM_aktiv_Tmin : 34|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Hybrid_01_NL_Daten_EEPROM : 48|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Hybrid_01_NL_Luefter : 49|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_Hybrid_01_UDS_CC : 63|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ NM_Hybrid_01_SNI : 0|8@1+ (1,0) [0|255] "" XXX + SG_ NM_Hybrid_01_NM_State : 16|6@1+ (1,0) [0|63] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ NM_Hybrid_01_Car_Wakeup : 22|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ NM_Hybrid_01_Wakeup : 24|8@1+ (1,0) [0|255] "" XXX + SG_ NM_Hybrid_01_NM_aktiv_KL15 : 32|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Hybrid_01_NM_aktiv_Diagnose : 33|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Hybrid_01_NM_aktiv_Tmin : 34|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Hybrid_01_NL_Daten_EEPROM : 48|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Hybrid_01_NL_Luefter : 49|1@1+ (1,0) [0|1] "" XXX + SG_ NM_Hybrid_01_UDS_CC : 63|1@1+ (1,0) [0|1] "" XXX BO_ 2600468598 NMH_MO_01: 8 Motor_Diesel_MQB - SG_ NM_MO_01_SNI : 0|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ NM_MO_01_NM_State : 16|6@1+ (1,0) [0|63] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ NM_MO_01_Car_Wakeup : 22|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ NM_MO_01_Wakeup : 24|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ NM_MO_01_NM_aktiv_KL15 : 32|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_MO_01_NM_aktiv_Diagnose : 33|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_MO_01_NM_aktiv_Tmin : 34|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_MO_01_NM_aktiv_HV_Abschaltung : 35|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_MO_01_NM_aktiv_EKP_Vorlauf : 36|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_MO_01_NM_aktiv_STH_Betrieb : 37|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_MO_01_NL_Kuehlerluefter : 48|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_MO_01_NL_Diagnose : 49|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_MO_01_NL_WFS : 50|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_MO_01_NL_EEPROM : 51|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_MO_01_NL_Sonstige : 52|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ NM_MO_01_UDS_CC : 63|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ NM_MO_01_SNI : 0|8@1+ (1,0) [0|255] "" XXX + SG_ NM_MO_01_NM_State : 16|6@1+ (1,0) [0|63] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB,Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ NM_MO_01_Car_Wakeup : 22|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ NM_MO_01_Wakeup : 24|8@1+ (1,0) [0|255] "" XXX + SG_ NM_MO_01_NM_aktiv_KL15 : 32|1@1+ (1,0) [0|1] "" XXX + SG_ NM_MO_01_NM_aktiv_Diagnose : 33|1@1+ (1,0) [0|1] "" XXX + SG_ NM_MO_01_NM_aktiv_Tmin : 34|1@1+ (1,0) [0|1] "" XXX + SG_ NM_MO_01_NM_aktiv_HV_Abschaltung : 35|1@1+ (1,0) [0|1] "" XXX + SG_ NM_MO_01_NM_aktiv_EKP_Vorlauf : 36|1@1+ (1,0) [0|1] "" XXX + SG_ NM_MO_01_NM_aktiv_STH_Betrieb : 37|1@1+ (1,0) [0|1] "" XXX + SG_ NM_MO_01_NL_Kuehlerluefter : 48|1@1+ (1,0) [0|1] "" XXX + SG_ NM_MO_01_NL_Diagnose : 49|1@1+ (1,0) [0|1] "" XXX + SG_ NM_MO_01_NL_WFS : 50|1@1+ (1,0) [0|1] "" XXX + SG_ NM_MO_01_NL_EEPROM : 51|1@1+ (1,0) [0|1] "" XXX + SG_ NM_MO_01_NL_Sonstige : 52|1@1+ (1,0) [0|1] "" XXX + SG_ NM_MO_01_UDS_CC : 63|1@1+ (1,0) [0|1] "" XXX BO_ 913 OBD_01: 8 Motor_Diesel_MQB - SG_ OBD_Calc_Load_Val : 0|8@1+ (0.39215686275,0) [0|100] "Unit_PerCent" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ OBD_Eng_Cool_Temp : 8|8@1+ (1,-40) [-40|215] "Unit_DegreCelsi" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ OBD_Abs_Throttle_Pos : 16|8@1+ (0.39215686275,0) [0|100] "Unit_PerCent" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ OBD_Abs_Load_Val : 24|16@1+ (0.39215686275,0) [0|25700] "Unit_PerCent" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ OBD_Abs_Pedal_Pos : 40|8@1+ (0.39215686275,0) [0|100] "Unit_PerCent" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ OBD_Kaltstart_Denominator : 59|1@1+ (1,0) [0|1] "" BMS_MQB,LEH_MQB - SG_ OBD_Minimum_Trip : 60|1@1+ (1,0) [0|1] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ OBD_Driving_Cycle : 61|1@1+ (1,0) [0|1] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ OBD_Warm_Up_Cycle : 62|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB - SG_ OBD_Normed_Trip : 63|1@1+ (1,0) [0|1] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ OBD_Calc_Load_Val : 0|8@1+ (0.39215686275,0) [0|100] "Unit_PerCent" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ OBD_Eng_Cool_Temp : 8|8@1+ (1,-40) [-40|215] "Unit_DegreCelsi" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ OBD_Abs_Throttle_Pos : 16|8@1+ (0.39215686275,0) [0|100] "Unit_PerCent" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ OBD_Abs_Load_Val : 24|16@1+ (0.39215686275,0) [0|25700] "Unit_PerCent" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ OBD_Abs_Pedal_Pos : 40|8@1+ (0.39215686275,0) [0|100] "Unit_PerCent" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ OBD_Kaltstart_Denominator : 59|1@1+ (1,0) [0|1] "" BMS_MQB,LEH_MQB + SG_ OBD_Minimum_Trip : 60|1@1+ (1,0) [0|1] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ OBD_Driving_Cycle : 61|1@1+ (1,0) [0|1] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ OBD_Warm_Up_Cycle : 62|1@1+ (1,0) [0|1] "" BMS_MQB,Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB + SG_ OBD_Normed_Trip : 63|1@1+ (1,0) [0|1] "" BMS_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB,LEH_MQB BO_ 1630 OBD_Tankgeber_01: 8 Gateway_MQB - SG_ OBD_TG_F_Status_1 : 0|4@1+ (1,0) [0|15] "" Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ OBD_TG_F_Status_2 : 4|4@1+ (1,0) [0|15] "" Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ OBD_TG_F_Status_3 : 8|4@1+ (1,0) [0|15] "" Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ OBD_TG_F_Status_4 : 12|4@1+ (1,0) [0|15] "" Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ OBD_TG_Sens_Rohwert_1 : 16|12@1+ (0.5,0) [0|2047.5] "Unit_Ohm" Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ OBD_TG_Sens_Rohwert_2 : 28|12@1+ (0.5,0) [0|2047.5] "Unit_Ohm" Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ OBD_TG_Sens_Rohwert_3 : 40|12@1+ (0.5,0) [0|2047.5] "Unit_Ohm" Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ OBD_TG_Sens_Rohwert_4 : 52|12@1+ (0.5,0) [0|2047.5] "Unit_Ohm" Motor_Hybrid_MQB,Motor_Otto_MQB - -BO_ 1437 Remotestart_FFB: 8 Gateway_MQB - SG_ RSF_Tastencode_1 : 0|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ RSF_Tastencode_2 : 8|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Otto_MQB - SG_ RSF_Tastencode_Maske : 16|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ OBD_TG_F_Status_1 : 0|4@1+ (1,0) [0|15] "" Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ OBD_TG_F_Status_2 : 4|4@1+ (1,0) [0|15] "" Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ OBD_TG_F_Status_3 : 8|4@1+ (1,0) [0|15] "" Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ OBD_TG_F_Status_4 : 12|4@1+ (1,0) [0|15] "" Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ OBD_TG_Sens_Rohwert_1 : 16|12@1+ (0.5,0) [0|2047.5] "Unit_Ohm" Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ OBD_TG_Sens_Rohwert_2 : 28|12@1+ (0.5,0) [0|2047.5] "Unit_Ohm" Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ OBD_TG_Sens_Rohwert_3 : 40|12@1+ (0.5,0) [0|2047.5] "Unit_Ohm" Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ OBD_TG_Sens_Rohwert_4 : 52|12@1+ (0.5,0) [0|2047.5] "Unit_Ohm" Motor_Hybrid_MQB,Motor_Otto_MQB + +BO_ 1437 Remotestart_FFB: 8 Kessy_MQB + SG_ RSF_Tastencode_1 : 0|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ RSF_Tastencode_2 : 8|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Otto_MQB + SG_ RSF_Tastencode_Maske : 16|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Otto_MQB BO_ 984 RGS_VL_01: 8 Airbag_MQB - SG_ RGS_VL_Texte : 12|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ RGS_VL_Charisma_FahrPr : 14|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ RGS_VL_Charisma_Status : 18|2@1+ (1,0) [0|3] "" Gateway_MQB - SG_ RGS_VL_aktiv : 21|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ RGS_VL_PC_Aktuator_Sitz : 25|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ RGS_VL_PC_Aktuator_Schiebedach : 26|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ RGS_VL_PC_Aktuator_Fenster : 27|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ RGS_VL_PC_Aktuator_Warnblinken : 28|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ RGS_VL_Precrash_Basis : 32|8@1+ (1,0) [0|255] "" Gateway_MQB - SG_ RGS_VL_Precrash_Front : 40|8@1+ (1,0) [0|255] "" Gateway_MQB - SG_ RGS_VL_Precrash_Rear : 48|8@1+ (1,0) [0|255] "" Gateway_MQB + SG_ RGS_VL_Texte : 12|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ RGS_VL_Charisma_FahrPr : 14|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ RGS_VL_Charisma_Status : 18|2@1+ (1,0) [0|3] "" Gateway_MQB + SG_ RGS_VL_aktiv : 21|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ RGS_VL_PC_Aktuator_Sitz : 25|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ RGS_VL_PC_Aktuator_Schiebedach : 26|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ RGS_VL_PC_Aktuator_Fenster : 27|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ RGS_VL_PC_Aktuator_Warnblinken : 28|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ RGS_VL_Precrash_Basis : 32|8@1+ (1,0) [0|255] "" Gateway_MQB + SG_ RGS_VL_Precrash_Front : 40|8@1+ (1,0) [0|255] "" Gateway_MQB + SG_ RGS_VL_Precrash_Rear : 48|8@1+ (1,0) [0|255] "" Gateway_MQB BO_ 1528 SAK_01: 8 SAK_MQB - SG_ SAK_Charisma_FahrPr : 16|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ SAK_Charisma_Status : 20|2@1+ (1,0) [0|3] "" Gateway_MQB - -BO_ 1313 STH_01: 8 Gateway_MQB - SG_ STH_Funk_ein : 0|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STH_Funk_aus : 1|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STH_Zusatzheizung : 2|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STH_LED : 3|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ STH_Pumpe_ein : 4|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STH_Geblaese : 5|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STH_EKP_Anst : 6|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ STH_Start_folgt : 7|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STH_Ventiloeffnungszeit : 8|6@1+ (1,0) [0|63] "Unit_Minut" Vector__XXX - SG_ STH_Ventil_Status : 14|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STH_Waermeeintrag : 16|6@1+ (1,0) [0|63] "" Vector__XXX - SG_ STH_KVS : 24|13@1+ (1,0) [0|8191] "Unit_MilliLiter" Vector__XXX - SG_ STH_Fehlerstatus : 37|3@1+ (1,0) [0|7] "" Vector__XXX - SG_ STH_Heizleistung : 40|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ STH_Wassertemp : 48|8@1+ (0.75,-40) [-40|142.25] "Unit_DegreCelsi" Vector__XXX - SG_ STH_Motorvorwaermung : 59|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ STH_Servicemode : 60|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STH_war_aktiv : 61|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ STH_KVS_Ueberlauf : 62|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STH_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Vector__XXX - -BO_ 1172 STS_01: 8 Gateway_MQB - SG_ STS_01_CRC : 0|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ STS_01_BZ : 8|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ STS_Car_not_under_theft : 12|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STS_Car_under_theft : 13|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STS_Anlassersperre : 15|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STS_Typencodierung : 16|5@1+ (1,0) [0|31] "" Vector__XXX - SG_ STS_LIN_aktiv : 23|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STS_Standlicht : 24|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STS_Fahrlicht : 25|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STS_Alarm_still : 26|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STS_Texte : 27|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ STS_Laderelais : 38|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STS_Summer : 48|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STS_Alarm_Blinker : 50|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STS_Notstart : 51|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STS_Signalhorn : 55|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ STS_Leerlaufschaltung : 56|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ SAK_Charisma_FahrPr : 16|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ SAK_Charisma_Status : 20|2@1+ (1,0) [0|3] "" Gateway_MQB + +BO_ 1313 STH_01: 8 Standheater_MQB + SG_ STH_Funk_ein : 0|1@1+ (1,0) [0|1] "" XXX + SG_ STH_Funk_aus : 1|1@1+ (1,0) [0|1] "" XXX + SG_ STH_Zusatzheizung : 2|1@1+ (1,0) [0|1] "" XXX + SG_ STH_LED : 3|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ STH_Pumpe_ein : 4|1@1+ (1,0) [0|1] "" XXX + SG_ STH_Geblaese : 5|1@1+ (1,0) [0|1] "" XXX + SG_ STH_EKP_Anst : 6|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ STH_Start_folgt : 7|1@1+ (1,0) [0|1] "" XXX + SG_ STH_Ventiloeffnungszeit : 8|6@1+ (1,0) [0|63] "Unit_Minut" XXX + SG_ STH_Ventil_Status : 14|1@1+ (1,0) [0|1] "" XXX + SG_ STH_Waermeeintrag : 16|6@1+ (1,0) [0|63] "" XXX + SG_ STH_KVS : 24|13@1+ (1,0) [0|8191] "Unit_MilliLiter" XXX + SG_ STH_Fehlerstatus : 37|3@1+ (1,0) [0|7] "" XXX + SG_ STH_Heizleistung : 40|8@1+ (1,0) [0|255] "" XXX + SG_ STH_Wassertemp : 48|8@1+ (0.75,-40) [-40|142.25] "Unit_DegreCelsi" XXX + SG_ STH_Motorvorwaermung : 59|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ STH_Servicemode : 60|1@1+ (1,0) [0|1] "" XXX + SG_ STH_war_aktiv : 61|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ STH_KVS_Ueberlauf : 62|1@1+ (1,0) [0|1] "" XXX + SG_ STH_KD_Fehler : 63|1@1+ (1,0) [0|1] "" XXX + +BO_ 1172 STS_01: 8 Kessy_MQB + SG_ STS_01_CRC : 0|8@1+ (1,0) [0|255] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ STS_01_BZ : 8|4@1+ (1,0) [0|15] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ STS_Car_not_under_theft : 12|1@1+ (1,0) [0|1] "" XXX + SG_ STS_Car_under_theft : 13|1@1+ (1,0) [0|1] "" XXX + SG_ STS_Anlassersperre : 15|1@1+ (1,0) [0|1] "" XXX + SG_ STS_Typencodierung : 16|5@1+ (1,0) [0|31] "" XXX + SG_ STS_LIN_aktiv : 23|1@1+ (1,0) [0|1] "" XXX + SG_ STS_Standlicht : 24|1@1+ (1,0) [0|1] "" XXX + SG_ STS_Fahrlicht : 25|1@1+ (1,0) [0|1] "" XXX + SG_ STS_Alarm_still : 26|1@1+ (1,0) [0|1] "" XXX + SG_ STS_Texte : 27|4@1+ (1,0) [0|15] "" XXX + SG_ STS_Laderelais : 38|1@1+ (1,0) [0|1] "" XXX + SG_ STS_Summer : 48|1@1+ (1,0) [0|1] "" XXX + SG_ STS_Alarm_Blinker : 50|1@1+ (1,0) [0|1] "" XXX + SG_ STS_Notstart : 51|1@1+ (1,0) [0|1] "" XXX + SG_ STS_Signalhorn : 55|1@1+ (1,0) [0|1] "" XXX + SG_ STS_Leerlaufschaltung : 56|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB BO_ 1413 Systeminfo_01: 8 Gateway_MQB - SG_ SI_Sammel_SG_Fehler : 0|6@1+ (1,0) [0|60] "" Vector__XXX - SG_ SI_Rollenmode : 6|2@1+ (1,0) [0|3] "" Vector__XXX - SG_ SI_QRS_Mode : 8|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB - SG_ SI_T_Mode : 9|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_NWDF : 10|1@1+ (1,0) [0|1] "" SAK_MQB - SG_ SI_NWDF_gueltig : 11|1@1+ (1,0) [0|1] "" SAK_MQB - SG_ SI_Sammelfehler : 12|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ GW_KD_Fehler : 13|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_01 : 16|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_02 : 17|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_03 : 18|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_04 : 19|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_05 : 20|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_06 : 21|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_07 : 22|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_08 : 23|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_09 : 24|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_10 : 25|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_11 : 26|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_12 : 27|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_13 : 28|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_14 : 29|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SI_BUS_15 : 30|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ SI_Sammel_SG_Fehler : 0|6@1+ (1,0) [0|60] "" XXX + SG_ SI_Rollenmode : 6|2@1+ (1,0) [0|3] "" XXX + SG_ SI_QRS_Mode : 8|1@1+ (1,0) [0|1] "" Motor_Diesel_MQB,Motor_Hybrid_MQB,Motor_Otto_MQB + SG_ SI_T_Mode : 9|1@1+ (1,0) [0|1] "" XXX + SG_ SI_NWDF : 10|1@1+ (1,0) [0|1] "" SAK_MQB + SG_ SI_NWDF_gueltig : 11|1@1+ (1,0) [0|1] "" SAK_MQB + SG_ SI_Sammelfehler : 12|1@1+ (1,0) [0|1] "" XXX + SG_ GW_KD_Fehler : 13|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_01 : 16|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_02 : 17|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_03 : 18|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_04 : 19|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_05 : 20|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_06 : 21|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_07 : 22|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_08 : 23|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_09 : 24|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_10 : 25|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_11 : 26|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_12 : 27|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_13 : 28|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_14 : 29|1@1+ (1,0) [0|1] "" XXX + SG_ SI_BUS_15 : 30|1@1+ (1,0) [0|1] "" XXX BO_ 288 TSK_06: 8 Motor_Diesel_MQB - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ TSK_Radbremsmom : 12|12@1+ (8,0) [0|32760] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ TSK_Status : 24|3@1+ (1,0) [0|7] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ TSK_v_Begrenzung_aktiv : 27|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ TSK_Standby_Anf_ESP : 28|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ TSK_Freig_Verzoeg_Anf : 30|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ TSK_Limiter_ausgewaehlt : 31|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ TSK_ax_Getriebe_02 : 48|9@1+ (0.024,-2.016) [-2.016|10.224] "Unit_MeterPerSeconSquar" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ TSK_Zwangszusch_ESP : 57|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ TSK_zul_Regelabw : 58|6@1+ (0.024,0) [0|1.512] "Unit_MeterPerSeconSquar" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ TSK_Radbremsmom : 12|12@1+ (8,0) [0|32760] "Unit_NewtoMeter" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ TSK_Status : 24|3@1+ (1,0) [0|7] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ TSK_v_Begrenzung_aktiv : 27|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ TSK_Standby_Anf_ESP : 28|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ TSK_Freig_Verzoeg_Anf : 30|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ TSK_Limiter_ausgewaehlt : 31|1@1+ (1,0) [0|1] "" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ TSK_ax_Getriebe_02 : 48|9@1+ (0.024,-2.016) [-2.016|10.224] "Unit_MeterPerSeconSquar" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ TSK_Zwangszusch_ESP : 57|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ TSK_zul_Regelabw : 58|6@1+ (0.024,0) [0|1.512] "Unit_MeterPerSeconSquar" Gateway_MQB,Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB BO_ 798 TSK_07: 8 Motor_Diesel_MQB - SG_ TSK_07_CRC : 0|8@1+ (1,0) [0|255] "" Gateway_MQB - SG_ TSK_07_BZ : 8|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ TSK_Wunschgeschw : 12|10@1+ (0.32,0) [0|326.72] "Unit_KiloMeterPerHour" Gateway_MQB - SG_ TSK_Texte_Primaeranz : 48|5@1+ (1,0) [0|31] "" Gateway_MQB - SG_ TSK_Limiter_Anzeige : 55|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ TSK_Status_Anzeige : 61|3@1+ (1,0) [0|7] "" Gateway_MQB + SG_ TSK_07_CRC : 0|8@1+ (1,0) [0|255] "" Gateway_MQB + SG_ TSK_07_BZ : 8|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ TSK_Wunschgeschw : 12|10@1+ (0.32,0) [0|326.72] "Unit_KiloMeterPerHour" Gateway_MQB + SG_ TSK_Texte_Primaeranz : 48|5@1+ (1,0) [0|31] "" Gateway_MQB + SG_ TSK_Limiter_Anzeige : 55|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ TSK_Status_Anzeige : 61|3@1+ (1,0) [0|7] "" Gateway_MQB BO_ 1716 VIN_01: 8 Gateway_MQB SG_ VIN_01_MUX M : 0|2@1+ (1,0) [0|3] "" Airbag_MQB - SG_ KS_Geheimnis_1 m0 : 8|8@1+ (1,0) [0|255] "" Vector__XXX + SG_ KS_Geheimnis_1 m0 : 8|8@1+ (1,0) [0|255] "" XXX SG_ VIN_4 m1 : 8|8@1+ (1,0) [0|255] "" Airbag_MQB SG_ VIN_11 m2 : 8|8@1+ (1,0) [0|255] "" Airbag_MQB - SG_ KS_Geheimnis_2 m0 : 16|8@1+ (1,0) [0|255] "" Vector__XXX + SG_ KS_Geheimnis_2 m0 : 16|8@1+ (1,0) [0|255] "" XXX SG_ VIN_5 m1 : 16|8@1+ (1,0) [0|255] "" Airbag_MQB SG_ VIN_12 m2 : 16|8@1+ (1,0) [0|255] "" Airbag_MQB - SG_ KS_Geheimnis_3 m0 : 24|8@1+ (1,0) [0|255] "" Vector__XXX + SG_ KS_Geheimnis_3 m0 : 24|8@1+ (1,0) [0|255] "" XXX SG_ VIN_6 m1 : 24|8@1+ (1,0) [0|255] "" Airbag_MQB SG_ VIN_13 m2 : 24|8@1+ (1,0) [0|255] "" Airbag_MQB - SG_ KS_Geheimnis_4 m0 : 32|8@1+ (1,0) [0|255] "" Vector__XXX + SG_ KS_Geheimnis_4 m0 : 32|8@1+ (1,0) [0|255] "" XXX SG_ VIN_7 m1 : 32|8@1+ (1,0) [0|255] "" Airbag_MQB SG_ VIN_14 m2 : 32|8@1+ (1,0) [0|255] "" Airbag_MQB SG_ VIN_1 m0 : 40|8@1+ (1,0) [0|255] "" Airbag_MQB @@ -1153,212 +1153,362 @@ BO_ 1716 VIN_01: 8 Gateway_MQB SG_ VIN_17 m2 : 56|8@1+ (1,0) [0|255] "" Airbag_MQB BO_ 175 Waehlhebel_03: 4 Waehlhebel_MQB - SG_ WH_Status_Sperre : 0|3@1+ (1,0) [0|7] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ WH_Initialisierung : 3|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ WH_SensorPos_roh : 4|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ WH_03_BZ : 8|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ WH_SensorPos_roh_inv : 12|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ WH_Testergebnis : 16|8@1+ (1,0) [0|255] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ WH_Test_Aktiv : 24|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB - SG_ WH_Status : 25|7@1+ (1,0) [0|127] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ WH_Status_Sperre : 0|3@1+ (1,0) [0|7] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ WH_Initialisierung : 3|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ WH_SensorPos_roh : 4|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ WH_03_BZ : 8|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ WH_SensorPos_roh_inv : 12|4@1+ (1,0) [0|15] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ WH_Testergebnis : 16|8@1+ (1,0) [0|255] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ WH_Test_Aktiv : 24|1@1+ (1,0) [0|1] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB + SG_ WH_Status : 25|7@1+ (1,0) [0|127] "" Getriebe_DQ_Hybrid_MQB,Getriebe_DQ_MQB BO_ 916 WBA_03: 8 Getriebe_DQ_Hybrid_MQB - SG_ WBA_03_CRC : 0|8@1+ (1,0) [0|255] "" Gateway_MQB - SG_ WBA_03_BZ : 8|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ WBA_Fahrstufe_02 : 12|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ WBA_ZielFahrstufe : 16|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ WBA_GE_Warnung_02 : 20|4@1+ (1,0) [0|15] "" Gateway_MQB - SG_ WBA_eing_Gang_02 : 24|4@1+ (1,0) [0|15] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Otto_MQB - SG_ WBA_GE_Texte : 28|3@1+ (1,0) [0|7] "" Gateway_MQB - SG_ WBA_Segeln_aktiv : 31|1@1+ (1,0) [0|1] "" Gateway_MQB - SG_ WBA_Schaltschema : 32|5@1+ (1,0) [0|31] "" Gateway_MQB + SG_ WBA_03_CRC : 0|8@1+ (1,0) [0|255] "" Gateway_MQB + SG_ WBA_03_BZ : 8|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ WBA_Fahrstufe_02 : 12|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ WBA_ZielFahrstufe : 16|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ WBA_GE_Warnung_02 : 20|4@1+ (1,0) [0|15] "" Gateway_MQB + SG_ WBA_eing_Gang_02 : 24|4@1+ (1,0) [0|15] "" Gateway_MQB,Motor_Diesel_MQB,Motor_Otto_MQB + SG_ WBA_GE_Texte : 28|3@1+ (1,0) [0|7] "" Gateway_MQB + SG_ WBA_Segeln_aktiv : 31|1@1+ (1,0) [0|1] "" Gateway_MQB + SG_ WBA_Schaltschema : 32|5@1+ (1,0) [0|31] "" Gateway_MQB BO_ 1602 WIV_01: 8 Motor_Diesel_MQB - SG_ WIV_Verschleissindex : 0|16@1+ (2e-8,0) [0|0.00131068] "" Gateway_MQB - SG_ WIV_Russindex : 16|16@1+ (2e-8,0) [0|0.00131068] "" Gateway_MQB - SG_ WIV_t_min : 32|6@1+ (1,0) [0|63] "Unit_Month" Gateway_MQB - SG_ WIV_t_max : 40|6@1+ (1,0) [0|63] "Unit_Month" Gateway_MQB - SG_ WIV_W_min : 48|7@1+ (1000,0) [0|127000] "Unit_KiloMeter" Gateway_MQB - SG_ WIV_W_max : 56|7@1+ (1000,0) [0|127000] "Unit_KiloMeter" Gateway_MQB - -BO_ 294 HCA_01: 8 XXX - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" XXX - SG_ COUNTER : 8|4@1+ (1,0) [0|255] "" XXX - SG_ SET_ME_0X3 : 12|4@1+ (1,0) [0|15] "" XXX - SG_ Assist_Torque : 16|14@1+ (1,0) [0|300] "Nm" XXX - SG_ Assist_Requested : 30|1@1+ (1,0) [0|1] "" XXX - SG_ Assist_VZ : 31|1@1+ (1,0) [0|1] "" XXX - SG_ HCA_Available : 32|1@1+ (1,0) [0|1] "" XXX - SG_ HCA_Standby : 33|1@1+ (1,0) [0|1] "" XXX - SG_ HCA_Active : 34|1@1+ (1,0) [0|1] "" XXX - SG_ SET_ME_0XFE : 40|8@1+ (1,0) [0|255] "" XXX - SG_ SET_ME_0X07 : 48|8@1+ (1,0) [0|255] "" XXX - -BO_ 159 EPS_01: 8 XXX - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" XXX - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" XXX - SG_ Steering_Wheel_Angle : 16|13@1+ (0.15,0) [0|16383] "Unit_DegreOfArc" XXX - SG_ Steering_Wheel_Angle_VZ : 31|1@1+ (1,0) [0|1] "" XXX - SG_ HCA_Active : 34|1@1+ (1,0) [0|1] "" XXX - SG_ HCA_Standby : 33|1@1+ (1,0) [0|1] "" XXX - SG_ Unknown_Status2 : 63|1@1+ (1,0) [0|1] "" XXX - SG_ HCA_Ready : 32|1@1+ (1,0) [0|3] "" XXX - SG_ Driver_Strain : 40|13@1+ (1,0) [0|255] "Nm" XXX - SG_ Driver_Strain_VZ : 55|1@1+ (1,0) [0|1] "" XXX - SG_ Unknown_Status1 : 62|1@1+ (1,0) [0|1] "" XXX - -BO_ 286 VehicleSpeed: 8 XXX - SG_ VehicleSpeed_CRC : 0|8@1+ (1,0) [0|255] "" XXX - SG_ VehicleSpeed_BZ : 8|4@1+ (1,0) [0|15] "" XXX - SG_ Speed : 52|12@1+ (0.125,0) [0|1] "" XXX - -BO_ 919 LDW_02: 8 XXX - SG_ LDW_DLC : 40|8@1+ (0.01,0) [0|255] "m" XXX - SG_ LDW_TLC : 48|5@1+ (0.05,0) [0|255] "Seconds" XXX - SG_ LDW_Unknown : 14|2@1+ (1,0) [0|3] "" XXX - SG_ Alert_Message : 16|4@1+ (1,0) [0|15] "" XXX - SG_ LDW_Direction : 20|1@1+ (1,0) [0|1] "" XXX - SG_ Right_Lane_Status : 36|2@1+ (1,0) [0|3] "" XXX - SG_ Left_Lane_Status : 38|2@1+ (1,0) [0|3] "" XXX - SG_ Kombi_Lamp_Orange : 61|1@1+ (1,0) [0|1] "" XXX - SG_ Kombi_Lamp_Green : 62|1@1+ (1,0) [0|1] "" XXX - -BO_ 780 ACC_02: 8 XXX - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" XXX - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" XXX - SG_ SetSpeed : 12|10@1+ (0.08865,0) [0|90.68] "Unit_MeterPerSecond" XXX - SG_ Kollision1 : 23|1@1+ (1,0) [0|1] "" XXX - SG_ Abstand : 24|10@1+ (0.1,0) [0|102.3] "m" XXX - SG_ ACC_MinusInv : 36|2@1+ (1,0) [0|3] "" XXX - SG_ ACC_Minus : 38|2@1+ (1,0) [0|3] "" XXX - SG_ Kollision2 : 40|1@1+ (1,0) [0|1] "" XXX - SG_ MotorbitB5_1 : 41|1@1+ (1,0) [0|1] "" XXX - SG_ 1_aktivieren : 42|1@1+ (1,0) [0|1] "" XXX - SG_ Tacho_LED : 43|1@1+ (1,0) [0|1] "" XXX - SG_ Hebelquit : 44|1@1+ (1,0) [0|1] "" XXX - SG_ 1_aktivieren_inv : 45|1@1+ (1,0) [0|1] "" XXX - SG_ Folgefahrt : 46|1@1+ (1,0) [0|1] "" XXX - SG_ MotorbitB5_7 : 47|1@1+ (1,0) [0|1] "" XXX - SG_ SetAbstand : 48|4@1+ (1,0) [0|15] "" XXX - SG_ Hebel : 56|4@1+ (1,0) [0|15] "" XXX - -BO_ 302 ACC_07: 8 XXX - SG_ ACC_07_BZ : 8|4@1+ (1,0) [0|15] "" XXX - SG_ ACC_07_CRC : 0|8@1+ (1,0) [0|255] "" XXX - -BO_ 264 Fahrwerk_01: 8 XXX - SG_ Fahrwerk_01_BZ : 8|4@1+ (1,0) [0|15] "" XXX - SG_ Fahrwerk_01_CRC : 0|8@1+ (1,0) [0|255] "" XXX - -BO_ 695 RCTA_01: 8 XXX - SG_ RCTA_01_BZ : 8|4@1+ (1,0) [0|15] "" XXX - SG_ RCTA_01_CRC : 0|8@1+ (1,0) [0|255] "" XXX - -BO_ 783 SWA_01: 8 Gateway_MQB - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Vector__XXX - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Vector__XXX - SG_ SWA_Anzeigen : 12|4@1+ (1,0) [0|15] "" Kombi_D4 - SG_ SWA_Blindheit_erkannt : 16|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_rel_Nichtverf : 17|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_rel_Fehler : 18|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_Sta_aktiv : 19|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_Sta_passiv : 20|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_Standziele_li : 24|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_Kolonne_li : 25|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_Infostufe_SWA_li : 26|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_Warnung_SWA_li : 27|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_Kolonne_mi : 33|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_Standziele_re : 40|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_Kolonne_re : 41|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_Infostufe_SWA_re : 42|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_Warnung_SWA_re : 43|1@1+ (1,0) [0|1] "" Vector__XXX - SG_ SWA_Gischtzaehler : 48|7@1+ (1,0) [0|100] "Unit_PerCent" Vector__XXX - SG_ SWA_KD_Fehler : 59|1@1+ (1,0) [0|1] "" Vector__XXX - -BO_ 804 ACC_04: 8 XXX - SG_ ACC_04_CRC : 0|8@1+ (1,0) [0|255] "" XXX - SG_ ACC_04_BZ : 8|4@1+ (1,0) [0|15] "" XXX - -BO_ 917 LWR_AFS_01: 8 XXX - -BO_ 991 Gateway_76: 8 XXX + SG_ WIV_Verschleissindex : 0|16@1+ (2E-008,0) [0|0.00131068] "" Gateway_MQB + SG_ WIV_Russindex : 16|16@1+ (2E-008,0) [0|0.00131068] "" Gateway_MQB + SG_ WIV_t_min : 32|6@1+ (1,0) [0|63] "Unit_Month" Gateway_MQB + SG_ WIV_t_max : 40|6@1+ (1,0) [0|63] "Unit_Month" Gateway_MQB + SG_ WIV_W_min : 48|7@1+ (1000,0) [0|127000] "Unit_KiloMeter" Gateway_MQB + SG_ WIV_W_max : 56|7@1+ (1000,0) [0|127000] "Unit_KiloMeter" Gateway_MQB + +BO_ 294 HCA_01: 8 Front_Multifunction_Camera_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" XXX + SG_ COUNTER : 8|4@1+ (1,0) [0|255] "" XXX + SG_ HCA_System_Status : 12|4@1+ (1,0) [0|15] "" XXX + SG_ LM_Offset : 16|14@1+ (1,0) [0|300] "Unit_centiNewtoMeter" XXX + SG_ LM_Offset_Valid : 30|1@1+ (1,0) [0|1] "" XXX + SG_ LM_Offsign : 31|1@1+ (1,0) [0|1] "" XXX + SG_ HCA_Control_Status : 32|3@1+ (1,0) [0|1] "" XXX + +BO_ 159 LH_EPS_03: 8 EPS_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" Parkhilfe_MQB + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" Parkhilfe_MQB + SG_ EPS_DSR_Status : 12|4@1+ (1,0) [0|15] "" XXX + SG_ EPS_Berechneter_LW : 16|12@1+ (0.15,0) [0|613.95] "Unit_DegreOfArc" Parkhilfe_MQB + SG_ EPS_BLW_QBit : 30|1@1+ (1,0) [0|1] "" Parkhilfe_MQB + SG_ EPS_VZ_BLW : 31|1@1+ (1,0) [0|1] "" Parkhilfe_MQB + SG_ EPS_HCA_Status : 32|4@1+ (1,0) [0|15] "" XXX + SG_ EPS_Lenkmoment : 40|10@1+ (0.01,0) [0|8] "Unit_NewtoMeter" Parkhilfe_MQB + SG_ EPS_Lenkmoment_QBit : 54|1@1+ (1,0) [0|1] "" Parkhilfe_MQB + SG_ EPS_VZ_Lenkmoment : 55|1@1+ (1,0) [0|1] "" Parkhilfe_MQB + SG_ EPS_Lenkungstyp : 60|4@1+ (1,0) [0|15] "" Parkhilfe_MQB + +BO_ 286 VehicleSpeed: 8 ESP_MQB + SG_ VehicleSpeed_CRC : 0|8@1+ (1,0) [0|255] "" XXX + SG_ VehicleSpeed_BZ : 8|4@1+ (1,0) [0|15] "" XXX + SG_ Speed : 52|12@1+ (0.125,0) [0|1] "" XXX + +BO_ 919 LDW_02: 8 Front_Multifunction_Camera_MQB + SG_ LDW_Gong : 12|2@1+ (1,0) [0|3] "" Kombi_MQB + SG_ LDW_SW_Warnung_links : 14|1@1+ (1,0) [0|1] "" XXX + SG_ LDW_SW_Warnung_rechts : 15|1@1+ (1,0) [0|1] "" XXX + SG_ LDW_Texte : 16|4@1+ (1,0) [0|15] "" Kombi_MQB + SG_ LDW_Seite_DLCTLC : 20|1@1+ (1,0) [0|1] "" XXX + SG_ LDW_Lernmodus : 21|3@1+ (1,0) [0|7] "" HUD_MQB + SG_ LDW_Anlaufsp_VLR : 24|4@1+ (1,0) [0|15] "" Vector__XXX + SG_ LDW_Vib_Amp_VLR : 28|4@1+ (1,0) [0|15] "" Vector__XXX + SG_ LDW_Anlaufzeit_VLR : 32|4@1+ (1,0) [0|15] "" Vector__XXX + SG_ LDW_SW_Info_rechts : 36|2@1+ (1,0) [0|3] "" XXX + SG_ LDW_SW_Info_links : 38|2@1+ (1,0) [0|3] "" XXX + SG_ LDW_DLC : 40|8@1+ (0.01,-1.25) [-1.25|1.25] "Unit_Meter" XXX + SG_ LDW_TLC : 48|5@1+ (0.1,0) [0|3] "Unit_Secon" XXX + SG_ LDW_Warnung_links : 56|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ LDW_Warnung_rechts : 57|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ LDW_Codierinfo_fuer_VLR : 58|2@1+ (1,0) [0|3] "" Vector__XXX + SG_ LDW_Frontscheibenheizung_aktiv : 60|1@1+ (1,0) [0|1] "" Klima_MQB + SG_ LDW_Status_LED_gelb : 61|1@1+ (1,0) [0|1] "" Parkhilfe_MQB,Kombi_MQB + SG_ LDW_Status_LED_gruen : 62|1@1+ (1,0) [0|1] "" Parkhilfe_MQB,Kombi_MQB + SG_ LDW_KD_Fehler : 63|1@1+ (1,0) [0|1] "" XXX + +BO_ 780 ACC_02: 8 Front_Radar_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" HUD_MQB,Kombi_MQB + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" HUD_MQB,Kombi_MQB + SG_ ACC_Wunschgeschw : 12|10@1+ (0.32,0) [0|326.72] "Unit_KiloMeterPerHour" HUD_MQB,Kombi_MQB + SG_ ACC_Status_Prim_Anz : 22|2@1+ (1,0) [0|3] "" HUD_MQB,Kombi_MQB + SG_ ACC_Abstandsindex : 24|10@1+ (1,0) [1|1021] "" HUD_MQB,Kombi_MQB + SG_ ACC_Akustik : 34|3@1+ (1,0) [0|7] "" Kombi_MQB + SG_ ACC_Gesetzte_Zeitluecke : 37|3@1+ (1,0) [0|7] "" Kombi_MQB + SG_ ACC_Optischer_Fahrerhinweis : 40|1@1+ (1,0) [0|1] "" Kombi_MQB + SG_ ACC_Typ_Tachokranz : 41|1@1+ (1,0) [0|1] "" Kombi_MQB + SG_ ACC_Anzeige_Zeitluecke : 42|1@1+ (1,0) [0|1] "" Kombi_MQB + SG_ ACC_Tachokranz : 43|1@1+ (1,0) [0|1] "" Kombi_MQB + SG_ ACC_Display_Prio : 44|2@1+ (1,0) [0|3] "" XXX + SG_ ACC_Relevantes_Objekt : 46|2@1+ (1,0) [0|3] "" HUD_MQB,Kombi_MQB + SG_ ACC_Texte_Primaeranz : 48|7@1+ (1,0) [0|127] "" HUD_MQB,Kombi_MQB + SG_ ACC_Wunschgeschw_erreicht : 55|1@1+ (1,0) [0|1] "" Kombi_MQB + SG_ ACC_Status_Anzeige : 61|3@1+ (1,0) [0|7] "" Parkhilfe_MQB,Kombi_MQB + +BO_ 302 ACC_07: 8 Front_Radar_MQB + SG_ ACC_07_BZ : 8|4@1+ (1,0) [0|15] "" XXX + SG_ ACC_07_CRC : 0|8@1+ (1,0) [0|255] "" XXX + +BO_ 264 Fahrwerk_01: 8 DCC_MQB + SG_ Fahrwerk_01_BZ : 8|4@1+ (1,0) [0|15] "" XXX + SG_ Fahrwerk_01_CRC : 0|8@1+ (1,0) [0|255] "" XXX + +BO_ 695 RCTA_01: 8 Rear_Radar_MQB + SG_ RCTA_01_BZ : 8|4@1+ (1,0) [0|15] "" XXX + SG_ RCTA_01_CRC : 0|8@1+ (1,0) [0|255] "" XXX + +BO_ 783 SWA_01: 8 Rear_Radar_MQB + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" XXX + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" XXX + SG_ SWA_Anzeigen : 12|4@1+ (1,0) [0|15] "" Kombi_MQB + SG_ SWA_Blindheit_erkannt : 16|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_rel_Nichtverf : 17|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_rel_Fehler : 18|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_Sta_aktiv : 19|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_Sta_passiv : 20|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_Standziele_li : 24|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_Kolonne_li : 25|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_Infostufe_SWA_li : 26|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_Warnung_SWA_li : 27|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_Kolonne_mi : 33|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_Standziele_re : 40|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_Kolonne_re : 41|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_Infostufe_SWA_re : 42|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_Warnung_SWA_re : 43|1@1+ (1,0) [0|1] "" XXX + SG_ SWA_Gischtzaehler : 48|7@1+ (1,0) [0|100] "Unit_PerCent" XXX + SG_ SWA_KD_Fehler : 59|1@1+ (1,0) [0|1] "" XXX + +BO_ 804 ACC_04: 8 Front_Radar_MQB + SG_ ACC_04_CHK : 0|8@1+ (1,0) [0|255] "" HUD_MQB,Kombi_MQB + SG_ ACC_04_BZ : 8|4@1+ (1,0) [0|15] "" HUD_MQB,Kombi_MQB + SG_ ACC_Texte_Zusatzanz : 16|6@1+ (1,0) [0|63] "" Kombi_MQB + SG_ ACC_Status_Zusatzanz : 22|5@1+ (1,0) [0|31] "" HUD_MQB,Kombi_MQB + SG_ ACC_Texte : 27|5@1+ (1,0) [0|31] "" Kombi_MQB + SG_ ACC_Texte_braking_guard : 32|3@1+ (1,0) [0|7] "" HUD_MQB,Kombi_MQB + SG_ ACC_Warnhinweis : 35|1@1+ (1,0) [0|1] "" XXX + SG_ ACC_Geschw_Zielfahrzeug : 40|10@1+ (0.32,0) [0|326.72] "Unit_KiloMeterPerHour" XXX + SG_ ACC_Charisma_FahrPr : 56|3@1+ (1,0) [0|7] "" XXX + SG_ ACC_Charisma_Status : 59|2@1+ (1,0) [0|3] "" XXX + SG_ ACC_Charisma_Umschaltung : 61|2@1+ (1,0) [0|3] "" XXX + +BO_ 917 LWR_AFS_01: 8 LCM_MQB + SG_ AFS_Abbiegelicht_li_Anf : 0|1@1+ (1,0) [0|1] "" XXX + SG_ AFS_Abbiegelicht_re_Anf : 1|1@1+ (1,0) [0|1] "" XXX + SG_ AFS_Abbiegelicht_Dimm_Anf : 2|1@1+ (1,0) [0|1] "" XXX + SG_ AFS_Verfuegbarkeit_GLW : 3|1@1+ (1,0) [0|1] "" XXX + SG_ AFS_Status_adaptive_LV : 4|1@1+ (1,0) [0|1] "" XXX + SG_ AFS_Fernlicht_li_defekt : 5|1@1+ (1,0) [0|1] "" XXX + SG_ AFS_Fernlicht_re_defekt : 6|1@1+ (1,0) [0|1] "" XXX + SG_ AFS_Fernlicht_Status : 7|1@1+ (1,0) [0|1] "" XXX + SG_ LWR_AFS_01_BZ : 8|4@1+ (1,0) [0|15] "" XXX + SG_ AFS_Lampe : 12|1@1+ (1,0) [0|1] "" Kombi_MQB + SG_ LWR_Lampe : 13|1@1+ (1,0) [0|1] "" Kombi_MQB + SG_ AFS_Fehlertext : 14|1@1+ (1,0) [0|1] "" Kombi_MQB + SG_ AFS_LED_Blinkmode : 15|1@1+ (1,0) [0|1] "" XXX + SG_ LWR_Touristenmodus_aktiv : 16|1@1+ (1,0) [0|1] "" Kombi_MQB + SG_ AFS_Charisma_FahrPr : 17|3@1+ (1,0) [0|7] "" XXX + SG_ AFS_Charisma_Status : 20|2@1+ (1,0) [0|3] "" XXX + SG_ AFS_Charisma_Umschaltung : 22|2@1+ (1,0) [0|3] "" XXX + SG_ AFS_Allwetterlicht : 24|1@1+ (1,0) [0|1] "" XXX + SG_ LWR_Pos_Schrittmotor : 32|8@1+ (0.4,0) [0|100] "Unit_PerCent" XXX + SG_ LWR_Hoehenwert_VL : 40|8@1+ (1,-127) [-127|126] "" XXX + SG_ LWR_Hoehenwert_HL : 48|8@1+ (1,-127) [-127|126] "" XXX + SG_ AFS_Ersatzlicht_Links : 56|1@1+ (1,0) [0|1] "" XXX + SG_ AFS_Ersatzlicht_Rechts : 57|1@1+ (1,0) [0|1] "" XXX + SG_ LWR_AFS_Grundeinstellung : 58|1@1+ (1,0) [0|1] "" XXX + SG_ LWR_AFS_Parametrisierung : 59|1@1+ (1,0) [0|1] "" XXX + SG_ LWR_Initialisierungslauf : 60|1@1+ (1,0) [0|1] "" XXX + SG_ LWR_Sicherheitsposition : 61|1@1+ (1,0) [0|1] "" XXX + SG_ LWR_Modus : 62|1@1+ (1,0) [0|1] "" XXX + SG_ LWR_KD_Fehler : 63|1@1+ (1,0) [0|1] "" XXX + +BO_ 991 Gateway_76: 8 Gateway_MQB BO_ 997 TSG_FT_02: 8 XXX - SG_ TSG_FT_02_BZ : 8|4@1+ (1,0) [0|15] "" XXX - SG_ TSG_FT_02_CRC : 0|8@1+ (1,0) [0|255] "" XXX - -BO_ 1175 Parkhilfe_01: 8 XXX - -BO_ 427 ESP_33: 8 XXX - SG_ ESP_33_BZ : 8|4@1+ (1,0) [0|15] "" XXX - SG_ ESP_33_CRC : 0|8@1+ (1,0) [0|255] "" XXX - -BO_ 418 ESP_15: 8 XXX - SG_ ESP_15_CRC : 0|8@1+ (1,0) [0|255] "" XXX - SG_ ESP_15_BZ : 8|4@1+ (1,0) [0|15] "" XXX - -BO_ 1122 PSD_04: 8 XXX - SG_ PSD_Object_Index : 0|6@1+ (1,0) [0|63] "" XXX - -BO_ 1123 PSD_05: 8 XXX - SG_ PSD_Current_Route_Index : 0|6@1+ (1,0) [0|63] "" XXX - SG_ Route_Distance_Remaining : 8|5@1+ (1,0) [0|31] "" XXX - -BO_ 1124 PSD_06: 8 XXX - -BO_ 988 Gateway_73: 8 XXX - -BO_ 792 Kamera_Status: 8 XXX - -BO_ 981 Licht_Anf_01: 8 XXX - -BO_ 1440 RLS_01: 8 XXX - -BO_ 870 Blinkmodi_02: 8 XXX - -BO_ 1385 HVEM_04: 8 XXX - -BO_ 1605 FLA_01: 8 XXX - -BO_ 1624 Licht_vorne_01: 8 XXX - -BO_ 1646 Klima_03: 8 XXX - -BO_ 1720 Kombi_03: 8 XXX + SG_ TSG_FT_02_BZ : 8|4@1+ (1,0) [0|15] "" XXX + SG_ TSG_FT_02_CRC : 0|8@1+ (1,0) [0|255] "" XXX + +BO_ 1175 Parkhilfe_01: 8 Parkhilfe_MQB + SG_ PH_Abschaltursache : 13|3@1+ (1,0) [0|7] "" Vector__XXX + SG_ PH_Opt_Anzeige_V_ein : 16|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ PH_Opt_Anzeige_H_ein : 17|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ PH_Opt_Anz_V_Hindernis : 18|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ PH_Opt_Anz_H_Hindernis : 19|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ PH_Tongeber_V_aktiv : 20|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ PH_Tongeber_H_aktiv : 21|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ PH_Tongeber_mute : 22|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ PH_Anf_Audioabsenkung : 23|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ PH_Frequenz_hinten : 32|4@1+ (1,0) [0|15] "" Vector__XXX + SG_ PH_Lautstaerke_hinten : 36|4@1+ (1,0) [0|15] "" Vector__XXX + SG_ PH_Frequenz_vorn : 40|4@1+ (1,0) [0|15] "" Vector__XXX + SG_ PH_Lautstaerke_vorn : 44|4@1+ (1,0) [0|15] "" Vector__XXX + SG_ PH_StartStopp_Info : 49|2@1+ (1,0) [0|3] "" Vector__XXX + SG_ PH_defekt : 56|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ PH_gestoert : 57|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ PH_Systemzustand : 58|3@1+ (1,0) [0|7] "" Vector__XXX + SG_ PH_Display_Kundenwunsch : 61|2@1+ (1,0) [0|3] "" Vector__XXX + SG_ PH_KD_Fehler : 63|1@1+ (1,0) [0|1] "" Vector__XXX + +BO_ 427 ESP_33: 8 ESP_MQB + SG_ ESP_33_BZ : 8|4@1+ (1,0) [0|15] "" XXX + SG_ ESP_33_CRC : 0|8@1+ (1,0) [0|255] "" XXX + +BO_ 418 ESP_15: 8 ESP_MQB + SG_ ESP_15_CRC : 0|8@1+ (1,0) [0|255] "" XXX + SG_ ESP_15_BZ : 8|4@1+ (1,0) [0|15] "" XXX + +BO_ 1122 PSD_04: 8 Navigation_MQB + SG_ PSD_Object_Index : 0|6@1+ (1,0) [0|63] "" XXX + +BO_ 1123 PSD_05: 8 Navigation_MQB + SG_ PSD_Current_Route_Index : 0|6@1+ (1,0) [0|63] "" XXX + SG_ Route_Distance_Remaining : 8|5@1+ (1,0) [0|31] "" XXX + +BO_ 1124 PSD_06: 8 Navigation_MQB + +BO_ 988 Gateway_73: 8 Gateway_MQB + +BO_ 792 Kamera_Status: 8 Front_Multifunction_Camera_MQB + +BO_ 981 Licht_Anf_01: 8 BCM_MQB + +BO_ 1440 RLS_01: 5 BCM_MQB + SG_ LS_Helligkeit_IR : 0|8@1+ (400,0) [0|101200] "Unit_Lux" HUD_MQB + SG_ LS_Helligkeit_FW : 8|10@1+ (6,0) [0|6126] "Unit_Lux" HUD_MQB + SG_ LS_defekt : 22|1@1+ (1,0) [0|1] "" HUD_MQB + SG_ LS_Verbau : 23|1@1+ (1,0) [0|1] "" HUD_MQB + SG_ RS_Regenmenge : 24|4@1+ (10,0) [0|100] "Unit_PerCent" XXX + SG_ RS_Verbau : 29|1@1+ (1,0) [0|1] "" XXX + SG_ RS_Verglasung_schliessen : 30|1@1+ (1,0) [0|1] "" XXX + SG_ RS_defekt : 31|1@1+ (1,0) [0|1] "" XXX + SG_ RS_Wischergeschwindigkeit : 32|3@1+ (1,0) [0|7] "" XXX + +BO_ 867 Blinkmodi_01: 4 BCM_MQB + SG_ BM_ZV_auf : 0|1@1+ (1,0) [0|1] "" XXX + SG_ BM_ZV_zu : 1|1@1+ (1,0) [0|1] "" XXX + SG_ BM_DWA_ein : 2|1@1+ (1,0) [0|1] "" XXX + SG_ BM_DWA_Alarm : 3|1@1+ (1,0) [0|1] "" XXX + SG_ BM_Crash : 4|1@1+ (1,0) [0|1] "" XXX + SG_ BM_Panik : 5|1@1+ (1,0) [0|1] "" XXX + SG_ BM_Not_Bremsung : 6|1@1+ (1,0) [0|1] "" XXX + SG_ BM_GDO : 7|1@1+ (1,0) [0|1] "" XXX + SG_ BM_links : 8|1@1+ (1,0) [0|1] "" XXX + SG_ BM_rechts : 9|1@1+ (1,0) [0|1] "" XXX + SG_ BM_Warnblinken : 10|1@1+ (1,0) [0|1] "" XXX + SG_ BM_Autobahn : 11|1@1+ (1,0) [0|1] "" XXX + SG_ BM_Taxi_Notalarm : 12|1@1+ (1,0) [0|1] "" XXX + SG_ BM_Telematik : 13|1@1+ (1,0) [0|1] "" XXX + SG_ BM_HD_Oeffnung_angelernt : 14|1@1+ (1,0) [0|1] "" XXX + SG_ BM_WBT_Beleuchtung : 15|1@1+ (1,0) [0|1] "" XXX + SG_ Blinken_li_Fzg_Takt : 16|1@1+ (1,0) [0|1] "" XXX + SG_ Blinken_re_Fzg_Takt : 17|1@1+ (1,0) [0|1] "" XXX + SG_ Blinken_li_Kombi_Takt : 18|1@1+ (1,0) [0|1] "" Kombi_MQB + SG_ Blinken_re_Kombi_Takt : 19|1@1+ (1,0) [0|1] "" Kombi_MQB + SG_ BM_NBA_n_codiert_n_aktiv : 20|1@1+ (1,0) [0|1] "" XXX + SG_ BM_NBA_Status : 21|2@1+ (1,0) [0|3] "" XXX + SG_ Blinken_FWB_aktiv : 23|1@1+ (1,0) [0|1] "" XXX + +BO_ 1 HVEM_04: 8 XXX + +BO_ 1605 FLA_01: 8 LCM_MQB + +BO_ 1624 Licht_vorne_01: 8 BCM_MQB + +BO_ 1646 Klima_03: 7 Klima_MQB + SG_ KL_STL_aktiv : 0|1@1+ (1,0) [0|1] "" Kombi_MQB,Standheater_MQB + SG_ KL_STH_aktiv : 1|1@1+ (1,0) [0|1] "" Kombi_MQB,Standheater_MQB + SG_ KL_Solarluefter_aktiv : 2|1@1+ (1,0) [0|1] "" Standheater_MQB + SG_ KL_Umluft_Taste : 3|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ KL_Geblaese_Fond_Status : 4|4@1+ (1,0) [0|15] "" Vector__XXX + SG_ KL_STH_Ansteuerung : 8|2@1+ (1,0) [0|3] "" Standheater_MQB + SG_ KL_STH_Betriebsdauer : 10|6@1+ (1,0) [0|60] "Unit_Minut" Standheater_MQB + SG_ KL_Magnetventil : 16|1@1+ (1,0) [0|1] "" Standheater_MQB + SG_ KL_WaPu : 17|1@1+ (1,0) [0|1] "" Standheater_MQB + SG_ KL_Freigabe_KRH_li : 18|3@1+ (1,0) [0|7] "" Vector__XXX + SG_ KL_Freigabe_KRH_re : 21|3@1+ (1,0) [0|7] "" Vector__XXX + SG_ KL_BCmE_Livetip_Freigabe : 24|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ KL_HYB_ASV_hinten_schliessen_Anf : 25|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ KL_HYB_ASV_vorne_schliessen_Anf : 26|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ KL_HYB_Spuelbetrieb_Freigabe : 27|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ KL_Innen_Temp : 32|8@1+ (0.5,-50) [-50|76] "Unit_DegreCelsi" Vector__XXX + SG_ KL_Sonnenintensitaet : 40|8@1+ (10,0) [0|1000] "Unit_WattPerMeterSquar" Vector__XXX + SG_ KL_AussenTemp_WK : 48|8@1+ (0.5,-50) [-50|76] "Unit_DegreCelsi" Vector__XXX + +BO_ 1720 Kombi_03: 8 Kombi_MQB + SG_ KBI_Reifenumfang : 0|12@1+ (1,0) [0|4095] "Unit_MilliMeter" Vector__XXX + SG_ WFS_Schluessel_Fahrberecht : 12|4@1+ (1,0) [0|15] "" Vector__XXX + SG_ KBI_BCmE_aktiv : 16|1@1+ (1,0) [0|1] "" Vector__XXX + SG_ KBI_Sparhinweis_quittiert : 17|1@1+ (1,0) [0|1] "" Vector__XXX BO_ 391 EV_Gearshift: 8 XXX - SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" XXX - SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" XXX - SG_ GearPosition : 16|4@1+ (1,0) [0|255] "" XXX - SG_ RegenBrakingMode : 12|2@1+ (1,0) [0|3] "" XXX - + SG_ CHECKSUM : 0|8@1+ (1,0) [0|255] "" XXX + SG_ COUNTER : 8|4@1+ (1,0) [0|15] "" XXX + SG_ GearPosition : 16|4@1+ (1,0) [0|255] "" XXX + SG_ RegenBrakingMode : 12|2@1+ (1,0) [0|3] "" XXX + +BO_ 1712 Klima_Sensor_01: 6 Klima_MQB + SG_ FS_Taupunkt : 0|10@1+ (0.1,-39.6) [-39.5|60.4] "Unit_DegreCelsi" Klima_MQB + SG_ FS_ResponseError : 15|1@1+ (1,0) [0|1] "" Klima_MQB + SG_ FS_Temp_Scheibe : 16|10@1+ (0.1,-39.6) [-39.5|60.4] "Unit_DegreCelsi" Klima_MQB + SG_ FS_Temp_Sensor : 32|8@1+ (0.5,-40) [-39.5|87] "Unit_DegreCelsi" Klima_MQB + SG_ FS_Luftfeuchte_rel : 40|8@1+ (0.5,-0.5) [0|100] "Unit_PerCent" Klima_MQB + +BO_ 1717 Klima_Sensor_03: 8 Klima_MQB + SG_ FSA_Taupunkt : 0|10@1+ (0.1,-40) [-40|60] "Unit_DegreCelsi" Klima_MQB + SG_ FSA_ResponseError : 15|1@1+ (1,0) [0|1] "" Klima_MQB + SG_ FSA_Temp_Luft : 16|10@1+ (0.1,-40) [-40|61] "Unit_DegreCelsi" Klima_MQB + SG_ FSA_Luftfeuchte_rel : 32|8@1+ (0.5,0) [0|100] "Unit_PerCent" Klima_MQB + SG_ FSA_HW : 40|4@1+ (1,0) [0|15] "" Klima_MQB + SG_ FSA_SW : 44|4@1+ (1,0) [0|15] "" Klima_MQB + SG_ FSA_Temp_Sensor : 48|11@1+ (0.1,-40) [-40|90] "Unit_DegreCelsi" Klima_MQB + SG_ FSA_Sensorheizung_Status : 59|1@1+ (1,0) [0|1] "" Klima_MQB + +BO_ 385 VZE_01: 8 Front_Multifunction_Camera_MQB + SG_ VZE_Anzeigemodus : 0|2@1+ (1,0) [0|3] "" HUD_MQB,Kombi_MQB + SG_ VZE_Hinweistext : 2|3@1+ (1,0) [1|7] "" Kombi_MQB + SG_ VZE_Statuszaehler_1 : 5|2@1+ (1,0) [0|3] "" Kombi_MQB + SG_ VZE_Statuszaehler_2 : 7|2@1+ (1,0) [0|3] "" Kombi_MQB + SG_ VZE_Statuszaehler_3 : 9|2@1+ (1,0) [0|3] "" Kombi_MQB + SG_ VZE_Verkehrszeichen_1 : 11|8@1+ (1,0) [1|255] "" HUD_MQB,Kombi_MQB + SG_ VZE_Verkehrszeichen_2 : 19|8@1+ (1,0) [1|255] "" HUD_MQB,Kombi_MQB + SG_ VZE_Verkehrszeichen_3 : 27|8@1+ (1,0) [1|255] "" HUD_MQB,Kombi_MQB + SG_ VZE_Warnung_Verkehrszeichen_1 : 35|1@1+ (1,0) [0|1] "" HUD_MQB,Kombi_MQB + SG_ VZE_Warnung_Verkehrszeichen_2 : 36|1@1+ (1,0) [0|1] "" HUD_MQB,Kombi_MQB + SG_ VZE_Warnung_Verkehrszeichen_3 : 37|1@1+ (1,0) [0|1] "" HUD_MQB,Kombi_MQB + SG_ VZE_Zusatzschild_1 : 38|4@1+ (1,0) [1|15] "" HUD_MQB,Kombi_MQB + SG_ VZE_Zusatzschild_2 : 42|4@1+ (1,0) [1|15] "" HUD_MQB,Kombi_MQB + SG_ VZE_Zusatzschild_3 : 46|4@1+ (1,0) [1|15] "" HUD_MQB,Kombi_MQB + + + +CM_ BO_ 1633 "Anhaenger (trailer light control)"; CM_ SG_ 173 COUNTERXX "Message not renamed to COUNTER because J533 rate-limiting makes it look like messages are being lost"; -CM_ SG_ 134 LWI_Lenkradwinkel "Steering angle WITH variable ratio effect included"; -CM_ SG_ 294 3 "May be zero when sent by older cameras"; -CM_ SG_ 294 7 "May be zero when sent by older cameras"; -CM_ SG_ 294 254 "May be zero when sent by older cameras"; +CM_ SG_ 134 LWI_Lenkradwinkel "Absolute angle of steering rack, includes effect of variable ratio steering"; +CM_ SG_ 134 LWI_VZ_Lenkradwinkel "Direction of steering rack angle signal"; +CM_ BO_ 1313 "Stand/parking heater"; +CM_ BO_ 175 "Selector lever"; +CM_ BO_ 294 "Heading Control Assist"; CM_ SG_ 294 Assist_Torque "Heading control input, torque"; CM_ SG_ 294 Assist_VZ "Heading control input, direction (sign)"; CM_ SG_ 294 HCA_Available "Must be 1 for steering rack to accept HCA commands"; -CM_ SG_ 159 HCA_Ready "1 if HCA is okay, 0 if the rack doesn't have HCA configured or a timer/constraint has been violated, rack will not respond to HCA commands"; -CM_ SG_ 159 Driver_Strain "Steering input by driver, torque"; -CM_ SG_ 159 Driver_Strain_VZ "Steering input by driver, sign (direction)"; -CM_ SG_ 159 Steering_Wheel_Angle "Steering angle WITHOUT variable ratio effect included"; -CM_ SG_ 919 LDW_DLC "Probable DLC (distance to line crossing)"; -CM_ SG_ 919 LDW_TLC "Probable TLC (time to line crossing)"; -CM_ SG_ 919 LDW_Unknown "Might be a steering pressed / driver active flag"; -CM_ SG_ 919 Alert_Message "Static table of alert messages to be invoked in the instrument cluster, some with or without beeps, 0 = no current message"; -CM_ SG_ 919 LDW_Direction "Left/right indicator for DLC and TLC"; -CM_ SG_ 919 Right_Lane_Status "Display brightness range, 0 = no lane, 3 = full brightness"; -CM_ SG_ 919 Left_Lane_Status "Display brightness range, 0 = no lane, 3 = full brightness"; -CM_ SG_ 919 Kombi_Lamp_Orange "Enables orange LDW light in instrument cluster"; -CM_ SG_ 919 Kombi_Lamp_Green "Enables green LDW light in instrument cluster"; -CM_ SG_ 780 Folgefahrt "Following another vehicle"; -CM_ SG_ 780 SetAbstand "Set following distance"; -CM_ SG_ 780 Abstand "Following distance"; -CM_ SG_ 780 SetSpeed "ACC set speed"; +CM_ BO_ 159 "Elektromechanische Lenkhilfe (electromechanical power steering)"; +CM_ BO_ 286 "True message name unknown, assumed to be from ABS/ESP"; +CM_ BO_ 919 "Lane Departure Warning"; +CM_ BO_ 695 "Rear Cross Traffic Assist"; +CM_ BO_ 783 "Spurwechselassistent (lane change assist)"; +CM_ BO_ 917 "Leuchtweiten Regulierung (luminous width regulation / advanced frontlighting system)"; +CM_ BO_ 1175 "Einparkhilfe (Park Distance Control)"; +CM_ BO_ 792 "Placeholder signal name"; +CM_ BO_ 1605 "FernLichtAssistent (high beam assist)"; +CM_ BO_ 391 "True message name unknown, e-Golf specific"; CM_ SG_ 391 GearPosition "Traditional PRND plus B-mode aggressive regen, B-mode mapped to Drive"; -CM_ SG_ 960 ZAS_Kl_15 "Indicates ignition on"; -VAL_ 173 GE_Fahrstufe 5 "P" 6 "R" 7 "N" 8 "D" 9 "S" 10 "E" 14 "T"; -VAL_ 391 GearPosition 2 "P" 3 "R" 4 "N" 5 "D" 6 "D"; -VAL_ 391 RegenBrakingMode 0 "default" 1 "B1" 2 "B2" 3 "B3"; +CM_ BO_ 385 "VerkehrsZeichen-Erkennung (traffic sign recognition)"; +VAL_ 173 GE_Fahrstufe 5 "P" 6 "R" 7 "N" 8 "D" 9 "S" 10 "E" 14 "T" ; +VAL_ 134 LWI_VZ_Lenkradwinkel 1 "right" 0 "left" ; +VAL_ 134 LWI_VZ_Lenkradw_Geschw 1 "right" 0 "left" ; +VAL_ 391 GearPosition 2 "P" 3 "R" 4 "N" 5 "D" 6 "D" ; +VAL_ 391 RegenBrakingMode 0 "default" 1 "B1" 2 "B2" 3 "B3" ; + diff --git a/panda/board/Makefile b/panda/board/Makefile index adeba0479a85e9..40ce3502b98314 100644 --- a/panda/board/Makefile +++ b/panda/board/Makefile @@ -3,6 +3,11 @@ CFLAGS = -g -Wall -Wextra -Wstrict-prototypes -Werror CFLAGS += -mlittle-endian -mthumb -mcpu=cortex-m4 CFLAGS += -mhard-float -DSTM32F4 -DSTM32F413xx -mfpu=fpv4-sp-d16 -fsingle-precision-constant +dp_vw := $(shell cat /data/params/d/dp_vw) +$(info dp_vw is ${dp_vw}) +ifeq ($(dp_vw), 1) + CFLAGS += -Dvw +endif STARTUP_FILE = startup_stm32f413xx include build.mk diff --git a/panda/board/boards/uno.h b/panda/board/boards/uno.h index cc9c4c0dc4ad67..ff71d9c1b35d80 100644 --- a/panda/board/boards/uno.h +++ b/panda/board/boards/uno.h @@ -77,9 +77,11 @@ void uno_set_usb_power_mode(uint8_t mode) { bool valid = false; switch (mode) { case USB_POWER_CLIENT: + uno_set_phone_power(false); valid = true; break; case USB_POWER_CDP: + uno_set_phone_power(true); uno_bootkick(); valid = true; break; diff --git a/panda/board/main.c b/panda/board/main.c index c6e4f0fceed116..93e2594af08fba 100644 --- a/panda/board/main.c +++ b/panda/board/main.c @@ -124,10 +124,24 @@ void set_safety_mode(uint16_t mode, int16_t param) { switch (mode_copy) { case SAFETY_SILENT: set_intercept_relay(false); + #ifdef vw + // Volkswagen community port: + // J533 integrations with White/Grey Panda really need Panda to respond + // at all times. Let the CAN transceivers ACK traffic unless this is + // BP/Uno where the physical relay makes it irrelevant. This makes + // SILENT identical to NOOUTPUT for White/Grey Panda. + if (board_has_obd()) { + current_board->set_can_mode(CAN_MODE_NORMAL); + can_silent = ALL_CAN_SILENT; + } else { + can_silent = ALL_CAN_LIVE; + } + #else if (board_has_obd()) { current_board->set_can_mode(CAN_MODE_NORMAL); } can_silent = ALL_CAN_SILENT; + #endif break; case SAFETY_NOOUTPUT: set_intercept_relay(false); diff --git a/panda/board/power_saving.h b/panda/board/power_saving.h index 2cb79cb61820ac..bd0e031f7e4444 100644 --- a/panda/board/power_saving.h +++ b/panda/board/power_saving.h @@ -28,7 +28,14 @@ void set_power_save_state(int state) { enable = true; } + #ifdef vw + // Volkswagen community port: + // If this is a White or Grey Panda, always keep the CAN transceivers + // powered up so that transparent forwarding is maintained. + current_board->enable_can_transceivers(board_has_obd() ? enable : true); + #else current_board->enable_can_transceivers(enable); + #endif // Switch EPS/GPS if (enable) { diff --git a/panda/board/safety/safety_defaults.h b/panda/board/safety/safety_defaults.h index 793dc9615888ca..a4554d92a7a123 100644 --- a/panda/board/safety/safety_defaults.h +++ b/panda/board/safety/safety_defaults.h @@ -24,9 +24,31 @@ static int nooutput_tx_lin_hook(int lin_num, uint8_t *data, int len) { } static int default_fwd_hook(int bus_num, CAN_FIFOMailBox_TypeDef *to_fwd) { - UNUSED(bus_num); UNUSED(to_fwd); + #ifdef vw + // Volkswagen community port: Advanced Virtual Relay Technology! + // Make Panda fully transparent from bus 0->2 and bus 2->0 if not otherwise + // instructed by EON/OP, returning the car to stock behavior under NOOUTPUT. + // Don't do this for BP/C2, where we have Advanced Actual Relay Technology. + int bus_fwd = -1; + + if(!board_has_relay()) { + switch (bus_num) { + case 0: + bus_fwd = 2; + break; + case 2: + bus_fwd = 0; + break; + default: + bus_fwd = -1; + break; + } + } + #else + UNUSED(bus_num); return -1; + #endif } const safety_hooks nooutput_hooks = { diff --git a/panda/board/safety/safety_volkswagen.h b/panda/board/safety/safety_volkswagen.h index 2a2c4474558346..fa6d4a2093d337 100644 --- a/panda/board/safety/safety_volkswagen.h +++ b/panda/board/safety/safety_volkswagen.h @@ -1,8 +1,8 @@ // Safety-relevant steering constants for Volkswagen const int VOLKSWAGEN_MAX_STEER = 300; // 3.0 Nm (EPS side max of 3.0Nm with fault if violated) -const int VOLKSWAGEN_MAX_RT_DELTA = 75; // 4 max rate up * 50Hz send rate * 250000 RT interval / 1000000 = 50 ; 50 * 1.5 for safety pad = 75 +const int VOLKSWAGEN_MAX_RT_DELTA = 188; // 10 max rate up * 50Hz send rate * 250000 RT interval / 1000000 = 125 ; 125 * 1.5 for safety pad = 187.5 const uint32_t VOLKSWAGEN_RT_INTERVAL = 250000; // 250ms between real time checks -const int VOLKSWAGEN_MAX_RATE_UP = 4; // 2.0 Nm/s RoC limit (EPS rack has own soft-limit of 5.0 Nm/s) +const int VOLKSWAGEN_MAX_RATE_UP = 10; // 5.0 Nm/s RoC limit (EPS rack has own soft-limit of 5.0 Nm/s) const int VOLKSWAGEN_MAX_RATE_DOWN = 10; // 5.0 Nm/s RoC limit (EPS rack has own soft-limit of 5.0 Nm/s) const int VOLKSWAGEN_DRIVER_TORQUE_ALLOWANCE = 80; const int VOLKSWAGEN_DRIVER_TORQUE_FACTOR = 3; diff --git a/phonelibs/nanovg/fontstash.h b/phonelibs/nanovg/fontstash.h index 35dfb0f6525ea8..cb96dbd0478379 100644 --- a/phonelibs/nanovg/fontstash.h +++ b/phonelibs/nanovg/fontstash.h @@ -38,6 +38,11 @@ enum FONSalign { FONS_ALIGN_BASELINE = 1<<6, // Default }; +enum FONSglyphBitmap { + FONS_GLYPH_BITMAP_OPTIONAL = 1, + FONS_GLYPH_BITMAP_REQUIRED = 2, +}; + enum FONSerrorCode { // Font atlas is full. FONS_ATLAS_FULL = 1, @@ -78,6 +83,7 @@ struct FONStextIter { const char* next; const char* end; unsigned int utf8state; + int bitmapOption; }; typedef struct FONStextIter FONStextIter; @@ -87,6 +93,8 @@ typedef struct FONScontext FONScontext; FONScontext* fonsCreateInternal(FONSparams* params); void fonsDeleteInternal(FONScontext* s); +void fontsDeleteFontByName(FONScontext* stash, const char* name); + void fonsSetErrorCallback(FONScontext* s, void (*callback)(void* uptr, int error, int val), void* uptr); // Returns current atlas size. void fonsGetAtlasSize(FONScontext* s, int* width, int* height); @@ -122,7 +130,7 @@ void fonsLineBounds(FONScontext* s, float y, float* miny, float* maxy); void fonsVertMetrics(FONScontext* s, float* ascender, float* descender, float* lineh); // Text iterator -int fonsTextIterInit(FONScontext* stash, FONStextIter* iter, float x, float y, const char* str, const char* end); +int fonsTextIterInit(FONScontext* stash, FONStextIter* iter, float x, float y, const char* str, const char* end, int bitmapOption); int fonsTextIterNext(FONScontext* stash, FONStextIter* iter, struct FONSquad* quad); // Pull texture changes @@ -156,11 +164,19 @@ static FT_Library ftLibrary; int fons__tt_init(FONScontext *context) { FT_Error ftError; - FONS_NOTUSED(context); + FONS_NOTUSED(context); ftError = FT_Init_FreeType(&ftLibrary); return ftError == 0; } +int fons__tt_done(FONScontext *context) +{ + FT_Error ftError; + FONS_NOTUSED(context); + ftError = FT_Done_FreeType(ftLibrary); + return ftError == 0; +} + int fons__tt_loadFont(FONScontext *context, FONSttFontImpl *font, unsigned char *data, int dataSize) { FT_Error ftError; @@ -198,7 +214,7 @@ int fons__tt_buildGlyphBitmap(FONSttFontImpl *font, int glyph, float size, float ftError = FT_Set_Pixel_Sizes(font->font, 0, (FT_UInt)(size * (float)font->font->units_per_EM / (float)(font->font->ascender - font->font->descender))); if (ftError) return 0; - ftError = FT_Load_Glyph(font->font, glyph, FT_LOAD_RENDER); + ftError = FT_Load_Glyph(font->font, glyph, FT_LOAD_RENDER | FT_LOAD_FORCE_AUTOHINT); if (ftError) return 0; ftError = FT_Get_Advance(font->font, glyph, FT_LOAD_NO_SCALE, &advFixed); if (ftError) return 0; @@ -258,6 +274,12 @@ int fons__tt_init(FONScontext *context) return 1; } +int fons__tt_done(FONScontext *context) +{ + FONS_NOTUSED(context); + return 1; +} + int fons__tt_loadFont(FONScontext *context, FONSttFontImpl *font, unsigned char *data, int dataSize) { int stbError; @@ -265,6 +287,7 @@ int fons__tt_loadFont(FONScontext *context, FONSttFontImpl *font, unsigned char font->font.userdata = context; stbError = stbtt_InitFont(&font->font, data, 0); + return stbError; } @@ -306,7 +329,7 @@ int fons__tt_getGlyphKernAdvance(FONSttFontImpl *font, int glyph1, int glyph2) #endif #ifndef FONS_SCRATCH_BUF_SIZE -# define FONS_SCRATCH_BUF_SIZE 64000 +# define FONS_SCRATCH_BUF_SIZE 96000 #endif #ifndef FONS_HASH_LUT_SIZE # define FONS_HASH_LUT_SIZE 256 @@ -869,7 +892,6 @@ static int fons__allocFont(FONScontext* stash) return FONS_INVALID; } - int fonsAddFont(FONScontext* stash, const char* name, const char* path) { FILE* fp = 0; @@ -922,7 +944,7 @@ int fonsAddFontMem(FONScontext* stash, const char* name, unsigned char* data, in // Init font stash->nscratch = 0; if (!fons__tt_loadFont(stash, &font->font, data, dataSize)) goto error; - + // Store normalized line height. The real line height is got // by multiplying the lineh by font size. fons__tt_getFontVMetrics( &font->font, &ascent, &descent, &lineGap); @@ -1028,7 +1050,7 @@ static void fons__blur(FONScontext* stash, unsigned char* dst, int w, int h, int } static FONSglyph* fons__getGlyph(FONScontext* stash, FONSfont* font, unsigned int codepoint, - short isize, short iblur) + short isize, short iblur, int bitmapOption) { int i, g, advance, lsb, x0, y0, x1, y1, gw, gh, gx, gy, x, y; float scale; @@ -1038,6 +1060,7 @@ static FONSglyph* fons__getGlyph(FONScontext* stash, FONSfont* font, unsigned in int pad, added; unsigned char* bdst; unsigned char* dst; + FONSfont* renderFont = font; if (isize < 2) return NULL; if (iblur > 20) iblur = 20; @@ -1050,41 +1073,66 @@ static FONSglyph* fons__getGlyph(FONScontext* stash, FONSfont* font, unsigned in h = fons__hashint(codepoint) & (FONS_HASH_LUT_SIZE-1); i = font->lut[h]; while (i != -1) { - if (font->glyphs[i].codepoint == codepoint && font->glyphs[i].size == isize && font->glyphs[i].blur == iblur) - return &font->glyphs[i]; + if (font->glyphs[i].codepoint == codepoint && font->glyphs[i].size == isize && font->glyphs[i].blur == iblur) { + glyph = &font->glyphs[i]; + if (bitmapOption == FONS_GLYPH_BITMAP_OPTIONAL || (glyph->x0 >= 0 && glyph->y0 >= 0)) { + return glyph; + } + // At this point, glyph exists but the bitmap data is not yet created. + break; + } i = font->glyphs[i].next; } - // Could not find glyph, create it. - scale = fons__tt_getPixelHeightScale(&font->font, size); + // Create a new glyph or rasterize bitmap data for a cached glyph. g = fons__tt_getGlyphIndex(&font->font, codepoint); // Try to find the glyph in fallback fonts. if (g == 0) { for (i = 0; i < font->nfallbacks; ++i) { - FONSglyph* fallbackGlyph = fons__getGlyph(stash, stash->fonts[font->fallbacks[i]], codepoint, isize, iblur); - if (fallbackGlyph != NULL && fallbackGlyph->index != 0) { - return fallbackGlyph; + FONSfont* fallbackFont = stash->fonts[font->fallbacks[i]]; + int fallbackIndex = fons__tt_getGlyphIndex(&fallbackFont->font, codepoint); + if (fallbackIndex != 0) { + g = fallbackIndex; + renderFont = fallbackFont; + break; } } + // It is possible that we did not find a fallback glyph. + // In that case the glyph index 'g' is 0, and we'll proceed below and cache empty glyph. } - fons__tt_buildGlyphBitmap(&font->font, g, size, scale, &advance, &lsb, &x0, &y0, &x1, &y1); + scale = fons__tt_getPixelHeightScale(&renderFont->font, size); + fons__tt_buildGlyphBitmap(&renderFont->font, g, size, scale, &advance, &lsb, &x0, &y0, &x1, &y1); gw = x1-x0 + pad*2; gh = y1-y0 + pad*2; - // Find free spot for the rect in the atlas - added = fons__atlasAddRect(stash->atlas, gw, gh, &gx, &gy); - if (added == 0 && stash->handleError != NULL) { - // Atlas is full, let the user to resize the atlas (or not), and try again. - stash->handleError(stash->errorUptr, FONS_ATLAS_FULL, 0); + // Determines the spot to draw glyph in the atlas. + if (bitmapOption == FONS_GLYPH_BITMAP_REQUIRED) { + // Find free spot for the rect in the atlas added = fons__atlasAddRect(stash->atlas, gw, gh, &gx, &gy); + if (added == 0 && stash->handleError != NULL) { + // Atlas is full, let the user to resize the atlas (or not), and try again. + stash->handleError(stash->errorUptr, FONS_ATLAS_FULL, 0); + added = fons__atlasAddRect(stash->atlas, gw, gh, &gx, &gy); + } + if (added == 0) return NULL; + } else { + // Negative coordinate indicates there is no bitmap data created. + gx = -1; + gy = -1; } - if (added == 0) return NULL; // Init glyph. - glyph = fons__allocGlyph(font); - glyph->codepoint = codepoint; - glyph->size = isize; - glyph->blur = iblur; + if (glyph == NULL) { + glyph = fons__allocGlyph(font); + glyph->codepoint = codepoint; + glyph->size = isize; + glyph->blur = iblur; + glyph->next = 0; + + // Insert char to hash lookup. + glyph->next = font->lut[h]; + font->lut[h] = font->nglyphs-1; + } glyph->index = g; glyph->x0 = (short)gx; glyph->y0 = (short)gy; @@ -1093,15 +1141,14 @@ static FONSglyph* fons__getGlyph(FONScontext* stash, FONSfont* font, unsigned in glyph->xadv = (short)(scale * advance * 10.0f); glyph->xoff = (short)(x0 - pad); glyph->yoff = (short)(y0 - pad); - glyph->next = 0; - // Insert char to hash lookup. - glyph->next = font->lut[h]; - font->lut[h] = font->nglyphs-1; + if (bitmapOption == FONS_GLYPH_BITMAP_OPTIONAL) { + return glyph; + } // Rasterize dst = &stash->texData[(glyph->x0+pad) + (glyph->y0+pad) * stash->params.width]; - fons__tt_renderGlyphBitmap(&font->font, dst, gw-pad*2,gh-pad*2, stash->params.width, scale,scale, g); + fons__tt_renderGlyphBitmap(&renderFont->font, dst, gw-pad*2,gh-pad*2, stash->params.width, scale, scale, g); // Make sure there is one pixel empty border. dst = &stash->texData[glyph->x0 + glyph->y0 * stash->params.width]; @@ -1128,7 +1175,7 @@ static FONSglyph* fons__getGlyph(FONScontext* stash, FONSfont* font, unsigned in if (iblur > 0) { stash->nscratch = 0; bdst = &stash->texData[glyph->x0 + glyph->y0 * stash->params.width]; - fons__blur(stash, bdst, gw,gh, stash->params.width, iblur); + fons__blur(stash, bdst, gw, gh, stash->params.width, iblur); } stash->dirtyRect[0] = fons__mini(stash->dirtyRect[0], glyph->x0); @@ -1290,7 +1337,7 @@ float fonsDrawText(FONScontext* stash, for (; str != end; ++str) { if (fons__decutf8(&utf8state, &codepoint, *(const unsigned char*)str)) continue; - glyph = fons__getGlyph(stash, font, codepoint, isize, iblur); + glyph = fons__getGlyph(stash, font, codepoint, isize, iblur, FONS_GLYPH_BITMAP_REQUIRED); if (glyph != NULL) { fons__getQuad(stash, font, prevGlyphIndex, glyph, scale, state->spacing, &x, &y, &q); @@ -1313,7 +1360,7 @@ float fonsDrawText(FONScontext* stash, } int fonsTextIterInit(FONScontext* stash, FONStextIter* iter, - float x, float y, const char* str, const char* end) + float x, float y, const char* str, const char* end, int bitmapOption) { FONSstate* state = fons__getState(stash); float width; @@ -1353,6 +1400,7 @@ int fonsTextIterInit(FONScontext* stash, FONStextIter* iter, iter->end = end; iter->codepoint = 0; iter->prevGlyphIndex = -1; + iter->bitmapOption = bitmapOption; return 1; } @@ -1373,7 +1421,8 @@ int fonsTextIterNext(FONScontext* stash, FONStextIter* iter, FONSquad* quad) // Get glyph and quad iter->x = iter->nextx; iter->y = iter->nexty; - glyph = fons__getGlyph(stash, iter->font, iter->codepoint, iter->isize, iter->iblur); + glyph = fons__getGlyph(stash, iter->font, iter->codepoint, iter->isize, iter->iblur, iter->bitmapOption); + // If the iterator was initialized with FONS_GLYPH_BITMAP_OPTIONAL, then the UV coordinates of the quad will be invalid. if (glyph != NULL) fons__getQuad(stash, iter->font, iter->prevGlyphIndex, glyph, iter->scale, iter->spacing, &iter->nextx, &iter->nexty, quad); iter->prevGlyphIndex = glyph != NULL ? glyph->index : -1; @@ -1470,7 +1519,7 @@ float fonsTextBounds(FONScontext* stash, for (; str != end; ++str) { if (fons__decutf8(&utf8state, &codepoint, *(const unsigned char*)str)) continue; - glyph = fons__getGlyph(stash, font, codepoint, isize, iblur); + glyph = fons__getGlyph(stash, font, codepoint, isize, iblur, FONS_GLYPH_BITMAP_OPTIONAL); if (glyph != NULL) { fons__getQuad(stash, font, prevGlyphIndex, glyph, scale, state->spacing, &x, &y, &q); if (q.x0 < minx) minx = q.x0; @@ -1579,6 +1628,35 @@ int fonsValidateTexture(FONScontext* stash, int* dirty) return 0; } +void fontsDeleteFontByName(FONScontext* stash, const char* name) +{ + int id = 0; + if (stash == NULL) return; + if(name == NULL) { + for (id = 0; id < stash->nfonts; ++id) { + fons__freeFont(stash->fonts[id]); + } + stash->nfonts = 0; + } + else { + id = fonsGetFontByName(stash, name); + if(id >= 0) { + fons__freeFont(stash->fonts[id]); + + for(; id < stash->nfonts; id++) { + if(id + 1 < stash->nfonts) { + stash->fonts[id] = stash->fonts[id + 1]; + } + else { + stash->fonts[id] = NULL; + break; + } + } + stash->nfonts--; + } + } +} + void fonsDeleteInternal(FONScontext* stash) { int i; @@ -1595,6 +1673,7 @@ void fonsDeleteInternal(FONScontext* stash) if (stash->texData) free(stash->texData); if (stash->scratch) free(stash->scratch); free(stash); + fons__tt_done(stash); } void fonsSetErrorCallback(FONScontext* stash, void (*callback)(void* uptr, int error, int val), void* uptr) diff --git a/phonelibs/nanovg/nanovg.c b/phonelibs/nanovg/nanovg.c index 51f972ca5b36d9..f5b34d1bd9d32b 100644 --- a/phonelibs/nanovg/nanovg.c +++ b/phonelibs/nanovg/nanovg.c @@ -1,4 +1,4 @@ -// +// // Copyright (c) 2013 Mikko Mononen memon@inside.org // // This software is provided 'as-is', without any express or implied @@ -17,15 +17,20 @@ // #include -#include #include -#include - #include "nanovg.h" + +#ifdef WITH_NANOVG_GPU +#include +#include #define FONTSTASH_IMPLEMENTATION #include "fontstash.h" #define STB_IMAGE_IMPLEMENTATION #include "stb_image.h" +#else +#include +#define printf(...) +#endif/*WITH_NANOVG_GPU*/ #ifdef _MSC_VER #pragma warning(disable: 4100) // unreferenced formal parameter @@ -67,6 +72,7 @@ enum NVGpointFlags struct NVGstate { NVGcompositeOperationState compositeOperation; + int shapeAntiAlias; NVGpaint fill; NVGpaint stroke; float strokeWidth; @@ -140,7 +146,7 @@ static float nvg__acosf(float a) { return acosf(a); } static int nvg__mini(int a, int b) { return a < b ? a : b; } static int nvg__maxi(int a, int b) { return a > b ? a : b; } -static int nvg__clampi(int a, int mn, int mx) { return a < mn ? mn : (a > mx ? mx : a); } +__attribute__((unused)) static int nvg__clampi(int a, int mn, int mx) { return a < mn ? mn : (a > mx ? mx : a); } static float nvg__minf(float a, float b) { return a < b ? a : b; } static float nvg__maxf(float a, float b) { return a > b ? a : b; } static float nvg__absf(float a) { return a >= 0.0f ? a : -a; } @@ -263,6 +269,11 @@ static NVGcompositeOperationState nvg__compositeOperationState(int op) sfactor = NVG_ONE_MINUS_DST_ALPHA; dfactor = NVG_ONE_MINUS_SRC_ALPHA; } + else + { + sfactor = NVG_ONE; + dfactor = NVG_ZERO; + } NVGcompositeOperationState state; state.srcRGB = sfactor; @@ -277,9 +288,19 @@ static NVGstate* nvg__getState(NVGcontext* ctx) return &ctx->states[ctx->nstates-1]; } +void nvgGetStateXfrom(NVGcontext* ctx, float* xform) +{ + if(xform != NULL) { + memcpy(xform, &(ctx->states[ctx->nstates-1].xform), sizeof(float) * 6); + } +} + + NVGcontext* nvgCreateInternal(NVGparams* params) { +#ifdef WITH_NANOVG_GPU FONSparams fontParams; +#endif/*WITH_NANOVG_GPU*/ NVGcontext* ctx = (NVGcontext*)malloc(sizeof(NVGcontext)); int i; if (ctx == NULL) goto error; @@ -304,6 +325,7 @@ NVGcontext* nvgCreateInternal(NVGparams* params) if (ctx->params.renderCreate(ctx->params.userPtr) == 0) goto error; +#ifdef WITH_NANOVG_GPU // Init font rendering memset(&fontParams, 0, sizeof(fontParams)); fontParams.width = NVG_INIT_FONTIMAGE_SIZE; @@ -318,9 +340,10 @@ NVGcontext* nvgCreateInternal(NVGparams* params) if (ctx->fs == NULL) goto error; // Create font texture - ctx->fontImages[0] = ctx->params.renderCreateTexture(ctx->params.userPtr, NVG_TEXTURE_ALPHA, fontParams.width, fontParams.height, 0, NULL); + ctx->fontImages[0] = ctx->params.renderCreateTexture(ctx->params.userPtr, NVG_TEXTURE_ALPHA, fontParams.width, fontParams.height, 0, 0, NULL); if (ctx->fontImages[0] == 0) goto error; ctx->fontImageIdx = 0; +#endif/*WITH_NANOVG_GPU*/ return ctx; @@ -341,6 +364,7 @@ void nvgDeleteInternal(NVGcontext* ctx) if (ctx->commands != NULL) free(ctx->commands); if (ctx->cache != NULL) nvg__deletePathCache(ctx->cache); +#ifdef WITH_NANOVG_GPU if (ctx->fs) fonsDeleteInternal(ctx->fs); @@ -350,6 +374,9 @@ void nvgDeleteInternal(NVGcontext* ctx) ctx->fontImages[i] = 0; } } +#else + (void)i; +#endif/*WITH_NANOVG_GPU*/ if (ctx->params.renderDelete != NULL) ctx->params.renderDelete(ctx->params.userPtr); @@ -357,7 +384,7 @@ void nvgDeleteInternal(NVGcontext* ctx) free(ctx); } -void nvgBeginFrame(NVGcontext* ctx, int windowWidth, int windowHeight, float devicePixelRatio) +void nvgBeginFrame(NVGcontext* ctx, float windowWidth, float windowHeight, float devicePixelRatio) { /* printf("Tris: draws:%d fill:%d stroke:%d text:%d TOT:%d\n", ctx->drawCallCount, ctx->fillTriCount, ctx->strokeTriCount, ctx->textTriCount, @@ -384,8 +411,7 @@ void nvgCancelFrame(NVGcontext* ctx) void nvgEndFrame(NVGcontext* ctx) { - NVGstate* state = nvg__getState(ctx); - ctx->params.renderFlush(ctx->params.userPtr, state->compositeOperation); + ctx->params.renderFlush(ctx->params.userPtr); if (ctx->fontImageIdx != 0) { int fontImage = ctx->fontImages[ctx->fontImageIdx]; int i, j, iw, ih; @@ -461,7 +487,7 @@ NVGcolor nvgLerpRGBA(NVGcolor c0, NVGcolor c1, float u) { int i; float oneminu; - NVGcolor cint = {0}; + NVGcolor cint = {{{0}}}; u = nvg__clampf(u, 0.0f, 1.0f); oneminu = 1.0f - u; @@ -641,6 +667,7 @@ void nvgReset(NVGcontext* ctx) nvg__setPaintColor(&state->fill, nvgRGBA(255,255,255,255)); nvg__setPaintColor(&state->stroke, nvgRGBA(0,0,0,255)); state->compositeOperation = nvg__compositeOperationState(NVG_SOURCE_OVER); + state->shapeAntiAlias = 1; state->strokeWidth = 1.0f; state->miterLimit = 10.0f; state->lineCap = NVG_BUTT; @@ -660,6 +687,12 @@ void nvgReset(NVGcontext* ctx) } // State setting +void nvgShapeAntiAlias(NVGcontext* ctx, int enabled) +{ + NVGstate* state = nvg__getState(ctx); + state->shapeAntiAlias = enabled; +} + void nvgStrokeWidth(NVGcontext* ctx, float width) { NVGstate* state = nvg__getState(ctx); @@ -676,12 +709,20 @@ void nvgLineCap(NVGcontext* ctx, int cap) { NVGstate* state = nvg__getState(ctx); state->lineCap = cap; + if(ctx->params.setLineJoin != NULL) + { + ctx->params.setLineCap(ctx->params.userPtr, cap); + } } void nvgLineJoin(NVGcontext* ctx, int join) { NVGstate* state = nvg__getState(ctx); state->lineJoin = join; + if(ctx->params.setLineJoin != NULL) + { + ctx->params.setLineJoin(ctx->params.userPtr, join); + } } void nvgGlobalAlpha(NVGcontext* ctx, float alpha) @@ -776,6 +817,7 @@ void nvgFillPaint(NVGcontext* ctx, NVGpaint paint) nvgTransformMultiply(state->fill.xform, state->xform); } +#ifdef WITH_NANOVG_GPU int nvgCreateImage(NVGcontext* ctx, const char* filename, int imageFlags) { int w, h, n, image; @@ -804,10 +846,21 @@ int nvgCreateImageMem(NVGcontext* ctx, int imageFlags, unsigned char* data, int stbi_image_free(img); return image; } +#else +int nvgCreateImage(NVGcontext* ctx, const char* filename, int imageFlags) +{ + return -1; +} + +int nvgCreateImageMem(NVGcontext* ctx, int imageFlags, unsigned char* data, int ndata) +{ + return -1; +} +#endif/*WITH_NANOVG_GPU*/ int nvgCreateImageRGBA(NVGcontext* ctx, int w, int h, int imageFlags, const unsigned char* data) { - return ctx->params.renderCreateTexture(ctx->params.userPtr, NVG_TEXTURE_RGBA, w, h, imageFlags, data); + return ctx->params.renderCreateTexture(ctx->params.userPtr, NVG_TEXTURE_RGBA, w, h, w * 4, imageFlags, data); } void nvgUpdateImage(NVGcontext* ctx, int image, const unsigned char* data) @@ -822,6 +875,15 @@ void nvgImageSize(NVGcontext* ctx, int image, int* w, int* h) ctx->params.renderGetTextureSize(ctx->params.userPtr, image, w, h); } +void nvgDeleteFontByName(NVGcontext* ctx, const char* name) +{ +#ifdef WITH_NANOVG_GPU + if (ctx->fs) { + fontsDeleteFontByName(ctx->fs, name); + } +#endif +} + void nvgDeleteImage(NVGcontext* ctx, int image) { ctx->params.renderDeleteTexture(ctx->params.userPtr, image); @@ -948,7 +1010,12 @@ void nvgScissor(NVGcontext* ctx, float x, float y, float w, float h) w = nvg__maxf(0.0f, w); h = nvg__maxf(0.0f, h); - + /* 消除着色器精度不够引起的漏出颜色的问题 */ + if (w == 0.0f || h == 0.0f) { + w = 0.0f; + h = 0.0f; + } + nvgTransformIdentity(state->scissor.xform); state->scissor.xform[4] = x+w*0.5f; state->scissor.xform[5] = y+h*0.5f; @@ -972,6 +1039,66 @@ static void nvg__isectRects(float* dst, dst[3] = nvg__maxf(0.0f, maxy - miny); } + +void nvgIntersectScissorForOtherRect(NVGcontext* ctx, float x, float y, float w, float h, float dx, float dy, float dw, float dh) +{ + NVGstate* state = nvg__getState(ctx); + float rect[4]; + float invxorm[6]; + float ex = 0.0f, ey = 0.0f, tex = 0.0f, tey = 0.0f; + /* 因为脏矩形默认坐标系就是没有旋转没有缩放没有平移的状态 */ + float pxform[6] = { 1.0f, 0.0f, 0.0f, 1.0f, 0.0f, 0.0f }; + ex = dw * 0.5f; + ey = dh * 0.5f; + pxform[4] = dx + dw * 0.5f; + pxform[5] = dy + dh * 0.5f; + memset(invxorm, 0, sizeof(float) * 6); + nvgTransformInverse(invxorm, state->xform); + nvgTransformMultiply(pxform, invxorm); + tex = ex*nvg__absf(pxform[0]) + ey*nvg__absf(pxform[2]); + tey = ex*nvg__absf(pxform[1]) + ey*nvg__absf(pxform[3]); + + // Intersect rects. + nvg__isectRects(rect, pxform[4] - tex, pxform[5] - tey, tex * 2, tey * 2, x, y, w, h); + + nvgScissor(ctx, rect[0], rect[1], rect[2], rect[3]); +} + +void nvgIntersectScissor_ex(NVGcontext* ctx, float* x, float* y, float* w, float* h) +{ + NVGstate* state = nvg__getState(ctx); + float pxform[6], invxorm[6]; + float rect[4]; + float ex, ey, tex, tey; + + // If no previous scissor has been set, set the scissor as current scissor. + if (state->scissor.extent[0] < 0) { + nvgScissor(ctx, *x, *y, *w, *h); + return; + } + + // Transform the current scissor rect into current transform space. + // If there is difference in rotation, this will be approximation. + memcpy(pxform, state->scissor.xform, sizeof(float)*6); + ex = state->scissor.extent[0]; + ey = state->scissor.extent[1]; + nvgTransformInverse(invxorm, state->xform); + nvgTransformMultiply(pxform, invxorm); + tex = ex*nvg__absf(pxform[0]) + ey*nvg__absf(pxform[2]); + tey = ex*nvg__absf(pxform[1]) + ey*nvg__absf(pxform[3]); + + // Intersect rects. + nvg__isectRects(rect, pxform[4]-tex,pxform[5]-tey,tex*2,tey*2, *x, *y, *w, *h); + + *x = rect[0]; + *y = rect[1]; + *w = rect[2]; + *h = rect[3]; + + nvgScissor(ctx, rect[0], rect[1], rect[2], rect[3]); +} + + void nvgIntersectScissor(NVGcontext* ctx, float x, float y, float w, float h) { NVGstate* state = nvg__getState(ctx); @@ -1411,6 +1538,7 @@ static int nvg__curveDivs(float r, float arc, float tol) return nvg__maxi(2, (int)ceilf(arc / da)); } +#ifdef WITH_NANOVG_GPU static void nvg__chooseBevel(int bevel, NVGpoint* p0, NVGpoint* p1, float w, float* x0, float* y0, float* x1, float* y1) { @@ -1428,7 +1556,8 @@ static void nvg__chooseBevel(int bevel, NVGpoint* p0, NVGpoint* p1, float w, } static NVGvertex* nvg__roundJoin(NVGvertex* dst, NVGpoint* p0, NVGpoint* p1, - float lw, float rw, float lu, float ru, int ncap, float fringe) + float lw, float rw, float lu, float ru, int ncap, + float fringe) { int i, n; float dlx0 = p0->dy; @@ -1561,36 +1690,39 @@ static NVGvertex* nvg__bevelJoin(NVGvertex* dst, NVGpoint* p0, NVGpoint* p1, } static NVGvertex* nvg__buttCapStart(NVGvertex* dst, NVGpoint* p, - float dx, float dy, float w, float d, float aa) + float dx, float dy, float w, float d, + float aa, float u0, float u1) { float px = p->x - dx*d; float py = p->y - dy*d; float dlx = dy; float dly = -dx; - nvg__vset(dst, px + dlx*w - dx*aa, py + dly*w - dy*aa, 0,0); dst++; - nvg__vset(dst, px - dlx*w - dx*aa, py - dly*w - dy*aa, 1,0); dst++; - nvg__vset(dst, px + dlx*w, py + dly*w, 0,1); dst++; - nvg__vset(dst, px - dlx*w, py - dly*w, 1,1); dst++; + nvg__vset(dst, px + dlx*w - dx*aa, py + dly*w - dy*aa, u0,0); dst++; + nvg__vset(dst, px - dlx*w - dx*aa, py - dly*w - dy*aa, u1,0); dst++; + nvg__vset(dst, px + dlx*w, py + dly*w, u0,1); dst++; + nvg__vset(dst, px - dlx*w, py - dly*w, u1,1); dst++; return dst; } static NVGvertex* nvg__buttCapEnd(NVGvertex* dst, NVGpoint* p, - float dx, float dy, float w, float d, float aa) + float dx, float dy, float w, float d, + float aa, float u0, float u1) { float px = p->x + dx*d; float py = p->y + dy*d; float dlx = dy; float dly = -dx; - nvg__vset(dst, px + dlx*w, py + dly*w, 0,1); dst++; - nvg__vset(dst, px - dlx*w, py - dly*w, 1,1); dst++; - nvg__vset(dst, px + dlx*w + dx*aa, py + dly*w + dy*aa, 0,0); dst++; - nvg__vset(dst, px - dlx*w + dx*aa, py - dly*w + dy*aa, 1,0); dst++; + nvg__vset(dst, px + dlx*w, py + dly*w, u0,1); dst++; + nvg__vset(dst, px - dlx*w, py - dly*w, u1,1); dst++; + nvg__vset(dst, px + dlx*w + dx*aa, py + dly*w + dy*aa, u0,0); dst++; + nvg__vset(dst, px - dlx*w + dx*aa, py - dly*w + dy*aa, u1,0); dst++; return dst; } static NVGvertex* nvg__roundCapStart(NVGvertex* dst, NVGpoint* p, - float dx, float dy, float w, int ncap, float aa) + float dx, float dy, float w, int ncap, + float aa, float u0, float u1) { int i; float px = p->x; @@ -1601,16 +1733,17 @@ static NVGvertex* nvg__roundCapStart(NVGvertex* dst, NVGpoint* p, for (i = 0; i < ncap; i++) { float a = i/(float)(ncap-1)*NVG_PI; float ax = cosf(a) * w, ay = sinf(a) * w; - nvg__vset(dst, px - dlx*ax - dx*ay, py - dly*ax - dy*ay, 0,1); dst++; + nvg__vset(dst, px - dlx*ax - dx*ay, py - dly*ax - dy*ay, u0,1); dst++; nvg__vset(dst, px, py, 0.5f,1); dst++; } - nvg__vset(dst, px + dlx*w, py + dly*w, 0,1); dst++; - nvg__vset(dst, px - dlx*w, py - dly*w, 1,1); dst++; + nvg__vset(dst, px + dlx*w, py + dly*w, u0,1); dst++; + nvg__vset(dst, px - dlx*w, py - dly*w, u1,1); dst++; return dst; } static NVGvertex* nvg__roundCapEnd(NVGvertex* dst, NVGpoint* p, - float dx, float dy, float w, int ncap, float aa) + float dx, float dy, float w, int ncap, + float aa, float u0, float u1) { int i; float px = p->x; @@ -1618,13 +1751,13 @@ static NVGvertex* nvg__roundCapEnd(NVGvertex* dst, NVGpoint* p, float dlx = dy; float dly = -dx; NVG_NOTUSED(aa); - nvg__vset(dst, px + dlx*w, py + dly*w, 0,1); dst++; - nvg__vset(dst, px - dlx*w, py - dly*w, 1,1); dst++; + nvg__vset(dst, px + dlx*w, py + dly*w, u0,1); dst++; + nvg__vset(dst, px - dlx*w, py - dly*w, u1,1); dst++; for (i = 0; i < ncap; i++) { float a = i/(float)(ncap-1)*NVG_PI; float ax = cosf(a) * w, ay = sinf(a) * w; nvg__vset(dst, px, py, 0.5f,1); dst++; - nvg__vset(dst, px - dlx*ax + dx*ay, py - dly*ax + dy*ay, 0,1); dst++; + nvg__vset(dst, px - dlx*ax + dx*ay, py - dly*ax + dy*ay, u0,1); dst++; } return dst; } @@ -1700,15 +1833,24 @@ static void nvg__calculateJoins(NVGcontext* ctx, float w, int lineJoin, float mi } -static int nvg__expandStroke(NVGcontext* ctx, float w, int lineCap, int lineJoin, float miterLimit) +static int nvg__expandStroke(NVGcontext* ctx, float w, float fringe, int lineCap, int lineJoin, float miterLimit) { NVGpathCache* cache = ctx->cache; NVGvertex* verts; NVGvertex* dst; int cverts, i, j; - float aa = ctx->fringeWidth; + float aa = fringe;//ctx->fringeWidth; + float u0 = 0.0f, u1 = 1.0f; int ncap = nvg__curveDivs(w, NVG_PI, ctx->tessTol); // Calculate divisions per half circle. + w += aa * 0.5f; + + // Disable the gradient used for antialiasing when antialiasing is not used. + if (aa == 0.0f) { + u0 = 0.5f; + u1 = 0.5f; + } + nvg__calculateJoins(ctx, w, lineJoin, miterLimit); // Calculate max vertex usage. @@ -1769,42 +1911,42 @@ static int nvg__expandStroke(NVGcontext* ctx, float w, int lineCap, int lineJoin dy = p1->y - p0->y; nvg__normalize(&dx, &dy); if (lineCap == NVG_BUTT) - dst = nvg__buttCapStart(dst, p0, dx, dy, w, -aa*0.5f, aa); + dst = nvg__buttCapStart(dst, p0, dx, dy, w, -aa*0.5f, aa, u0, u1); else if (lineCap == NVG_BUTT || lineCap == NVG_SQUARE) - dst = nvg__buttCapStart(dst, p0, dx, dy, w, w-aa, aa); + dst = nvg__buttCapStart(dst, p0, dx, dy, w, w-aa, aa, u0, u1); else if (lineCap == NVG_ROUND) - dst = nvg__roundCapStart(dst, p0, dx, dy, w, ncap, aa); + dst = nvg__roundCapStart(dst, p0, dx, dy, w, ncap, aa, u0, u1); } for (j = s; j < e; ++j) { if ((p1->flags & (NVG_PT_BEVEL | NVG_PR_INNERBEVEL)) != 0) { if (lineJoin == NVG_ROUND) { - dst = nvg__roundJoin(dst, p0, p1, w, w, 0, 1, ncap, aa); + dst = nvg__roundJoin(dst, p0, p1, w, w, u0, u1, ncap, aa); } else { - dst = nvg__bevelJoin(dst, p0, p1, w, w, 0, 1, aa); + dst = nvg__bevelJoin(dst, p0, p1, w, w, u0, u1, aa); } } else { - nvg__vset(dst, p1->x + (p1->dmx * w), p1->y + (p1->dmy * w), 0,1); dst++; - nvg__vset(dst, p1->x - (p1->dmx * w), p1->y - (p1->dmy * w), 1,1); dst++; + nvg__vset(dst, p1->x + (p1->dmx * w), p1->y + (p1->dmy * w), u0,1); dst++; + nvg__vset(dst, p1->x - (p1->dmx * w), p1->y - (p1->dmy * w), u1,1); dst++; } p0 = p1++; } if (loop) { // Loop it - nvg__vset(dst, verts[0].x, verts[0].y, 0,1); dst++; - nvg__vset(dst, verts[1].x, verts[1].y, 1,1); dst++; + nvg__vset(dst, verts[0].x, verts[0].y, u0,1); dst++; + nvg__vset(dst, verts[1].x, verts[1].y, u1,1); dst++; } else { // Add cap dx = p1->x - p0->x; dy = p1->y - p0->y; nvg__normalize(&dx, &dy); if (lineCap == NVG_BUTT) - dst = nvg__buttCapEnd(dst, p1, dx, dy, w, -aa*0.5f, aa); + dst = nvg__buttCapEnd(dst, p1, dx, dy, w, -aa*0.5f, aa, u0, u1); else if (lineCap == NVG_BUTT || lineCap == NVG_SQUARE) - dst = nvg__buttCapEnd(dst, p1, dx, dy, w, w-aa, aa); + dst = nvg__buttCapEnd(dst, p1, dx, dy, w, w-aa, aa, u0, u1); else if (lineCap == NVG_ROUND) - dst = nvg__roundCapEnd(dst, p1, dx, dy, w, ncap, aa); + dst = nvg__roundCapEnd(dst, p1, dx, dy, w, ncap, aa, u0, u1); } path->nstroke = (int)(dst - verts); @@ -1935,6 +2077,197 @@ static int nvg__expandFill(NVGcontext* ctx, float w, int lineJoin, float miterLi return 1; } +#else + +static int nvg__expandStroke(NVGcontext* ctx, float w, float fringe, int lineCap, int lineJoin, float miterLimit) +{ + NVGpathCache* cache = ctx->cache; + NVGvertex* verts; + NVGvertex* dst; + int cverts, i, j; + float aa = fringe;//ctx->fringeWidth; + float u0 = 0.0f, u1 = 1.0f; + int ncap = nvg__curveDivs(w, NVG_PI, ctx->tessTol); // Calculate divisions per half circle. + + w += aa * 0.5f; + + // Disable the gradient used for antialiasing when antialiasing is not used. + if (aa == 0.0f) { + u0 = 0.5f; + u1 = 0.5f; + } + + // Calculate max vertex usage. + cverts = 0; + for (i = 0; i < cache->npaths; i++) { + NVGpath* path = &cache->paths[i]; + int loop = (path->closed == 0) ? 0 : 1; + cverts += (path->count + path->nbevel*5 + 1) * 2; // plus one for loop + if (loop == 0) { + // space for caps + if (lineCap == NVG_ROUND) { + cverts += (ncap*2 + 2)*2; + } else { + cverts += (3+3)*2; + } + } + } + + verts = nvg__allocTempVerts(ctx, cverts); + if (verts == NULL) return 0; + + for (i = 0; i < cache->npaths; i++) { + NVGpath* path = &cache->paths[i]; + NVGpoint* pts = &cache->points[path->first]; + NVGpoint* p0; + NVGpoint* p1; + int s, e, loop; + + path->fill = 0; + path->nfill = 0; + + // Calculate fringe or stroke + loop = (path->closed == 0) ? 0 : 1; + dst = verts; + path->stroke = dst; + + if (loop) { + // Looping + p0 = &pts[path->count-1]; + p1 = &pts[0]; + s = 0; + e = path->count; + } else { + // Add cap + p0 = &pts[0]; + p1 = &pts[1]; + s = 1; + e = path->count-1; + } + + if (loop == 0) { + // Add cap + nvg__vset(dst, p0->x, p0->y, u0,1); dst++; + } + + for (j = s; j < e; ++j) { + nvg__vset(dst, p1->x + (p1->dmx * w), p1->y + (p1->dmy * w), u0,1); dst++; + nvg__vset(dst, p1->x - (p1->dmx * w), p1->y - (p1->dmy * w), u1,1); dst++; + p0 = p1++; + } + + if (loop) { + // Loop it + nvg__vset(dst, verts[0].x, verts[0].y, u0,1); dst++; + nvg__vset(dst, verts[1].x, verts[1].y, u1,1); dst++; + } else { + // Add cap + nvg__vset(dst, p1->x, p1->y, u0,1); dst++; + } + + path->nstroke = (int)(dst - verts); + + verts = dst; + } + + return 1; +} + +static int nvg__expandFill(NVGcontext* ctx, float w, int lineJoin, float miterLimit) +{ + NVGpathCache* cache = ctx->cache; + NVGvertex* verts; + NVGvertex* dst; + int cverts, convex, i, j; + float aa = ctx->fringeWidth; + int fringe = w > 0.0f; + + // Calculate max vertex usage. + cverts = 0; + for (i = 0; i < cache->npaths; i++) { + NVGpath* path = &cache->paths[i]; + cverts += path->count + path->nbevel + 1; + if (fringe) + cverts += (path->count + path->nbevel*5 + 1) * 2; // plus one for loop + } + + verts = nvg__allocTempVerts(ctx, cverts); + if (verts == NULL) return 0; + + convex = cache->npaths == 1 && cache->paths[0].convex; + + for (i = 0; i < cache->npaths; i++) { + NVGpath* path = &cache->paths[i]; + NVGpoint* pts = &cache->points[path->first]; + NVGpoint* p0; + NVGpoint* p1; + float rw, lw, woff; + float ru, lu; + + // Calculate shape vertices. + woff = 0.5f*aa; + dst = verts; + path->fill = dst; + + if (fringe) { + // Looping + p0 = &pts[path->count-1]; + p1 = &pts[0]; + for (j = 0; j < path->count; ++j) { + nvg__vset(dst, p1->x + (p1->dmx * woff), p1->y + (p1->dmy * woff), 0.5f,1); dst++; + p0 = p1++; + } + } else { + for (j = 0; j < path->count; ++j) { + nvg__vset(dst, pts[j].x, pts[j].y, 0.5f,1); + dst++; + } + } + + path->nfill = (int)(dst - verts); + verts = dst; + + // Calculate fringe + if (fringe) { + lw = w + woff; + rw = w - woff; + lu = 0; + ru = 1; + dst = verts; + path->stroke = dst; + + // Create only half a fringe for convex shapes so that + // the shape can be rendered without stenciling. + if (convex) { + lw = woff; // This should generate the same vertex as fill inset above. + lu = 0.5f; // Set outline fade at middle. + } + + // Looping + p0 = &pts[path->count-1]; + p1 = &pts[0]; + + for (j = 0; j < path->count; ++j) { + nvg__vset(dst, p1->x + (p1->dmx * lw), p1->y + (p1->dmy * lw), lu,1); dst++; + nvg__vset(dst, p1->x - (p1->dmx * rw), p1->y - (p1->dmy * rw), ru,1); dst++; + p0 = p1++; + } + + // Loop it + nvg__vset(dst, verts[0].x, verts[0].y, lu,1); dst++; + nvg__vset(dst, verts[1].x, verts[1].y, ru,1); dst++; + + path->nstroke = (int)(dst - verts); + verts = dst; + } else { + path->stroke = NULL; + path->nstroke = 0; + } + } + + return 1; +} +#endif/*WITH_NANOVG_GPU*/ // Draw void nvgBeginPath(NVGcontext* ctx) @@ -2168,6 +2501,14 @@ void nvgCircle(NVGcontext* ctx, float cx, float cy, float r) nvgEllipse(ctx, cx,cy, r,r); } +int nvgClearCache(NVGcontext* ctx) { + if(ctx->params.clearCache != NULL) { + ctx->params.clearCache(ctx->params.userPtr); + } + return 0; +} + +#ifdef WITH_NANOVG_GPU void nvgDebugDumpPathCache(NVGcontext* ctx) { const NVGpath* path; @@ -2189,6 +2530,7 @@ void nvgDebugDumpPathCache(NVGcontext* ctx) } } } +#endif/*WITH_NANOVG_GPU*/ void nvgFill(NVGcontext* ctx) { @@ -2198,7 +2540,7 @@ void nvgFill(NVGcontext* ctx) int i; nvg__flattenPaths(ctx); - if (ctx->params.edgeAntiAlias) + if (ctx->params.edgeAntiAlias && state->shapeAntiAlias) nvg__expandFill(ctx, ctx->fringeWidth, NVG_MITER, 2.4f); else nvg__expandFill(ctx, 0.0f, NVG_MITER, 2.4f); @@ -2207,7 +2549,12 @@ void nvgFill(NVGcontext* ctx) fillPaint.innerColor.a *= state->alpha; fillPaint.outerColor.a *= state->alpha; - ctx->params.renderFill(ctx->params.userPtr, &fillPaint, &state->scissor, ctx->fringeWidth, + /* 把 nanovg 的坐标系传入到适量画布算法中 */ + if(ctx->params.setStateXfrom != NULL) { + ctx->params.setStateXfrom(ctx->params.userPtr, state->xform); + } + + ctx->params.renderFill(ctx->params.userPtr, &fillPaint, state->compositeOperation, &state->scissor, ctx->fringeWidth, ctx->cache->bounds, ctx->cache->paths, ctx->cache->npaths); // Count triangles @@ -2228,6 +2575,7 @@ void nvgStroke(NVGcontext* ctx) const NVGpath* path; int i; + if (strokeWidth < ctx->fringeWidth) { // If the stroke width is less than pixel size, use alpha to emulate coverage. // Since coverage is area, scale by alpha*alpha. @@ -2243,12 +2591,17 @@ void nvgStroke(NVGcontext* ctx) nvg__flattenPaths(ctx); - if (ctx->params.edgeAntiAlias) - nvg__expandStroke(ctx, strokeWidth*0.5f + ctx->fringeWidth*0.5f, state->lineCap, state->lineJoin, state->miterLimit); + if (ctx->params.edgeAntiAlias && state->shapeAntiAlias) + nvg__expandStroke(ctx, strokeWidth*0.5f, ctx->fringeWidth, state->lineCap, state->lineJoin, state->miterLimit); else - nvg__expandStroke(ctx, strokeWidth*0.5f, state->lineCap, state->lineJoin, state->miterLimit); + nvg__expandStroke(ctx, strokeWidth*0.5f, 0.0f, state->lineCap, state->lineJoin, state->miterLimit); - ctx->params.renderStroke(ctx->params.userPtr, &strokePaint, &state->scissor, ctx->fringeWidth, + /* 把 nanovg 的坐标系传入到适量画布算法中 */ + if(ctx->params.setStateXfrom != NULL) { + ctx->params.setStateXfrom(ctx->params.userPtr, state->xform); + } + + ctx->params.renderStroke(ctx->params.userPtr, &strokePaint, state->compositeOperation, &state->scissor, ctx->fringeWidth, strokeWidth, ctx->cache->paths, ctx->cache->npaths); // Count triangles @@ -2259,6 +2612,7 @@ void nvgStroke(NVGcontext* ctx) } } +#ifdef WITH_NANOVG_GPU // Add fonts int nvgCreateFont(NVGcontext* ctx, const char* name, const char* path) { @@ -2377,7 +2731,7 @@ static int nvg__allocTextAtlas(NVGcontext* ctx) iw *= 2; if (iw > NVG_MAX_FONTIMAGE_SIZE || ih > NVG_MAX_FONTIMAGE_SIZE) iw = ih = NVG_MAX_FONTIMAGE_SIZE; - ctx->fontImages[ctx->fontImageIdx+1] = ctx->params.renderCreateTexture(ctx->params.userPtr, NVG_TEXTURE_ALPHA, iw, ih, 0, NULL); + ctx->fontImages[ctx->fontImageIdx+1] = ctx->params.renderCreateTexture(ctx->params.userPtr, NVG_TEXTURE_ALPHA, iw, ih, 0, 0, NULL); } ++ctx->fontImageIdx; fonsResetAtlas(ctx->fs, iw, ih); @@ -2396,7 +2750,7 @@ static void nvg__renderText(NVGcontext* ctx, NVGvertex* verts, int nverts) paint.innerColor.a *= state->alpha; paint.outerColor.a *= state->alpha; - ctx->params.renderTriangles(ctx->params.userPtr, &paint, &state->scissor, verts, nverts); + ctx->params.renderTriangles(ctx->params.userPtr, &paint, state->compositeOperation, &state->scissor, verts, nverts); ctx->drawCallCount++; ctx->textTriCount += nverts/3; @@ -2428,17 +2782,17 @@ float nvgText(NVGcontext* ctx, float x, float y, const char* string, const char* verts = nvg__allocTempVerts(ctx, cverts); if (verts == NULL) return x; - fonsTextIterInit(ctx->fs, &iter, x*scale, y*scale, string, end); + fonsTextIterInit(ctx->fs, &iter, x*scale, y*scale, string, end, FONS_GLYPH_BITMAP_REQUIRED); prevIter = iter; while (fonsTextIterNext(ctx->fs, &iter, &q)) { float c[4*2]; if (iter.prevGlyphIndex == -1) { // can not retrieve glyph? - if (!nvg__allocTextAtlas(ctx)) - break; // no memory :( if (nverts != 0) { nvg__renderText(ctx, verts, nverts); nverts = 0; } + if (!nvg__allocTextAtlas(ctx)) + break; // no memory :( iter = prevIter; fonsTextIterNext(ctx->fs, &iter, &q); // try again if (iter.prevGlyphIndex == -1) // still can not find glyph? @@ -2466,7 +2820,7 @@ float nvgText(NVGcontext* ctx, float x, float y, const char* string, const char* nvg__renderText(ctx, verts, nverts); - return iter.x; + return iter.nextx / scale; } void nvgTextBox(NVGcontext* ctx, float x, float y, float breakRowWidth, const char* string, const char* end) @@ -2525,7 +2879,7 @@ int nvgTextGlyphPositions(NVGcontext* ctx, float x, float y, const char* string, fonsSetAlign(ctx->fs, state->textAlign); fonsSetFont(ctx->fs, state->fontId); - fonsTextIterInit(ctx->fs, &iter, x*scale, y*scale, string, end); + fonsTextIterInit(ctx->fs, &iter, x*scale, y*scale, string, end, FONS_GLYPH_BITMAP_OPTIONAL); prevIter = iter; while (fonsTextIterNext(ctx->fs, &iter, &q)) { if (iter.prevGlyphIndex < 0 && nvg__allocTextAtlas(ctx)) { // can not retrieve glyph? @@ -2549,6 +2903,7 @@ enum NVGcodepointType { NVG_SPACE, NVG_NEWLINE, NVG_CHAR, + NVG_CJK_CHAR, }; int nvgTextBreakLines(NVGcontext* ctx, const char* string, const char* end, float breakRowWidth, NVGtextRow* rows, int maxRows) @@ -2590,7 +2945,7 @@ int nvgTextBreakLines(NVGcontext* ctx, const char* string, const char* end, floa breakRowWidth *= scale; - fonsTextIterInit(ctx->fs, &iter, 0, 0, string, end); + fonsTextIterInit(ctx->fs, &iter, 0, 0, string, end, FONS_GLYPH_BITMAP_OPTIONAL); prevIter = iter; while (fonsTextIterNext(ctx->fs, &iter, &q)) { if (iter.prevGlyphIndex < 0 && nvg__allocTextAtlas(ctx)) { // can not retrieve glyph? @@ -2616,7 +2971,15 @@ int nvgTextBreakLines(NVGcontext* ctx, const char* string, const char* end, floa type = NVG_NEWLINE; break; default: - type = NVG_CHAR; + if ((iter.codepoint >= 0x4E00 && iter.codepoint <= 0x9FFF) || + (iter.codepoint >= 0x3000 && iter.codepoint <= 0x30FF) || + (iter.codepoint >= 0xFF00 && iter.codepoint <= 0xFFEF) || + (iter.codepoint >= 0x1100 && iter.codepoint <= 0x11FF) || + (iter.codepoint >= 0x3130 && iter.codepoint <= 0x318F) || + (iter.codepoint >= 0xAC00 && iter.codepoint <= 0xD7AF)) + type = NVG_CJK_CHAR; + else + type = NVG_CHAR; break; } @@ -2643,7 +3006,7 @@ int nvgTextBreakLines(NVGcontext* ctx, const char* string, const char* end, floa } else { if (rowStart == NULL) { // Skip white space until the beginning of the line - if (type == NVG_CHAR) { + if (type == NVG_CHAR || type == NVG_CJK_CHAR) { // The current char is the row so far rowStartX = iter.x; rowStart = iter.str; @@ -2663,26 +3026,26 @@ int nvgTextBreakLines(NVGcontext* ctx, const char* string, const char* end, floa float nextWidth = iter.nextx - rowStartX; // track last non-white space character - if (type == NVG_CHAR) { + if (type == NVG_CHAR || type == NVG_CJK_CHAR) { rowEnd = iter.next; rowWidth = iter.nextx - rowStartX; rowMaxX = q.x1 - rowStartX; } // track last end of a word - if (ptype == NVG_CHAR && type == NVG_SPACE) { + if (((ptype == NVG_CHAR || ptype == NVG_CJK_CHAR) && type == NVG_SPACE) || type == NVG_CJK_CHAR) { breakEnd = iter.str; breakWidth = rowWidth; breakMaxX = rowMaxX; } // track last beginning of a word - if (ptype == NVG_SPACE && type == NVG_CHAR) { + if ((ptype == NVG_SPACE && (type == NVG_CHAR || type == NVG_CJK_CHAR)) || type == NVG_CJK_CHAR) { wordStart = iter.str; wordStartX = iter.x; wordMinX = q.x0 - rowStartX; } // Break to new line when a character is beyond break width. - if (type == NVG_CHAR && nextWidth > breakRowWidth) { + if ((type == NVG_CHAR || type == NVG_CJK_CHAR) && nextWidth > breakRowWidth) { // The run length is too long, need to break to new line. if (breakEnd == rowStart) { // The current word is longer than the row length, just break it from here. @@ -2867,4 +3230,73 @@ void nvgTextMetrics(NVGcontext* ctx, float* ascender, float* descender, float* l if (lineh != NULL) *lineh *= invscale; } +#else +// State setting +void nvgFontSize(NVGcontext* ctx, float size) +{ + NVGstate* state = nvg__getState(ctx); + state->fontSize = size; +} + +void nvgFontBlur(NVGcontext* ctx, float blur) +{ +} + +void nvgTextLetterSpacing(NVGcontext* ctx, float spacing) +{ +} + +void nvgTextLineHeight(NVGcontext* ctx, float lineHeight) +{ +} + +void nvgTextAlign(NVGcontext* ctx, int align) +{ +} + +void nvgFontFaceId(NVGcontext* ctx, int font) +{ +} + +void nvgFontFace(NVGcontext* ctx, const char* font) +{ +} + +int nvgCreateFontMem(NVGcontext* ctx, const char* name, unsigned char* data, int ndata, int freeData) +{ + return 0; +} + +int nvgFindFont(NVGcontext* ctx, const char* name) { + return 0; +} + +float nvgText(NVGcontext* ctx, float x, float y, const char* string, const char* end) { + return 0; +} + +float nvgTextBounds(NVGcontext* ctx, float x, float y, const char* string, const char* end, float* bounds) +{ + return 0; +} + +#endif/*WITH_NANOVG_GPU*/ + +NVGparams* nvgGetParams(NVGcontext* ctx) { + return &(ctx->params); +} + +int nvgCreateImageRaw(NVGcontext* ctx, int w, int h, int format, int stride, int imageFlags, const unsigned char* data) +{ + return ctx->params.renderCreateTexture(ctx->params.userPtr, format, w, h, stride, imageFlags, data); +} + +int nvgFindTextureRaw(NVGcontext* ctx, const void* data) +{ + if(ctx->params.findTexture != NULL) { + return ctx->params.findTexture(ctx->params.userPtr, data); + } + return -1; +} + // vim: ft=c nu noet ts=4 diff --git a/phonelibs/nanovg/nanovg.h b/phonelibs/nanovg/nanovg.h index bb0d3417a286ce..970b0ae4733d49 100644 --- a/phonelibs/nanovg/nanovg.h +++ b/phonelibs/nanovg/nanovg.h @@ -1,4 +1,4 @@ -// +// // Copyright (c) 2013 Mikko Mononen memon@inside.org // // This software is provided 'as-is', without any express or implied @@ -24,6 +24,7 @@ extern "C" { #endif #define NVG_PI 3.14159265358979323846264338327f +#define WITH_NANOVG_GPU #ifdef _MSC_VER #pragma warning(push) @@ -141,6 +142,7 @@ enum NVGimageFlags { NVG_IMAGE_REPEATY = 1<<2, // Repeat image in Y direction. NVG_IMAGE_FLIPY = 1<<3, // Flips (inverses) image in Y direction when rendered. NVG_IMAGE_PREMULTIPLIED = 1<<4, // Image data has premultiplied alpha. + NVG_IMAGE_NEAREST = 1<<5, // Image interpolation is Nearest instead Linear }; // Begin drawing a new frame @@ -151,7 +153,7 @@ enum NVGimageFlags { // For example, GLFW returns two dimension for an opened window: window size and // frame buffer size. In that case you would set windowWidth/Height to the window size // devicePixelRatio to: frameBufferWidth / windowWidth. -void nvgBeginFrame(NVGcontext* ctx, int windowWidth, int windowHeight, float devicePixelRatio); +void nvgBeginFrame(NVGcontext* ctx, float windowWidth, float windowHeight, float devicePixelRatio); // Cancels drawing the current frame. void nvgCancelFrame(NVGcontext* ctx); @@ -237,6 +239,9 @@ void nvgReset(NVGcontext* ctx); // // Current render style can be saved and restored using nvgSave() and nvgRestore(). +// Sets whether to draw antialias for nvgStroke() and nvgFill(). It's enabled by default. +void nvgShapeAntiAlias(NVGcontext* ctx, int enabled); + // Sets current stroke style to a solid color. void nvgStrokeColor(NVGcontext* ctx, NVGcolor color); @@ -384,6 +389,9 @@ void nvgImageSize(NVGcontext* ctx, int image, int* w, int* h); // Deletes created image. void nvgDeleteImage(NVGcontext* ctx, int image); +// Deletes font's assets for font's name. +void nvgDeleteFontByName(NVGcontext* ctx, const char* name); + // // Paints // @@ -416,6 +424,9 @@ NVGpaint nvgRadialGradient(NVGcontext* ctx, float cx, float cy, float inr, float NVGpaint nvgImagePattern(NVGcontext* ctx, float ox, float oy, float ex, float ey, float angle, int image, float alpha); +// get xfrom data +void nvgGetStateXfrom(NVGcontext* ctx, float* xform); + // // Scissoring // @@ -434,9 +445,45 @@ void nvgScissor(NVGcontext* ctx, float x, float y, float w, float h); // transform space. The resulting shape is always rectangle. void nvgIntersectScissor(NVGcontext* ctx, float x, float y, float w, float h); +/** + * @method nvgIntersectScissor_ex + * 设置一个与前一个裁剪区做交集的矩形裁剪区。 + * 输入要设置的裁剪区,做交集后把新的裁剪区返回来给用户。 + * + * @annotation ["scriptable"] + * @param {NVGcontext*} ctx nanovg的对象 + * @param {float_t} x 裁剪区x坐标。 + * @param {float_t} y 裁剪区y坐标。 + * @param {float_t} w 裁剪区宽度。 + * @param {float_t} h 裁剪区高度。 + * + * @return {ret_t} 返回RET_OK表示成功,否则表示失败。 + */ +void nvgIntersectScissor_ex(NVGcontext* ctx, float* x, float* y, float* w, float* h); + // Reset and disables scissoring. void nvgResetScissor(NVGcontext* ctx); + +/** + * @method nvgIntersectScissorForOtherRect + * 设置一个裁剪区,但是该裁剪区收到脏矩形的影响 + * 首先会把脏矩形根据当前 nanovg 的坐标系转换为新的脏矩形区域,再和裁剪区做交集,把交集设为新的裁剪区 + * + * @annotation ["scriptable"] + * @param {NVGcontext*} ctx nanovg的对象 + * @param {float_t} x 裁剪区x坐标。 + * @param {float_t} y 裁剪区y坐标。 + * @param {float_t} w 裁剪区宽度。 + * @param {float_t} h 裁剪区高度。 + * @param {float_t} dx 脏矩形x坐标。 + * @param {float_t} dy 脏矩形y坐标。 + * @param {float_t} dw 脏矩形宽度。 + * @param {float_t} dh 脏矩形高度。 + * + */ +void nvgIntersectScissorForOtherRect(NVGcontext* ctx, float x, float y, float w, float h, float dx, float dy, float dw, float dh); + // // Paths // @@ -612,8 +659,13 @@ int nvgTextBreakLines(NVGcontext* ctx, const char* string, const char* end, floa // Internal Render API // enum NVGtexture { - NVG_TEXTURE_ALPHA = 0x01, - NVG_TEXTURE_RGBA = 0x02, + NVG_TEXTURE_ALPHA = 1, + NVG_TEXTURE_RGBA = 2, + NVG_TEXTURE_BGRA = 4, + NVG_TEXTURE_RGB = 8, + NVG_TEXTURE_BGR = 16, + NVG_TEXTURE_RGB565 = 32, + NVG_TEXTURE_BGR565 = 64 }; struct NVGscissor { @@ -644,17 +696,24 @@ typedef struct NVGpath NVGpath; struct NVGparams { void* userPtr; int edgeAntiAlias; + + void (*setLineCap)(void* uptr, int lineCap); + void (*setLineJoin)(void* uptr, int lineJoin); + + int (*clearCache)(void* uptr); int (*renderCreate)(void* uptr); - int (*renderCreateTexture)(void* uptr, int type, int w, int h, int imageFlags, const unsigned char* data); + int (*findTexture)(void* uptr, const void* data); + void (*setStateXfrom)(void* uptr, float* xform); + int (*renderCreateTexture)(void* uptr, int type, int w, int h, int stride, int imageFlags, const unsigned char* data); int (*renderDeleteTexture)(void* uptr, int image); int (*renderUpdateTexture)(void* uptr, int image, int x, int y, int w, int h, const unsigned char* data); int (*renderGetTextureSize)(void* uptr, int image, int* w, int* h); - void (*renderViewport)(void* uptr, int width, int height, float devicePixelRatio); + void (*renderViewport)(void* uptr, float width, float height, float devicePixelRatio); void (*renderCancel)(void* uptr); - void (*renderFlush)(void* uptr, NVGcompositeOperationState compositeOperation); - void (*renderFill)(void* uptr, NVGpaint* paint, NVGscissor* scissor, float fringe, const float* bounds, const NVGpath* paths, int npaths); - void (*renderStroke)(void* uptr, NVGpaint* paint, NVGscissor* scissor, float fringe, float strokeWidth, const NVGpath* paths, int npaths); - void (*renderTriangles)(void* uptr, NVGpaint* paint, NVGscissor* scissor, const NVGvertex* verts, int nverts); + void (*renderFlush)(void* uptr); + void (*renderFill)(void* uptr, NVGpaint* paint, NVGcompositeOperationState compositeOperation, NVGscissor* scissor, float fringe, const float* bounds, const NVGpath* paths, int npaths); + void (*renderStroke)(void* uptr, NVGpaint* paint, NVGcompositeOperationState compositeOperation, NVGscissor* scissor, float fringe, float strokeWidth, const NVGpath* paths, int npaths); + void (*renderTriangles)(void* uptr, NVGpaint* paint, NVGcompositeOperationState compositeOperation, NVGscissor* scissor, const NVGvertex* verts, int nverts); void (*renderDelete)(void* uptr); }; typedef struct NVGparams NVGparams; @@ -674,6 +733,13 @@ void nvgDebugDumpPathCache(NVGcontext* ctx); #define NVG_NOTUSED(v) for (;;) { (void)(1 ? (void)0 : ( (void)(v) ) ); break; } +NVGparams* nvgGetParams(NVGcontext* ctx); +int nvgCreateImageRaw(NVGcontext* ctx, int w, int h, int format, int stride, int imageFlags, const unsigned char* data); + +int nvgFindTextureRaw(NVGcontext* ctx, const void* data); + +int nvgClearCache(NVGcontext* ctx); + #ifdef __cplusplus } #endif diff --git a/phonelibs/nanovg/nanovg_gl.h b/phonelibs/nanovg/nanovg_gl.h index c050067321993d..06705bdc1eb480 100644 --- a/phonelibs/nanovg/nanovg_gl.h +++ b/phonelibs/nanovg/nanovg_gl.h @@ -1,4 +1,4 @@ -// +// // Copyright (c) 2009-2013 Mikko Mononen memon@inside.org // // This software is provided 'as-is', without any express or implied @@ -25,28 +25,28 @@ extern "C" { // Create flags enum NVGcreateFlags { - // Flag indicating if geometry based anti-aliasing is used (may not be needed when using MSAA). - NVG_ANTIALIAS = 1<<0, - // Flag indicating if strokes should be drawn using stencil buffer. The rendering will be a little - // slower, but path overlaps (i.e. self-intersecting or sharp turns) will be drawn just once. - NVG_STENCIL_STROKES = 1<<1, - // Flag indicating that additional debug checks are done. - NVG_DEBUG = 1<<2, + // Flag indicating if geometry based anti-aliasing is used (may not be needed when using MSAA). + NVG_ANTIALIAS = 1 << 0, + // Flag indicating if strokes should be drawn using stencil buffer. The rendering will be a little + // slower, but path overlaps (i.e. self-intersecting or sharp turns) will be drawn just once. + NVG_STENCIL_STROKES = 1 << 1, + // Flag indicating that additional debug checks are done. + NVG_DEBUG = 1 << 2, }; #if defined NANOVG_GL2_IMPLEMENTATION -# define NANOVG_GL2 1 -# define NANOVG_GL_IMPLEMENTATION 1 +#define NANOVG_GL2 1 +#define NANOVG_GL_IMPLEMENTATION 1 #elif defined NANOVG_GL3_IMPLEMENTATION -# define NANOVG_GL3 1 -# define NANOVG_GL_IMPLEMENTATION 1 -# define NANOVG_GL_USE_UNIFORMBUFFER 1 +#define NANOVG_GL3 1 +#define NANOVG_GL_IMPLEMENTATION 1 +#define NANOVG_GL_USE_UNIFORMBUFFER 1 #elif defined NANOVG_GLES2_IMPLEMENTATION -# define NANOVG_GLES2 1 -# define NANOVG_GL_IMPLEMENTATION 1 +#define NANOVG_GLES2 1 +#define NANOVG_GL_IMPLEMENTATION 1 #elif defined NANOVG_GLES3_IMPLEMENTATION -# define NANOVG_GLES3 1 -# define NANOVG_GL_IMPLEMENTATION 1 +#define NANOVG_GLES3 1 +#define NANOVG_GL_IMPLEMENTATION 1 #endif #define NANOVG_GL_USE_STATE_FILTER (1) @@ -96,7 +96,7 @@ GLuint nvglImageHandleGLES3(NVGcontext* ctx, int image); // These are additional flags on top of NVGimageFlags. enum NVGimageFlagsGL { - NVG_IMAGE_NODELETE = 1<<16, // Do not delete GL texture handle. + NVG_IMAGE_NODELETE = 1 << 16, // Do not delete GL texture handle. }; #ifdef __cplusplus @@ -113,1385 +113,1512 @@ enum NVGimageFlagsGL { #include #include "nanovg.h" -enum GLNVGuniformLoc { - GLNVG_LOC_VIEWSIZE, - GLNVG_LOC_TEX, - GLNVG_LOC_FRAG, - GLNVG_MAX_LOCS -}; +enum GLNVGuniformLoc { GLNVG_LOC_VIEWSIZE, GLNVG_LOC_TEX, GLNVG_LOC_FRAG, GLNVG_MAX_LOCS }; enum GLNVGshaderType { - NSVG_SHADER_FILLGRAD, - NSVG_SHADER_FILLIMG, - NSVG_SHADER_SIMPLE, - NSVG_SHADER_IMG + NSVG_SHADER_FILLGRAD, + NSVG_SHADER_FILLIMG, + NSVG_SHADER_SIMPLE, + NSVG_SHADER_IMG, + NSVG_SHADER_FAST_FILLCOLOR = 5, + NSVG_SHADER_FAST_FILLIMG, + NSVG_SHADER_FILLCOLOR, + NSVG_SHADER_FAST_FILLGLYPH, }; #if NANOVG_GL_USE_UNIFORMBUFFER enum GLNVGuniformBindings { - GLNVG_FRAG_BINDING = 0, + GLNVG_FRAG_BINDING = 0, }; #endif struct GLNVGshader { - GLuint prog; - GLuint frag; - GLuint vert; - GLint loc[GLNVG_MAX_LOCS]; + GLuint prog; + GLuint frag; + GLuint vert; + GLint loc[GLNVG_MAX_LOCS]; }; typedef struct GLNVGshader GLNVGshader; struct GLNVGtexture { - int id; - GLuint tex; - int width, height; - int type; - int flags; + int id; + GLuint tex; + int width, height; + int type; + int flags; }; typedef struct GLNVGtexture GLNVGtexture; +struct GLNVGblend { + GLenum srcRGB; + GLenum dstRGB; + GLenum srcAlpha; + GLenum dstAlpha; +}; +typedef struct GLNVGblend GLNVGblend; + enum GLNVGcallType { - GLNVG_NONE = 0, - GLNVG_FILL, - GLNVG_CONVEXFILL, - GLNVG_STROKE, - GLNVG_TRIANGLES, + GLNVG_NONE = 0, + GLNVG_FILL, + GLNVG_CONVEXFILL, + GLNVG_STROKE, + GLNVG_TRIANGLES, }; struct GLNVGcall { - int type; - int image; - int pathOffset; - int pathCount; - int triangleOffset; - int triangleCount; - int uniformOffset; + int type; + int image; + int pathOffset; + int pathCount; + int triangleOffset; + int triangleCount; + int uniformOffset; + GLNVGblend blendFunc; }; typedef struct GLNVGcall GLNVGcall; struct GLNVGpath { - int fillOffset; - int fillCount; - int strokeOffset; - int strokeCount; + int fillOffset; + int fillCount; + int strokeOffset; + int strokeCount; }; typedef struct GLNVGpath GLNVGpath; struct GLNVGfragUniforms { - #if NANOVG_GL_USE_UNIFORMBUFFER - float scissorMat[12]; // matrices are actually 3 vec4s - float paintMat[12]; - struct NVGcolor innerCol; - struct NVGcolor outerCol; - float scissorExt[2]; - float scissorScale[2]; - float extent[2]; - float radius; - float feather; - float strokeMult; - float strokeThr; - int texType; - int type; - #else - // note: after modifying layout or size of uniform array, - // don't forget to also update the fragment shader source! - #define NANOVG_GL_UNIFORMARRAY_SIZE 11 - union { - struct { - float scissorMat[12]; // matrices are actually 3 vec4s - float paintMat[12]; - struct NVGcolor innerCol; - struct NVGcolor outerCol; - float scissorExt[2]; - float scissorScale[2]; - float extent[2]; - float radius; - float feather; - float strokeMult; - float strokeThr; - float texType; - float type; - }; - float uniformArray[NANOVG_GL_UNIFORMARRAY_SIZE][4]; - }; - #endif +#if NANOVG_GL_USE_UNIFORMBUFFER + float scissorMat[12]; // matrices are actually 3 vec4s + float paintMat[12]; + struct NVGcolor innerCol; + struct NVGcolor outerCol; + float scissorExt[2]; + float scissorScale[2]; + float extent[2]; + float radius; + float feather; + float strokeMult; + float strokeThr; + int texType; + int type; +#else +// note: after modifying layout or size of uniform array, +// don't forget to also update the fragment shader source! +#define NANOVG_GL_UNIFORMARRAY_SIZE 11 + union { + struct { + float scissorMat[12]; // matrices are actually 3 vec4s + float paintMat[12]; + struct NVGcolor innerCol; + struct NVGcolor outerCol; + float scissorExt[2]; + float scissorScale[2]; + float extent[2]; + float radius; + float feather; + float strokeMult; + float strokeThr; + float texType; + float type; + }; + float uniformArray[NANOVG_GL_UNIFORMARRAY_SIZE][4]; + }; +#endif }; typedef struct GLNVGfragUniforms GLNVGfragUniforms; struct GLNVGcontext { - GLNVGshader shader; - GLNVGtexture* textures; - float view[2]; - int ntextures; - int ctextures; - int textureId; - GLuint vertBuf; + GLNVGshader shader; + GLNVGtexture* textures; + float view[2]; + int ntextures; + int ctextures; + int textureId; + GLuint vertBuf; + float devicePixelRatio; #if defined NANOVG_GL3 - GLuint vertArr; + GLuint vertArr; #endif #if NANOVG_GL_USE_UNIFORMBUFFER - GLuint fragBuf; + GLuint fragBuf; +#endif + int fragSize; + int flags; + float g_xform[6]; + // Per frame buffers + GLNVGcall* calls; + int ccalls; + int ncalls; + GLNVGpath* paths; + int cpaths; + int npaths; + struct NVGvertex* verts; + int cverts; + int nverts; + unsigned char* uniforms; + int cuniforms; + int nuniforms; + +// cached state +#if NANOVG_GL_USE_STATE_FILTER + GLuint boundTexture; + GLuint stencilMask; + GLenum stencilFunc; + GLint stencilFuncRef; + GLuint stencilFuncMask; + GLNVGblend blendFunc; #endif - int fragSize; - int flags; - - // Per frame buffers - GLNVGcall* calls; - int ccalls; - int ncalls; - GLNVGpath* paths; - int cpaths; - int npaths; - struct NVGvertex* verts; - int cverts; - int nverts; - unsigned char* uniforms; - int cuniforms; - int nuniforms; - - // cached state - #if NANOVG_GL_USE_STATE_FILTER - GLuint boundTexture; - GLuint stencilMask; - GLenum stencilFunc; - GLint stencilFuncRef; - GLuint stencilFuncMask; - #endif }; typedef struct GLNVGcontext GLNVGcontext; -static int glnvg__maxi(int a, int b) { return a > b ? a : b; } +static int glnvg__maxi(int a, int b) { + return a > b ? a : b; +} #ifdef NANOVG_GLES2 -static unsigned int glnvg__nearestPow2(unsigned int num) -{ - unsigned n = num > 0 ? num - 1 : 0; - n |= n >> 1; - n |= n >> 2; - n |= n >> 4; - n |= n >> 8; - n |= n >> 16; - n++; - return n; +static unsigned int glnvg__nearestPow2(unsigned int num) { + unsigned n = num > 0 ? num - 1 : 0; + n |= n >> 1; + n |= n >> 2; + n |= n >> 4; + n |= n >> 8; + n |= n >> 16; + n++; + return n; } #endif -static void glnvg__bindTexture(GLNVGcontext* gl, GLuint tex) -{ +static void glnvg__bindTexture(GLNVGcontext* gl, GLuint tex) { #if NANOVG_GL_USE_STATE_FILTER - if (gl->boundTexture != tex) { - gl->boundTexture = tex; - glBindTexture(GL_TEXTURE_2D, tex); - } + if (gl->boundTexture != tex) { + gl->boundTexture = tex; + glBindTexture(GL_TEXTURE_2D, tex); + } #else - glBindTexture(GL_TEXTURE_2D, tex); + glBindTexture(GL_TEXTURE_2D, tex); #endif } -static void glnvg__stencilMask(GLNVGcontext* gl, GLuint mask) -{ +static void glnvg__stencilMask(GLNVGcontext* gl, GLuint mask) { #if NANOVG_GL_USE_STATE_FILTER - if (gl->stencilMask != mask) { - gl->stencilMask = mask; - glStencilMask(mask); - } + if (gl->stencilMask != mask) { + gl->stencilMask = mask; + glStencilMask(mask); + } #else - glStencilMask(mask); + glStencilMask(mask); #endif } -static void glnvg__stencilFunc(GLNVGcontext* gl, GLenum func, GLint ref, GLuint mask) -{ +static void glnvg__stencilFunc(GLNVGcontext* gl, GLenum func, GLint ref, GLuint mask) { #if NANOVG_GL_USE_STATE_FILTER - if ((gl->stencilFunc != func) || - (gl->stencilFuncRef != ref) || - (gl->stencilFuncMask != mask)) { - - gl->stencilFunc = func; - gl->stencilFuncRef = ref; - gl->stencilFuncMask = mask; - glStencilFunc(func, ref, mask); - } + if ((gl->stencilFunc != func) || (gl->stencilFuncRef != ref) || (gl->stencilFuncMask != mask)) { + gl->stencilFunc = func; + gl->stencilFuncRef = ref; + gl->stencilFuncMask = mask; + glStencilFunc(func, ref, mask); + } #else - glStencilFunc(func, ref, mask); + glStencilFunc(func, ref, mask); #endif } - -static GLNVGtexture* glnvg__allocTexture(GLNVGcontext* gl) -{ - GLNVGtexture* tex = NULL; - int i; - - for (i = 0; i < gl->ntextures; i++) { - if (gl->textures[i].id == 0) { - tex = &gl->textures[i]; - break; - } - } - if (tex == NULL) { - if (gl->ntextures+1 > gl->ctextures) { - GLNVGtexture* textures; - int ctextures = glnvg__maxi(gl->ntextures+1, 4) + gl->ctextures/2; // 1.5x Overallocate - textures = (GLNVGtexture*)realloc(gl->textures, sizeof(GLNVGtexture)*ctextures); - if (textures == NULL) return NULL; - gl->textures = textures; - gl->ctextures = ctextures; - } - tex = &gl->textures[gl->ntextures++]; - } - - memset(tex, 0, sizeof(*tex)); - tex->id = ++gl->textureId; - - return tex; +static void glnvg__blendFuncSeparate(GLNVGcontext* gl, const GLNVGblend* blend) { +#if NANOVG_GL_USE_STATE_FILTER + if ((gl->blendFunc.srcRGB != blend->srcRGB) || (gl->blendFunc.dstRGB != blend->dstRGB) || + (gl->blendFunc.srcAlpha != blend->srcAlpha) || (gl->blendFunc.dstAlpha != blend->dstAlpha)) { + gl->blendFunc = *blend; + glBlendFuncSeparate(blend->srcRGB, blend->dstRGB, blend->srcAlpha, blend->dstAlpha); + } +#else + glBlendFuncSeparate(blend->srcRGB, blend->dstRGB, blend->srcAlpha, blend->dstAlpha); +#endif } -static GLNVGtexture* glnvg__findTexture(GLNVGcontext* gl, int id) -{ - int i; - for (i = 0; i < gl->ntextures; i++) - if (gl->textures[i].id == id) - return &gl->textures[i]; - return NULL; +static GLNVGtexture* glnvg__allocTexture(GLNVGcontext* gl) { + GLNVGtexture* tex = NULL; + int i; + + for (i = 0; i < gl->ntextures; i++) { + if (gl->textures[i].id == 0) { + tex = &gl->textures[i]; + break; + } + } + if (tex == NULL) { + if (gl->ntextures + 1 > gl->ctextures) { + GLNVGtexture* textures; + int ctextures = glnvg__maxi(gl->ntextures + 1, 4) + gl->ctextures / 2; // 1.5x Overallocate + textures = (GLNVGtexture*)realloc(gl->textures, sizeof(GLNVGtexture) * ctextures); + if (textures == NULL) return NULL; + gl->textures = textures; + gl->ctextures = ctextures; + } + tex = &gl->textures[gl->ntextures++]; + } + + memset(tex, 0, sizeof(*tex)); + tex->id = ++gl->textureId; + + return tex; } -static int glnvg__deleteTexture(GLNVGcontext* gl, int id) -{ - int i; - for (i = 0; i < gl->ntextures; i++) { - if (gl->textures[i].id == id) { - if (gl->textures[i].tex != 0 && (gl->textures[i].flags & NVG_IMAGE_NODELETE) == 0) - glDeleteTextures(1, &gl->textures[i].tex); - memset(&gl->textures[i], 0, sizeof(gl->textures[i])); - return 1; - } - } - return 0; +static GLNVGtexture* glnvg__findTexture(GLNVGcontext* gl, int id) { + int i; + for (i = 0; i < gl->ntextures; i++) + if (gl->textures[i].id == id) return &gl->textures[i]; + return NULL; } -static void glnvg__dumpShaderError(GLuint shader, const char* name, const char* type) -{ - GLchar str[512+1]; - GLsizei len = 0; - glGetShaderInfoLog(shader, 512, &len, str); - if (len > 512) len = 512; - str[len] = '\0'; - printf("Shader %s/%s error:\n%s\n", name, type, str); +static int glnvg__deleteTexture(GLNVGcontext* gl, int id) { + int i; + for (i = 0; i < gl->ntextures; i++) { + if (gl->textures[i].id == id) { + if (gl->textures[i].tex != 0 && (gl->textures[i].flags & NVG_IMAGE_NODELETE) == 0) + glDeleteTextures(1, &gl->textures[i].tex); + memset(&gl->textures[i], 0, sizeof(gl->textures[i])); + return 1; + } + } + return 0; } -static void glnvg__dumpProgramError(GLuint prog, const char* name) -{ - GLchar str[512+1]; - GLsizei len = 0; - glGetProgramInfoLog(prog, 512, &len, str); - if (len > 512) len = 512; - str[len] = '\0'; - printf("Program %s error:\n%s\n", name, str); +static void glnvg__dumpShaderError(GLuint shader, const char* name, const char* type) { + GLchar str[512 + 1]; + GLsizei len = 0; + glGetShaderInfoLog(shader, 512, &len, str); + if (len > 512) len = 512; + str[len] = '\0'; + printf("Shader %s/%s error:\n%s\n", name, type, str); } -static void glnvg__checkError(GLNVGcontext* gl, const char* str) -{ - GLenum err; - if ((gl->flags & NVG_DEBUG) == 0) return; - err = glGetError(); - if (err != GL_NO_ERROR) { - printf("Error %08x after %s\n", err, str); - return; - } +static void glnvg__dumpProgramError(GLuint prog, const char* name) { + GLchar str[512 + 1]; + GLsizei len = 0; + glGetProgramInfoLog(prog, 512, &len, str); + if (len > 512) len = 512; + str[len] = '\0'; + printf("Program %s error:\n%s\n", name, str); } -static int glnvg__createShader(GLNVGshader* shader, const char* name, const char* header, const char* opts, const char* vshader, const char* fshader) -{ - GLint status; - GLuint prog, vert, frag; - const char* str[3]; - str[0] = header; - str[1] = opts != NULL ? opts : ""; - - memset(shader, 0, sizeof(*shader)); - - prog = glCreateProgram(); - vert = glCreateShader(GL_VERTEX_SHADER); - frag = glCreateShader(GL_FRAGMENT_SHADER); - str[2] = vshader; - glShaderSource(vert, 3, str, 0); - str[2] = fshader; - glShaderSource(frag, 3, str, 0); - - glCompileShader(vert); - glGetShaderiv(vert, GL_COMPILE_STATUS, &status); - if (status != GL_TRUE) { - glnvg__dumpShaderError(vert, name, "vert"); - return 0; - } - - glCompileShader(frag); - glGetShaderiv(frag, GL_COMPILE_STATUS, &status); - if (status != GL_TRUE) { - glnvg__dumpShaderError(frag, name, "frag"); - return 0; - } - - glAttachShader(prog, vert); - glAttachShader(prog, frag); - - glBindAttribLocation(prog, 0, "vertex"); - glBindAttribLocation(prog, 1, "tcoord"); - - glLinkProgram(prog); - glGetProgramiv(prog, GL_LINK_STATUS, &status); - if (status != GL_TRUE) { - glnvg__dumpProgramError(prog, name); - return 0; - } - - shader->prog = prog; - shader->vert = vert; - shader->frag = frag; +static void glnvg__checkError(GLNVGcontext* gl, const char* str) { + GLenum err; + if ((gl->flags & NVG_DEBUG) == 0) return; + err = glGetError(); + if (err != GL_NO_ERROR) { + printf("Error %08x after %s\n", err, str); + return; + } +} - return 1; +static int glnvg__createShader(GLNVGshader* shader, const char* name, const char* header, + const char* opts, const char* vshader, const char* fshader) { + GLint status; + GLuint prog, vert, frag; + const char* str[3]; + str[0] = header; + str[1] = opts != NULL ? opts : ""; + + memset(shader, 0, sizeof(*shader)); + + prog = glCreateProgram(); + vert = glCreateShader(GL_VERTEX_SHADER); + frag = glCreateShader(GL_FRAGMENT_SHADER); + str[2] = vshader; + glShaderSource(vert, 3, str, 0); + str[2] = fshader; + glShaderSource(frag, 3, str, 0); + + glCompileShader(vert); + glGetShaderiv(vert, GL_COMPILE_STATUS, &status); + if (status != GL_TRUE) { + glnvg__dumpShaderError(vert, name, "vert"); + return 0; + } + + glCompileShader(frag); + glGetShaderiv(frag, GL_COMPILE_STATUS, &status); + if (status != GL_TRUE) { + glnvg__dumpShaderError(frag, name, "frag"); + return 0; + } + + glAttachShader(prog, vert); + glAttachShader(prog, frag); + + glBindAttribLocation(prog, 0, "vertex"); + glBindAttribLocation(prog, 1, "tcoord"); + + glLinkProgram(prog); + glGetProgramiv(prog, GL_LINK_STATUS, &status); + if (status != GL_TRUE) { + glnvg__dumpProgramError(prog, name); + return 0; + } + + shader->prog = prog; + shader->vert = vert; + shader->frag = frag; + + return 1; } -static void glnvg__deleteShader(GLNVGshader* shader) -{ - if (shader->prog != 0) - glDeleteProgram(shader->prog); - if (shader->vert != 0) - glDeleteShader(shader->vert); - if (shader->frag != 0) - glDeleteShader(shader->frag); +static void glnvg__deleteShader(GLNVGshader* shader) { + if (shader->prog != 0) glDeleteProgram(shader->prog); + if (shader->vert != 0) glDeleteShader(shader->vert); + if (shader->frag != 0) glDeleteShader(shader->frag); } -static void glnvg__getUniforms(GLNVGshader* shader) -{ - shader->loc[GLNVG_LOC_VIEWSIZE] = glGetUniformLocation(shader->prog, "viewSize"); - shader->loc[GLNVG_LOC_TEX] = glGetUniformLocation(shader->prog, "tex"); +static void glnvg__getUniforms(GLNVGshader* shader) { + shader->loc[GLNVG_LOC_VIEWSIZE] = glGetUniformLocation(shader->prog, "viewSize"); + shader->loc[GLNVG_LOC_TEX] = glGetUniformLocation(shader->prog, "tex"); #if NANOVG_GL_USE_UNIFORMBUFFER - shader->loc[GLNVG_LOC_FRAG] = glGetUniformBlockIndex(shader->prog, "frag"); + shader->loc[GLNVG_LOC_FRAG] = glGetUniformBlockIndex(shader->prog, "frag"); #else - shader->loc[GLNVG_LOC_FRAG] = glGetUniformLocation(shader->prog, "frag"); + shader->loc[GLNVG_LOC_FRAG] = glGetUniformLocation(shader->prog, "frag"); #endif } -static int glnvg__renderCreate(void* uptr) -{ - GLNVGcontext* gl = (GLNVGcontext*)uptr; - int align = 4; +static int glnvg__renderCreate(void* uptr) { + GLNVGcontext* gl = (GLNVGcontext*)uptr; + int align = 4; - // TODO: mediump float may not be enough for GLES2 in iOS. - // see the following discussion: https://github.com/memononen/nanovg/issues/46 - static const char* shaderHeader = + // TODO: mediump float may not be enough for GLES2 in iOS. + // see the following discussion: https://github.com/memononen/nanovg/issues/46 + static const char* shaderHeader = #if defined NANOVG_GL2 - "#define NANOVG_GL2 1\n" + "#define NANOVG_GL2 1\n" #elif defined NANOVG_GL3 - "#version 150 core\n" - "#define NANOVG_GL3 1\n" + "#version 150 core\n" + "#define NANOVG_GL3 1\n" #elif defined NANOVG_GLES2 - "#version 100\n" - "#define NANOVG_GL2 1\n" + "#version 100\n" + "#define NANOVG_GL2 1\n" #elif defined NANOVG_GLES3 - "#version 300 es\n" - "#define NANOVG_GL3 1\n" + "#version 300 es\n" + "#define NANOVG_GL3 1\n" #endif #if NANOVG_GL_USE_UNIFORMBUFFER - "#define USE_UNIFORMBUFFER 1\n" + "#define USE_UNIFORMBUFFER 1\n" #else - "#define UNIFORMARRAY_SIZE 11\n" + "#define UNIFORMARRAY_SIZE 11\n" #endif - "\n"; - - static const char* fillVertShader = - "#ifdef NANOVG_GL3\n" - " uniform vec2 viewSize;\n" - " in vec2 vertex;\n" - " in vec2 tcoord;\n" - " out vec2 ftcoord;\n" - " out vec2 fpos;\n" - "#else\n" - " uniform vec2 viewSize;\n" - " attribute vec2 vertex;\n" - " attribute vec2 tcoord;\n" - " varying vec2 ftcoord;\n" - " varying vec2 fpos;\n" - "#endif\n" - "void main(void) {\n" - " ftcoord = tcoord;\n" - " fpos = vertex;\n" - " gl_Position = vec4(2.0*vertex.x/viewSize.x - 1.0, 1.0 - 2.0*vertex.y/viewSize.y, 0, 1);\n" - "}\n"; - - static const char* fillFragShader = - "#ifdef GL_ES\n" - "#if defined(GL_FRAGMENT_PRECISION_HIGH) || defined(NANOVG_GL3)\n" - " precision highp float;\n" - "#else\n" - " precision mediump float;\n" - "#endif\n" - "#endif\n" - "#ifdef NANOVG_GL3\n" - "#ifdef USE_UNIFORMBUFFER\n" - " layout(std140) uniform frag {\n" - " mat3 scissorMat;\n" - " mat3 paintMat;\n" - " vec4 innerCol;\n" - " vec4 outerCol;\n" - " vec2 scissorExt;\n" - " vec2 scissorScale;\n" - " vec2 extent;\n" - " float radius;\n" - " float feather;\n" - " float strokeMult;\n" - " float strokeThr;\n" - " int texType;\n" - " int type;\n" - " };\n" - "#else\n" // NANOVG_GL3 && !USE_UNIFORMBUFFER - " uniform vec4 frag[UNIFORMARRAY_SIZE];\n" - "#endif\n" - " uniform sampler2D tex;\n" - " in vec2 ftcoord;\n" - " in vec2 fpos;\n" - " out vec4 outColor;\n" - "#else\n" // !NANOVG_GL3 - " uniform vec4 frag[UNIFORMARRAY_SIZE];\n" - " uniform sampler2D tex;\n" - " varying vec2 ftcoord;\n" - " varying vec2 fpos;\n" - "#endif\n" - "#ifndef USE_UNIFORMBUFFER\n" - " #define scissorMat mat3(frag[0].xyz, frag[1].xyz, frag[2].xyz)\n" - " #define paintMat mat3(frag[3].xyz, frag[4].xyz, frag[5].xyz)\n" - " #define innerCol frag[6]\n" - " #define outerCol frag[7]\n" - " #define scissorExt frag[8].xy\n" - " #define scissorScale frag[8].zw\n" - " #define extent frag[9].xy\n" - " #define radius frag[9].z\n" - " #define feather frag[9].w\n" - " #define strokeMult frag[10].x\n" - " #define strokeThr frag[10].y\n" - " #define texType int(frag[10].z)\n" - " #define type int(frag[10].w)\n" - "#endif\n" - "\n" - "float sdroundrect(vec2 pt, vec2 ext, float rad) {\n" - " vec2 ext2 = ext - vec2(rad,rad);\n" - " vec2 d = abs(pt) - ext2;\n" - " return min(max(d.x,d.y),0.0) + length(max(d,0.0)) - rad;\n" - "}\n" - "\n" - "// Scissoring\n" - "float scissorMask(vec2 p) {\n" - " vec2 sc = (abs((scissorMat * vec3(p,1.0)).xy) - scissorExt);\n" - " sc = vec2(0.5,0.5) - sc * scissorScale;\n" - " return clamp(sc.x,0.0,1.0) * clamp(sc.y,0.0,1.0);\n" - "}\n" - "#ifdef EDGE_AA\n" - "// Stroke - from [0..1] to clipped pyramid, where the slope is 1px.\n" - "float strokeMask() {\n" - " return min(1.0, (1.0-abs(ftcoord.x*2.0-1.0))*strokeMult) * min(1.0, ftcoord.y);\n" - "}\n" - "#endif\n" - "\n" - "void main(void) {\n" - " vec4 result;\n" - " float scissor = scissorMask(fpos);\n" - "#ifdef EDGE_AA\n" - " float strokeAlpha = strokeMask();\n" - "#else\n" - " float strokeAlpha = 1.0;\n" - "#endif\n" - " if (type == 0) { // Gradient\n" - " // Calculate gradient color using box gradient\n" - " vec2 pt = (paintMat * vec3(fpos,1.0)).xy;\n" - " float d = clamp((sdroundrect(pt, extent, radius) + feather*0.5) / feather, 0.0, 1.0);\n" - " vec4 color = mix(innerCol,outerCol,d);\n" - " // Combine alpha\n" - " color *= strokeAlpha * scissor;\n" - " result = color;\n" - " } else if (type == 1) { // Image\n" - " // Calculate color fron texture\n" - " vec2 pt = (paintMat * vec3(fpos,1.0)).xy / extent;\n" - "#ifdef NANOVG_GL3\n" - " vec4 color = texture(tex, pt);\n" - "#else\n" - " vec4 color = texture2D(tex, pt);\n" - "#endif\n" - " if (texType == 1) color = vec4(color.xyz*color.w,color.w);" - " if (texType == 2) color = vec4(color.x);" - " // Apply color tint and alpha.\n" - " color *= innerCol;\n" - " // Combine alpha\n" - " color *= strokeAlpha * scissor;\n" - " result = color;\n" - " } else if (type == 2) { // Stencil fill\n" - " result = vec4(1,1,1,1);\n" - " } else if (type == 3) { // Textured tris\n" - "#ifdef NANOVG_GL3\n" - " vec4 color = texture(tex, ftcoord);\n" - "#else\n" - " vec4 color = texture2D(tex, ftcoord);\n" - "#endif\n" - " if (texType == 1) color = vec4(color.xyz*color.w,color.w);" - " if (texType == 2) color = vec4(color.x);" - " color *= scissor;\n" - " result = color * innerCol;\n" - " }\n" - "#ifdef EDGE_AA\n" - " if (strokeAlpha < strokeThr) discard;\n" - "#endif\n" - "#ifdef NANOVG_GL3\n" - " outColor = result;\n" - "#else\n" - " gl_FragColor = result;\n" - "#endif\n" - "}\n"; - - glnvg__checkError(gl, "init"); - - if (gl->flags & NVG_ANTIALIAS) { - if (glnvg__createShader(&gl->shader, "shader", shaderHeader, "#define EDGE_AA 1\n", fillVertShader, fillFragShader) == 0) - return 0; - } else { - if (glnvg__createShader(&gl->shader, "shader", shaderHeader, NULL, fillVertShader, fillFragShader) == 0) - return 0; - } - - glnvg__checkError(gl, "uniform locations"); - glnvg__getUniforms(&gl->shader); - - // Create dynamic vertex array + "\n"; + + static const char* fillVertShader = + "#ifdef NANOVG_GL3\n" + " uniform vec2 viewSize;\n" + " in vec2 vertex;\n" + " in vec2 tcoord;\n" + " out vec2 ftcoord;\n" + " out vec2 fpos;\n" + "#else\n" + " uniform vec2 viewSize;\n" + " attribute vec2 vertex;\n" + " attribute vec2 tcoord;\n" + " varying vec2 ftcoord;\n" + " varying vec2 fpos;\n" + "#endif\n" + "void main(void) {\n" + " ftcoord = tcoord;\n" + " fpos = vertex;\n" + " gl_Position = vec4(2.0*vertex.x/viewSize.x - 1.0, 1.0 - 2.0*vertex.y/viewSize.y, 0, 1);\n" + "}\n"; + + static const char* fillFragShader = + "#ifdef GL_ES\n" + "#if defined(GL_FRAGMENT_PRECISION_HIGH) || defined(NANOVG_GL3)\n" + " precision highp float;\n" + "#else\n" + " precision mediump float;\n" + "#endif\n" + "#endif\n" + "#ifdef NANOVG_GL3\n" + "#ifdef USE_UNIFORMBUFFER\n" + " layout(std140) uniform frag {\n" + " mat3 scissorMat;\n" + " mat3 paintMat;\n" + " vec4 innerCol;\n" + " vec4 outerCol;\n" + " vec2 scissorExt;\n" + " vec2 scissorScale;\n" + " vec2 extent;\n" + " float radius;\n" + " float feather;\n" + " float strokeMult;\n" + " float strokeThr;\n" + " int texType;\n" + " int type;\n" + " };\n" + "#else\n" // NANOVG_GL3 && !USE_UNIFORMBUFFER + " uniform vec4 frag[UNIFORMARRAY_SIZE];\n" + "#endif\n" + " uniform sampler2D tex;\n" + " in vec2 ftcoord;\n" + " in vec2 fpos;\n" + " out vec4 outColor;\n" + "#else\n" // !NANOVG_GL3 + " uniform vec4 frag[UNIFORMARRAY_SIZE];\n" + " uniform sampler2D tex;\n" + " varying vec2 ftcoord;\n" + " varying vec2 fpos;\n" + "#endif\n" + "#ifndef USE_UNIFORMBUFFER\n" + " #define scissorMat mat3(frag[0].xyz, frag[1].xyz, frag[2].xyz)\n" + " #define paintMat mat3(frag[3].xyz, frag[4].xyz, frag[5].xyz)\n" + " #define innerCol frag[6]\n" + " #define outerCol frag[7]\n" + " #define scissorExt frag[8].xy\n" + " #define scissorScale frag[8].zw\n" + " #define extent frag[9].xy\n" + " #define radius frag[9].z\n" + " #define feather frag[9].w\n" + " #define strokeMult frag[10].x\n" + " #define strokeThr frag[10].y\n" + " #define texType int(frag[10].z)\n" + " #define type int(frag[10].w)\n" + "#endif\n" + "\n" + "float sdroundrect(vec2 pt, vec2 ext, float rad) {\n" + " vec2 ext2 = ext - vec2(rad,rad);\n" + " vec2 d = abs(pt) - ext2;\n" + " return min(max(d.x,d.y),0.0) + length(max(d,0.0)) - rad;\n" + "}\n" + "\n" + "// Scissoring\n" + "float scissorMask(vec2 p) {\n" + " vec2 sc = (abs((scissorMat * vec3(p,1.0)).xy) - scissorExt);\n" + " sc = vec2(0.5,0.5) - sc * scissorScale;\n" + " return clamp(sc.x,0.0,1.0) * clamp(sc.y,0.0,1.0);\n" + "}\n" + "// Stroke - from [0..1] to clipped pyramid, where the slope is 1px.\n" + "float strokeMask() {\n" + " return min(1.0, (1.0-abs(ftcoord.x*2.0-1.0))*strokeMult) * min(1.0, ftcoord.y);\n" + "}\n" + "\n" + "void main(void) {\n" + " vec4 result;\n" + " float strokeAlpha;\n" + " if (type == 5) { //fast fill color\n" + " result = innerCol;\n" + " } else if (type == 6) { //fast fill image\n" + " vec2 pt = (paintMat * vec3(fpos,1.0)).xy / extent;\n" + "#ifdef NANOVG_GL3\n" + " vec4 color = texture(tex, pt);\n" + "#else\n" + " vec4 color = texture2D(tex, pt);\n" + "#endif\n" + " strokeAlpha = strokeMask();\n" + " if (strokeAlpha < strokeThr) discard;\n" + " if (texType == 1) color = vec4(color.xyz*color.w,color.w);" + " result = innerCol * color * strokeAlpha;\n" + " } else if(type == 7) { // fill color\n" + " strokeAlpha = strokeMask();\n" + " if (strokeAlpha < strokeThr) discard;\n" + " float scissor = scissorMask(fpos);\n" + " vec4 color = innerCol;\n" + " color *= strokeAlpha * scissor;\n" + " result = color;\n" + " } else if (type == 8) { // fast fill glyph\n" + "#ifdef NANOVG_GL3\n" + " vec4 color = texture(tex, ftcoord);\n" + "#else\n" + " vec4 color = texture2D(tex, ftcoord);\n" + "#endif\n" + " if(color.x < 0.02) discard;\n" + " result = innerCol * color.x;\n" + " } else if (type == 0) { // gradient\n" + " strokeAlpha = strokeMask();\n" + " if (strokeAlpha < strokeThr) discard;\n" + " // Calculate gradient color using box gradient\n" + " vec2 pt = (paintMat * vec3(fpos,1.0)).xy;\n" + " float d = clamp((sdroundrect(pt, extent, radius) + feather*0.5) / feather, 0.0, 1.0);\n" + " vec4 color = mix(innerCol,outerCol,d);\n" + " // Combine alpha\n" + " float scissor = scissorMask(fpos);\n" + " color *= strokeAlpha * scissor;\n" + " result = color;\n" + " } else if (type == 1) { // Image\n" + " strokeAlpha = strokeMask();\n" + " if (strokeAlpha < strokeThr) discard;\n" + " // Calculate color fron texture\n" + " vec2 pt = (paintMat * vec3(fpos,1.0)).xy / extent;\n" + "#ifdef NANOVG_GL3\n" + " vec4 color = texture(tex, pt);\n" + "#else\n" + " vec4 color = texture2D(tex, pt);\n" + "#endif\n" + " if (texType == 1) color = vec4(color.xyz*color.w,color.w);" + " if (texType == 2) color = vec4(color.x);" + " // Apply color tint and alpha.\n" + " color *= innerCol;\n" + " // Combine alpha\n" + " float scissor = scissorMask(fpos);\n" + " color *= strokeAlpha * scissor;\n" + " result = color;\n" + " } else if (type == 2) { // Stencil fill\n" + " result = vec4(1,1,1,1);\n" + " } else if (type == 3) { // Textured tris\n" + "#ifdef NANOVG_GL3\n" + " vec4 color = texture(tex, ftcoord);\n" + "#else\n" + " vec4 color = texture2D(tex, ftcoord);\n" + "#endif\n" + " if(color.x < 0.02) discard;\n" + " strokeAlpha = strokeMask();\n" + " if (strokeAlpha < strokeThr) discard;\n" + " float scissor = scissorMask(fpos);\n" + " color = vec4(color.x);" + " color *= scissor;\n" + " result = color * innerCol;\n" + " }\n" + "#ifdef NANOVG_GL3\n" + " outColor = result;\n" + "#else\n" + " gl_FragColor = result;\n" + "#endif\n" + "}\n"; + + glnvg__checkError(gl, "init"); + + if (gl->flags & NVG_ANTIALIAS) { + if (glnvg__createShader(&gl->shader, "shader", shaderHeader, "#define EDGE_AA 1\n", + fillVertShader, fillFragShader) == 0) + return 0; + } else { + if (glnvg__createShader(&gl->shader, "shader", shaderHeader, NULL, fillVertShader, + fillFragShader) == 0) + return 0; + } + + glnvg__checkError(gl, "uniform locations"); + glnvg__getUniforms(&gl->shader); + + // Create dynamic vertex array #if defined NANOVG_GL3 - glGenVertexArrays(1, &gl->vertArr); + glGenVertexArrays(1, &gl->vertArr); #endif - glGenBuffers(1, &gl->vertBuf); + glGenBuffers(1, &gl->vertBuf); #if NANOVG_GL_USE_UNIFORMBUFFER - // Create UBOs - glUniformBlockBinding(gl->shader.prog, gl->shader.loc[GLNVG_LOC_FRAG], GLNVG_FRAG_BINDING); - glGenBuffers(1, &gl->fragBuf); - glGetIntegerv(GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT, &align); + // Create UBOs + glUniformBlockBinding(gl->shader.prog, gl->shader.loc[GLNVG_LOC_FRAG], GLNVG_FRAG_BINDING); + glGenBuffers(1, &gl->fragBuf); + glGetIntegerv(GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT, &align); #endif - gl->fragSize = sizeof(GLNVGfragUniforms) + align - sizeof(GLNVGfragUniforms) % align; + gl->fragSize = sizeof(GLNVGfragUniforms) + align - sizeof(GLNVGfragUniforms) % align; - glnvg__checkError(gl, "create done"); + glnvg__checkError(gl, "create done"); - glFinish(); + glFinish(); - return 1; + return 1; } -static int glnvg__renderCreateTexture(void* uptr, int type, int w, int h, int imageFlags, const unsigned char* data) -{ - GLNVGcontext* gl = (GLNVGcontext*)uptr; - GLNVGtexture* tex = glnvg__allocTexture(gl); +static int glnvg__renderCreateTexture(void* uptr, int type, int w, int h, int stride, int imageFlags, + const unsigned char* data) { + GLNVGcontext* gl = (GLNVGcontext*)uptr; + GLNVGtexture* tex = glnvg__allocTexture(gl); - if (tex == NULL) return 0; + if (tex == NULL) return 0; #ifdef NANOVG_GLES2 - // Check for non-power of 2. - if (glnvg__nearestPow2(w) != (unsigned int)w || glnvg__nearestPow2(h) != (unsigned int)h) { - // No repeat - if ((imageFlags & NVG_IMAGE_REPEATX) != 0 || (imageFlags & NVG_IMAGE_REPEATY) != 0) { - printf("Repeat X/Y is not supported for non power-of-two textures (%d x %d)\n", w, h); - imageFlags &= ~(NVG_IMAGE_REPEATX | NVG_IMAGE_REPEATY); - } - // No mips. - if (imageFlags & NVG_IMAGE_GENERATE_MIPMAPS) { - printf("Mip-maps is not support for non power-of-two textures (%d x %d)\n", w, h); - imageFlags &= ~NVG_IMAGE_GENERATE_MIPMAPS; - } - } + // Check for non-power of 2. + if (glnvg__nearestPow2(w) != (unsigned int)w || glnvg__nearestPow2(h) != (unsigned int)h) { + // No repeat + if ((imageFlags & NVG_IMAGE_REPEATX) != 0 || (imageFlags & NVG_IMAGE_REPEATY) != 0) { + printf("Repeat X/Y is not supported for non power-of-two textures (%d x %d)\n", w, h); + imageFlags &= ~(NVG_IMAGE_REPEATX | NVG_IMAGE_REPEATY); + } + // No mips. + if (imageFlags & NVG_IMAGE_GENERATE_MIPMAPS) { + printf("Mip-maps is not support for non power-of-two textures (%d x %d)\n", w, h); + imageFlags &= ~NVG_IMAGE_GENERATE_MIPMAPS; + } + } #endif - glGenTextures(1, &tex->tex); - tex->width = w; - tex->height = h; - tex->type = type; - tex->flags = imageFlags; - glnvg__bindTexture(gl, tex->tex); + glGenTextures(1, &tex->tex); + tex->width = w; + tex->height = h; + tex->type = type; + tex->flags = imageFlags; + glnvg__bindTexture(gl, tex->tex); - glPixelStorei(GL_UNPACK_ALIGNMENT,1); + glPixelStorei(GL_UNPACK_ALIGNMENT, 1); #ifndef NANOVG_GLES2 - glPixelStorei(GL_UNPACK_ROW_LENGTH, tex->width); - glPixelStorei(GL_UNPACK_SKIP_PIXELS, 0); - glPixelStorei(GL_UNPACK_SKIP_ROWS, 0); + glPixelStorei(GL_UNPACK_ROW_LENGTH, tex->width); + glPixelStorei(GL_UNPACK_SKIP_PIXELS, 0); + glPixelStorei(GL_UNPACK_SKIP_ROWS, 0); #endif -#if defined (NANOVG_GL2) - // GL 1.4 and later has support for generating mipmaps using a tex parameter. - if (imageFlags & NVG_IMAGE_GENERATE_MIPMAPS) { - glTexParameteri(GL_TEXTURE_2D, GL_GENERATE_MIPMAP, GL_TRUE); - } +#if defined(NANOVG_GL2) + // GL 1.4 and later has support for generating mipmaps using a tex parameter. + if (imageFlags & NVG_IMAGE_GENERATE_MIPMAPS) { + glTexParameteri(GL_TEXTURE_2D, GL_GENERATE_MIPMAP, GL_TRUE); + } #endif - if (type == NVG_TEXTURE_RGBA) - glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, w, h, 0, GL_RGBA, GL_UNSIGNED_BYTE, data); - else -#if defined(NANOVG_GLES2) - glTexImage2D(GL_TEXTURE_2D, 0, GL_LUMINANCE, w, h, 0, GL_LUMINANCE, GL_UNSIGNED_BYTE, data); + if (type == NVG_TEXTURE_RGBA) + glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, w, h, 0, GL_RGBA, GL_UNSIGNED_BYTE, data); + else +#if defined(NANOVG_GLES2) || defined(NANOVG_GL2) + glTexImage2D(GL_TEXTURE_2D, 0, GL_LUMINANCE, w, h, 0, GL_LUMINANCE, GL_UNSIGNED_BYTE, data); #elif defined(NANOVG_GLES3) - glTexImage2D(GL_TEXTURE_2D, 0, GL_R8, w, h, 0, GL_RED, GL_UNSIGNED_BYTE, data); + glTexImage2D(GL_TEXTURE_2D, 0, GL_R8, w, h, 0, GL_RED, GL_UNSIGNED_BYTE, data); #else - glTexImage2D(GL_TEXTURE_2D, 0, GL_RED, w, h, 0, GL_RED, GL_UNSIGNED_BYTE, data); + glTexImage2D(GL_TEXTURE_2D, 0, GL_RED, w, h, 0, GL_RED, GL_UNSIGNED_BYTE, data); #endif - if (imageFlags & NVG_IMAGE_GENERATE_MIPMAPS) { - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR); - } else { - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); - } - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); - - if (imageFlags & NVG_IMAGE_REPEATX) - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); - else - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); - - if (imageFlags & NVG_IMAGE_REPEATY) - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); - else - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); - - glPixelStorei(GL_UNPACK_ALIGNMENT, 4); + if (imageFlags & NVG_IMAGE_GENERATE_MIPMAPS) { + if (imageFlags & NVG_IMAGE_NEAREST) { + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST_MIPMAP_NEAREST); + } else { + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR); + } + } else { + if (imageFlags & NVG_IMAGE_NEAREST) { + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); + } else { + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); + } + } + + if (imageFlags & NVG_IMAGE_NEAREST) { + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST); + } else { + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); + } + + if (imageFlags & NVG_IMAGE_REPEATX) + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); + else + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); + + if (imageFlags & NVG_IMAGE_REPEATY) + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); + else + glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); + + glPixelStorei(GL_UNPACK_ALIGNMENT, 4); #ifndef NANOVG_GLES2 - glPixelStorei(GL_UNPACK_ROW_LENGTH, 0); - glPixelStorei(GL_UNPACK_SKIP_PIXELS, 0); - glPixelStorei(GL_UNPACK_SKIP_ROWS, 0); + glPixelStorei(GL_UNPACK_ROW_LENGTH, 0); + glPixelStorei(GL_UNPACK_SKIP_PIXELS, 0); + glPixelStorei(GL_UNPACK_SKIP_ROWS, 0); #endif - // The new way to build mipmaps on GLES and GL3 + // The new way to build mipmaps on GLES and GL3 #if !defined(NANOVG_GL2) - if (imageFlags & NVG_IMAGE_GENERATE_MIPMAPS) { - glGenerateMipmap(GL_TEXTURE_2D); - } + if (imageFlags & NVG_IMAGE_GENERATE_MIPMAPS) { + glGenerateMipmap(GL_TEXTURE_2D); + } #endif - glnvg__checkError(gl, "create tex"); - glnvg__bindTexture(gl, 0); + glnvg__checkError(gl, "create tex"); + glnvg__bindTexture(gl, 0); - return tex->id; + return tex->id; } - -static int glnvg__renderDeleteTexture(void* uptr, int image) -{ - GLNVGcontext* gl = (GLNVGcontext*)uptr; - return glnvg__deleteTexture(gl, image); +static int glnvg__renderDeleteTexture(void* uptr, int image) { + GLNVGcontext* gl = (GLNVGcontext*)uptr; + return glnvg__deleteTexture(gl, image); } -static int glnvg__renderUpdateTexture(void* uptr, int image, int x, int y, int w, int h, const unsigned char* data) -{ - GLNVGcontext* gl = (GLNVGcontext*)uptr; - GLNVGtexture* tex = glnvg__findTexture(gl, image); +static int glnvg__renderUpdateTexture(void* uptr, int image, int x, int y, int w, int h, + const unsigned char* data) { + GLNVGcontext* gl = (GLNVGcontext*)uptr; + GLNVGtexture* tex = glnvg__findTexture(gl, image); - if (tex == NULL) return 0; - glnvg__bindTexture(gl, tex->tex); + if (tex == NULL) return 0; + glnvg__bindTexture(gl, tex->tex); - glPixelStorei(GL_UNPACK_ALIGNMENT,1); + glPixelStorei(GL_UNPACK_ALIGNMENT, 1); #ifndef NANOVG_GLES2 - glPixelStorei(GL_UNPACK_ROW_LENGTH, tex->width); - glPixelStorei(GL_UNPACK_SKIP_PIXELS, x); - glPixelStorei(GL_UNPACK_SKIP_ROWS, y); + glPixelStorei(GL_UNPACK_ROW_LENGTH, tex->width); + glPixelStorei(GL_UNPACK_SKIP_PIXELS, x); + glPixelStorei(GL_UNPACK_SKIP_ROWS, y); #else - // No support for all of skip, need to update a whole row at a time. - if (tex->type == NVG_TEXTURE_RGBA) - data += y*tex->width*4; - else - data += y*tex->width; - x = 0; - w = tex->width; + // No support for all of skip, need to update a whole row at a time. + if (tex->type == NVG_TEXTURE_RGBA) + data += y * tex->width * 4; + else + data += y * tex->width; + x = 0; + w = tex->width; #endif - if (tex->type == NVG_TEXTURE_RGBA) - glTexSubImage2D(GL_TEXTURE_2D, 0, x,y, w,h, GL_RGBA, GL_UNSIGNED_BYTE, data); - else -#ifdef NANOVG_GLES2 - glTexSubImage2D(GL_TEXTURE_2D, 0, x,y, w,h, GL_LUMINANCE, GL_UNSIGNED_BYTE, data); + if (tex->type == NVG_TEXTURE_RGBA) + glTexSubImage2D(GL_TEXTURE_2D, 0, x, y, w, h, GL_RGBA, GL_UNSIGNED_BYTE, data); + else +#if defined(NANOVG_GLES2) || defined(NANOVG_GL2) + glTexSubImage2D(GL_TEXTURE_2D, 0, x, y, w, h, GL_LUMINANCE, GL_UNSIGNED_BYTE, data); #else - glTexSubImage2D(GL_TEXTURE_2D, 0, x,y, w,h, GL_RED, GL_UNSIGNED_BYTE, data); + glTexSubImage2D(GL_TEXTURE_2D, 0, x, y, w, h, GL_RED, GL_UNSIGNED_BYTE, data); #endif - glPixelStorei(GL_UNPACK_ALIGNMENT, 4); + glPixelStorei(GL_UNPACK_ALIGNMENT, 4); #ifndef NANOVG_GLES2 - glPixelStorei(GL_UNPACK_ROW_LENGTH, 0); - glPixelStorei(GL_UNPACK_SKIP_PIXELS, 0); - glPixelStorei(GL_UNPACK_SKIP_ROWS, 0); + glPixelStorei(GL_UNPACK_ROW_LENGTH, 0); + glPixelStorei(GL_UNPACK_SKIP_PIXELS, 0); + glPixelStorei(GL_UNPACK_SKIP_ROWS, 0); #endif - glnvg__bindTexture(gl, 0); + glnvg__bindTexture(gl, 0); - return 1; + return 1; } -static int glnvg__renderGetTextureSize(void* uptr, int image, int* w, int* h) -{ - GLNVGcontext* gl = (GLNVGcontext*)uptr; - GLNVGtexture* tex = glnvg__findTexture(gl, image); - if (tex == NULL) return 0; - *w = tex->width; - *h = tex->height; - return 1; +static int glnvg__renderGetTextureSize(void* uptr, int image, int* w, int* h) { + GLNVGcontext* gl = (GLNVGcontext*)uptr; + GLNVGtexture* tex = glnvg__findTexture(gl, image); + if (tex == NULL) return 0; + *w = tex->width; + *h = tex->height; + return 1; } -static void glnvg__xformToMat3x4(float* m3, float* t) -{ - m3[0] = t[0]; - m3[1] = t[1]; - m3[2] = 0.0f; - m3[3] = 0.0f; - m3[4] = t[2]; - m3[5] = t[3]; - m3[6] = 0.0f; - m3[7] = 0.0f; - m3[8] = t[4]; - m3[9] = t[5]; - m3[10] = 1.0f; - m3[11] = 0.0f; +static void glnvg__xformToMat3x4(float* m3, float* t) { + m3[0] = t[0]; + m3[1] = t[1]; + m3[2] = 0.0f; + m3[3] = 0.0f; + m3[4] = t[2]; + m3[5] = t[3]; + m3[6] = 0.0f; + m3[7] = 0.0f; + m3[8] = t[4]; + m3[9] = t[5]; + m3[10] = 1.0f; + m3[11] = 0.0f; } -static NVGcolor glnvg__premulColor(NVGcolor c) -{ - c.r *= c.a; - c.g *= c.a; - c.b *= c.a; - return c; +static NVGcolor glnvg__premulColor(NVGcolor c) { + c.r *= c.a; + c.g *= c.a; + c.b *= c.a; + return c; } static int glnvg__convertPaint(GLNVGcontext* gl, GLNVGfragUniforms* frag, NVGpaint* paint, - NVGscissor* scissor, float width, float fringe, float strokeThr) -{ - GLNVGtexture* tex = NULL; - float invxform[6]; - - memset(frag, 0, sizeof(*frag)); - - frag->innerCol = glnvg__premulColor(paint->innerColor); - frag->outerCol = glnvg__premulColor(paint->outerColor); - - if (scissor->extent[0] < -0.5f || scissor->extent[1] < -0.5f) { - memset(frag->scissorMat, 0, sizeof(frag->scissorMat)); - frag->scissorExt[0] = 1.0f; - frag->scissorExt[1] = 1.0f; - frag->scissorScale[0] = 1.0f; - frag->scissorScale[1] = 1.0f; - } else { - nvgTransformInverse(invxform, scissor->xform); - glnvg__xformToMat3x4(frag->scissorMat, invxform); - frag->scissorExt[0] = scissor->extent[0]; - frag->scissorExt[1] = scissor->extent[1]; - frag->scissorScale[0] = sqrtf(scissor->xform[0]*scissor->xform[0] + scissor->xform[2]*scissor->xform[2]) / fringe; - frag->scissorScale[1] = sqrtf(scissor->xform[1]*scissor->xform[1] + scissor->xform[3]*scissor->xform[3]) / fringe; - } + NVGscissor* scissor, float width, float fringe, float strokeThr) { + GLNVGtexture* tex = NULL; + float invxform[6]; + + memset(frag, 0, sizeof(*frag)); + + frag->innerCol = glnvg__premulColor(paint->innerColor); + frag->outerCol = glnvg__premulColor(paint->outerColor); + + if (scissor->extent[0] < -0.5f || scissor->extent[1] < -0.5f) { + memset(frag->scissorMat, 0, sizeof(frag->scissorMat)); + frag->scissorExt[0] = 1.0f; + frag->scissorExt[1] = 1.0f; + frag->scissorScale[0] = 1.0f; + frag->scissorScale[1] = 1.0f; + } else { + nvgTransformInverse(invxform, scissor->xform); + glnvg__xformToMat3x4(frag->scissorMat, invxform); + frag->scissorExt[0] = scissor->extent[0]; + frag->scissorExt[1] = scissor->extent[1]; + frag->scissorScale[0] = + sqrtf(scissor->xform[0] * scissor->xform[0] + scissor->xform[2] * scissor->xform[2]) / + fringe; + frag->scissorScale[1] = + sqrtf(scissor->xform[1] * scissor->xform[1] + scissor->xform[3] * scissor->xform[3]) / + fringe; + } + + memcpy(frag->extent, paint->extent, sizeof(frag->extent)); + frag->strokeMult = (width * 0.5f + fringe * 0.5f) / fringe; + frag->strokeThr = strokeThr; + + if (paint->image != 0) { + tex = glnvg__findTexture(gl, paint->image); + if (tex == NULL) return 0; + if ((tex->flags & NVG_IMAGE_FLIPY) != 0) { + float m1[6], m2[6]; + nvgTransformTranslate(m1, 0.0f, frag->extent[1] * 0.5f); + nvgTransformMultiply(m1, paint->xform); + nvgTransformScale(m2, 1.0f, -1.0f); + nvgTransformMultiply(m2, m1); + nvgTransformTranslate(m1, 0.0f, -frag->extent[1] * 0.5f); + nvgTransformMultiply(m1, m2); + nvgTransformInverse(invxform, m1); + } else { + nvgTransformInverse(invxform, paint->xform); + } + frag->type = NSVG_SHADER_FILLIMG; - memcpy(frag->extent, paint->extent, sizeof(frag->extent)); - frag->strokeMult = (width*0.5f + fringe*0.5f) / fringe; - frag->strokeThr = strokeThr; - - if (paint->image != 0) { - tex = glnvg__findTexture(gl, paint->image); - if (tex == NULL) return 0; - if ((tex->flags & NVG_IMAGE_FLIPY) != 0) { - float m1[6], m2[6]; - nvgTransformTranslate(m1, 0.0f, frag->extent[1] * 0.5f); - nvgTransformMultiply(m1, paint->xform); - nvgTransformScale(m2, 1.0f, -1.0f); - nvgTransformMultiply(m2, m1); - nvgTransformTranslate(m1, 0.0f, -frag->extent[1] * 0.5f); - nvgTransformMultiply(m1, m2); - nvgTransformInverse(invxform, m1); - } else { - nvgTransformInverse(invxform, paint->xform); - } - frag->type = NSVG_SHADER_FILLIMG; - - if (tex->type == NVG_TEXTURE_RGBA) - frag->texType = (tex->flags & NVG_IMAGE_PREMULTIPLIED) ? 0 : 1; - else - frag->texType = 2; -// printf("frag->texType = %d\n", frag->texType); - } else { - frag->type = NSVG_SHADER_FILLGRAD; - frag->radius = paint->radius; - frag->feather = paint->feather; - nvgTransformInverse(invxform, paint->xform); - } +#if NANOVG_GL_USE_UNIFORMBUFFER + if (tex->type == NVG_TEXTURE_RGBA) + frag->texType = (tex->flags & NVG_IMAGE_PREMULTIPLIED) ? 0 : 1; + else + frag->texType = 2; +#else + if (tex->type == NVG_TEXTURE_RGBA) + frag->texType = (tex->flags & NVG_IMAGE_PREMULTIPLIED) ? 0.0f : 1.0f; + else + frag->texType = 2.0f; +#endif + // printf("frag->texType = %d\n", frag->texType); + } else { + frag->type = NSVG_SHADER_FILLGRAD; + frag->radius = paint->radius; + frag->feather = paint->feather; + nvgTransformInverse(invxform, paint->xform); + } - glnvg__xformToMat3x4(frag->paintMat, invxform); + glnvg__xformToMat3x4(frag->paintMat, invxform); - return 1; + return 1; } static GLNVGfragUniforms* nvg__fragUniformPtr(GLNVGcontext* gl, int i); -static void glnvg__setUniforms(GLNVGcontext* gl, int uniformOffset, int image) -{ +static void glnvg__setUniforms(GLNVGcontext* gl, int uniformOffset, int image) { #if NANOVG_GL_USE_UNIFORMBUFFER - glBindBufferRange(GL_UNIFORM_BUFFER, GLNVG_FRAG_BINDING, gl->fragBuf, uniformOffset, sizeof(GLNVGfragUniforms)); + glBindBufferRange(GL_UNIFORM_BUFFER, GLNVG_FRAG_BINDING, gl->fragBuf, uniformOffset, + sizeof(GLNVGfragUniforms)); #else - GLNVGfragUniforms* frag = nvg__fragUniformPtr(gl, uniformOffset); - glUniform4fv(gl->shader.loc[GLNVG_LOC_FRAG], NANOVG_GL_UNIFORMARRAY_SIZE, &(frag->uniformArray[0][0])); + GLNVGfragUniforms* frag = nvg__fragUniformPtr(gl, uniformOffset); + glUniform4fv(gl->shader.loc[GLNVG_LOC_FRAG], NANOVG_GL_UNIFORMARRAY_SIZE, + &(frag->uniformArray[0][0])); #endif - if (image != 0) { - GLNVGtexture* tex = glnvg__findTexture(gl, image); - glnvg__bindTexture(gl, tex != NULL ? tex->tex : 0); - glnvg__checkError(gl, "tex paint tex"); - } else { - glnvg__bindTexture(gl, 0); - } + if (image != 0) { + GLNVGtexture* tex = glnvg__findTexture(gl, image); + glnvg__bindTexture(gl, tex != NULL ? tex->tex : 0); + glnvg__checkError(gl, "tex paint tex"); + } else { + glnvg__bindTexture(gl, 0); + } } -static void glnvg__renderViewport(void* uptr, int width, int height, float devicePixelRatio) -{ - GLNVGcontext* gl = (GLNVGcontext*)uptr; - gl->view[0] = (float)width; - gl->view[1] = (float)height; +static void glnvg__renderViewport(void* uptr, float width, float height, float devicePixelRatio) { + //NVG_NOTUSED(devicePixelRatio); + GLNVGcontext* gl = (GLNVGcontext*)uptr; + gl->view[0] = width; + gl->view[1] = height; + gl->devicePixelRatio = devicePixelRatio; } -static void glnvg__fill(GLNVGcontext* gl, GLNVGcall* call) -{ - GLNVGpath* paths = &gl->paths[call->pathOffset]; - int i, npaths = call->pathCount; - - // Draw shapes - glEnable(GL_STENCIL_TEST); - glnvg__stencilMask(gl, 0xff); - glnvg__stencilFunc(gl, GL_ALWAYS, 0, 0xff); - glColorMask(GL_FALSE, GL_FALSE, GL_FALSE, GL_FALSE); - - // set bindpoint for solid loc - glnvg__setUniforms(gl, call->uniformOffset, 0); - glnvg__checkError(gl, "fill simple"); - - glStencilOpSeparate(GL_FRONT, GL_KEEP, GL_KEEP, GL_INCR_WRAP); - glStencilOpSeparate(GL_BACK, GL_KEEP, GL_KEEP, GL_DECR_WRAP); - glDisable(GL_CULL_FACE); - for (i = 0; i < npaths; i++) - glDrawArrays(GL_TRIANGLE_FAN, paths[i].fillOffset, paths[i].fillCount); - glEnable(GL_CULL_FACE); - - // Draw anti-aliased pixels - glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE); - - glnvg__setUniforms(gl, call->uniformOffset + gl->fragSize, call->image); - glnvg__checkError(gl, "fill fill"); - - if (gl->flags & NVG_ANTIALIAS) { - glnvg__stencilFunc(gl, GL_EQUAL, 0x00, 0xff); - glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP); - // Draw fringes - for (i = 0; i < npaths; i++) - glDrawArrays(GL_TRIANGLE_STRIP, paths[i].strokeOffset, paths[i].strokeCount); - } +static void glnvg__fill(GLNVGcontext* gl, GLNVGcall* call) { + GLNVGpath* paths = &gl->paths[call->pathOffset]; + int i, npaths = call->pathCount; + + // Draw shapes + glEnable(GL_STENCIL_TEST); + glnvg__stencilMask(gl, 0xff); + glnvg__stencilFunc(gl, GL_ALWAYS, 0, 0xff); + glColorMask(GL_FALSE, GL_FALSE, GL_FALSE, GL_FALSE); + + // set bindpoint for solid loc + glnvg__setUniforms(gl, call->uniformOffset, 0); + glnvg__checkError(gl, "fill simple"); + + glStencilOpSeparate(GL_FRONT, GL_KEEP, GL_KEEP, GL_INCR_WRAP); + glStencilOpSeparate(GL_BACK, GL_KEEP, GL_KEEP, GL_DECR_WRAP); + glDisable(GL_CULL_FACE); + for (i = 0; i < npaths; i++) + glDrawArrays(GL_TRIANGLE_FAN, paths[i].fillOffset, paths[i].fillCount); + glEnable(GL_CULL_FACE); + + // Draw anti-aliased pixels + glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE); + + glnvg__setUniforms(gl, call->uniformOffset + gl->fragSize, call->image); + glnvg__checkError(gl, "fill fill"); + + if (gl->flags & NVG_ANTIALIAS) { + glnvg__stencilFunc(gl, GL_EQUAL, 0x00, 0xff); + glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP); + // Draw fringes + for (i = 0; i < npaths; i++) + glDrawArrays(GL_TRIANGLE_STRIP, paths[i].strokeOffset, paths[i].strokeCount); + } + + // Draw fill + glnvg__stencilFunc(gl, GL_NOTEQUAL, 0x0, 0xff); + glStencilOp(GL_ZERO, GL_ZERO, GL_ZERO); + glDrawArrays(GL_TRIANGLE_STRIP, call->triangleOffset, call->triangleCount); + + glDisable(GL_STENCIL_TEST); +} - // Draw fill - glnvg__stencilFunc(gl, GL_NOTEQUAL, 0x0, 0xff); - glStencilOp(GL_ZERO, GL_ZERO, GL_ZERO); - glDrawArrays(GL_TRIANGLES, call->triangleOffset, call->triangleCount); +static void glnvg__convexFill(GLNVGcontext* gl, GLNVGcall* call) { + GLNVGpath* paths = &gl->paths[call->pathOffset]; + int i, npaths = call->pathCount; - glDisable(GL_STENCIL_TEST); -} + glnvg__setUniforms(gl, call->uniformOffset, call->image); + glnvg__checkError(gl, "convex fill"); -static void glnvg__convexFill(GLNVGcontext* gl, GLNVGcall* call) -{ - GLNVGpath* paths = &gl->paths[call->pathOffset]; - int i, npaths = call->pathCount; - - glnvg__setUniforms(gl, call->uniformOffset, call->image); - glnvg__checkError(gl, "convex fill"); - - for (i = 0; i < npaths; i++) - glDrawArrays(GL_TRIANGLE_FAN, paths[i].fillOffset, paths[i].fillCount); - if (gl->flags & NVG_ANTIALIAS) { - // Draw fringes - for (i = 0; i < npaths; i++) - glDrawArrays(GL_TRIANGLE_STRIP, paths[i].strokeOffset, paths[i].strokeCount); - } + for (i = 0; i < npaths; i++) { + glDrawArrays(GL_TRIANGLE_FAN, paths[i].fillOffset, paths[i].fillCount); + // Draw fringes + if (paths[i].strokeCount > 0) { + glDrawArrays(GL_TRIANGLE_STRIP, paths[i].strokeOffset, paths[i].strokeCount); + } + } } -static void glnvg__stroke(GLNVGcontext* gl, GLNVGcall* call) -{ - GLNVGpath* paths = &gl->paths[call->pathOffset]; - int npaths = call->pathCount, i; - - if (gl->flags & NVG_STENCIL_STROKES) { - - glEnable(GL_STENCIL_TEST); - glnvg__stencilMask(gl, 0xff); - - // Fill the stroke base without overlap - glnvg__stencilFunc(gl, GL_EQUAL, 0x0, 0xff); - glStencilOp(GL_KEEP, GL_KEEP, GL_INCR); - glnvg__setUniforms(gl, call->uniformOffset + gl->fragSize, call->image); - glnvg__checkError(gl, "stroke fill 0"); - for (i = 0; i < npaths; i++) - glDrawArrays(GL_TRIANGLE_STRIP, paths[i].strokeOffset, paths[i].strokeCount); - - // Draw anti-aliased pixels. - glnvg__setUniforms(gl, call->uniformOffset, call->image); - glnvg__stencilFunc(gl, GL_EQUAL, 0x00, 0xff); - glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP); - for (i = 0; i < npaths; i++) - glDrawArrays(GL_TRIANGLE_STRIP, paths[i].strokeOffset, paths[i].strokeCount); - - // Clear stencil buffer. - glColorMask(GL_FALSE, GL_FALSE, GL_FALSE, GL_FALSE); - glnvg__stencilFunc(gl, GL_ALWAYS, 0x0, 0xff); - glStencilOp(GL_ZERO, GL_ZERO, GL_ZERO); - glnvg__checkError(gl, "stroke fill 1"); - for (i = 0; i < npaths; i++) - glDrawArrays(GL_TRIANGLE_STRIP, paths[i].strokeOffset, paths[i].strokeCount); - glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE); - - glDisable(GL_STENCIL_TEST); - -// glnvg__convertPaint(gl, nvg__fragUniformPtr(gl, call->uniformOffset + gl->fragSize), paint, scissor, strokeWidth, fringe, 1.0f - 0.5f/255.0f); - - } else { - glnvg__setUniforms(gl, call->uniformOffset, call->image); - glnvg__checkError(gl, "stroke fill"); - // Draw Strokes - for (i = 0; i < npaths; i++) - glDrawArrays(GL_TRIANGLE_STRIP, paths[i].strokeOffset, paths[i].strokeCount); - } +static void glnvg__stroke(GLNVGcontext* gl, GLNVGcall* call) { + GLNVGpath* paths = &gl->paths[call->pathOffset]; + int npaths = call->pathCount, i; + + if (gl->flags & NVG_STENCIL_STROKES) { + glEnable(GL_STENCIL_TEST); + glnvg__stencilMask(gl, 0xff); + + // Fill the stroke base without overlap + glnvg__stencilFunc(gl, GL_EQUAL, 0x0, 0xff); + glStencilOp(GL_KEEP, GL_KEEP, GL_INCR); + glnvg__setUniforms(gl, call->uniformOffset + gl->fragSize, call->image); + glnvg__checkError(gl, "stroke fill 0"); + for (i = 0; i < npaths; i++) + glDrawArrays(GL_TRIANGLE_STRIP, paths[i].strokeOffset, paths[i].strokeCount); + + // Draw anti-aliased pixels. + glnvg__setUniforms(gl, call->uniformOffset, call->image); + glnvg__stencilFunc(gl, GL_EQUAL, 0x00, 0xff); + glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP); + for (i = 0; i < npaths; i++) + glDrawArrays(GL_TRIANGLE_STRIP, paths[i].strokeOffset, paths[i].strokeCount); + + // Clear stencil buffer. + glColorMask(GL_FALSE, GL_FALSE, GL_FALSE, GL_FALSE); + glnvg__stencilFunc(gl, GL_ALWAYS, 0x0, 0xff); + glStencilOp(GL_ZERO, GL_ZERO, GL_ZERO); + glnvg__checkError(gl, "stroke fill 1"); + for (i = 0; i < npaths; i++) + glDrawArrays(GL_TRIANGLE_STRIP, paths[i].strokeOffset, paths[i].strokeCount); + glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE); + + glDisable(GL_STENCIL_TEST); + + // glnvg__convertPaint(gl, nvg__fragUniformPtr(gl, call->uniformOffset + gl->fragSize), + // paint, scissor, strokeWidth, fringe, 1.0f - 0.5f/255.0f); + + } else { + glnvg__setUniforms(gl, call->uniformOffset, call->image); + glnvg__checkError(gl, "stroke fill"); + // Draw Strokes + for (i = 0; i < npaths; i++) + glDrawArrays(GL_TRIANGLE_STRIP, paths[i].strokeOffset, paths[i].strokeCount); + } } -static void glnvg__triangles(GLNVGcontext* gl, GLNVGcall* call) -{ - glnvg__setUniforms(gl, call->uniformOffset, call->image); - glnvg__checkError(gl, "triangles fill"); +static void glnvg__triangles(GLNVGcontext* gl, GLNVGcall* call) { + glnvg__setUniforms(gl, call->uniformOffset, call->image); + glnvg__checkError(gl, "triangles fill"); - glDrawArrays(GL_TRIANGLES, call->triangleOffset, call->triangleCount); + glDrawArrays(GL_TRIANGLES, call->triangleOffset, call->triangleCount); } static void glnvg__renderCancel(void* uptr) { - GLNVGcontext* gl = (GLNVGcontext*)uptr; - gl->nverts = 0; - gl->npaths = 0; - gl->ncalls = 0; - gl->nuniforms = 0; + GLNVGcontext* gl = (GLNVGcontext*)uptr; + gl->nverts = 0; + gl->npaths = 0; + gl->ncalls = 0; + gl->nuniforms = 0; } -static GLenum glnvg_convertBlendFuncFactor(int factor) -{ - if (factor == NVG_ZERO) - return GL_ZERO; - if (factor == NVG_ONE) - return GL_ONE; - if (factor == NVG_SRC_COLOR) - return GL_SRC_COLOR; - if (factor == NVG_ONE_MINUS_SRC_COLOR) - return GL_ONE_MINUS_SRC_COLOR; - if (factor == NVG_DST_COLOR) - return GL_DST_COLOR; - if (factor == NVG_ONE_MINUS_DST_COLOR) - return GL_ONE_MINUS_DST_COLOR; - if (factor == NVG_SRC_ALPHA) - return GL_SRC_ALPHA; - if (factor == NVG_ONE_MINUS_SRC_ALPHA) - return GL_ONE_MINUS_SRC_ALPHA; - if (factor == NVG_DST_ALPHA) - return GL_DST_ALPHA; - if (factor == NVG_ONE_MINUS_DST_ALPHA) - return GL_ONE_MINUS_DST_ALPHA; - if (factor == NVG_SRC_ALPHA_SATURATE) - return GL_SRC_ALPHA_SATURATE; - return GL_INVALID_ENUM; +static GLenum glnvg_convertBlendFuncFactor(int factor) { + if (factor == NVG_ZERO) return GL_ZERO; + if (factor == NVG_ONE) return GL_ONE; + if (factor == NVG_SRC_COLOR) return GL_SRC_COLOR; + if (factor == NVG_ONE_MINUS_SRC_COLOR) return GL_ONE_MINUS_SRC_COLOR; + if (factor == NVG_DST_COLOR) return GL_DST_COLOR; + if (factor == NVG_ONE_MINUS_DST_COLOR) return GL_ONE_MINUS_DST_COLOR; + if (factor == NVG_SRC_ALPHA) return GL_SRC_ALPHA; + if (factor == NVG_ONE_MINUS_SRC_ALPHA) return GL_ONE_MINUS_SRC_ALPHA; + if (factor == NVG_DST_ALPHA) return GL_DST_ALPHA; + if (factor == NVG_ONE_MINUS_DST_ALPHA) return GL_ONE_MINUS_DST_ALPHA; + if (factor == NVG_SRC_ALPHA_SATURATE) return GL_SRC_ALPHA_SATURATE; + return GL_INVALID_ENUM; } -static void glnvg__blendCompositeOperation(NVGcompositeOperationState op) -{ - GLenum srcRGB = glnvg_convertBlendFuncFactor(op.srcRGB); - GLenum dstRGB = glnvg_convertBlendFuncFactor(op.dstRGB); - GLenum srcAlpha = glnvg_convertBlendFuncFactor(op.srcAlpha); - GLenum dstAlpha = glnvg_convertBlendFuncFactor(op.dstAlpha); - if (srcRGB == GL_INVALID_ENUM || dstRGB == GL_INVALID_ENUM || srcAlpha == GL_INVALID_ENUM || dstAlpha == GL_INVALID_ENUM) - glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA); - else - glBlendFuncSeparate(srcRGB, dstRGB, srcAlpha, dstAlpha); +static GLNVGblend glnvg__blendCompositeOperation(NVGcompositeOperationState op) { + GLNVGblend blend; + blend.srcRGB = glnvg_convertBlendFuncFactor(op.srcRGB); + blend.dstRGB = glnvg_convertBlendFuncFactor(op.dstRGB); + blend.srcAlpha = glnvg_convertBlendFuncFactor(op.srcAlpha); + blend.dstAlpha = glnvg_convertBlendFuncFactor(op.dstAlpha); + if (blend.srcRGB == GL_INVALID_ENUM || blend.dstRGB == GL_INVALID_ENUM || + blend.srcAlpha == GL_INVALID_ENUM || blend.dstAlpha == GL_INVALID_ENUM) { + blend.srcRGB = GL_ONE; + blend.dstRGB = GL_ONE_MINUS_SRC_ALPHA; + blend.srcAlpha = GL_ONE; + blend.dstAlpha = GL_ONE_MINUS_SRC_ALPHA; + } + return blend; } -static void glnvg__renderFlush(void* uptr, NVGcompositeOperationState compositeOperation) -{ - GLNVGcontext* gl = (GLNVGcontext*)uptr; - int i; - - if (gl->ncalls > 0) { - - // Setup require GL state. - glUseProgram(gl->shader.prog); - - glnvg__blendCompositeOperation(compositeOperation); - glEnable(GL_CULL_FACE); - glCullFace(GL_BACK); - glFrontFace(GL_CCW); - glEnable(GL_BLEND); - glDisable(GL_DEPTH_TEST); - glDisable(GL_SCISSOR_TEST); - glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE); - glStencilMask(0xffffffff); - glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP); - glStencilFunc(GL_ALWAYS, 0, 0xffffffff); - glActiveTexture(GL_TEXTURE0); - glBindTexture(GL_TEXTURE_2D, 0); - #if NANOVG_GL_USE_STATE_FILTER - gl->boundTexture = 0; - gl->stencilMask = 0xffffffff; - gl->stencilFunc = GL_ALWAYS; - gl->stencilFuncRef = 0; - gl->stencilFuncMask = 0xffffffff; - #endif +static void glnvg__renderFlush(void* uptr) { + GLNVGcontext* gl = (GLNVGcontext*)uptr; + int i; + + if (gl->ncalls > 0) { + // Setup require GL state. + glUseProgram(gl->shader.prog); + + glEnable(GL_CULL_FACE); + glCullFace(GL_BACK); + glFrontFace(GL_CCW); + glEnable(GL_BLEND); + glDisable(GL_DEPTH_TEST); + glDisable(GL_SCISSOR_TEST); + glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE); + glStencilMask(0xffffffff); + glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP); + glStencilFunc(GL_ALWAYS, 0, 0xffffffff); + glActiveTexture(GL_TEXTURE0); + glBindTexture(GL_TEXTURE_2D, 0); +#if NANOVG_GL_USE_STATE_FILTER + gl->boundTexture = 0; + gl->stencilMask = 0xffffffff; + gl->stencilFunc = GL_ALWAYS; + gl->stencilFuncRef = 0; + gl->stencilFuncMask = 0xffffffff; + gl->blendFunc.srcRGB = GL_INVALID_ENUM; + gl->blendFunc.srcAlpha = GL_INVALID_ENUM; + gl->blendFunc.dstRGB = GL_INVALID_ENUM; + gl->blendFunc.dstAlpha = GL_INVALID_ENUM; +#endif #if NANOVG_GL_USE_UNIFORMBUFFER - // Upload ubo for frag shaders - glBindBuffer(GL_UNIFORM_BUFFER, gl->fragBuf); - glBufferData(GL_UNIFORM_BUFFER, gl->nuniforms * gl->fragSize, gl->uniforms, GL_STREAM_DRAW); + // Upload ubo for frag shaders + glBindBuffer(GL_UNIFORM_BUFFER, gl->fragBuf); + glBufferData(GL_UNIFORM_BUFFER, gl->nuniforms * gl->fragSize, gl->uniforms, GL_STREAM_DRAW); #endif - // Upload vertex data + // Upload vertex data #if defined NANOVG_GL3 - glBindVertexArray(gl->vertArr); + glBindVertexArray(gl->vertArr); #endif - glBindBuffer(GL_ARRAY_BUFFER, gl->vertBuf); - glBufferData(GL_ARRAY_BUFFER, gl->nverts * sizeof(NVGvertex), gl->verts, GL_STREAM_DRAW); - glEnableVertexAttribArray(0); - glEnableVertexAttribArray(1); - glVertexAttribPointer(0, 2, GL_FLOAT, GL_FALSE, sizeof(NVGvertex), (const GLvoid*)(size_t)0); - glVertexAttribPointer(1, 2, GL_FLOAT, GL_FALSE, sizeof(NVGvertex), (const GLvoid*)(0 + 2*sizeof(float))); - - // Set view and texture just once per frame. - glUniform1i(gl->shader.loc[GLNVG_LOC_TEX], 0); - glUniform2fv(gl->shader.loc[GLNVG_LOC_VIEWSIZE], 1, gl->view); + glBindBuffer(GL_ARRAY_BUFFER, gl->vertBuf); + glBufferData(GL_ARRAY_BUFFER, gl->nverts * sizeof(NVGvertex), gl->verts, GL_STREAM_DRAW); + glEnableVertexAttribArray(0); + glEnableVertexAttribArray(1); + glVertexAttribPointer(0, 2, GL_FLOAT, GL_FALSE, sizeof(NVGvertex), (const GLvoid*)(size_t)0); + glVertexAttribPointer(1, 2, GL_FLOAT, GL_FALSE, sizeof(NVGvertex), + (const GLvoid*)(0 + 2 * sizeof(float))); + + // Set view and texture just once per frame. + glUniform1i(gl->shader.loc[GLNVG_LOC_TEX], 0); + glUniform2fv(gl->shader.loc[GLNVG_LOC_VIEWSIZE], 1, gl->view); #if NANOVG_GL_USE_UNIFORMBUFFER - glBindBuffer(GL_UNIFORM_BUFFER, gl->fragBuf); + glBindBuffer(GL_UNIFORM_BUFFER, gl->fragBuf); #endif - for (i = 0; i < gl->ncalls; i++) { - GLNVGcall* call = &gl->calls[i]; - if (call->type == GLNVG_FILL) - glnvg__fill(gl, call); - else if (call->type == GLNVG_CONVEXFILL) - glnvg__convexFill(gl, call); - else if (call->type == GLNVG_STROKE) - glnvg__stroke(gl, call); - else if (call->type == GLNVG_TRIANGLES) - glnvg__triangles(gl, call); - } - - glDisableVertexAttribArray(0); - glDisableVertexAttribArray(1); + for (i = 0; i < gl->ncalls; i++) { + GLNVGcall* call = &gl->calls[i]; + glnvg__blendFuncSeparate(gl, &call->blendFunc); + if (call->type == GLNVG_FILL) + glnvg__fill(gl, call); + else if (call->type == GLNVG_CONVEXFILL) + glnvg__convexFill(gl, call); + else if (call->type == GLNVG_STROKE) + glnvg__stroke(gl, call); + else if (call->type == GLNVG_TRIANGLES) + glnvg__triangles(gl, call); + } + + glDisableVertexAttribArray(0); + glDisableVertexAttribArray(1); #if defined NANOVG_GL3 - glBindVertexArray(0); + glBindVertexArray(0); #endif - glDisable(GL_CULL_FACE); - glBindBuffer(GL_ARRAY_BUFFER, 0); - glUseProgram(0); - glnvg__bindTexture(gl, 0); - } - - // Reset calls - gl->nverts = 0; - gl->npaths = 0; - gl->ncalls = 0; - gl->nuniforms = 0; + glDisable(GL_CULL_FACE); + glBindBuffer(GL_ARRAY_BUFFER, 0); + glUseProgram(0); + glnvg__bindTexture(gl, 0); + } + + // Reset calls + gl->nverts = 0; + gl->npaths = 0; + gl->ncalls = 0; + gl->nuniforms = 0; } -static int glnvg__maxVertCount(const NVGpath* paths, int npaths) -{ - int i, count = 0; - for (i = 0; i < npaths; i++) { - count += paths[i].nfill; - count += paths[i].nstroke; - } - return count; +static int glnvg__maxVertCount(const NVGpath* paths, int npaths) { + int i, count = 0; + for (i = 0; i < npaths; i++) { + count += paths[i].nfill; + count += paths[i].nstroke; + } + return count; } -static GLNVGcall* glnvg__allocCall(GLNVGcontext* gl) -{ - GLNVGcall* ret = NULL; - if (gl->ncalls+1 > gl->ccalls) { - GLNVGcall* calls; - int ccalls = glnvg__maxi(gl->ncalls+1, 128) + gl->ccalls/2; // 1.5x Overallocate - calls = (GLNVGcall*)realloc(gl->calls, sizeof(GLNVGcall) * ccalls); - if (calls == NULL) return NULL; - gl->calls = calls; - gl->ccalls = ccalls; - } - ret = &gl->calls[gl->ncalls++]; - memset(ret, 0, sizeof(GLNVGcall)); - return ret; +static GLNVGcall* glnvg__allocCall(GLNVGcontext* gl) { + GLNVGcall* ret = NULL; + if (gl->ncalls + 1 > gl->ccalls) { + GLNVGcall* calls; + int ccalls = glnvg__maxi(gl->ncalls + 1, 128) + gl->ccalls / 2; // 1.5x Overallocate + calls = (GLNVGcall*)realloc(gl->calls, sizeof(GLNVGcall) * ccalls); + if (calls == NULL) return NULL; + gl->calls = calls; + gl->ccalls = ccalls; + } + ret = &gl->calls[gl->ncalls++]; + memset(ret, 0, sizeof(GLNVGcall)); + return ret; } -static int glnvg__allocPaths(GLNVGcontext* gl, int n) -{ - int ret = 0; - if (gl->npaths+n > gl->cpaths) { - GLNVGpath* paths; - int cpaths = glnvg__maxi(gl->npaths + n, 128) + gl->cpaths/2; // 1.5x Overallocate - paths = (GLNVGpath*)realloc(gl->paths, sizeof(GLNVGpath) * cpaths); - if (paths == NULL) return -1; - gl->paths = paths; - gl->cpaths = cpaths; - } - ret = gl->npaths; - gl->npaths += n; - return ret; +static int glnvg__allocPaths(GLNVGcontext* gl, int n) { + int ret = 0; + if (gl->npaths + n > gl->cpaths) { + GLNVGpath* paths; + int cpaths = glnvg__maxi(gl->npaths + n, 128) + gl->cpaths / 2; // 1.5x Overallocate + paths = (GLNVGpath*)realloc(gl->paths, sizeof(GLNVGpath) * cpaths); + if (paths == NULL) return -1; + gl->paths = paths; + gl->cpaths = cpaths; + } + ret = gl->npaths; + gl->npaths += n; + return ret; } -static int glnvg__allocVerts(GLNVGcontext* gl, int n) -{ - int ret = 0; - if (gl->nverts+n > gl->cverts) { - NVGvertex* verts; - int cverts = glnvg__maxi(gl->nverts + n, 4096) + gl->cverts/2; // 1.5x Overallocate - verts = (NVGvertex*)realloc(gl->verts, sizeof(NVGvertex) * cverts); - if (verts == NULL) return -1; - gl->verts = verts; - gl->cverts = cverts; - } - ret = gl->nverts; - gl->nverts += n; - return ret; +static int glnvg__allocVerts(GLNVGcontext* gl, int n) { + int ret = 0; + if (gl->nverts + n > gl->cverts) { + NVGvertex* verts; + int cverts = glnvg__maxi(gl->nverts + n, 4096) + gl->cverts / 2; // 1.5x Overallocate + verts = (NVGvertex*)realloc(gl->verts, sizeof(NVGvertex) * cverts); + if (verts == NULL) return -1; + gl->verts = verts; + gl->cverts = cverts; + } + ret = gl->nverts; + gl->nverts += n; + return ret; } -static int glnvg__allocFragUniforms(GLNVGcontext* gl, int n) -{ - int ret = 0, structSize = gl->fragSize; - if (gl->nuniforms+n > gl->cuniforms) { - unsigned char* uniforms; - int cuniforms = glnvg__maxi(gl->nuniforms+n, 128) + gl->cuniforms/2; // 1.5x Overallocate - uniforms = (unsigned char*)realloc(gl->uniforms, structSize * cuniforms); - if (uniforms == NULL) return -1; - gl->uniforms = uniforms; - gl->cuniforms = cuniforms; - } - ret = gl->nuniforms * structSize; - gl->nuniforms += n; - return ret; +static int glnvg__allocFragUniforms(GLNVGcontext* gl, int n) { + int ret = 0, structSize = gl->fragSize; + if (gl->nuniforms + n > gl->cuniforms) { + unsigned char* uniforms; + int cuniforms = glnvg__maxi(gl->nuniforms + n, 128) + gl->cuniforms / 2; // 1.5x Overallocate + uniforms = (unsigned char*)realloc(gl->uniforms, structSize * cuniforms); + if (uniforms == NULL) return -1; + gl->uniforms = uniforms; + gl->cuniforms = cuniforms; + } + ret = gl->nuniforms * structSize; + gl->nuniforms += n; + return ret; } -static GLNVGfragUniforms* nvg__fragUniformPtr(GLNVGcontext* gl, int i) -{ - return (GLNVGfragUniforms*)&gl->uniforms[i]; +static GLNVGfragUniforms* nvg__fragUniformPtr(GLNVGcontext* gl, int i) { + return (GLNVGfragUniforms*)&gl->uniforms[i]; } -static void glnvg__vset(NVGvertex* vtx, float x, float y, float u, float v) -{ - vtx->x = x; - vtx->y = y; - vtx->u = u; - vtx->v = v; +static void glnvg__vset(NVGvertex* vtx, float x, float y, float u, float v) { + vtx->x = x; + vtx->y = y; + vtx->u = u; + vtx->v = v; } -static void glnvg__renderFill(void* uptr, NVGpaint* paint, NVGscissor* scissor, float fringe, - const float* bounds, const NVGpath* paths, int npaths) -{ - GLNVGcontext* gl = (GLNVGcontext*)uptr; - GLNVGcall* call = glnvg__allocCall(gl); - NVGvertex* quad; - GLNVGfragUniforms* frag; - int i, maxverts, offset; - - if (call == NULL) return; - - call->type = GLNVG_FILL; - call->pathOffset = glnvg__allocPaths(gl, npaths); - if (call->pathOffset == -1) goto error; - call->pathCount = npaths; - call->image = paint->image; - - if (npaths == 1 && paths[0].convex) - call->type = GLNVG_CONVEXFILL; - - // Allocate vertices for all the paths. - maxverts = glnvg__maxVertCount(paths, npaths) + 6; - offset = glnvg__allocVerts(gl, maxverts); - if (offset == -1) goto error; - - for (i = 0; i < npaths; i++) { - GLNVGpath* copy = &gl->paths[call->pathOffset + i]; - const NVGpath* path = &paths[i]; - memset(copy, 0, sizeof(GLNVGpath)); - if (path->nfill > 0) { - copy->fillOffset = offset; - copy->fillCount = path->nfill; - memcpy(&gl->verts[offset], path->fill, sizeof(NVGvertex) * path->nfill); - offset += path->nfill; - } - if (path->nstroke > 0) { - copy->strokeOffset = offset; - copy->strokeCount = path->nstroke; - memcpy(&gl->verts[offset], path->stroke, sizeof(NVGvertex) * path->nstroke); - offset += path->nstroke; - } - } +static int glnvg__pathIsRect(const NVGpath* path) { + const NVGvertex* verts = path->fill; + if (path->nfill == 4) { + int ret1 = (verts[0].y == verts[1].y && verts[1].x == verts[2].x && verts[2].y == verts[3].y && + verts[3].x == verts[0].x); - // Quad - call->triangleOffset = offset; - call->triangleCount = 6; - quad = &gl->verts[call->triangleOffset]; - glnvg__vset(&quad[0], bounds[0], bounds[3], 0.5f, 1.0f); - glnvg__vset(&quad[1], bounds[2], bounds[3], 0.5f, 1.0f); - glnvg__vset(&quad[2], bounds[2], bounds[1], 0.5f, 1.0f); - - glnvg__vset(&quad[3], bounds[0], bounds[3], 0.5f, 1.0f); - glnvg__vset(&quad[4], bounds[2], bounds[1], 0.5f, 1.0f); - glnvg__vset(&quad[5], bounds[0], bounds[1], 0.5f, 1.0f); - - // Setup uniforms for draw calls - if (call->type == GLNVG_FILL) { - call->uniformOffset = glnvg__allocFragUniforms(gl, 2); - if (call->uniformOffset == -1) goto error; - // Simple shader for stencil - frag = nvg__fragUniformPtr(gl, call->uniformOffset); - memset(frag, 0, sizeof(*frag)); - frag->strokeThr = -1.0f; - frag->type = NSVG_SHADER_SIMPLE; - // Fill shader - glnvg__convertPaint(gl, nvg__fragUniformPtr(gl, call->uniformOffset + gl->fragSize), paint, scissor, fringe, fringe, -1.0f); - } else { - call->uniformOffset = glnvg__allocFragUniforms(gl, 1); - if (call->uniformOffset == -1) goto error; - // Fill shader - glnvg__convertPaint(gl, nvg__fragUniformPtr(gl, call->uniformOffset), paint, scissor, fringe, fringe, -1.0f); - } + int ret2 = (verts[0].x == verts[1].x && verts[1].y == verts[2].y && verts[2].x == verts[3].x && + verts[3].y == verts[0].y); - return; + if (ret1 || ret2) { + return 1; + } + } -error: - // We get here if call alloc was ok, but something else is not. - // Roll back the last call to prevent drawing it. - if (gl->ncalls > 0) gl->ncalls--; + return 0; } -static void glnvg__renderStroke(void* uptr, NVGpaint* paint, NVGscissor* scissor, float fringe, - float strokeWidth, const NVGpath* paths, int npaths) -{ - GLNVGcontext* gl = (GLNVGcontext*)uptr; - GLNVGcall* call = glnvg__allocCall(gl); - int i, maxverts, offset; - - if (call == NULL) return; - - call->type = GLNVG_STROKE; - call->pathOffset = glnvg__allocPaths(gl, npaths); - if (call->pathOffset == -1) goto error; - call->pathCount = npaths; - call->image = paint->image; - - // Allocate vertices for all the paths. - maxverts = glnvg__maxVertCount(paths, npaths); - offset = glnvg__allocVerts(gl, maxverts); - if (offset == -1) goto error; - - for (i = 0; i < npaths; i++) { - GLNVGpath* copy = &gl->paths[call->pathOffset + i]; - const NVGpath* path = &paths[i]; - memset(copy, 0, sizeof(GLNVGpath)); - if (path->nstroke) { - copy->strokeOffset = offset; - copy->strokeCount = path->nstroke; - memcpy(&gl->verts[offset], path->stroke, sizeof(NVGvertex) * path->nstroke); - offset += path->nstroke; - } - } +static int glnvg_getSupportFastDraw(GLNVGcontext* gl, NVGscissor* scissor) { + /* 根据 nanovg 的坐标系,判断坐标系是否已经旋转或者缩放了,如果是就返回不支持快速绘画的方法 */ + if(gl->g_xform[0] == 1.0f && gl->g_xform[1] == 0.0f + && gl->g_xform[2] == 0.0f && gl->g_xform[3] == 1.0f + && scissor->xform[0] == 1.0f && scissor->xform[1] == 0.0f + && scissor->xform[2] == 0.0f && scissor->xform[3] == 1.0f) { + return 1; + } else { + return 0; + } +} + +static int glnvg__VertsInScissor(const NVGvertex* verts, int nr, NVGscissor* scissor) { + int32_t i = 0; + float cx = scissor->xform[4]; + float cy = scissor->xform[5]; + float hw = scissor->extent[0]; + float hh = scissor->extent[1]; + + float l = cx - hw; + float t = cy - hh; + float r = l + 2 * hw - 1; + float b = t + 2 * hh - 1; + + for (i = 0; i < nr; i++) { + const NVGvertex* iter = verts + i; + int x = iter->x; + int y = iter->y; + if (x < l || x > r || y < t || y > b) { + return 0; + } + } + + return 1; +} - if (gl->flags & NVG_STENCIL_STROKES) { - // Fill shader - call->uniformOffset = glnvg__allocFragUniforms(gl, 2); - if (call->uniformOffset == -1) goto error; +static int glnvg__pathInScissor(const NVGpath* path, NVGscissor* scissor) { + return glnvg__VertsInScissor(path->fill, path->nfill, scissor); +} - glnvg__convertPaint(gl, nvg__fragUniformPtr(gl, call->uniformOffset), paint, scissor, strokeWidth, fringe, -1.0f); - glnvg__convertPaint(gl, nvg__fragUniformPtr(gl, call->uniformOffset + gl->fragSize), paint, scissor, strokeWidth, fringe, 1.0f - 0.5f/255.0f); +static void glnvg__renderFill(void* uptr, NVGpaint* paint, + NVGcompositeOperationState compositeOperation, NVGscissor* scissor, + float fringe, const float* bounds, const NVGpath* paths, int npaths) { + int support_fast_draw = 0; + int is_gradient = memcmp(&(paint->innerColor), &(paint->outerColor), sizeof(paint->outerColor)); + + GLNVGcontext* gl = (GLNVGcontext*)uptr; + GLNVGcall* call = glnvg__allocCall(gl); + NVGvertex* quad; + GLNVGfragUniforms* frag = NULL; + int i, maxverts, offset; + + if (call == NULL) return; + + call->type = GLNVG_FILL; + call->triangleCount = 4; + call->pathOffset = glnvg__allocPaths(gl, npaths); + if (call->pathOffset == -1) goto error; + call->pathCount = npaths; + call->image = paint->image; + call->blendFunc = glnvg__blendCompositeOperation(compositeOperation); + + if (npaths == 1 && paths[0].convex) { + call->type = GLNVG_CONVEXFILL; + call->triangleCount = 0; // Bounding box fill quad not needed for convex fill + } + + // Allocate vertices for all the paths. + maxverts = glnvg__maxVertCount(paths, npaths) + call->triangleCount; + offset = glnvg__allocVerts(gl, maxverts); + if (offset == -1) goto error; + + for (i = 0; i < npaths; i++) { + GLNVGpath* copy = &gl->paths[call->pathOffset + i]; + const NVGpath* path = &paths[i]; + memset(copy, 0, sizeof(GLNVGpath)); + if (path->nfill > 0) { + copy->fillOffset = offset; + copy->fillCount = path->nfill; + memcpy(&gl->verts[offset], path->fill, sizeof(NVGvertex) * path->nfill); + offset += path->nfill; + if (npaths == 1) { + support_fast_draw = glnvg__pathIsRect(path) && glnvg__pathInScissor(path, scissor) && glnvg_getSupportFastDraw(gl, scissor); + } + } + if (path->nstroke > 0) { + copy->strokeOffset = offset; + copy->strokeCount = path->nstroke; + memcpy(&gl->verts[offset], path->stroke, sizeof(NVGvertex) * path->nstroke); + offset += path->nstroke; + } + } + + // Setup uniforms for draw calls + if (call->type == GLNVG_FILL) { + // Quad + call->triangleOffset = offset; + quad = &gl->verts[call->triangleOffset]; + glnvg__vset(&quad[0], bounds[2], bounds[3], 0.5f, 1.0f); + glnvg__vset(&quad[1], bounds[2], bounds[1], 0.5f, 1.0f); + glnvg__vset(&quad[2], bounds[0], bounds[3], 0.5f, 1.0f); + glnvg__vset(&quad[3], bounds[0], bounds[1], 0.5f, 1.0f); + + call->uniformOffset = glnvg__allocFragUniforms(gl, 2); + if (call->uniformOffset == -1) goto error; + // Simple shader for stencil + frag = nvg__fragUniformPtr(gl, call->uniformOffset); + memset(frag, 0, sizeof(*frag)); + frag->strokeThr = -1.0f; + frag->type = NSVG_SHADER_SIMPLE; + // Fill shader + glnvg__convertPaint(gl, nvg__fragUniformPtr(gl, call->uniformOffset + gl->fragSize), paint, + scissor, fringe, fringe, -1.0f); + + } else { + call->uniformOffset = glnvg__allocFragUniforms(gl, 1); + if (call->uniformOffset == -1) goto error; + // Fill shader + frag = nvg__fragUniformPtr(gl, call->uniformOffset); + glnvg__convertPaint(gl, nvg__fragUniformPtr(gl, call->uniformOffset), paint, scissor, fringe, + fringe, -1.0f); + } + + if (support_fast_draw) { + if (paint->image != 0) { + frag->type = NSVG_SHADER_FAST_FILLIMG; + } else if (!is_gradient) { + frag->type = NSVG_SHADER_FAST_FILLCOLOR; + } + } else { + if (paint->image == 0 && !is_gradient) { + frag->type = NSVG_SHADER_FILLCOLOR; + } + } + + return; - } else { - // Fill shader - call->uniformOffset = glnvg__allocFragUniforms(gl, 1); - if (call->uniformOffset == -1) goto error; - glnvg__convertPaint(gl, nvg__fragUniformPtr(gl, call->uniformOffset), paint, scissor, strokeWidth, fringe, -1.0f); - } +error: + // We get here if call alloc was ok, but something else is not. + // Roll back the last call to prevent drawing it. + if (gl->ncalls > 0) gl->ncalls--; +} - return; +static void glnvg__renderStroke(void* uptr, NVGpaint* paint, + NVGcompositeOperationState compositeOperation, NVGscissor* scissor, + float fringe, float strokeWidth, const NVGpath* paths, int npaths) { + GLNVGcontext* gl = (GLNVGcontext*)uptr; + GLNVGcall* call = glnvg__allocCall(gl); + int i, maxverts, offset; + + if (call == NULL) return; + + call->type = GLNVG_STROKE; + call->pathOffset = glnvg__allocPaths(gl, npaths); + if (call->pathOffset == -1) goto error; + call->pathCount = npaths; + call->image = paint->image; + call->blendFunc = glnvg__blendCompositeOperation(compositeOperation); + + // Allocate vertices for all the paths. + maxverts = glnvg__maxVertCount(paths, npaths); + offset = glnvg__allocVerts(gl, maxverts); + if (offset == -1) goto error; + + for (i = 0; i < npaths; i++) { + GLNVGpath* copy = &gl->paths[call->pathOffset + i]; + const NVGpath* path = &paths[i]; + memset(copy, 0, sizeof(GLNVGpath)); + if (path->nstroke) { + copy->strokeOffset = offset; + copy->strokeCount = path->nstroke; + memcpy(&gl->verts[offset], path->stroke, sizeof(NVGvertex) * path->nstroke); + offset += path->nstroke; + } + } + + if (gl->flags & NVG_STENCIL_STROKES) { + // Fill shader + call->uniformOffset = glnvg__allocFragUniforms(gl, 2); + if (call->uniformOffset == -1) goto error; + + glnvg__convertPaint(gl, nvg__fragUniformPtr(gl, call->uniformOffset), paint, scissor, + strokeWidth, fringe, -1.0f); + glnvg__convertPaint(gl, nvg__fragUniformPtr(gl, call->uniformOffset + gl->fragSize), paint, + scissor, strokeWidth, fringe, 1.0f - 0.5f / 255.0f); + + } else { + // Fill shader + call->uniformOffset = glnvg__allocFragUniforms(gl, 1); + if (call->uniformOffset == -1) goto error; + glnvg__convertPaint(gl, nvg__fragUniformPtr(gl, call->uniformOffset), paint, scissor, + strokeWidth, fringe, -1.0f); + } + + return; error: - // We get here if call alloc was ok, but something else is not. - // Roll back the last call to prevent drawing it. - if (gl->ncalls > 0) gl->ncalls--; + // We get here if call alloc was ok, but something else is not. + // Roll back the last call to prevent drawing it. + if (gl->ncalls > 0) gl->ncalls--; } -static void glnvg__renderTriangles(void* uptr, NVGpaint* paint, NVGscissor* scissor, - const NVGvertex* verts, int nverts) -{ - GLNVGcontext* gl = (GLNVGcontext*)uptr; - GLNVGcall* call = glnvg__allocCall(gl); - GLNVGfragUniforms* frag; +static void glnvg__renderTriangles(void* uptr, NVGpaint* paint, + NVGcompositeOperationState compositeOperation, + NVGscissor* scissor, const NVGvertex* verts, int nverts) { + GLNVGcontext* gl = (GLNVGcontext*)uptr; + GLNVGcall* call = glnvg__allocCall(gl); + GLNVGfragUniforms* frag; + float fringe = 1.0f / gl->devicePixelRatio; - if (call == NULL) return; + if (call == NULL) return; - call->type = GLNVG_TRIANGLES; - call->image = paint->image; + call->type = GLNVG_TRIANGLES; + call->image = paint->image; + call->blendFunc = glnvg__blendCompositeOperation(compositeOperation); - // Allocate vertices for all the paths. - call->triangleOffset = glnvg__allocVerts(gl, nverts); - if (call->triangleOffset == -1) goto error; - call->triangleCount = nverts; + // Allocate vertices for all the paths. + call->triangleOffset = glnvg__allocVerts(gl, nverts); + if (call->triangleOffset == -1) goto error; + call->triangleCount = nverts; - memcpy(&gl->verts[call->triangleOffset], verts, sizeof(NVGvertex) * nverts); + memcpy(&gl->verts[call->triangleOffset], verts, sizeof(NVGvertex) * nverts); - // Fill shader - call->uniformOffset = glnvg__allocFragUniforms(gl, 1); - if (call->uniformOffset == -1) goto error; - frag = nvg__fragUniformPtr(gl, call->uniformOffset); - glnvg__convertPaint(gl, frag, paint, scissor, 1.0f, 1.0f, -1.0f); - frag->type = NSVG_SHADER_IMG; + // Fill shader + call->uniformOffset = glnvg__allocFragUniforms(gl, 1); + if (call->uniformOffset == -1) goto error; + frag = nvg__fragUniformPtr(gl, call->uniformOffset); + glnvg__convertPaint(gl, frag, paint, scissor, 1.0f, fringe, -1.0f); + if(glnvg__VertsInScissor(verts, nverts, scissor) && glnvg_getSupportFastDraw(gl, scissor)) { + frag->type = NSVG_SHADER_FAST_FILLGLYPH; + } else { + frag->type = NSVG_SHADER_IMG; + } - return; + return; error: - // We get here if call alloc was ok, but something else is not. - // Roll back the last call to prevent drawing it. - if (gl->ncalls > 0) gl->ncalls--; + // We get here if call alloc was ok, but something else is not. + // Roll back the last call to prevent drawing it. + if (gl->ncalls > 0) gl->ncalls--; } -static void glnvg__renderDelete(void* uptr) -{ - GLNVGcontext* gl = (GLNVGcontext*)uptr; - int i; - if (gl == NULL) return; +static void glnvg__setStateXfrom(void* uptr, float* xform) { + GLNVGcontext* gl = (GLNVGcontext*)uptr; + if(xform != NULL) { + memcpy(gl->g_xform, xform, sizeof(gl->g_xform)); + } +} - glnvg__deleteShader(&gl->shader); +static void glnvg__renderDelete(void* uptr) { + GLNVGcontext* gl = (GLNVGcontext*)uptr; + int i; + if (gl == NULL) return; + + glnvg__deleteShader(&gl->shader); #if NANOVG_GL3 #if NANOVG_GL_USE_UNIFORMBUFFER - if (gl->fragBuf != 0) - glDeleteBuffers(1, &gl->fragBuf); + if (gl->fragBuf != 0) glDeleteBuffers(1, &gl->fragBuf); #endif - if (gl->vertArr != 0) - glDeleteVertexArrays(1, &gl->vertArr); + if (gl->vertArr != 0) glDeleteVertexArrays(1, &gl->vertArr); #endif - if (gl->vertBuf != 0) - glDeleteBuffers(1, &gl->vertBuf); + if (gl->vertBuf != 0) glDeleteBuffers(1, &gl->vertBuf); - for (i = 0; i < gl->ntextures; i++) { - if (gl->textures[i].tex != 0 && (gl->textures[i].flags & NVG_IMAGE_NODELETE) == 0) - glDeleteTextures(1, &gl->textures[i].tex); - } - free(gl->textures); + for (i = 0; i < gl->ntextures; i++) { + if (gl->textures[i].tex != 0 && (gl->textures[i].flags & NVG_IMAGE_NODELETE) == 0) + glDeleteTextures(1, &gl->textures[i].tex); + } + free(gl->textures); - free(gl->paths); - free(gl->verts); - free(gl->uniforms); - free(gl->calls); + free(gl->paths); + free(gl->verts); + free(gl->uniforms); + free(gl->calls); - free(gl); + free(gl); } - #if defined NANOVG_GL2 NVGcontext* nvgCreateGL2(int flags) #elif defined NANOVG_GL3 @@ -1502,39 +1629,40 @@ NVGcontext* nvgCreateGLES2(int flags) NVGcontext* nvgCreateGLES3(int flags) #endif { - NVGparams params; - NVGcontext* ctx = NULL; - GLNVGcontext* gl = (GLNVGcontext*)malloc(sizeof(GLNVGcontext)); - if (gl == NULL) goto error; - memset(gl, 0, sizeof(GLNVGcontext)); - - memset(¶ms, 0, sizeof(params)); - params.renderCreate = glnvg__renderCreate; - params.renderCreateTexture = glnvg__renderCreateTexture; - params.renderDeleteTexture = glnvg__renderDeleteTexture; - params.renderUpdateTexture = glnvg__renderUpdateTexture; - params.renderGetTextureSize = glnvg__renderGetTextureSize; - params.renderViewport = glnvg__renderViewport; - params.renderCancel = glnvg__renderCancel; - params.renderFlush = glnvg__renderFlush; - params.renderFill = glnvg__renderFill; - params.renderStroke = glnvg__renderStroke; - params.renderTriangles = glnvg__renderTriangles; - params.renderDelete = glnvg__renderDelete; - params.userPtr = gl; - params.edgeAntiAlias = flags & NVG_ANTIALIAS ? 1 : 0; - - gl->flags = flags; - - ctx = nvgCreateInternal(¶ms); - if (ctx == NULL) goto error; - - return ctx; + NVGparams params; + NVGcontext* ctx = NULL; + GLNVGcontext* gl = (GLNVGcontext*)malloc(sizeof(GLNVGcontext)); + if (gl == NULL) goto error; + memset(gl, 0, sizeof(GLNVGcontext)); + + memset(¶ms, 0, sizeof(params)); + params.renderCreate = glnvg__renderCreate; + params.renderCreateTexture = glnvg__renderCreateTexture; + params.renderDeleteTexture = glnvg__renderDeleteTexture; + params.renderUpdateTexture = glnvg__renderUpdateTexture; + params.renderGetTextureSize = glnvg__renderGetTextureSize; + params.renderViewport = glnvg__renderViewport; + params.renderCancel = glnvg__renderCancel; + params.renderFlush = glnvg__renderFlush; + params.renderFill = glnvg__renderFill; + params.renderStroke = glnvg__renderStroke; + params.renderTriangles = glnvg__renderTriangles; + params.renderDelete = glnvg__renderDelete; + params.setStateXfrom = glnvg__setStateXfrom; + params.userPtr = gl; + params.edgeAntiAlias = flags & NVG_ANTIALIAS ? 1 : 0; + + gl->flags = flags; + + ctx = nvgCreateInternal(¶ms); + if (ctx == NULL) goto error; + + return ctx; error: - // 'gl' is freed by nvgDeleteInternal. - if (ctx != NULL) nvgDeleteInternal(ctx); - return NULL; + // 'gl' is freed by nvgDeleteInternal. + if (ctx != NULL) nvgDeleteInternal(ctx); + return NULL; } #if defined NANOVG_GL2 @@ -1547,7 +1675,7 @@ void nvgDeleteGLES2(NVGcontext* ctx) void nvgDeleteGLES3(NVGcontext* ctx) #endif { - nvgDeleteInternal(ctx); + nvgDeleteInternal(ctx); } #if defined NANOVG_GL2 @@ -1560,18 +1688,18 @@ int nvglCreateImageFromHandleGLES2(NVGcontext* ctx, GLuint textureId, int w, int int nvglCreateImageFromHandleGLES3(NVGcontext* ctx, GLuint textureId, int w, int h, int imageFlags) #endif { - GLNVGcontext* gl = (GLNVGcontext*)nvgInternalParams(ctx)->userPtr; - GLNVGtexture* tex = glnvg__allocTexture(gl); + GLNVGcontext* gl = (GLNVGcontext*)nvgInternalParams(ctx)->userPtr; + GLNVGtexture* tex = glnvg__allocTexture(gl); - if (tex == NULL) return 0; + if (tex == NULL) return 0; - tex->type = NVG_TEXTURE_RGBA; - tex->tex = textureId; - tex->flags = imageFlags; - tex->width = w; - tex->height = h; + tex->type = NVG_TEXTURE_RGBA; + tex->tex = textureId; + tex->flags = imageFlags; + tex->width = w; + tex->height = h; - return tex->id; + return tex->id; } #if defined NANOVG_GL2 @@ -1584,9 +1712,9 @@ GLuint nvglImageHandleGLES2(NVGcontext* ctx, int image) GLuint nvglImageHandleGLES3(NVGcontext* ctx, int image) #endif { - GLNVGcontext* gl = (GLNVGcontext*)nvgInternalParams(ctx)->userPtr; - GLNVGtexture* tex = glnvg__findTexture(gl, image); - return tex->tex; + GLNVGcontext* gl = (GLNVGcontext*)nvgInternalParams(ctx)->userPtr; + GLNVGtexture* tex = glnvg__findTexture(gl, image); + return tex->tex; } #endif /* NANOVG_GL_IMPLEMENTATION */ diff --git a/phonelibs/nanovg/nanovg_gl_utils.h b/phonelibs/nanovg/nanovg_gl_utils.h index 1323e90c64cf90..e54ec2fb2b3d2b 100644 --- a/phonelibs/nanovg/nanovg_gl_utils.h +++ b/phonelibs/nanovg/nanovg_gl_utils.h @@ -49,6 +49,16 @@ void nvgluDeleteFramebuffer(NVGLUframebuffer* fb); static GLint defaultFBO = -1; +int nvgluGetCurrFramebuffer() { +#ifdef NANOVG_FBO_VALID + GLint defaultFBO; + glGetIntegerv(GL_FRAMEBUFFER_BINDING, &defaultFBO); + return defaultFBO; +#else + return -1; +#endif +} + NVGLUframebuffer* nvgluCreateFramebuffer(NVGcontext* ctx, int w, int h, int imageFlags) { #ifdef NANOVG_FBO_VALID @@ -90,7 +100,18 @@ NVGLUframebuffer* nvgluCreateFramebuffer(NVGcontext* ctx, int w, int h, int imag glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, fb->texture, 0); glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT, GL_RENDERBUFFER, fb->rbo); - if (glCheckFramebufferStatus(GL_FRAMEBUFFER) != GL_FRAMEBUFFER_COMPLETE) goto error; + if (glCheckFramebufferStatus(GL_FRAMEBUFFER) != GL_FRAMEBUFFER_COMPLETE) { +#ifdef GL_DEPTH24_STENCIL8 + // If GL_STENCIL_INDEX8 is not supported, try GL_DEPTH24_STENCIL8 as a fallback. + // Some graphics cards require a depth buffer along with a stencil. + glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH24_STENCIL8, w, h); + glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, fb->texture, 0); + glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT, GL_RENDERBUFFER, fb->rbo); + + if (glCheckFramebufferStatus(GL_FRAMEBUFFER) != GL_FRAMEBUFFER_COMPLETE) +#endif // GL_DEPTH24_STENCIL8 + goto error; + } glBindFramebuffer(GL_FRAMEBUFFER, defaultFBO); glBindRenderbuffer(GL_RENDERBUFFER, defaultRBO); @@ -119,6 +140,14 @@ void nvgluBindFramebuffer(NVGLUframebuffer* fb) #endif } +void nvgluReadCurrentFramebufferData(unsigned int x, unsigned int y, unsigned int w, unsigned int h, unsigned int width, unsigned int height, void* pixels) +{ + if(x + w <= width && y + h <= height && pixels != NULL) { + glPixelStorei(GL_UNPACK_ALIGNMENT, 1); + glReadPixels(x, y, w, h, GL_RGBA, GL_UNSIGNED_BYTE, pixels); + } +} + void nvgluDeleteFramebuffer(NVGLUframebuffer* fb) { #ifdef NANOVG_FBO_VALID diff --git a/phonelibs/nanovg/stb_image.h b/phonelibs/nanovg/stb_image.h index e06f7a1d73b1e3..e40a2e8a1f2db9 100644 --- a/phonelibs/nanovg/stb_image.h +++ b/phonelibs/nanovg/stb_image.h @@ -411,7 +411,7 @@ extern "C" { #endif #ifdef STB_IMAGE_STATIC -#define STBIDEF static +#define STBIDEF static inline #else #define STBIDEF extern #endif diff --git a/scripts/atl.sh b/scripts/atl.sh new file mode 100755 index 00000000000000..188c8cda77c4a0 --- /dev/null +++ b/scripts/atl.sh @@ -0,0 +1,21 @@ +#!/usr/bin/bash + +export LD_LIBRARY_PATH=/data/data/com.termux/files/usr/lib +export HOME=/data/data/com.termux/files/home +export PATH=/usr/local/bin:/data/data/com.termux/files/usr/bin:/data/data/com.termux/files/usr/sbin:/data/data/com.termux/files/usr/bin/applets:/bin:/sbin:/vendor/bin:/system/sbin:/system/bin:/system/xbin:/data/data/com.termux/files/usr/bin/git +export PYTHONPATH=/data/openpilot +echo -n 1 > /data/params/d/dp_is_updating +if [ $1 -eq 1 ]; then + printf %s "1" > /data/params/d/CommunityFeaturesToggle + printf %s "1" > /data/params/d/dp_atl + printf %s "0" > /data/params/d/dp_uploader + printf %s "0" > /data/params/d/dp_accel_profile + printf %s "0" > /data/params/d/dp_dynamic_follow +fi +if [ $1 -eq 0 ]; then + printf %s "0" > /data/params/d/dp_atl + cd /data/openpilot || exit + git reset --hard @{u} + git clean -xdf +fi +reboot diff --git a/scripts/complete_setup.sh b/scripts/complete_setup.sh new file mode 100755 index 00000000000000..8c5a8f38b4df1d --- /dev/null +++ b/scripts/complete_setup.sh @@ -0,0 +1,9 @@ +#!/usr/bin/bash + +touch /data/data/com.termux/files/continue.sh +echo "#!/usr/bin/bash" >> /data/data/com.termux/files/continue.sh +echo "cd /data/openpilot" >> /data/data/com.termux/files/continue.sh +echo "exec ./launch_openpilot.sh" >> /data/data/com.termux/files/continue.sh + +chmod u+x /data/data/com.termux/files/continue.sh +reboot \ No newline at end of file diff --git a/scripts/disable_relay.sh b/scripts/disable_relay.sh new file mode 100755 index 00000000000000..80564f147ecdac --- /dev/null +++ b/scripts/disable_relay.sh @@ -0,0 +1,10 @@ +#!/usr/bin/bash + +if [ $1 -eq 1 ]; then + printf %s "1" > /data/params/d/dp_disable_relay +fi +if [ $1 -eq 0 ]; then + printf %s "0" > /data/params/d/dp_disable_relay +fi + +rm -rf /data/openpilot/selfdrive/boardd/boardd && reboot \ No newline at end of file diff --git a/scripts/rebuild.sh b/scripts/rebuild.sh new file mode 100755 index 00000000000000..51bd33070d7567 --- /dev/null +++ b/scripts/rebuild.sh @@ -0,0 +1,13 @@ +#!/usr/bin/bash + +export LD_LIBRARY_PATH=/data/data/com.termux/files/usr/lib +export HOME=/data/data/com.termux/files/home +export PATH=/usr/local/bin:/data/data/com.termux/files/usr/bin:/data/data/com.termux/files/usr/sbin:/data/data/com.termux/files/usr/bin/applets:/bin:/sbin:/vendor/bin:/system/sbin:/system/bin:/system/xbin:/data/data/com.termux/files/usr/bin/git +printf %s "1" > /data/params/d/DragonUpdating +cd /data/openpilot || exit +#git reset --hard @{u} +git clean -xdf +rm -fr /tmp/scons_cache/ +find . -type f -name '*.py[co]' -delete -o -type d -name __pycache__ -delete +scons --clean +reboot \ No newline at end of file diff --git a/scripts/reset_dp.sh b/scripts/reset_dp.sh new file mode 100755 index 00000000000000..a89cc70d902f4c --- /dev/null +++ b/scripts/reset_dp.sh @@ -0,0 +1,10 @@ +#!/usr/bin/bash + +export LD_LIBRARY_PATH=/data/data/com.termux/files/usr/lib +export HOME=/data/data/com.termux/files/home +export PATH=/usr/local/bin:/data/data/com.termux/files/usr/bin:/data/data/com.termux/files/usr/sbin:/data/data/com.termux/files/usr/bin/applets:/bin:/sbin:/vendor/bin:/system/sbin:/system/bin:/system/xbin:/data/data/com.termux/files/usr/bin/git +export PYTHONPATH=/data/openpilot +echo -n 1 > /data/params/d/dp_is_updating +rm -fr /data/params/d/dp_* +rm -fr /data/params/d/Dragon* +reboot \ No newline at end of file diff --git a/scripts/reset_update.sh b/scripts/reset_update.sh new file mode 100755 index 00000000000000..f569a806621343 --- /dev/null +++ b/scripts/reset_update.sh @@ -0,0 +1,9 @@ +#!/usr/bin/bash + +export LD_LIBRARY_PATH=/data/data/com.termux/files/usr/lib +export HOME=/data/data/com.termux/files/home +export PATH=/usr/local/bin:/data/data/com.termux/files/usr/bin:/data/data/com.termux/files/usr/sbin:/data/data/com.termux/files/usr/bin/applets:/bin:/sbin:/vendor/bin:/system/sbin:/system/bin:/system/xbin:/data/data/com.termux/files/usr/bin/git +export PYTHONPATH=/data/openpilot +echo -n 1 > /data/params/d/dp_is_updating +rm /data/openpilot/panda/board/obj/panda.bin +cd /data/openpilot && git fetch --all && git reset --hard @{u} && git clean -xdf && scons --clean && reboot diff --git a/scripts/update_panda_firmware.sh b/scripts/update_panda_firmware.sh new file mode 100755 index 00000000000000..81b0c39dc115c7 --- /dev/null +++ b/scripts/update_panda_firmware.sh @@ -0,0 +1,9 @@ +#!/usr/bin/bash + +export LD_LIBRARY_PATH=/data/data/com.termux/files/usr/lib +export HOME=/data/data/com.termux/files/home +export PATH=/usr/local/bin:/data/data/com.termux/files/usr/bin:/data/data/com.termux/files/usr/sbin:/data/data/com.termux/files/usr/bin/applets:/bin:/sbin:/vendor/bin:/system/sbin:/system/bin:/system/xbin:/data/data/com.termux/files/usr/bin/python +export PYTHONPATH=/data/openpilot +printf %s "1" > /data/params/d/DragonUpdating +rm /data/openpilot/panda/board/obj/panda.bin +cd /data/openpilot/panda || exit ; pkill -f boardd ; python -c "from panda import Panda; Panda().flash()" && reboot \ No newline at end of file diff --git a/scripts/vw.sh b/scripts/vw.sh new file mode 100755 index 00000000000000..3bae817f53b7ab --- /dev/null +++ b/scripts/vw.sh @@ -0,0 +1,9 @@ +#!/usr/bin/bash + +if [ $1 -eq 1 ]; then + printf %s "1" > /data/params/d/dp_vw +fi +if [ $1 -eq 0 ]; then + printf %s "0" > /data/params/d/dp_vw +fi +rm /data/openpilot/panda/board/obj/panda.bin \ No newline at end of file diff --git a/selfdrive/assets/images/button_home.png b/selfdrive/assets/images/button_home.png index 9f52faf9e2da48..aa90a78c471f41 100644 Binary files a/selfdrive/assets/images/button_home.png and b/selfdrive/assets/images/button_home.png differ diff --git a/selfdrive/assets/img_spinner_comma.png b/selfdrive/assets/img_spinner_comma.png index 16109557f85911..aa90a78c471f41 100644 Binary files a/selfdrive/assets/img_spinner_comma.png and b/selfdrive/assets/img_spinner_comma.png differ diff --git a/selfdrive/assets/locales/events.pot b/selfdrive/assets/locales/events.pot new file mode 100644 index 00000000000000..0f19dfa2a6b597 --- /dev/null +++ b/selfdrive/assets/locales/events.pot @@ -0,0 +1,540 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2020-10-15 13:37+1000\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME \n" +"Language-Team: LANGUAGE \n" +"Language: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=CHARSET\n" +"Content-Transfer-Encoding: 8bit\n" + +#: selfdrive/controls/lib/events.py:153 +msgid "openpilot Unavailable" +msgstr "" + +#: selfdrive/controls/lib/events.py:160 selfdrive/controls/lib/events.py:167 +msgid "TAKE CONTROL IMMEDIATELY" +msgstr "" + +#: selfdrive/controls/lib/events.py:187 selfdrive/controls/lib/events.py:328 +#: selfdrive/controls/lib/events.py:354 selfdrive/controls/lib/events.py:418 +#: selfdrive/controls/lib/events.py:470 selfdrive/controls/lib/events.py:522 +#: selfdrive/controls/lib/events.py:532 +msgid "TAKE CONTROL" +msgstr "" + +#: selfdrive/controls/lib/events.py:188 +#, python-format +msgid "Steer Unavailable Below %(speed)d %(unit)s" +msgstr "" + +#: selfdrive/controls/lib/events.py:196 +#, python-format +msgid "Calibration in Progress: %d%%" +msgstr "" + +#: selfdrive/controls/lib/events.py:197 +#, python-format +msgid "Drive Above %(speed)d %(unit)s" +msgstr "" + +#: selfdrive/controls/lib/events.py:204 +msgid "Poor GPS reception" +msgstr "" + +#: selfdrive/controls/lib/events.py:205 +msgid "If sky is visible, contact support" +msgstr "" + +#: selfdrive/controls/lib/events.py:205 +msgid "Check GPS antenna placement" +msgstr "" + +#: selfdrive/controls/lib/events.py:210 +msgid "Cruise Mode Disabled" +msgstr "" + +#: selfdrive/controls/lib/events.py:212 +msgid "Main Switch Off" +msgstr "" + +#: selfdrive/controls/lib/events.py:222 +msgid "DEBUG ALERT" +msgstr "" + +#: selfdrive/controls/lib/events.py:230 +msgid "Be ready to take over at any time" +msgstr "" + +#: selfdrive/controls/lib/events.py:231 selfdrive/controls/lib/events.py:239 +#: selfdrive/controls/lib/events.py:247 selfdrive/controls/lib/events.py:255 +msgid "Always keep hands on wheel and eyes on road" +msgstr "" + +#: selfdrive/controls/lib/events.py:238 +msgid "WARNING: This branch is not tested" +msgstr "" + +#: selfdrive/controls/lib/events.py:246 +msgid "Dashcam mode" +msgstr "" + +#: selfdrive/controls/lib/events.py:254 +msgid "Dashcam mode for unsupported car" +msgstr "" + +#: selfdrive/controls/lib/events.py:262 +msgid "Unsupported Giraffe Configuration" +msgstr "" + +#: selfdrive/controls/lib/events.py:263 +msgid "Visit comma.ai/tg" +msgstr "" + +#: selfdrive/controls/lib/events.py:270 +msgid "White Panda Is No Longer Supported" +msgstr "" + +#: selfdrive/controls/lib/events.py:271 +msgid "Upgrade to comma two or black panda" +msgstr "" + +#: selfdrive/controls/lib/events.py:274 +msgid "White panda is no longer supported" +msgstr "" + +#: selfdrive/controls/lib/events.py:279 +msgid "Stock LKAS is turned on" +msgstr "" + +#: selfdrive/controls/lib/events.py:280 +msgid "Turn off stock LKAS to engage" +msgstr "" + +#: selfdrive/controls/lib/events.py:288 +msgid "Community Feature Detected" +msgstr "" + +#: selfdrive/controls/lib/events.py:289 +msgid "Enable Community Features in Developer Settings" +msgstr "" + +#: selfdrive/controls/lib/events.py:296 +msgid "Dashcam Mode" +msgstr "" + +#: selfdrive/controls/lib/events.py:297 +msgid "Car Unrecognized" +msgstr "" + +#: selfdrive/controls/lib/events.py:304 selfdrive/controls/lib/events.py:312 +#: selfdrive/controls/lib/events.py:320 +msgid "BRAKE!" +msgstr "" + +#: selfdrive/controls/lib/events.py:305 +msgid "Stock AEB: Risk of Collision" +msgstr "" + +#: selfdrive/controls/lib/events.py:313 +msgid "Stock FCW: Risk of Collision" +msgstr "" + +#: selfdrive/controls/lib/events.py:321 +msgid "Risk of Collision" +msgstr "" + +#: selfdrive/controls/lib/events.py:329 +msgid "Lane Departure Detected" +msgstr "" + +#: selfdrive/controls/lib/events.py:338 +msgid "openpilot will not brake while gas pressed" +msgstr "" + +#: selfdrive/controls/lib/events.py:346 +msgid "Vehicle Parameter Identification Failed" +msgstr "" + +#: selfdrive/controls/lib/events.py:355 selfdrive/controls/lib/events.py:523 +#: selfdrive/controls/lib/events.py:526 +msgid "Steering Temporarily Unavailable" +msgstr "" + +#: selfdrive/controls/lib/events.py:362 +msgid "KEEP EYES ON ROAD: Driver Distracted" +msgstr "" + +#: selfdrive/controls/lib/events.py:370 +msgid "KEEP EYES ON ROAD" +msgstr "" + +#: selfdrive/controls/lib/events.py:371 +msgid "Driver Appears Distracted" +msgstr "" + +#: selfdrive/controls/lib/events.py:378 selfdrive/controls/lib/events.py:402 +msgid "DISENGAGE IMMEDIATELY" +msgstr "" + +#: selfdrive/controls/lib/events.py:379 +msgid "Driver Was Distracted" +msgstr "" + +#: selfdrive/controls/lib/events.py:386 +msgid "TOUCH STEERING WHEEL: No Face Detected" +msgstr "" + +#: selfdrive/controls/lib/events.py:394 +msgid "TOUCH STEERING WHEEL" +msgstr "" + +#: selfdrive/controls/lib/events.py:395 +msgid "Driver Is Unresponsive" +msgstr "" + +#: selfdrive/controls/lib/events.py:403 +msgid "Driver Was Unresponsive" +msgstr "" + +#: selfdrive/controls/lib/events.py:410 +msgid "CHECK DRIVER FACE VISIBILITY" +msgstr "" + +#: selfdrive/controls/lib/events.py:411 +msgid "Driver Monitor Model Output Uncertain" +msgstr "" + +#: selfdrive/controls/lib/events.py:419 +msgid "Resume Driving Manually" +msgstr "" + +#: selfdrive/controls/lib/events.py:426 +msgid "STOPPED" +msgstr "" + +#: selfdrive/controls/lib/events.py:427 +msgid "Press Resume to Move" +msgstr "" + +#: selfdrive/controls/lib/events.py:438 +msgid "Steer Left to Start Lane Change" +msgstr "" + +#: selfdrive/controls/lib/events.py:439 selfdrive/controls/lib/events.py:447 +#: selfdrive/controls/lib/events.py:455 selfdrive/controls/lib/events.py:463 +#: selfdrive/controls/lib/events.py:802 selfdrive/controls/lib/events.py:810 +msgid "Monitor Other Vehicles" +msgstr "" + +#: selfdrive/controls/lib/events.py:446 +msgid "Steer Right to Start Lane Change" +msgstr "" + +#: selfdrive/controls/lib/events.py:454 +msgid "Car Detected in Blindspot" +msgstr "" + +#: selfdrive/controls/lib/events.py:462 +msgid "Changing Lane" +msgstr "" + +#: selfdrive/controls/lib/events.py:471 +msgid "Turn Exceeds Steering Limit" +msgstr "" + +#: selfdrive/controls/lib/events.py:496 +msgid "Brake Hold Active" +msgstr "" + +#: selfdrive/controls/lib/events.py:501 +msgid "Park Brake Engaged" +msgstr "" + +#: selfdrive/controls/lib/events.py:506 +msgid "Pedal Pressed During Attempt" +msgstr "" + +#: selfdrive/controls/lib/events.py:517 +msgid "Enable Adaptive Cruise" +msgstr "" + +#: selfdrive/controls/lib/events.py:533 +msgid "Attempting Refocus: Camera Focus Invalid" +msgstr "" + +#: selfdrive/controls/lib/events.py:539 +msgid "Out of Storage Space" +msgstr "" + +#: selfdrive/controls/lib/events.py:544 +msgid "Speed Too Low" +msgstr "" + +#: selfdrive/controls/lib/events.py:549 selfdrive/controls/lib/events.py:553 +msgid "NEOS Update Required" +msgstr "" + +#: selfdrive/controls/lib/events.py:550 +msgid "Please Wait for Update" +msgstr "" + +#: selfdrive/controls/lib/events.py:558 selfdrive/controls/lib/events.py:562 +msgid "No Data from Device Sensors" +msgstr "" + +#: selfdrive/controls/lib/events.py:559 selfdrive/controls/lib/events.py:572 +#: selfdrive/controls/lib/events.py:669 +msgid "Reboot your Device" +msgstr "" + +#: selfdrive/controls/lib/events.py:571 selfdrive/controls/lib/events.py:575 +msgid "Speaker not found" +msgstr "" + +#: selfdrive/controls/lib/events.py:579 +msgid "Distraction Level Too High" +msgstr "" + +#: selfdrive/controls/lib/events.py:583 +msgid "System Overheated" +msgstr "" + +#: selfdrive/controls/lib/events.py:584 +msgid "System overheated" +msgstr "" + +#: selfdrive/controls/lib/events.py:588 selfdrive/controls/lib/events.py:589 +msgid "Gear not D" +msgstr "" + +#: selfdrive/controls/lib/events.py:594 +msgid "Calibration Invalid" +msgstr "" + +#: selfdrive/controls/lib/events.py:595 +msgid "Reposition Device and Recalibrate" +msgstr "" + +#: selfdrive/controls/lib/events.py:598 selfdrive/controls/lib/events.py:599 +msgid "Calibration Invalid: Reposition Device & Recalibrate" +msgstr "" + +#: selfdrive/controls/lib/events.py:603 selfdrive/controls/lib/events.py:605 +msgid "Calibration in Progress" +msgstr "" + +#: selfdrive/controls/lib/events.py:609 +msgid "Door Open" +msgstr "" + +#: selfdrive/controls/lib/events.py:610 +msgid "Door open" +msgstr "" + +#: selfdrive/controls/lib/events.py:614 +msgid "Seatbelt Unlatched" +msgstr "" + +#: selfdrive/controls/lib/events.py:615 +msgid "Seatbelt unlatched" +msgstr "" + +#: selfdrive/controls/lib/events.py:619 selfdrive/controls/lib/events.py:620 +msgid "ESP Off" +msgstr "" + +#: selfdrive/controls/lib/events.py:624 selfdrive/controls/lib/events.py:625 +msgid "Low Battery" +msgstr "" + +#: selfdrive/controls/lib/events.py:629 selfdrive/controls/lib/events.py:630 +msgid "Communication Issue between Processes" +msgstr "" + +#: selfdrive/controls/lib/events.py:635 selfdrive/controls/lib/events.py:636 +msgid "Radar Communication Issue" +msgstr "" + +#: selfdrive/controls/lib/events.py:641 selfdrive/controls/lib/events.py:642 +#: selfdrive/controls/lib/events.py:646 selfdrive/controls/lib/events.py:647 +msgid "Radar Error: Restart the Car" +msgstr "" + +#: selfdrive/controls/lib/events.py:651 selfdrive/controls/lib/events.py:652 +msgid "Driving model lagging" +msgstr "" + +#: selfdrive/controls/lib/events.py:656 selfdrive/controls/lib/events.py:657 +msgid "Vision Model Output Uncertain" +msgstr "" + +#: selfdrive/controls/lib/events.py:661 selfdrive/controls/lib/events.py:662 +msgid "Device Fell Off Mount" +msgstr "" + +#: selfdrive/controls/lib/events.py:666 selfdrive/controls/lib/events.py:672 +msgid "Low Memory: Reboot Your Device" +msgstr "" + +#: selfdrive/controls/lib/events.py:668 +msgid "RAM Critically Low" +msgstr "" + +#: selfdrive/controls/lib/events.py:677 selfdrive/controls/lib/events.py:678 +msgid "Controls Failed" +msgstr "" + +#: selfdrive/controls/lib/events.py:682 +msgid "Controls Mismatch" +msgstr "" + +#: selfdrive/controls/lib/events.py:686 selfdrive/controls/lib/events.py:688 +#: selfdrive/controls/lib/events.py:692 +msgid "CAN Error: Check Connections" +msgstr "" + +#: selfdrive/controls/lib/events.py:696 selfdrive/controls/lib/events.py:702 +msgid "LKAS Fault: Restart the Car" +msgstr "" + +#: selfdrive/controls/lib/events.py:698 +msgid "LKAS Fault: Restart the car to engage" +msgstr "" + +#: selfdrive/controls/lib/events.py:706 selfdrive/controls/lib/events.py:712 +#: selfdrive/controls/lib/events.py:795 +msgid "Cruise Fault: Restart the Car" +msgstr "" + +#: selfdrive/controls/lib/events.py:708 selfdrive/controls/lib/events.py:791 +msgid "Cruise Fault: Restart the car to engage" +msgstr "" + +#: selfdrive/controls/lib/events.py:716 +msgid "Gas Fault: Restart the Car" +msgstr "" + +#: selfdrive/controls/lib/events.py:717 +msgid "Gas Error: Restart the Car" +msgstr "" + +#: selfdrive/controls/lib/events.py:722 +msgid "" +"Reverse\n" +"Gear" +msgstr "" + +#: selfdrive/controls/lib/events.py:726 +msgid "Reverse Gear" +msgstr "" + +#: selfdrive/controls/lib/events.py:731 +msgid "Cruise Is Off" +msgstr "" + +#: selfdrive/controls/lib/events.py:735 selfdrive/controls/lib/events.py:736 +msgid "Planner Solution Error" +msgstr "" + +#: selfdrive/controls/lib/events.py:740 selfdrive/controls/lib/events.py:742 +#: selfdrive/controls/lib/events.py:746 +msgid "Harness Malfunction" +msgstr "" + +#: selfdrive/controls/lib/events.py:743 +msgid "Please Check Hardware" +msgstr "" + +#: selfdrive/controls/lib/events.py:751 selfdrive/controls/lib/events.py:760 +msgid "openpilot Canceled" +msgstr "" + +#: selfdrive/controls/lib/events.py:752 +msgid "No close lead car" +msgstr "" + +#: selfdrive/controls/lib/events.py:755 +msgid "No Close Lead Car" +msgstr "" + +#: selfdrive/controls/lib/events.py:761 +msgid "Speed too low" +msgstr "" + +#: selfdrive/controls/lib/events.py:768 selfdrive/controls/lib/events.py:773 +msgid "Speed Too High" +msgstr "" + +#: selfdrive/controls/lib/events.py:769 +msgid "Slow down to resume operation" +msgstr "" + +#: selfdrive/controls/lib/events.py:774 +msgid "Slow down to engage" +msgstr "" + +#: selfdrive/controls/lib/events.py:781 +msgid "Please connect to Internet" +msgstr "" + +#: selfdrive/controls/lib/events.py:782 +msgid "An Update Check Is Required to Engage" +msgstr "" + +#: selfdrive/controls/lib/events.py:785 +msgid "Please Connect to Internet" +msgstr "" + +#: selfdrive/controls/lib/events.py:801 +msgid "Left ALC will start in 3s" +msgstr "" + +#: selfdrive/controls/lib/events.py:809 +msgid "Right ALC will start in 3s" +msgstr "" + +#: selfdrive/controls/lib/events.py:817 +msgid "STEERING REQUIRED: Lane Keeping OFF" +msgstr "" + +#: selfdrive/controls/lib/events.py:825 +msgid "STEERING REQUIRED: Blinkers ON" +msgstr "" + +#: selfdrive/controls/lib/events.py:833 selfdrive/controls/lib/events.py:838 +msgid "Lead Car Is Moving" +msgstr "" + +#: selfdrive/controls/lib/events.py:847 +msgid "WARNING" +msgstr "" + +#: selfdrive/controls/lib/events.py:848 +msgid "Grab wheel to start bypass" +msgstr "" + +#: selfdrive/controls/lib/events.py:855 +msgid "BYPASSING" +msgstr "" + +#: selfdrive/controls/lib/events.py:856 +msgid "HOLD WHEEL" +msgstr "" + +#: selfdrive/controls/lib/events.py:863 +msgid "Bypassed!" +msgstr "" + +#: selfdrive/controls/lib/events.py:864 +msgid "Release wheel when ready" +msgstr "" diff --git a/selfdrive/assets/locales/ja-JP/LC_MESSAGES/events.mo b/selfdrive/assets/locales/ja-JP/LC_MESSAGES/events.mo new file mode 100644 index 00000000000000..b11f449886594e Binary files /dev/null and b/selfdrive/assets/locales/ja-JP/LC_MESSAGES/events.mo differ diff --git a/selfdrive/assets/locales/ja-JP/LC_MESSAGES/events.po b/selfdrive/assets/locales/ja-JP/LC_MESSAGES/events.po new file mode 100644 index 00000000000000..7d095198cc0b04 --- /dev/null +++ b/selfdrive/assets/locales/ja-JP/LC_MESSAGES/events.po @@ -0,0 +1,545 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2020-10-15 13:37+1000\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: nikkurie <@nikkurie>\n" +"Language-Team: LANGUAGE \n" +"Language: ja-JP\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#: selfdrive/controls/lib/events.py:153 +msgid "openpilot Unavailable" +msgstr "オープンパイロットは利用できません" + +#: selfdrive/controls/lib/events.py:160 selfdrive/controls/lib/events.py:167 +msgid "TAKE CONTROL IMMEDIATELY" +msgstr "すぐにハンドルを持って" + +#: selfdrive/controls/lib/events.py:187 selfdrive/controls/lib/events.py:328 +#: selfdrive/controls/lib/events.py:354 selfdrive/controls/lib/events.py:418 +#: selfdrive/controls/lib/events.py:470 selfdrive/controls/lib/events.py:522 +#: selfdrive/controls/lib/events.py:532 +msgid "TAKE CONTROL" +msgstr "ハンドルを持って" + +#: selfdrive/controls/lib/events.py:188 +#, fuzzy, python-format +msgid "Steer Unavailable Below %(speed)d %(unit)s" +msgstr "横の制御が無効になり速度が以下になります" + +#: selfdrive/controls/lib/events.py:196 +#, fuzzy, python-format +msgid "Calibration in Progress: %d%%" +msgstr "キャリブレーション中:" + +#: selfdrive/controls/lib/events.py:197 +#, python-format +msgid "Drive Above %(speed)d %(unit)s" +msgstr "%(speed)d %(unit)s 制限速度以上の運転をしてください" + +#: selfdrive/controls/lib/events.py:204 +msgid "Poor GPS reception" +msgstr "GPS受信不良" + +#: selfdrive/controls/lib/events.py:205 +msgid "If sky is visible, contact support" +msgstr "地下・トンネルでない場合は、カスタマーサービスに連絡ください" + +#: selfdrive/controls/lib/events.py:205 +msgid "Check GPS antenna placement" +msgstr "GPSアンテナの位置を確認してください。" + +#: selfdrive/controls/lib/events.py:210 +msgid "Cruise Mode Disabled" +msgstr "クルーズモードをオフ" + +#: selfdrive/controls/lib/events.py:212 +msgid "Main Switch Off" +msgstr "メインスイッチをオフ" + +#: selfdrive/controls/lib/events.py:222 +msgid "DEBUG ALERT" +msgstr "テストメッセージを削除" + +#: selfdrive/controls/lib/events.py:230 +msgid "Be ready to take over at any time" +msgstr "いつでも引き継げるよう準備しておいてください。" + +#: selfdrive/controls/lib/events.py:231 selfdrive/controls/lib/events.py:239 +#: selfdrive/controls/lib/events.py:247 selfdrive/controls/lib/events.py:255 +msgid "Always keep hands on wheel and eyes on road" +msgstr "常にハンドルに触れ、道路から目を離さない" + +#: selfdrive/controls/lib/events.py:238 +msgid "WARNING: This branch is not tested" +msgstr "警告: このブランチはテストされていません" + +#: selfdrive/controls/lib/events.py:246 +msgid "Dashcam mode" +msgstr "ダッシュカムモード" + +#: selfdrive/controls/lib/events.py:254 +msgid "Dashcam mode for unsupported car" +msgstr "未対応車のためダッシュカムモードのみ" + +#: selfdrive/controls/lib/events.py:262 +msgid "Unsupported Giraffe Configuration" +msgstr "サポートされていないGiraffeの設定" + +#: selfdrive/controls/lib/events.py:263 +msgid "Visit comma.ai/tg" +msgstr "comma.ai/tg を参照" + +#: selfdrive/controls/lib/events.py:270 +msgid "White Panda Is No Longer Supported" +msgstr "ホワイトパンダはサポート終了しました" + +#: selfdrive/controls/lib/events.py:271 +msgid "Upgrade to comma two or black panda" +msgstr "コンマ2やブラックパンダにアップグレード" + +#: selfdrive/controls/lib/events.py:274 +msgid "White panda is no longer supported" +msgstr "ホワイトパンダはサポート終了しました" + +#: selfdrive/controls/lib/events.py:279 +msgid "Stock LKAS is turned on" +msgstr "純正LKASがオン" + +#: selfdrive/controls/lib/events.py:280 +msgid "Turn off stock LKAS to engage" +msgstr "純正LKASをオフにしてエンゲージ" + +#: selfdrive/controls/lib/events.py:288 +msgid "Community Feature Detected" +msgstr "コミュニティ開発の機能を検出" + +#: selfdrive/controls/lib/events.py:289 +msgid "Enable Community Features in Developer Settings" +msgstr "開発者設定でコミュニティ機能を有効にする" + +#: selfdrive/controls/lib/events.py:296 +msgid "Dashcam Mode" +msgstr "ダッシュカムモード" + +#: selfdrive/controls/lib/events.py:297 +msgid "Car Unrecognized" +msgstr "認識できない車" + +#: selfdrive/controls/lib/events.py:304 selfdrive/controls/lib/events.py:312 +#: selfdrive/controls/lib/events.py:320 +msgid "BRAKE!" +msgstr "ブレーキ!" + +#: selfdrive/controls/lib/events.py:305 +msgid "Stock AEB: Risk of Collision" +msgstr "衝突の危険" + +#: selfdrive/controls/lib/events.py:313 +msgid "Stock FCW: Risk of Collision" +msgstr "衝突の危険" + +#: selfdrive/controls/lib/events.py:321 +msgid "Risk of Collision" +msgstr "衝突の危険" + +#: selfdrive/controls/lib/events.py:329 +msgid "Lane Departure Detected" +msgstr "車線逸脱を検知" + +#: selfdrive/controls/lib/events.py:338 +msgid "openpilot will not brake while gas pressed" +msgstr "アクセル中、オープンパイロットはブレーキをかけません" + +#: selfdrive/controls/lib/events.py:346 +msgid "Vehicle Parameter Identification Failed" +msgstr "車両パラメータの識別に失敗しました。" + +#: selfdrive/controls/lib/events.py:355 selfdrive/controls/lib/events.py:523 +#: selfdrive/controls/lib/events.py:526 +msgid "Steering Temporarily Unavailable" +msgstr "ステアリングは一時的に利用不可" + +#: selfdrive/controls/lib/events.py:362 +msgid "KEEP EYES ON ROAD: Driver Distracted" +msgstr "道路から目を離さないで:注意散漫です" + +#: selfdrive/controls/lib/events.py:370 +msgid "KEEP EYES ON ROAD" +msgstr "道路から目を離さないで" + +#: selfdrive/controls/lib/events.py:371 +msgid "Driver Appears Distracted" +msgstr "ドライバーは注意散漫に見えます" + +#: selfdrive/controls/lib/events.py:378 selfdrive/controls/lib/events.py:402 +msgid "DISENGAGE IMMEDIATELY" +msgstr "すぐに解除してください" + +#: selfdrive/controls/lib/events.py:379 +msgid "Driver Was Distracted" +msgstr "ドライバーは注意力散漫" + +#: selfdrive/controls/lib/events.py:386 +msgid "TOUCH STEERING WHEEL: No Face Detected" +msgstr "ハンドルに触れて:顔が検出できない" + +#: selfdrive/controls/lib/events.py:394 +msgid "TOUCH STEERING WHEEL" +msgstr "ハンドルに触れて" + +#: selfdrive/controls/lib/events.py:395 +msgid "Driver Is Unresponsive" +msgstr "ドライバーが無反応" + +#: selfdrive/controls/lib/events.py:403 +msgid "Driver Was Unresponsive" +msgstr "ドライバーが無反応でした" + +#: selfdrive/controls/lib/events.py:410 +msgid "CHECK DRIVER FACE VISIBILITY" +msgstr "ドライバーの顔の視認性を確認" + +#: selfdrive/controls/lib/events.py:411 +msgid "Driver Monitor Model Output Uncertain" +msgstr "ドライバー監視モデルが不完全" + +#: selfdrive/controls/lib/events.py:419 +msgid "Resume Driving Manually" +msgstr "手動で運転を再開" + +#: selfdrive/controls/lib/events.py:426 +msgid "STOPPED" +msgstr "停止" + +#: selfdrive/controls/lib/events.py:427 +msgid "Press Resume to Move" +msgstr "Resumeを押して移動します。" + +#: selfdrive/controls/lib/events.py:438 +msgid "Steer Left to Start Lane Change" +msgstr "左ハンドルで車線変更を開始" + +#: selfdrive/controls/lib/events.py:439 selfdrive/controls/lib/events.py:447 +#: selfdrive/controls/lib/events.py:455 selfdrive/controls/lib/events.py:463 +#: selfdrive/controls/lib/events.py:802 selfdrive/controls/lib/events.py:810 +msgid "Monitor Other Vehicles" +msgstr "他の車両を監視" + +#: selfdrive/controls/lib/events.py:446 +msgid "Steer Right to Start Lane Change" +msgstr "右ハンドルで車線変更を開始" + +#: selfdrive/controls/lib/events.py:454 +msgid "Car Detected in Blindspot" +msgstr "ブラインドスポットで車両を発見" + +#: selfdrive/controls/lib/events.py:462 +msgid "Changing Lane" +msgstr "レーンチェンジ中" + +#: selfdrive/controls/lib/events.py:471 +msgid "Turn Exceeds Steering Limit" +msgstr "ステアリングリミットを超えています" + +#: selfdrive/controls/lib/events.py:496 +msgid "Brake Hold Active" +msgstr "サイドブレーキが作動" + +#: selfdrive/controls/lib/events.py:501 +msgid "Park Brake Engaged" +msgstr "サイドブレーキ作動中" + +#: selfdrive/controls/lib/events.py:506 +msgid "Pedal Pressed During Attempt" +msgstr "ペダル/ブレーキを検出" + +#: selfdrive/controls/lib/events.py:517 +msgid "Enable Adaptive Cruise" +msgstr "ACCを有効化" + +#: selfdrive/controls/lib/events.py:533 +msgid "Attempting Refocus: Camera Focus Invalid" +msgstr "再フォーカス中です" + +#: selfdrive/controls/lib/events.py:539 +msgid "Out of Storage Space" +msgstr "空き容量不足" + +#: selfdrive/controls/lib/events.py:544 +msgid "Speed Too Low" +msgstr "速度が遅すぎます" + +#: selfdrive/controls/lib/events.py:549 selfdrive/controls/lib/events.py:553 +msgid "NEOS Update Required" +msgstr "NEOSの更新が必要" + +#: selfdrive/controls/lib/events.py:550 +msgid "Please Wait for Update" +msgstr "更新をお待ちください" + +#: selfdrive/controls/lib/events.py:558 selfdrive/controls/lib/events.py:562 +msgid "No Data from Device Sensors" +msgstr "デバイスセンサからのデータがありません" + +#: selfdrive/controls/lib/events.py:559 selfdrive/controls/lib/events.py:572 +#: selfdrive/controls/lib/events.py:669 +msgid "Reboot your Device" +msgstr "デバイスを再起動" + +#: selfdrive/controls/lib/events.py:571 selfdrive/controls/lib/events.py:575 +msgid "Speaker not found" +msgstr "スピーカーが見つかりません" + +#: selfdrive/controls/lib/events.py:579 +msgid "Distraction Level Too High" +msgstr "注意力散漫すぎます" + +#: selfdrive/controls/lib/events.py:583 +msgid "System Overheated" +msgstr "オーバーヒート" + +#: selfdrive/controls/lib/events.py:584 +msgid "System overheated" +msgstr "オーバーヒート" + +#: selfdrive/controls/lib/events.py:588 selfdrive/controls/lib/events.py:589 +msgid "Gear not D" +msgstr "Dではない" + +#: selfdrive/controls/lib/events.py:594 +#, fuzzy +msgid "Calibration Invalid" +msgstr "キャリブレーション" + +#: selfdrive/controls/lib/events.py:595 +#, fuzzy +msgid "Reposition Device and Recalibrate" +msgstr "キャリブレーションが無効です。再実行してください。" + +#: selfdrive/controls/lib/events.py:598 selfdrive/controls/lib/events.py:599 +msgid "Calibration Invalid: Reposition Device & Recalibrate" +msgstr "キャリブレーションが無効です。再実行してください。" + +#: selfdrive/controls/lib/events.py:603 selfdrive/controls/lib/events.py:605 +msgid "Calibration in Progress" +msgstr "キャリブレーション" + +#: selfdrive/controls/lib/events.py:609 +msgid "Door Open" +msgstr "ドアが開いています" + +#: selfdrive/controls/lib/events.py:610 +msgid "Door open" +msgstr "ドアが開いています" + +#: selfdrive/controls/lib/events.py:614 +msgid "Seatbelt Unlatched" +msgstr "シートベルト未着用" + +#: selfdrive/controls/lib/events.py:615 +msgid "Seatbelt unlatched" +msgstr "シートベルト未着用" + +#: selfdrive/controls/lib/events.py:619 selfdrive/controls/lib/events.py:620 +msgid "ESP Off" +msgstr "ESPオフ" + +#: selfdrive/controls/lib/events.py:624 selfdrive/controls/lib/events.py:625 +msgid "Low Battery" +msgstr "低バッテリー" + +#: selfdrive/controls/lib/events.py:629 selfdrive/controls/lib/events.py:630 +msgid "Communication Issue between Processes" +msgstr "プロセス間の通信の問題" + +#: selfdrive/controls/lib/events.py:635 selfdrive/controls/lib/events.py:636 +msgid "Radar Communication Issue" +msgstr "レーダー通信問題" + +#: selfdrive/controls/lib/events.py:641 selfdrive/controls/lib/events.py:642 +#: selfdrive/controls/lib/events.py:646 selfdrive/controls/lib/events.py:647 +msgid "Radar Error: Restart the Car" +msgstr "レーダーエラー:車を再起動" + +#: selfdrive/controls/lib/events.py:651 selfdrive/controls/lib/events.py:652 +msgid "Driving model lagging" +msgstr "制御モデルに遅延がある" + +#: selfdrive/controls/lib/events.py:656 selfdrive/controls/lib/events.py:657 +msgid "Vision Model Output Uncertain" +msgstr "映像が不明瞭です" + +#: selfdrive/controls/lib/events.py:661 selfdrive/controls/lib/events.py:662 +msgid "Device Fell Off Mount" +msgstr "" + +#: selfdrive/controls/lib/events.py:666 selfdrive/controls/lib/events.py:672 +msgid "Low Memory: Reboot Your Device" +msgstr "ローメモリ:デバイスを再起動" + +#: selfdrive/controls/lib/events.py:668 +msgid "RAM Critically Low" +msgstr "RAMが致命的に低い" + +#: selfdrive/controls/lib/events.py:677 selfdrive/controls/lib/events.py:678 +msgid "Controls Failed" +msgstr "制御失敗" + +#: selfdrive/controls/lib/events.py:682 +msgid "Controls Mismatch" +msgstr "制御不一致" + +#: selfdrive/controls/lib/events.py:686 selfdrive/controls/lib/events.py:688 +#: selfdrive/controls/lib/events.py:692 +msgid "CAN Error: Check Connections" +msgstr "CANエラー:接続を確認" + +#: selfdrive/controls/lib/events.py:696 selfdrive/controls/lib/events.py:702 +msgid "LKAS Fault: Restart the Car" +msgstr "LKASの故障:車を再起動" + +#: selfdrive/controls/lib/events.py:698 +msgid "LKAS Fault: Restart the car to engage" +msgstr "LKASの故障:車を再起動後発進" + +#: selfdrive/controls/lib/events.py:706 selfdrive/controls/lib/events.py:712 +#: selfdrive/controls/lib/events.py:795 +msgid "Cruise Fault: Restart the Car" +msgstr "クルーズ失敗:車を再起動" + +#: selfdrive/controls/lib/events.py:708 selfdrive/controls/lib/events.py:791 +msgid "Cruise Fault: Restart the car to engage" +msgstr "クルーズ失敗:車を再起動後発進" + +#: selfdrive/controls/lib/events.py:716 +msgid "Gas Fault: Restart the Car" +msgstr "アクセル故障:車を再起動" + +#: selfdrive/controls/lib/events.py:717 +msgid "Gas Error: Restart the Car" +msgstr "アクセルエラー:車を再起動" + +#: selfdrive/controls/lib/events.py:722 +#, fuzzy +msgid "" +"Reverse\n" +"Gear" +msgstr "Rに切り替え" + +#: selfdrive/controls/lib/events.py:726 +msgid "Reverse Gear" +msgstr "Rに切り替え" + +#: selfdrive/controls/lib/events.py:731 +msgid "Cruise Is Off" +msgstr "クルーズコントロールオフ" + +#: selfdrive/controls/lib/events.py:735 selfdrive/controls/lib/events.py:736 +msgid "Planner Solution Error" +msgstr "Planner Solution エラー" + +#: selfdrive/controls/lib/events.py:740 selfdrive/controls/lib/events.py:742 +#: selfdrive/controls/lib/events.py:746 +msgid "Harness Malfunction" +msgstr "ハーネスが故障" + +#: selfdrive/controls/lib/events.py:743 +msgid "Please Check Hardware" +msgstr "ハードウェアを確認して" + +#: selfdrive/controls/lib/events.py:751 selfdrive/controls/lib/events.py:760 +msgid "openpilot Canceled" +msgstr "オープンパイロットはキャンセルされました" + +#: selfdrive/controls/lib/events.py:752 +msgid "No close lead car" +msgstr "リードカー不在" + +#: selfdrive/controls/lib/events.py:755 +msgid "No Close Lead Car" +msgstr "リードカー不在" + +#: selfdrive/controls/lib/events.py:761 +msgid "Speed too low" +msgstr "速度が遅すぎる" + +#: selfdrive/controls/lib/events.py:768 selfdrive/controls/lib/events.py:773 +msgid "Speed Too High" +msgstr "速度が速すぎる" + +#: selfdrive/controls/lib/events.py:769 +msgid "Slow down to resume operation" +msgstr "速度を下げてオープンパイロットを再開" + +#: selfdrive/controls/lib/events.py:774 +msgid "Slow down to engage" +msgstr "速度を落として発進" + +#: selfdrive/controls/lib/events.py:781 +msgid "Please connect to Internet" +msgstr "インターネット接続を確認" + +#: selfdrive/controls/lib/events.py:782 +msgid "An Update Check Is Required to Engage" +msgstr "発進するには更新が必要です" + +#: selfdrive/controls/lib/events.py:785 +msgid "Please Connect to Internet" +msgstr "インターネット接続を確認" + +#: selfdrive/controls/lib/events.py:801 +msgid "Left ALC will start in 3s" +msgstr "左車線に移動します" + +#: selfdrive/controls/lib/events.py:809 +msgid "Right ALC will start in 3s" +msgstr "右車線に移動します" + +#: selfdrive/controls/lib/events.py:817 +msgid "STEERING REQUIRED: Lane Keeping OFF" +msgstr "操作が必要:レーンキープオフ" + +#: selfdrive/controls/lib/events.py:825 +msgid "STEERING REQUIRED: Blinkers ON" +msgstr "操作が必要:ウインカーオン" + +#: selfdrive/controls/lib/events.py:833 selfdrive/controls/lib/events.py:838 +msgid "Lead Car Is Moving" +msgstr "リードカーが移動しました" + +#: selfdrive/controls/lib/events.py:847 +msgid "WARNING" +msgstr "" + +#: selfdrive/controls/lib/events.py:848 +msgid "Grab wheel to start bypass" +msgstr "" + +#: selfdrive/controls/lib/events.py:855 +msgid "BYPASSING" +msgstr "" + +#: selfdrive/controls/lib/events.py:856 +msgid "HOLD WHEEL" +msgstr "" + +#: selfdrive/controls/lib/events.py:863 +msgid "Bypassed!" +msgstr "" + +#: selfdrive/controls/lib/events.py:864 +msgid "Release wheel when ready" +msgstr "" + +#~ msgid "Drive Above" +#~ msgstr "制限速度以上の運転をしてください" diff --git a/selfdrive/assets/locales/ko-KR/LC_MESSAGES/events.mo b/selfdrive/assets/locales/ko-KR/LC_MESSAGES/events.mo new file mode 100644 index 00000000000000..951599fffbe09e Binary files /dev/null and b/selfdrive/assets/locales/ko-KR/LC_MESSAGES/events.mo differ diff --git a/selfdrive/assets/locales/ko-KR/LC_MESSAGES/events.po b/selfdrive/assets/locales/ko-KR/LC_MESSAGES/events.po new file mode 100644 index 00000000000000..63d8438ec7e1b3 --- /dev/null +++ b/selfdrive/assets/locales/ko-KR/LC_MESSAGES/events.po @@ -0,0 +1,543 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2020-10-15 13:37+1000\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME \n" +"Language-Team: LANGUAGE \n" +"Language: ko-KR\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#: selfdrive/controls/lib/events.py:153 +msgid "openpilot Unavailable" +msgstr "오픈파일럿 사용불가" + +#: selfdrive/controls/lib/events.py:160 selfdrive/controls/lib/events.py:167 +msgid "TAKE CONTROL IMMEDIATELY" +msgstr "핸들을 잡아주세요" + +#: selfdrive/controls/lib/events.py:187 selfdrive/controls/lib/events.py:328 +#: selfdrive/controls/lib/events.py:354 selfdrive/controls/lib/events.py:418 +#: selfdrive/controls/lib/events.py:470 selfdrive/controls/lib/events.py:522 +#: selfdrive/controls/lib/events.py:532 +msgid "TAKE CONTROL" +msgstr "핸들을 잡아주세요" + +#: selfdrive/controls/lib/events.py:188 +#, fuzzy, python-format +msgid "Steer Unavailable Below %(speed)d %(unit)s" +msgstr "%d %s 이하에서는 조향제어가 불가합니다" + +#: selfdrive/controls/lib/events.py:196 +#, fuzzy, python-format +msgid "Calibration in Progress: %d%%" +msgstr "캘리브레이션 진행중: %d%%" + +#: selfdrive/controls/lib/events.py:197 +#, fuzzy, python-format +msgid "Drive Above %(speed)d %(unit)s" +msgstr "%(speed)d %(unit)s 이상의 속도로 주행하세요" + +#: selfdrive/controls/lib/events.py:204 +msgid "Poor GPS reception" +msgstr "GPS 신호 약함" + +#: selfdrive/controls/lib/events.py:205 +msgid "If sky is visible, contact support" +msgstr "환경에 문제가 없을경우 서비스팀에 연락하세요" + +#: selfdrive/controls/lib/events.py:205 +msgid "Check GPS antenna placement" +msgstr "GPS안테나 위치를 점검하세요" + +#: selfdrive/controls/lib/events.py:210 +msgid "Cruise Mode Disabled" +msgstr "크루즈 모드 꺼짐" + +#: selfdrive/controls/lib/events.py:212 +msgid "Main Switch Off" +msgstr "" + +#: selfdrive/controls/lib/events.py:222 +msgid "DEBUG ALERT" +msgstr "" + +#: selfdrive/controls/lib/events.py:230 +msgid "Be ready to take over at any time" +msgstr "오픈파일럿 사용준비가 되었습니다" + +#: selfdrive/controls/lib/events.py:231 selfdrive/controls/lib/events.py:239 +#: selfdrive/controls/lib/events.py:247 selfdrive/controls/lib/events.py:255 +msgid "Always keep hands on wheel and eyes on road" +msgstr "안전운전을 위해 항상 핸들을 잡고 도로교통 상황을 주시하세요" + +#: selfdrive/controls/lib/events.py:238 +msgid "WARNING: This branch is not tested" +msgstr "경고: 이 Branch는 테스트되지 않았습니다" + +#: selfdrive/controls/lib/events.py:246 +msgid "Dashcam mode" +msgstr "대시캠 모드" + +#: selfdrive/controls/lib/events.py:254 +msgid "Dashcam mode for unsupported car" +msgstr "안전운전을 위해 항상 핸들을 잡고 도로교통 상황을 주시하세요" + +#: selfdrive/controls/lib/events.py:262 +msgid "Unsupported Giraffe Configuration" +msgstr "지원되지 않는 지라프 설정" + +#: selfdrive/controls/lib/events.py:263 +msgid "Visit comma.ai/tg" +msgstr "comma.ai/tg 방문하세요" + +#: selfdrive/controls/lib/events.py:270 +msgid "White Panda Is No Longer Supported" +msgstr "화이트판다는 더 이상 지원되지 않습니다" + +#: selfdrive/controls/lib/events.py:271 +msgid "Upgrade to comma two or black panda" +msgstr "콤마2나 블랙판다로 업그레이드 하세요" + +#: selfdrive/controls/lib/events.py:274 +msgid "White panda is no longer supported" +msgstr "화이트판다는 더 이상 지원되지 않습니다" + +#: selfdrive/controls/lib/events.py:279 +msgid "Stock LKAS is turned on" +msgstr "차량의 LKAS 기능이 켜져 있습니다" + +#: selfdrive/controls/lib/events.py:280 +msgid "Turn off stock LKAS to engage" +msgstr "오픈파일럿 사용을 위해 LKAS를 끄세요" + +#: selfdrive/controls/lib/events.py:288 +msgid "Community Feature Detected" +msgstr "커뮤니티 기능 감지됨" + +#: selfdrive/controls/lib/events.py:289 +msgid "Enable Community Features in Developer Settings" +msgstr "개발자 설정에서 커뮤니티 기능을 활성화하세요" + +#: selfdrive/controls/lib/events.py:296 +msgid "Dashcam Mode" +msgstr "대시캠 모드" + +#: selfdrive/controls/lib/events.py:297 +msgid "Car Unrecognized" +msgstr "미인식 차량" + +#: selfdrive/controls/lib/events.py:304 selfdrive/controls/lib/events.py:312 +#: selfdrive/controls/lib/events.py:320 +msgid "BRAKE!" +msgstr "브레이크!" + +#: selfdrive/controls/lib/events.py:305 +msgid "Stock AEB: Risk of Collision" +msgstr "순정 AEB: 충돌 위험" + +#: selfdrive/controls/lib/events.py:313 +msgid "Stock FCW: Risk of Collision" +msgstr "순정 FCW: 충돌 위험" + +#: selfdrive/controls/lib/events.py:321 +msgid "Risk of Collision" +msgstr "충돌 위험" + +#: selfdrive/controls/lib/events.py:329 +msgid "Lane Departure Detected" +msgstr "차선이탈이 감지되었습니다" + +#: selfdrive/controls/lib/events.py:338 +msgid "openpilot will not brake while gas pressed" +msgstr "가속중에는 오픈파일럿 브레이크 작동불가" + +#: selfdrive/controls/lib/events.py:346 +msgid "Vehicle Parameter Identification Failed" +msgstr "차량 매개 변수 식별 실패" + +#: selfdrive/controls/lib/events.py:355 selfdrive/controls/lib/events.py:523 +#: selfdrive/controls/lib/events.py:526 +msgid "Steering Temporarily Unavailable" +msgstr "조향제어가 일시적으로 비활성화 되었습니다" + +#: selfdrive/controls/lib/events.py:362 +msgid "KEEP EYES ON ROAD: Driver Distracted" +msgstr "도로상황에 주의를 기울이세요" + +#: selfdrive/controls/lib/events.py:370 +msgid "KEEP EYES ON ROAD" +msgstr "도로상황에 주의하세요" + +#: selfdrive/controls/lib/events.py:371 +msgid "Driver Appears Distracted" +msgstr "전방주시 필요" + +#: selfdrive/controls/lib/events.py:378 selfdrive/controls/lib/events.py:402 +msgid "DISENGAGE IMMEDIATELY" +msgstr "경고: 조향제어가 즉시 해제됩니다" + +#: selfdrive/controls/lib/events.py:379 +msgid "Driver Was Distracted" +msgstr "운전자 전방주시 불안" + +#: selfdrive/controls/lib/events.py:386 +msgid "TOUCH STEERING WHEEL: No Face Detected" +msgstr "핸들을 터치하세요: 모니터링 없음" + +#: selfdrive/controls/lib/events.py:394 +msgid "TOUCH STEERING WHEEL" +msgstr "핸들을 터치하세요" + +#: selfdrive/controls/lib/events.py:395 +msgid "Driver Is Unresponsive" +msgstr "운전자 모니터링 없음" + +#: selfdrive/controls/lib/events.py:403 +msgid "Driver Was Unresponsive" +msgstr "운전자 모니터링 없음" + +#: selfdrive/controls/lib/events.py:410 +msgid "CHECK DRIVER FACE VISIBILITY" +msgstr "운전자 얼굴 확인 중" + +#: selfdrive/controls/lib/events.py:411 +msgid "Driver Monitor Model Output Uncertain" +msgstr "운전자 얼굴 인식이 어렵습니다" + +#: selfdrive/controls/lib/events.py:419 +msgid "Resume Driving Manually" +msgstr "수동으로 재출발 하세요" + +#: selfdrive/controls/lib/events.py:426 +msgid "STOPPED" +msgstr "잠시멈춤" + +#: selfdrive/controls/lib/events.py:427 +msgid "Press Resume to Move" +msgstr "재출발을 위해 RES버튼을 누르세요" + +#: selfdrive/controls/lib/events.py:438 +msgid "Steer Left to Start Lane Change" +msgstr "차선 변경을 위해 핸들을 좌측으로 살짝 돌리세요" + +#: selfdrive/controls/lib/events.py:439 selfdrive/controls/lib/events.py:447 +#: selfdrive/controls/lib/events.py:455 selfdrive/controls/lib/events.py:463 +#: selfdrive/controls/lib/events.py:802 selfdrive/controls/lib/events.py:810 +msgid "Monitor Other Vehicles" +msgstr "다른 차량에 주의하세요" + +#: selfdrive/controls/lib/events.py:446 +msgid "Steer Right to Start Lane Change" +msgstr "차선 변경을 위해 핸들을 우측으로 살짝 돌리세요" + +#: selfdrive/controls/lib/events.py:454 +msgid "Car Detected in Blindspot" +msgstr "측면 차량 접근 중" + +#: selfdrive/controls/lib/events.py:462 +msgid "Changing Lane" +msgstr "차선 변경 중" + +#: selfdrive/controls/lib/events.py:471 +msgid "Turn Exceeds Steering Limit" +msgstr "" + +#: selfdrive/controls/lib/events.py:496 +msgid "Brake Hold Active" +msgstr "브레이크 홀드 중" + +#: selfdrive/controls/lib/events.py:501 +msgid "Park Brake Engaged" +msgstr "파킹브레이크 체결 됨" + +#: selfdrive/controls/lib/events.py:506 +msgid "Pedal Pressed During Attempt" +msgstr "시작 중 페달 밟음" + +#: selfdrive/controls/lib/events.py:517 +msgid "Enable Adaptive Cruise" +msgstr "어댑티브 크루즈를 활성화하세요" + +#: selfdrive/controls/lib/events.py:533 +msgid "Attempting Refocus: Camera Focus Invalid" +msgstr "카메라 포커스 조정중: 카메라 포커스 부정확" + +#: selfdrive/controls/lib/events.py:539 +msgid "Out of Storage Space" +msgstr "저장공간 부족" + +#: selfdrive/controls/lib/events.py:544 +msgid "Speed Too Low" +msgstr "차량의 속도 낮음" + +#: selfdrive/controls/lib/events.py:549 selfdrive/controls/lib/events.py:553 +msgid "NEOS Update Required" +msgstr "NEOS 업데이트 필요" + +#: selfdrive/controls/lib/events.py:550 +msgid "Please Wait for Update" +msgstr "업데이트를 위해 기다리세요" + +#: selfdrive/controls/lib/events.py:558 selfdrive/controls/lib/events.py:562 +msgid "No Data from Device Sensors" +msgstr "EON센서로부터 데이터를 받지 못했습니다" + +#: selfdrive/controls/lib/events.py:559 selfdrive/controls/lib/events.py:572 +#: selfdrive/controls/lib/events.py:669 +msgid "Reboot your Device" +msgstr "장치를 재시작 하세요" + +#: selfdrive/controls/lib/events.py:571 selfdrive/controls/lib/events.py:575 +msgid "Speaker not found" +msgstr "스피커를 찾을 수 없습니다" + +#: selfdrive/controls/lib/events.py:579 +msgid "Distraction Level Too High" +msgstr "운전자 전방주시 매우 불안" + +#: selfdrive/controls/lib/events.py:583 +msgid "System Overheated" +msgstr "시스템이 과열되었습니다" + +#: selfdrive/controls/lib/events.py:584 +msgid "System overheated" +msgstr "시스템이 과열되었습니다" + +#: selfdrive/controls/lib/events.py:588 selfdrive/controls/lib/events.py:589 +msgid "Gear not D" +msgstr "기어가 드라이브모드가 아닙니다" + +#: selfdrive/controls/lib/events.py:594 +#, fuzzy +msgid "Calibration Invalid" +msgstr "캘리브레이션 진행 중" + +#: selfdrive/controls/lib/events.py:595 +#, fuzzy +msgid "Reposition Device and Recalibrate" +msgstr "캘리브레이션 유효하지 않음: 장치 위치 조정 및 재 캘리브레이션" + +#: selfdrive/controls/lib/events.py:598 selfdrive/controls/lib/events.py:599 +msgid "Calibration Invalid: Reposition Device & Recalibrate" +msgstr "캘리브레이션 유효하지 않음: 장치 위치 조정 및 재 캘리브레이션" + +#: selfdrive/controls/lib/events.py:603 selfdrive/controls/lib/events.py:605 +msgid "Calibration in Progress" +msgstr "캘리브레이션 진행 중" + +#: selfdrive/controls/lib/events.py:609 +msgid "Door Open" +msgstr "도어가 열려있습니다" + +#: selfdrive/controls/lib/events.py:610 +msgid "Door open" +msgstr "도어가 열려있습니다" + +#: selfdrive/controls/lib/events.py:614 +msgid "Seatbelt Unlatched" +msgstr "안전벨트를 체결하세요" + +#: selfdrive/controls/lib/events.py:615 +msgid "Seatbelt unlatched" +msgstr "안전벨트를 체결하세요" + +#: selfdrive/controls/lib/events.py:619 selfdrive/controls/lib/events.py:620 +msgid "ESP Off" +msgstr "ESP 꺼짐" + +#: selfdrive/controls/lib/events.py:624 selfdrive/controls/lib/events.py:625 +msgid "Low Battery" +msgstr "배터리 부족" + +#: selfdrive/controls/lib/events.py:629 selfdrive/controls/lib/events.py:630 +msgid "Communication Issue between Processes" +msgstr "프로세스 간 통신 오류가 있습니다" + +#: selfdrive/controls/lib/events.py:635 selfdrive/controls/lib/events.py:636 +msgid "Radar Communication Issue" +msgstr "레이더 오류: 차량을 재시작하세요" + +#: selfdrive/controls/lib/events.py:641 selfdrive/controls/lib/events.py:642 +#: selfdrive/controls/lib/events.py:646 selfdrive/controls/lib/events.py:647 +msgid "Radar Error: Restart the Car" +msgstr "레이더 오류: 차량을 재시작하세요" + +#: selfdrive/controls/lib/events.py:651 selfdrive/controls/lib/events.py:652 +msgid "Driving model lagging" +msgstr "주행 모델 지연" + +#: selfdrive/controls/lib/events.py:656 selfdrive/controls/lib/events.py:657 +msgid "Vision Model Output Uncertain" +msgstr "전방 영상 인식 불안" + +#: selfdrive/controls/lib/events.py:661 selfdrive/controls/lib/events.py:662 +msgid "Device Fell Off Mount" +msgstr "" + +#: selfdrive/controls/lib/events.py:666 selfdrive/controls/lib/events.py:672 +msgid "Low Memory: Reboot Your Device" +msgstr "메모리 부족: 장치를 재시작하세요" + +#: selfdrive/controls/lib/events.py:668 +msgid "RAM Critically Low" +msgstr "메모리 부족 심각" + +#: selfdrive/controls/lib/events.py:677 selfdrive/controls/lib/events.py:678 +msgid "Controls Failed" +msgstr "차량제어 불가" + +#: selfdrive/controls/lib/events.py:682 +msgid "Controls Mismatch" +msgstr "" + +#: selfdrive/controls/lib/events.py:686 selfdrive/controls/lib/events.py:688 +#: selfdrive/controls/lib/events.py:692 +msgid "CAN Error: Check Connections" +msgstr "CAN 오류: CAN 신호를 확인하세요" + +#: selfdrive/controls/lib/events.py:696 selfdrive/controls/lib/events.py:702 +msgid "LKAS Fault: Restart the Car" +msgstr "LKAS 오류: 차량을 재시작하세요" + +#: selfdrive/controls/lib/events.py:698 +msgid "LKAS Fault: Restart the car to engage" +msgstr "LKAS 오류: 시작을 위해 차량을 재시작하세요" + +#: selfdrive/controls/lib/events.py:706 selfdrive/controls/lib/events.py:712 +#: selfdrive/controls/lib/events.py:795 +msgid "Cruise Fault: Restart the Car" +msgstr "크루즈 오류: 차량을 재시작하세요" + +#: selfdrive/controls/lib/events.py:708 selfdrive/controls/lib/events.py:791 +msgid "Cruise Fault: Restart the car to engage" +msgstr "크루즈 오류: 시작을 위해 차량을 재시작하세요" + +#: selfdrive/controls/lib/events.py:716 +msgid "Gas Fault: Restart the Car" +msgstr "가속페달 오류: 차량을 재시작하세요" + +#: selfdrive/controls/lib/events.py:717 +msgid "Gas Error: Restart the Car" +msgstr "가속페달 오류: 차량을 재시작하세요" + +#: selfdrive/controls/lib/events.py:722 +#, fuzzy +msgid "" +"Reverse\n" +"Gear" +msgstr "후진 기어" + +#: selfdrive/controls/lib/events.py:726 +msgid "Reverse Gear" +msgstr "후진 기어" + +#: selfdrive/controls/lib/events.py:731 +msgid "Cruise Is Off" +msgstr "크루즈 꺼짐" + +#: selfdrive/controls/lib/events.py:735 selfdrive/controls/lib/events.py:736 +msgid "Planner Solution Error" +msgstr "" + +#: selfdrive/controls/lib/events.py:740 selfdrive/controls/lib/events.py:742 +#: selfdrive/controls/lib/events.py:746 +msgid "Harness Malfunction" +msgstr "하네스 오작동" + +#: selfdrive/controls/lib/events.py:743 +msgid "Please Check Hardware" +msgstr "장치를 점검하세요" + +#: selfdrive/controls/lib/events.py:751 selfdrive/controls/lib/events.py:760 +msgid "openpilot Canceled" +msgstr "오픈파일럿 시작불가" + +#: selfdrive/controls/lib/events.py:752 +msgid "No close lead car" +msgstr "선행차량이 없습니다" + +#: selfdrive/controls/lib/events.py:755 +msgid "No Close Lead Car" +msgstr "선행차량이 없습니다" + +#: selfdrive/controls/lib/events.py:761 +msgid "Speed too low" +msgstr "선행차량이 없습니다" + +#: selfdrive/controls/lib/events.py:768 selfdrive/controls/lib/events.py:773 +msgid "Speed Too High" +msgstr "속도가 너무 높습니다" + +#: selfdrive/controls/lib/events.py:769 +msgid "Slow down to resume operation" +msgstr "재 작동을 위해 차량의 속도를 낮추세요" + +#: selfdrive/controls/lib/events.py:774 +msgid "Slow down to engage" +msgstr "시작을 위해 차량의 속도를 낮추세요" + +#: selfdrive/controls/lib/events.py:781 +msgid "Please connect to Internet" +msgstr "인터넷에 연결하세요" + +#: selfdrive/controls/lib/events.py:782 +msgid "An Update Check Is Required to Engage" +msgstr "시작을 위해 업데이트를 확인해야 합니다" + +#: selfdrive/controls/lib/events.py:785 +msgid "Please Connect to Internet" +msgstr "인터넷에 연결하세요" + +#: selfdrive/controls/lib/events.py:801 +msgid "Left ALC will start in 3s" +msgstr "" + +#: selfdrive/controls/lib/events.py:809 +msgid "Right ALC will start in 3s" +msgstr "" + +#: selfdrive/controls/lib/events.py:817 +msgid "STEERING REQUIRED: Lane Keeping OFF" +msgstr "" + +#: selfdrive/controls/lib/events.py:825 +msgid "STEERING REQUIRED: Blinkers ON" +msgstr "" + +#: selfdrive/controls/lib/events.py:833 selfdrive/controls/lib/events.py:838 +msgid "Lead Car Is Moving" +msgstr "" + +#: selfdrive/controls/lib/events.py:847 +msgid "WARNING" +msgstr "" + +#: selfdrive/controls/lib/events.py:848 +msgid "Grab wheel to start bypass" +msgstr "" + +#: selfdrive/controls/lib/events.py:855 +msgid "BYPASSING" +msgstr "" + +#: selfdrive/controls/lib/events.py:856 +msgid "HOLD WHEEL" +msgstr "" + +#: selfdrive/controls/lib/events.py:863 +msgid "Bypassed!" +msgstr "" + +#: selfdrive/controls/lib/events.py:864 +msgid "Release wheel when ready" +msgstr "" diff --git a/selfdrive/assets/locales/zh-CN/LC_MESSAGES/events.mo b/selfdrive/assets/locales/zh-CN/LC_MESSAGES/events.mo new file mode 100644 index 00000000000000..f808fbc6704d76 Binary files /dev/null and b/selfdrive/assets/locales/zh-CN/LC_MESSAGES/events.mo differ diff --git a/selfdrive/assets/locales/zh-CN/LC_MESSAGES/events.po b/selfdrive/assets/locales/zh-CN/LC_MESSAGES/events.po new file mode 100644 index 00000000000000..364d302942d663 --- /dev/null +++ b/selfdrive/assets/locales/zh-CN/LC_MESSAGES/events.po @@ -0,0 +1,542 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2020-10-15 13:37+1000\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: Rick Lan \n" +"Language-Team: LANGUAGE \n" +"Language: zh-CN\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#: selfdrive/controls/lib/events.py:153 +msgid "openpilot Unavailable" +msgstr "无法使用 openpilot" + +#: selfdrive/controls/lib/events.py:160 selfdrive/controls/lib/events.py:167 +msgid "TAKE CONTROL IMMEDIATELY" +msgstr "即刻接管控制" + +#: selfdrive/controls/lib/events.py:187 selfdrive/controls/lib/events.py:328 +#: selfdrive/controls/lib/events.py:354 selfdrive/controls/lib/events.py:418 +#: selfdrive/controls/lib/events.py:470 selfdrive/controls/lib/events.py:522 +#: selfdrive/controls/lib/events.py:532 +msgid "TAKE CONTROL" +msgstr "接管控制" + +#: selfdrive/controls/lib/events.py:188 +#, fuzzy, python-format +msgid "Steer Unavailable Below %(speed)d %(unit)s" +msgstr "横向控制暂时失效,车速低于 %d %s" + +#: selfdrive/controls/lib/events.py:196 +#, fuzzy, python-format +msgid "Calibration in Progress: %d%%" +msgstr "正在校准中:%d%%" + +#: selfdrive/controls/lib/events.py:197 +#, fuzzy, python-format +msgid "Drive Above %(speed)d %(unit)s" +msgstr "车速请高于 %(speed)d %(unit)s" + +#: selfdrive/controls/lib/events.py:204 +msgid "Poor GPS reception" +msgstr "GPS 讯号不良" + +#: selfdrive/controls/lib/events.py:205 +msgid "If sky is visible, contact support" +msgstr "如果您不在地下室/隧道,请联系客服" + +#: selfdrive/controls/lib/events.py:205 +msgid "Check GPS antenna placement" +msgstr "请检查 GPS 天线位置" + +#: selfdrive/controls/lib/events.py:210 +msgid "Cruise Mode Disabled" +msgstr "巡航模式关闭" + +#: selfdrive/controls/lib/events.py:212 +msgid "Main Switch Off" +msgstr "主开关已关闭" + +#: selfdrive/controls/lib/events.py:222 +msgid "DEBUG ALERT" +msgstr "除错用警示讯息" + +#: selfdrive/controls/lib/events.py:230 +msgid "Be ready to take over at any time" +msgstr "请准备好随时接管" + +#: selfdrive/controls/lib/events.py:231 selfdrive/controls/lib/events.py:239 +#: selfdrive/controls/lib/events.py:247 selfdrive/controls/lib/events.py:255 +msgid "Always keep hands on wheel and eyes on road" +msgstr "将手放在方向盘上并持续监视路况" + +#: selfdrive/controls/lib/events.py:238 +msgid "WARNING: This branch is not tested" +msgstr "注意:这个分支未经过测试" + +#: selfdrive/controls/lib/events.py:246 +msgid "Dashcam mode" +msgstr "行车记录模式" + +#: selfdrive/controls/lib/events.py:254 +msgid "Dashcam mode for unsupported car" +msgstr "行车记录模式 (尚未支援车种)" + +#: selfdrive/controls/lib/events.py:262 +msgid "Unsupported Giraffe Configuration" +msgstr "未支援的 Giraffe 设置" + +#: selfdrive/controls/lib/events.py:263 +msgid "Visit comma.ai/tg" +msgstr "请查阅 comma.ai/tg" + +#: selfdrive/controls/lib/events.py:270 +msgid "White Panda Is No Longer Supported" +msgstr "不再支持 White Panda" + +#: selfdrive/controls/lib/events.py:271 +msgid "Upgrade to comma two or black panda" +msgstr "请升级至 comma two 或是使用 black panda" + +#: selfdrive/controls/lib/events.py:274 +msgid "White panda is no longer supported" +msgstr "不再支持 White panda" + +#: selfdrive/controls/lib/events.py:279 +msgid "Stock LKAS is turned on" +msgstr "原厂 LKAS 已开启" + +#: selfdrive/controls/lib/events.py:280 +msgid "Turn off stock LKAS to engage" +msgstr "需关闭原厂 LKAS 才能启用" + +#: selfdrive/controls/lib/events.py:288 +msgid "Community Feature Detected" +msgstr "检测到社群开发功能" + +#: selfdrive/controls/lib/events.py:289 +msgid "Enable Community Features in Developer Settings" +msgstr "请至开发人员设定裡启用社群开发功能" + +#: selfdrive/controls/lib/events.py:296 +msgid "Dashcam Mode" +msgstr "行车记录模式" + +#: selfdrive/controls/lib/events.py:297 +msgid "Car Unrecognized" +msgstr "无法辨识车款" + +#: selfdrive/controls/lib/events.py:304 selfdrive/controls/lib/events.py:312 +#: selfdrive/controls/lib/events.py:320 +msgid "BRAKE!" +msgstr "刹车!" + +#: selfdrive/controls/lib/events.py:305 +msgid "Stock AEB: Risk of Collision" +msgstr "有碰撞的风险" + +#: selfdrive/controls/lib/events.py:313 +msgid "Stock FCW: Risk of Collision" +msgstr "有碰撞的风险" + +#: selfdrive/controls/lib/events.py:321 +msgid "Risk of Collision" +msgstr "有碰撞的风险" + +#: selfdrive/controls/lib/events.py:329 +msgid "Lane Departure Detected" +msgstr "偏离车道" + +#: selfdrive/controls/lib/events.py:338 +msgid "openpilot will not brake while gas pressed" +msgstr "在您踩着油门的时候 openpilot 将不会刹车" + +#: selfdrive/controls/lib/events.py:346 +msgid "Vehicle Parameter Identification Failed" +msgstr "车子参数识别失败" + +#: selfdrive/controls/lib/events.py:355 selfdrive/controls/lib/events.py:523 +#: selfdrive/controls/lib/events.py:526 +msgid "Steering Temporarily Unavailable" +msgstr "横向控制暂时失效" + +#: selfdrive/controls/lib/events.py:362 +msgid "KEEP EYES ON ROAD: Driver Distracted" +msgstr "注意路况:驾驶分心" + +#: selfdrive/controls/lib/events.py:370 +msgid "KEEP EYES ON ROAD" +msgstr "注意路况" + +#: selfdrive/controls/lib/events.py:371 +msgid "Driver Appears Distracted" +msgstr "驾驶分心" + +#: selfdrive/controls/lib/events.py:378 selfdrive/controls/lib/events.py:402 +msgid "DISENGAGE IMMEDIATELY" +msgstr "立即解除" + +#: selfdrive/controls/lib/events.py:379 +msgid "Driver Was Distracted" +msgstr "驾驶分心" + +#: selfdrive/controls/lib/events.py:386 +msgid "TOUCH STEERING WHEEL: No Face Detected" +msgstr "请触碰方向盘:未侦测到驾驶面容" + +#: selfdrive/controls/lib/events.py:394 +msgid "TOUCH STEERING WHEEL" +msgstr "请触碰方向盘" + +#: selfdrive/controls/lib/events.py:395 +msgid "Driver Is Unresponsive" +msgstr "驾驶没有反应" + +#: selfdrive/controls/lib/events.py:403 +msgid "Driver Was Unresponsive" +msgstr "驾驶没有反应" + +#: selfdrive/controls/lib/events.py:410 +msgid "CHECK DRIVER FACE VISIBILITY" +msgstr "请检查驾驶面部的可见度" + +#: selfdrive/controls/lib/events.py:411 +msgid "Driver Monitor Model Output Uncertain" +msgstr "驾驶监控模型判断不明确" + +#: selfdrive/controls/lib/events.py:419 +msgid "Resume Driving Manually" +msgstr "请自行恢復驾驶" + +#: selfdrive/controls/lib/events.py:426 +msgid "STOPPED" +msgstr "已停止" + +#: selfdrive/controls/lib/events.py:427 +msgid "Press Resume to Move" +msgstr "请按 RES 继续" + +#: selfdrive/controls/lib/events.py:438 +msgid "Steer Left to Start Lane Change" +msgstr "请往左打方向盘切换至左车道" + +#: selfdrive/controls/lib/events.py:439 selfdrive/controls/lib/events.py:447 +#: selfdrive/controls/lib/events.py:455 selfdrive/controls/lib/events.py:463 +#: selfdrive/controls/lib/events.py:802 selfdrive/controls/lib/events.py:810 +msgid "Monitor Other Vehicles" +msgstr "请注意其它车辆" + +#: selfdrive/controls/lib/events.py:446 +msgid "Steer Right to Start Lane Change" +msgstr "请往右打方向盘切换至右车道" + +#: selfdrive/controls/lib/events.py:454 +msgid "Car Detected in Blindspot" +msgstr "盲点侦测到车辆" + +#: selfdrive/controls/lib/events.py:462 +msgid "Changing Lane" +msgstr "切换车道中" + +#: selfdrive/controls/lib/events.py:471 +msgid "Turn Exceeds Steering Limit" +msgstr "弯道超过横向操控限制" + +#: selfdrive/controls/lib/events.py:496 +msgid "Brake Hold Active" +msgstr "驻车煞车已启用" + +#: selfdrive/controls/lib/events.py:501 +msgid "Park Brake Engaged" +msgstr "电子驻车已启动" + +#: selfdrive/controls/lib/events.py:506 +msgid "Pedal Pressed During Attempt" +msgstr "启用时侦测到驾驶踩踏油门/刹车" + +#: selfdrive/controls/lib/events.py:517 +msgid "Enable Adaptive Cruise" +msgstr "启用自适应巡航" + +#: selfdrive/controls/lib/events.py:533 +msgid "Attempting Refocus: Camera Focus Invalid" +msgstr "尝试对焦:相机已失焦" + +#: selfdrive/controls/lib/events.py:539 +msgid "Out of Storage Space" +msgstr "存储空间不足" + +#: selfdrive/controls/lib/events.py:544 +msgid "Speed Too Low" +msgstr "车速过慢" + +#: selfdrive/controls/lib/events.py:549 selfdrive/controls/lib/events.py:553 +msgid "NEOS Update Required" +msgstr "NEOS 需要更新" + +#: selfdrive/controls/lib/events.py:550 +msgid "Please Wait for Update" +msgstr "更新中请稍候" + +#: selfdrive/controls/lib/events.py:558 selfdrive/controls/lib/events.py:562 +msgid "No Data from Device Sensors" +msgstr "未收到装置传感器数据" + +#: selfdrive/controls/lib/events.py:559 selfdrive/controls/lib/events.py:572 +#: selfdrive/controls/lib/events.py:669 +msgid "Reboot your Device" +msgstr "请重启装置" + +#: selfdrive/controls/lib/events.py:571 selfdrive/controls/lib/events.py:575 +msgid "Speaker not found" +msgstr "找不到音效装置" + +#: selfdrive/controls/lib/events.py:579 +msgid "Distraction Level Too High" +msgstr "驾驶分心太多次" + +#: selfdrive/controls/lib/events.py:583 +msgid "System Overheated" +msgstr "系统过热" + +#: selfdrive/controls/lib/events.py:584 +msgid "System overheated" +msgstr "系统过热" + +#: selfdrive/controls/lib/events.py:588 selfdrive/controls/lib/events.py:589 +msgid "Gear not D" +msgstr "不在 D 档位" + +#: selfdrive/controls/lib/events.py:594 +#, fuzzy +msgid "Calibration Invalid" +msgstr "正在校准中" + +#: selfdrive/controls/lib/events.py:595 +#, fuzzy +msgid "Reposition Device and Recalibrate" +msgstr "校准无效:请将装置放于新的位置并重新校准" + +#: selfdrive/controls/lib/events.py:598 selfdrive/controls/lib/events.py:599 +msgid "Calibration Invalid: Reposition Device & Recalibrate" +msgstr "校准无效:请将装置放于新的位置并重新校准" + +#: selfdrive/controls/lib/events.py:603 selfdrive/controls/lib/events.py:605 +msgid "Calibration in Progress" +msgstr "正在校准中" + +#: selfdrive/controls/lib/events.py:609 +msgid "Door Open" +msgstr "车门开启" + +#: selfdrive/controls/lib/events.py:610 +msgid "Door open" +msgstr "车门未关" + +#: selfdrive/controls/lib/events.py:614 +msgid "Seatbelt Unlatched" +msgstr "安全带未繫" + +#: selfdrive/controls/lib/events.py:615 +msgid "Seatbelt unlatched" +msgstr "安全带未繫" + +#: selfdrive/controls/lib/events.py:619 selfdrive/controls/lib/events.py:620 +msgid "ESP Off" +msgstr "ESP 关闭" + +#: selfdrive/controls/lib/events.py:624 selfdrive/controls/lib/events.py:625 +msgid "Low Battery" +msgstr "电量过低" + +#: selfdrive/controls/lib/events.py:629 selfdrive/controls/lib/events.py:630 +msgid "Communication Issue between Processes" +msgstr "行程间出现通讯问题" + +#: selfdrive/controls/lib/events.py:635 selfdrive/controls/lib/events.py:636 +msgid "Radar Communication Issue" +msgstr "雷达通讯出现问题" + +#: selfdrive/controls/lib/events.py:641 selfdrive/controls/lib/events.py:642 +#: selfdrive/controls/lib/events.py:646 selfdrive/controls/lib/events.py:647 +msgid "Radar Error: Restart the Car" +msgstr "雷达讯号错误:请重新发动车辆" + +#: selfdrive/controls/lib/events.py:651 selfdrive/controls/lib/events.py:652 +msgid "Driving model lagging" +msgstr "操控模型有延迟" + +#: selfdrive/controls/lib/events.py:656 selfdrive/controls/lib/events.py:657 +msgid "Vision Model Output Uncertain" +msgstr "视觉模型判断不明确" + +#: selfdrive/controls/lib/events.py:661 selfdrive/controls/lib/events.py:662 +msgid "Device Fell Off Mount" +msgstr "装置掉落侦测" + +#: selfdrive/controls/lib/events.py:666 selfdrive/controls/lib/events.py:672 +msgid "Low Memory: Reboot Your Device" +msgstr "记忆体不足:请重启您的装置" + +#: selfdrive/controls/lib/events.py:668 +msgid "RAM Critically Low" +msgstr "记忆体严重不足" + +#: selfdrive/controls/lib/events.py:677 selfdrive/controls/lib/events.py:678 +msgid "Controls Failed" +msgstr "控制发生错误" + +#: selfdrive/controls/lib/events.py:682 +msgid "Controls Mismatch" +msgstr "控制不匹配" + +#: selfdrive/controls/lib/events.py:686 selfdrive/controls/lib/events.py:688 +#: selfdrive/controls/lib/events.py:692 +msgid "CAN Error: Check Connections" +msgstr "CAN 讯号错误:请检查线路" + +#: selfdrive/controls/lib/events.py:696 selfdrive/controls/lib/events.py:702 +msgid "LKAS Fault: Restart the Car" +msgstr "LKAS 错误:请重新发动车辆" + +#: selfdrive/controls/lib/events.py:698 +msgid "LKAS Fault: Restart the car to engage" +msgstr "LKAS 错误:请重新发动车辆" + +#: selfdrive/controls/lib/events.py:706 selfdrive/controls/lib/events.py:712 +#: selfdrive/controls/lib/events.py:795 +msgid "Cruise Fault: Restart the Car" +msgstr "巡航系统错误:请重新发动车辆" + +#: selfdrive/controls/lib/events.py:708 selfdrive/controls/lib/events.py:791 +msgid "Cruise Fault: Restart the car to engage" +msgstr "巡航系统错误:请重新发动车辆" + +#: selfdrive/controls/lib/events.py:716 +msgid "Gas Fault: Restart the Car" +msgstr "油门错误:请重新发动车辆" + +#: selfdrive/controls/lib/events.py:717 +msgid "Gas Error: Restart the Car" +msgstr "油门错误:请重新发动车辆" + +#: selfdrive/controls/lib/events.py:722 +#, fuzzy +msgid "" +"Reverse\n" +"Gear" +msgstr "切换至倒车档" + +#: selfdrive/controls/lib/events.py:726 +msgid "Reverse Gear" +msgstr "切换至倒车档" + +#: selfdrive/controls/lib/events.py:731 +msgid "Cruise Is Off" +msgstr "巡航系统关闭" + +#: selfdrive/controls/lib/events.py:735 selfdrive/controls/lib/events.py:736 +msgid "Planner Solution Error" +msgstr "Planner Solution 错误" + +#: selfdrive/controls/lib/events.py:740 selfdrive/controls/lib/events.py:742 +#: selfdrive/controls/lib/events.py:746 +msgid "Harness Malfunction" +msgstr "Harness 故障" + +#: selfdrive/controls/lib/events.py:743 +msgid "Please Check Hardware" +msgstr "请检查硬体" + +#: selfdrive/controls/lib/events.py:751 selfdrive/controls/lib/events.py:760 +msgid "openpilot Canceled" +msgstr "openpilot 已取消" + +#: selfdrive/controls/lib/events.py:752 +msgid "No close lead car" +msgstr "前方没有车辆" + +#: selfdrive/controls/lib/events.py:755 +msgid "No Close Lead Car" +msgstr "前方没有车辆" + +#: selfdrive/controls/lib/events.py:761 +msgid "Speed too low" +msgstr "车速过慢" + +#: selfdrive/controls/lib/events.py:768 selfdrive/controls/lib/events.py:773 +msgid "Speed Too High" +msgstr "车速过快" + +#: selfdrive/controls/lib/events.py:769 +msgid "Slow down to resume operation" +msgstr "请减速后再启用" + +#: selfdrive/controls/lib/events.py:774 +msgid "Slow down to engage" +msgstr "请减速后再启用" + +#: selfdrive/controls/lib/events.py:781 +msgid "Please connect to Internet" +msgstr "请连接网路" + +#: selfdrive/controls/lib/events.py:782 +msgid "An Update Check Is Required to Engage" +msgstr "需检查更新后才能启用" + +#: selfdrive/controls/lib/events.py:785 +msgid "Please Connect to Internet" +msgstr "请连接网路" + +#: selfdrive/controls/lib/events.py:801 +msgid "Left ALC will start in 3s" +msgstr "准备自动切至左车道" + +#: selfdrive/controls/lib/events.py:809 +msgid "Right ALC will start in 3s" +msgstr "准备自动切至右车道" + +#: selfdrive/controls/lib/events.py:817 +msgid "STEERING REQUIRED: Lane Keeping OFF" +msgstr "请接管方向盘:车道维持关闭" + +#: selfdrive/controls/lib/events.py:825 +msgid "STEERING REQUIRED: Blinkers ON" +msgstr "请接管方向盘:方向灯开启" + +#: selfdrive/controls/lib/events.py:833 selfdrive/controls/lib/events.py:838 +msgid "Lead Car Is Moving" +msgstr "前方车辆车移动中" + +#: selfdrive/controls/lib/events.py:847 +msgid "WARNING" +msgstr "警告" + +#: selfdrive/controls/lib/events.py:848 +msgid "Grab wheel to start bypass" +msgstr "请握好方向盘以绕过时间限制" + +#: selfdrive/controls/lib/events.py:855 +msgid "BYPASSING" +msgstr "绕过时间限制中" + +#: selfdrive/controls/lib/events.py:856 +msgid "HOLD WHEEL" +msgstr "握好方向盘" + +#: selfdrive/controls/lib/events.py:863 +msgid "Bypassed!" +msgstr "时间限制已绕过" + +#: selfdrive/controls/lib/events.py:864 +msgid "Release wheel when ready" +msgstr "准备好后请松开放向盘" diff --git a/selfdrive/assets/locales/zh-TW/LC_MESSAGES/events.mo b/selfdrive/assets/locales/zh-TW/LC_MESSAGES/events.mo new file mode 100644 index 00000000000000..f1eb3638b4744a Binary files /dev/null and b/selfdrive/assets/locales/zh-TW/LC_MESSAGES/events.mo differ diff --git a/selfdrive/assets/locales/zh-TW/LC_MESSAGES/events.po b/selfdrive/assets/locales/zh-TW/LC_MESSAGES/events.po new file mode 100644 index 00000000000000..e06a22ffd8b560 --- /dev/null +++ b/selfdrive/assets/locales/zh-TW/LC_MESSAGES/events.po @@ -0,0 +1,542 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2020-10-15 13:37+1000\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: Rick Lan \n" +"Language-Team: LANGUAGE \n" +"Language: zh-TW\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#: selfdrive/controls/lib/events.py:153 +msgid "openpilot Unavailable" +msgstr "無法使用 openpilot" + +#: selfdrive/controls/lib/events.py:160 selfdrive/controls/lib/events.py:167 +msgid "TAKE CONTROL IMMEDIATELY" +msgstr "即刻接管控制" + +#: selfdrive/controls/lib/events.py:187 selfdrive/controls/lib/events.py:328 +#: selfdrive/controls/lib/events.py:354 selfdrive/controls/lib/events.py:418 +#: selfdrive/controls/lib/events.py:470 selfdrive/controls/lib/events.py:522 +#: selfdrive/controls/lib/events.py:532 +msgid "TAKE CONTROL" +msgstr "接管控制" + +#: selfdrive/controls/lib/events.py:188 +#, fuzzy, python-format +msgid "Steer Unavailable Below %(speed)d %(unit)s" +msgstr "橫向控制暫時失效,車速低於 %d %s" + +#: selfdrive/controls/lib/events.py:196 +#, fuzzy, python-format +msgid "Calibration in Progress: %d%%" +msgstr "正在校準中:%d%%" + +#: selfdrive/controls/lib/events.py:197 +#, fuzzy, python-format +msgid "Drive Above %(speed)d %(unit)s" +msgstr "車速請高於 %(speed)d %(unit)s" + +#: selfdrive/controls/lib/events.py:204 +msgid "Poor GPS reception" +msgstr "GPS 訊號不良" + +#: selfdrive/controls/lib/events.py:205 +msgid "If sky is visible, contact support" +msgstr "如果您不在地下室/隧道,請聯系客服" + +#: selfdrive/controls/lib/events.py:205 +msgid "Check GPS antenna placement" +msgstr "請檢查 GPS 天線位置" + +#: selfdrive/controls/lib/events.py:210 +msgid "Cruise Mode Disabled" +msgstr "巡航模式關閉" + +#: selfdrive/controls/lib/events.py:212 +msgid "Main Switch Off" +msgstr "主開關已關閉" + +#: selfdrive/controls/lib/events.py:222 +msgid "DEBUG ALERT" +msgstr "除錯用警示訊息" + +#: selfdrive/controls/lib/events.py:230 +msgid "Be ready to take over at any time" +msgstr "請準備好隨時接管" + +#: selfdrive/controls/lib/events.py:231 selfdrive/controls/lib/events.py:239 +#: selfdrive/controls/lib/events.py:247 selfdrive/controls/lib/events.py:255 +msgid "Always keep hands on wheel and eyes on road" +msgstr "將手放在方向盤上並持續監視路況" + +#: selfdrive/controls/lib/events.py:238 +msgid "WARNING: This branch is not tested" +msgstr "注意:這個分支未經過測試" + +#: selfdrive/controls/lib/events.py:246 +msgid "Dashcam mode" +msgstr "行車記錄模式" + +#: selfdrive/controls/lib/events.py:254 +msgid "Dashcam mode for unsupported car" +msgstr "行車記錄模式 (尚未支援車種)" + +#: selfdrive/controls/lib/events.py:262 +msgid "Unsupported Giraffe Configuration" +msgstr "未支援的 Giraffe 設置" + +#: selfdrive/controls/lib/events.py:263 +msgid "Visit comma.ai/tg" +msgstr "請查閱 comma.ai/tg" + +#: selfdrive/controls/lib/events.py:270 +msgid "White Panda Is No Longer Supported" +msgstr "不再支援 White Panda" + +#: selfdrive/controls/lib/events.py:271 +msgid "Upgrade to comma two or black panda" +msgstr "請升級至 comma two 或是使用 black panda" + +#: selfdrive/controls/lib/events.py:274 +msgid "White panda is no longer supported" +msgstr "不再支援 White panda" + +#: selfdrive/controls/lib/events.py:279 +msgid "Stock LKAS is turned on" +msgstr "原廠 LKAS 已開啟" + +#: selfdrive/controls/lib/events.py:280 +msgid "Turn off stock LKAS to engage" +msgstr "需關閉原廠 LKAS 才能啟用" + +#: selfdrive/controls/lib/events.py:288 +msgid "Community Feature Detected" +msgstr "檢測到社群開發功能" + +#: selfdrive/controls/lib/events.py:289 +msgid "Enable Community Features in Developer Settings" +msgstr "請至開發人員設定裡啟用社群開發功能" + +#: selfdrive/controls/lib/events.py:296 +msgid "Dashcam Mode" +msgstr "行車記錄模式" + +#: selfdrive/controls/lib/events.py:297 +msgid "Car Unrecognized" +msgstr "無法辨識車款" + +#: selfdrive/controls/lib/events.py:304 selfdrive/controls/lib/events.py:312 +#: selfdrive/controls/lib/events.py:320 +msgid "BRAKE!" +msgstr "剎車!" + +#: selfdrive/controls/lib/events.py:305 +msgid "Stock AEB: Risk of Collision" +msgstr "有碰撞的風險" + +#: selfdrive/controls/lib/events.py:313 +msgid "Stock FCW: Risk of Collision" +msgstr "有碰撞的風險" + +#: selfdrive/controls/lib/events.py:321 +msgid "Risk of Collision" +msgstr "有碰撞的風險" + +#: selfdrive/controls/lib/events.py:329 +msgid "Lane Departure Detected" +msgstr "偏離車道" + +#: selfdrive/controls/lib/events.py:338 +msgid "openpilot will not brake while gas pressed" +msgstr "在您踩著油門的時候 openpilot 將不會剎車" + +#: selfdrive/controls/lib/events.py:346 +msgid "Vehicle Parameter Identification Failed" +msgstr "車子參數識別失敗" + +#: selfdrive/controls/lib/events.py:355 selfdrive/controls/lib/events.py:523 +#: selfdrive/controls/lib/events.py:526 +msgid "Steering Temporarily Unavailable" +msgstr "橫向控制暫時失效" + +#: selfdrive/controls/lib/events.py:362 +msgid "KEEP EYES ON ROAD: Driver Distracted" +msgstr "注意路況:駕駛分心" + +#: selfdrive/controls/lib/events.py:370 +msgid "KEEP EYES ON ROAD" +msgstr "注意路況" + +#: selfdrive/controls/lib/events.py:371 +msgid "Driver Appears Distracted" +msgstr "駕駛分心" + +#: selfdrive/controls/lib/events.py:378 selfdrive/controls/lib/events.py:402 +msgid "DISENGAGE IMMEDIATELY" +msgstr "立即解除" + +#: selfdrive/controls/lib/events.py:379 +msgid "Driver Was Distracted" +msgstr "駕駛分心" + +#: selfdrive/controls/lib/events.py:386 +msgid "TOUCH STEERING WHEEL: No Face Detected" +msgstr "請觸碰方向盤:未偵測到駕駛面容" + +#: selfdrive/controls/lib/events.py:394 +msgid "TOUCH STEERING WHEEL" +msgstr "請觸碰方向盤" + +#: selfdrive/controls/lib/events.py:395 +msgid "Driver Is Unresponsive" +msgstr "駕駛沒有反應" + +#: selfdrive/controls/lib/events.py:403 +msgid "Driver Was Unresponsive" +msgstr "駕駛沒有反應" + +#: selfdrive/controls/lib/events.py:410 +msgid "CHECK DRIVER FACE VISIBILITY" +msgstr "請檢查駕駛面部的可見度" + +#: selfdrive/controls/lib/events.py:411 +msgid "Driver Monitor Model Output Uncertain" +msgstr "駕駛監控模型判斷不明確" + +#: selfdrive/controls/lib/events.py:419 +msgid "Resume Driving Manually" +msgstr "請自行恢復駕駛" + +#: selfdrive/controls/lib/events.py:426 +msgid "STOPPED" +msgstr "已停止" + +#: selfdrive/controls/lib/events.py:427 +msgid "Press Resume to Move" +msgstr "請按 RES 繼續" + +#: selfdrive/controls/lib/events.py:438 +msgid "Steer Left to Start Lane Change" +msgstr "請往左打方向盤切換至左車道" + +#: selfdrive/controls/lib/events.py:439 selfdrive/controls/lib/events.py:447 +#: selfdrive/controls/lib/events.py:455 selfdrive/controls/lib/events.py:463 +#: selfdrive/controls/lib/events.py:802 selfdrive/controls/lib/events.py:810 +msgid "Monitor Other Vehicles" +msgstr "請注意其它車輛" + +#: selfdrive/controls/lib/events.py:446 +msgid "Steer Right to Start Lane Change" +msgstr "請往右打方向盤切換至右車道" + +#: selfdrive/controls/lib/events.py:454 +msgid "Car Detected in Blindspot" +msgstr "盲點偵測到車輛" + +#: selfdrive/controls/lib/events.py:462 +msgid "Changing Lane" +msgstr "切換車道中" + +#: selfdrive/controls/lib/events.py:471 +msgid "Turn Exceeds Steering Limit" +msgstr "彎道超過橫向操控限制" + +#: selfdrive/controls/lib/events.py:496 +msgid "Brake Hold Active" +msgstr "駐車煞車已啟用" + +#: selfdrive/controls/lib/events.py:501 +msgid "Park Brake Engaged" +msgstr "電子駐車已啟動" + +#: selfdrive/controls/lib/events.py:506 +msgid "Pedal Pressed During Attempt" +msgstr "啟用時偵測到駕駛踩踏油門/剎車" + +#: selfdrive/controls/lib/events.py:517 +msgid "Enable Adaptive Cruise" +msgstr "啟用主動定速巡航" + +#: selfdrive/controls/lib/events.py:533 +msgid "Attempting Refocus: Camera Focus Invalid" +msgstr "嘗試對焦:相機已失焦" + +#: selfdrive/controls/lib/events.py:539 +msgid "Out of Storage Space" +msgstr "儲存空間不足" + +#: selfdrive/controls/lib/events.py:544 +msgid "Speed Too Low" +msgstr "車速過慢" + +#: selfdrive/controls/lib/events.py:549 selfdrive/controls/lib/events.py:553 +msgid "NEOS Update Required" +msgstr "NEOS 需要更新" + +#: selfdrive/controls/lib/events.py:550 +msgid "Please Wait for Update" +msgstr "更新中請稍候" + +#: selfdrive/controls/lib/events.py:558 selfdrive/controls/lib/events.py:562 +msgid "No Data from Device Sensors" +msgstr "未收到裝置傳感器數據" + +#: selfdrive/controls/lib/events.py:559 selfdrive/controls/lib/events.py:572 +#: selfdrive/controls/lib/events.py:669 +msgid "Reboot your Device" +msgstr "請重啟裝置" + +#: selfdrive/controls/lib/events.py:571 selfdrive/controls/lib/events.py:575 +msgid "Speaker not found" +msgstr "找不到音效裝置" + +#: selfdrive/controls/lib/events.py:579 +msgid "Distraction Level Too High" +msgstr "駕駛分心太多次" + +#: selfdrive/controls/lib/events.py:583 +msgid "System Overheated" +msgstr "系統過熱" + +#: selfdrive/controls/lib/events.py:584 +msgid "System overheated" +msgstr "系統過熱" + +#: selfdrive/controls/lib/events.py:588 selfdrive/controls/lib/events.py:589 +msgid "Gear not D" +msgstr "不在 D 檔位" + +#: selfdrive/controls/lib/events.py:594 +#, fuzzy +msgid "Calibration Invalid" +msgstr "正在校準中" + +#: selfdrive/controls/lib/events.py:595 +#, fuzzy +msgid "Reposition Device and Recalibrate" +msgstr "校準無效:請將裝置放於新的位置並重新校準" + +#: selfdrive/controls/lib/events.py:598 selfdrive/controls/lib/events.py:599 +msgid "Calibration Invalid: Reposition Device & Recalibrate" +msgstr "校準無效:請將裝置放於新的位置並重新校準" + +#: selfdrive/controls/lib/events.py:603 selfdrive/controls/lib/events.py:605 +msgid "Calibration in Progress" +msgstr "正在校準中" + +#: selfdrive/controls/lib/events.py:609 +msgid "Door Open" +msgstr "車門開啟" + +#: selfdrive/controls/lib/events.py:610 +msgid "Door open" +msgstr "車門未關" + +#: selfdrive/controls/lib/events.py:614 +msgid "Seatbelt Unlatched" +msgstr "安全帶未繫" + +#: selfdrive/controls/lib/events.py:615 +msgid "Seatbelt unlatched" +msgstr "安全帶未繫" + +#: selfdrive/controls/lib/events.py:619 selfdrive/controls/lib/events.py:620 +msgid "ESP Off" +msgstr "ESP 關閉" + +#: selfdrive/controls/lib/events.py:624 selfdrive/controls/lib/events.py:625 +msgid "Low Battery" +msgstr "電量過低" + +#: selfdrive/controls/lib/events.py:629 selfdrive/controls/lib/events.py:630 +msgid "Communication Issue between Processes" +msgstr "行程間出現通訊問題" + +#: selfdrive/controls/lib/events.py:635 selfdrive/controls/lib/events.py:636 +msgid "Radar Communication Issue" +msgstr "雷達通訊出現問題" + +#: selfdrive/controls/lib/events.py:641 selfdrive/controls/lib/events.py:642 +#: selfdrive/controls/lib/events.py:646 selfdrive/controls/lib/events.py:647 +msgid "Radar Error: Restart the Car" +msgstr "雷達訊號錯誤:請重新發動車輛" + +#: selfdrive/controls/lib/events.py:651 selfdrive/controls/lib/events.py:652 +msgid "Driving model lagging" +msgstr "操控模型有延遲" + +#: selfdrive/controls/lib/events.py:656 selfdrive/controls/lib/events.py:657 +msgid "Vision Model Output Uncertain" +msgstr "視覺模型判斷不明確" + +#: selfdrive/controls/lib/events.py:661 selfdrive/controls/lib/events.py:662 +msgid "Device Fell Off Mount" +msgstr "裝置掉落偵測" + +#: selfdrive/controls/lib/events.py:666 selfdrive/controls/lib/events.py:672 +msgid "Low Memory: Reboot Your Device" +msgstr "記憶體不足:請重啟您的裝置" + +#: selfdrive/controls/lib/events.py:668 +msgid "RAM Critically Low" +msgstr "記憶體嚴重不足" + +#: selfdrive/controls/lib/events.py:677 selfdrive/controls/lib/events.py:678 +msgid "Controls Failed" +msgstr "控制發生錯誤" + +#: selfdrive/controls/lib/events.py:682 +msgid "Controls Mismatch" +msgstr "控制不匹配" + +#: selfdrive/controls/lib/events.py:686 selfdrive/controls/lib/events.py:688 +#: selfdrive/controls/lib/events.py:692 +msgid "CAN Error: Check Connections" +msgstr "CAN 訊號錯誤:請檢查線路" + +#: selfdrive/controls/lib/events.py:696 selfdrive/controls/lib/events.py:702 +msgid "LKAS Fault: Restart the Car" +msgstr "LKAS 錯誤:請重新發動車輛" + +#: selfdrive/controls/lib/events.py:698 +msgid "LKAS Fault: Restart the car to engage" +msgstr "LKAS 錯誤:請重新發動車輛" + +#: selfdrive/controls/lib/events.py:706 selfdrive/controls/lib/events.py:712 +#: selfdrive/controls/lib/events.py:795 +msgid "Cruise Fault: Restart the Car" +msgstr "巡航系統錯誤:請重新發動車輛" + +#: selfdrive/controls/lib/events.py:708 selfdrive/controls/lib/events.py:791 +msgid "Cruise Fault: Restart the car to engage" +msgstr "巡航系統錯誤:請重新發動車輛" + +#: selfdrive/controls/lib/events.py:716 +msgid "Gas Fault: Restart the Car" +msgstr "油門錯誤:請重新發動車輛" + +#: selfdrive/controls/lib/events.py:717 +msgid "Gas Error: Restart the Car" +msgstr "油門錯誤:請重新發動車輛" + +#: selfdrive/controls/lib/events.py:722 +#, fuzzy +msgid "" +"Reverse\n" +"Gear" +msgstr "切換至倒車檔" + +#: selfdrive/controls/lib/events.py:726 +msgid "Reverse Gear" +msgstr "切換至倒車檔" + +#: selfdrive/controls/lib/events.py:731 +msgid "Cruise Is Off" +msgstr "巡航系統關閉" + +#: selfdrive/controls/lib/events.py:735 selfdrive/controls/lib/events.py:736 +msgid "Planner Solution Error" +msgstr "Planner Solution 錯誤" + +#: selfdrive/controls/lib/events.py:740 selfdrive/controls/lib/events.py:742 +#: selfdrive/controls/lib/events.py:746 +msgid "Harness Malfunction" +msgstr "Harness 故障" + +#: selfdrive/controls/lib/events.py:743 +msgid "Please Check Hardware" +msgstr "請檢查硬體" + +#: selfdrive/controls/lib/events.py:751 selfdrive/controls/lib/events.py:760 +msgid "openpilot Canceled" +msgstr "openpilot 已取消" + +#: selfdrive/controls/lib/events.py:752 +msgid "No close lead car" +msgstr "前方沒有車輛" + +#: selfdrive/controls/lib/events.py:755 +msgid "No Close Lead Car" +msgstr "前方沒有車輛" + +#: selfdrive/controls/lib/events.py:761 +msgid "Speed too low" +msgstr "車速過慢" + +#: selfdrive/controls/lib/events.py:768 selfdrive/controls/lib/events.py:773 +msgid "Speed Too High" +msgstr "車速過快" + +#: selfdrive/controls/lib/events.py:769 +msgid "Slow down to resume operation" +msgstr "請減速後再啟用" + +#: selfdrive/controls/lib/events.py:774 +msgid "Slow down to engage" +msgstr "請減速後再啟用" + +#: selfdrive/controls/lib/events.py:781 +msgid "Please connect to Internet" +msgstr "請連接網路" + +#: selfdrive/controls/lib/events.py:782 +msgid "An Update Check Is Required to Engage" +msgstr "需檢查更新後才能啟用" + +#: selfdrive/controls/lib/events.py:785 +msgid "Please Connect to Internet" +msgstr "請連接網路" + +#: selfdrive/controls/lib/events.py:801 +msgid "Left ALC will start in 3s" +msgstr "準備自動切至左車道" + +#: selfdrive/controls/lib/events.py:809 +msgid "Right ALC will start in 3s" +msgstr "準備自動切至右車道" + +#: selfdrive/controls/lib/events.py:817 +msgid "STEERING REQUIRED: Lane Keeping OFF" +msgstr "請接管方向盤:車道維持關閉" + +#: selfdrive/controls/lib/events.py:825 +msgid "STEERING REQUIRED: Blinkers ON" +msgstr "請接管方向盤:方向燈開啟" + +#: selfdrive/controls/lib/events.py:833 selfdrive/controls/lib/events.py:838 +msgid "Lead Car Is Moving" +msgstr "前方車輛車移動中" + +#: selfdrive/controls/lib/events.py:847 +msgid "WARNING" +msgstr "警告" + +#: selfdrive/controls/lib/events.py:848 +msgid "Grab wheel to start bypass" +msgstr "請握好方向盤以繞過時間限制" + +#: selfdrive/controls/lib/events.py:855 +msgid "BYPASSING" +msgstr "繞過時間限制中" + +#: selfdrive/controls/lib/events.py:856 +msgid "HOLD WHEEL" +msgstr "握好方向盤" + +#: selfdrive/controls/lib/events.py:863 +msgid "Bypassed!" +msgstr "時間限制已繞過" + +#: selfdrive/controls/lib/events.py:864 +msgid "Release wheel when ready" +msgstr "準備好後請鬆開放向盤" diff --git a/selfdrive/boardd/SConscript b/selfdrive/boardd/SConscript index f2a1f3f7bd9f2d..5284785d34a188 100644 --- a/selfdrive/boardd/SConscript +++ b/selfdrive/boardd/SConscript @@ -1,5 +1,9 @@ Import('env', 'envCython', 'common', 'cereal', 'messaging') - +# dp - Add read dp_disable_relay value +if FindFile('dp_disable_relay', '/data/params/d') != None: + with open('/data/params/d/dp_disable_relay') as f: + if (int(f.read())) == 1: + env.Append(CCFLAGS='-DDisableRelay') env.Program('boardd', ['boardd.cc', 'panda.cc', 'pigeon.cc'], LIBS=['usb-1.0', common, cereal, messaging, 'pthread', 'zmq', 'capnp', 'kj']) env.Library('libcan_list_to_can_capnp', ['can_list_to_can_capnp.cc']) diff --git a/selfdrive/boardd/boardd.cc b/selfdrive/boardd/boardd.cc index 1033c082567ba9..7dfc9363d4f3a3 100644 --- a/selfdrive/boardd/boardd.cc +++ b/selfdrive/boardd/boardd.cc @@ -62,6 +62,7 @@ bool time_valid(struct tm sys_time){ } void safety_setter_thread() { + #ifndef DisableRelay LOGD("Starting safety setter thread"); // diagnostic only is the default, needed for VIN query panda->set_safety_model(cereal::CarParams::SafetyModel::ELM327); @@ -86,7 +87,7 @@ void safety_setter_thread() { // VIN query done, stop listening to OBDII panda->set_safety_model(cereal::CarParams::SafetyModel::NO_OUTPUT); - + #endif std::vector params; LOGW("waiting for params to set safety model"); while (1) { @@ -109,7 +110,7 @@ void safety_setter_thread() { cereal::CarParams::Reader car_params = cmsg.getRoot(); cereal::CarParams::SafetyModel safety_model = car_params.getSafetyModel(); - panda->set_unsafe_mode(0); // see safety_declarations.h for allowed values + panda->set_unsafe_mode(9); // see safety_declarations.h for allowed values auto safety_param = car_params.getSafetyParam(); LOGW("setting safety model: %d with param %d", (int)safety_model, safety_param); @@ -297,12 +298,12 @@ void can_health_thread() { if (spoofing_started) { health.ignition_line = 1; } - + #ifndef DisableRelay // Make sure CAN buses are live: safety_setter_thread does not work if Panda CAN are silent and there is only one other CAN node if (health.safety_model == (uint8_t)(cereal::CarParams::SafetyModel::SILENT)) { panda->set_safety_model(cereal::CarParams::SafetyModel::NO_OUTPUT); } - + #endif ignition = ((health.ignition_line != 0) || (health.ignition_can != 0)); if (ignition) { @@ -316,11 +317,12 @@ void can_health_thread() { if (health.power_save_enabled != power_save_desired){ panda->set_power_saving(power_save_desired); } - + #ifndef DisableRelay // set safety mode to NO_OUTPUT when car is off. ELM327 is an alternative if we want to leverage athenad/connect if (!ignition && (health.safety_model != (uint8_t)(cereal::CarParams::SafetyModel::NO_OUTPUT))) { panda->set_safety_model(cereal::CarParams::SafetyModel::NO_OUTPUT); } + #endif #endif // clear VIN, CarParams, and set new safety on car start @@ -483,6 +485,11 @@ void pigeon_thread() { pigeon->init(); + // dp + #ifdef DisableRelay + panda->set_safety_model(cereal::CarParams::SafetyModel::TOYOTA); + #endif + while (!do_exit && panda->connected) { std::string recv = pigeon->receive(); if (recv.length() > 0) { @@ -505,7 +512,9 @@ void pigeon_thread() { int main() { int err; LOGW("starting boardd"); - + #ifdef DisableRelay + LOGW("boardd is in DisableRelay mode."); + #endif // set process priority and affinity err = set_realtime_priority(54); LOG("set priority returns %d", err); diff --git a/selfdrive/car/car_helpers.py b/selfdrive/car/car_helpers.py index 2af6df269e0721..7cf856d0537628 100644 --- a/selfdrive/car/car_helpers.py +++ b/selfdrive/car/car_helpers.py @@ -1,5 +1,5 @@ import os -from common.params import Params +from common.params import Params, put_nonblocking from common.basedir import BASEDIR from selfdrive.version import comma_remote, tested_branch from selfdrive.car.fingerprints import eliminate_incompatible_cars, all_known_cars @@ -9,15 +9,16 @@ import cereal.messaging as messaging from selfdrive.car import gen_empty_fingerprint -from cereal import car +from cereal import car, log +from common.dp_common import is_online +import threading +import selfdrive.crash as crash + EventName = car.CarEvent.EventName def get_startup_event(car_recognized, controller_available): - if comma_remote and tested_branch: - event = EventName.startup - else: - event = EventName.startupMaster + event = EventName.startup if not car_recognized: event = EventName.startupNoCar @@ -81,15 +82,24 @@ def only_toyota_left(candidate_cars): # **** for use live only **** -def fingerprint(logcan, sendcan): +def fingerprint(logcan, sendcan, has_relay): + params = Params() + car_selected = params.get('dp_car_selected', encoding='utf8') + car_detected = params.get('dp_car_detected', encoding='utf8') + cached_params = params.get("CarParamsCache") + if cached_params is None and car_selected == "" and car_detected != "": + params.put('dp_car_selected', car_detected) + params.put('dp_car_detected', "") + fixed_fingerprint = os.environ.get('FINGERPRINT', "") + if fixed_fingerprint == "" and cached_params is None and car_selected != "": + fixed_fingerprint = car_selected skip_fw_query = os.environ.get('SKIP_FW_QUERY', False) - if not fixed_fingerprint and not skip_fw_query: + if has_relay and not fixed_fingerprint and not skip_fw_query: # Vin query only reliably works thorugh OBDII bus = 1 - cached_params = Params().get("CarParamsCache") if cached_params is not None: cached_params = car.CarParams.from_bytes(cached_params) if cached_params.carName == "mock": @@ -164,20 +174,30 @@ def fingerprint(logcan, sendcan): source = car.CarParams.FingerprintSource.fixed cloudlog.warning("fingerprinted %s", car_fingerprint) + put_nonblocking('dp_car_detected', car_fingerprint) return car_fingerprint, finger, vin, car_fw, source -def get_car(logcan, sendcan): - candidate, fingerprints, vin, car_fw, source = fingerprint(logcan, sendcan) +def get_car(logcan, sendcan, has_relay=False): + candidate, fingerprints, vin, car_fw, source = fingerprint(logcan, sendcan, has_relay) if candidate is None: cloudlog.warning("car doesn't match any fingerprints: %r", fingerprints) candidate = "mock" + if is_online(): + x = threading.Thread(target=log_fingerprinted, args=(candidate,)) + x.start() + CarInterface, CarController, CarState = interfaces[candidate] - car_params = CarInterface.get_params(candidate, fingerprints, car_fw) + car_params = CarInterface.get_params(candidate, fingerprints, has_relay, car_fw) car_params.carVin = vin car_params.carFw = car_fw car_params.fingerprintSource = source return CarInterface(car_params, CarController, CarState), car_params + +def log_fingerprinted(candidate): + while True: + crash.capture_warning("fingerprinted %s" % candidate) + break \ No newline at end of file diff --git a/selfdrive/car/chrysler/carcontroller.py b/selfdrive/car/chrysler/carcontroller.py index b81526e9c002f8..e11d0209c25c5f 100644 --- a/selfdrive/car/chrysler/carcontroller.py +++ b/selfdrive/car/chrysler/carcontroller.py @@ -3,6 +3,7 @@ create_wheel_buttons from selfdrive.car.chrysler.values import CAR, SteerLimitParams from opendbc.can.packer import CANPacker +from common.dp_common import common_controller_ctrl class CarController(): def __init__(self, dbc_name, CP, VM): @@ -16,7 +17,11 @@ def __init__(self, dbc_name, CP, VM): self.packer = CANPacker(dbc_name) - def update(self, enabled, CS, actuators, pcm_cancel_cmd, hud_alert): + # dp + self.last_blinker_on = False + self.blinker_end_frame = 0. + + def update(self, enabled, CS, actuators, pcm_cancel_cmd, hud_alert, dragonconf): # this seems needed to avoid steering faults and to force the sync with the EPS counter frame = CS.lkas_counter if self.prev_frame == frame: @@ -40,6 +45,18 @@ def update(self, enabled, CS, actuators, pcm_cancel_cmd, hud_alert): if not lkas_active: apply_steer = 0 + # dp + blinker_on = CS.out.leftBlinker or CS.out.rightBlinker + if not enabled: + self.blinker_end_frame = 0 + if self.last_blinker_on and not blinker_on: + self.blinker_end_frame = frame + dragonconf.dpSignalOffDelay + apply_steer = common_controller_ctrl(enabled, + dragonconf, + blinker_on or frame < self.blinker_end_frame, + apply_steer, CS.out.vEgo) + self.last_blinker_on = blinker_on + self.apply_steer_last = apply_steer can_sends = [] diff --git a/selfdrive/car/chrysler/carstate.py b/selfdrive/car/chrysler/carstate.py index b6fdb11314c294..037f3d4b491dc0 100644 --- a/selfdrive/car/chrysler/carstate.py +++ b/selfdrive/car/chrysler/carstate.py @@ -111,7 +111,7 @@ def get_can_parser(CP): ("DOORS", 1), ("TRACTION_BUTTON", 1), ] - + checks = [] return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, 0) @staticmethod @@ -127,5 +127,5 @@ def get_cam_can_parser(CP): ("LKAS_HEARTBIT", 10), ("LKAS_HUD", 4), ] - + checks = [] return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, 2) diff --git a/selfdrive/car/chrysler/interface.py b/selfdrive/car/chrysler/interface.py index e433665d992f9a..ad3d671c5604b9 100755 --- a/selfdrive/car/chrysler/interface.py +++ b/selfdrive/car/chrysler/interface.py @@ -1,9 +1,9 @@ #!/usr/bin/env python3 from cereal import car -from selfdrive.car.chrysler.values import CAR -from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, gen_empty_fingerprint +from selfdrive.car.chrysler.values import Ecu, ECU_FINGERPRINT, CAR, FINGERPRINTS +from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, is_ecu_disconnected, gen_empty_fingerprint from selfdrive.car.interfaces import CarInterfaceBase - +from common.dp_common import common_interface_atl, common_interface_get_params_lqr class CarInterface(CarInterfaceBase): @staticmethod @@ -11,13 +11,14 @@ def compute_gb(accel, speed): return float(accel) / 3.0 @staticmethod - def get_params(candidate, fingerprint=None, car_fw=None): + def get_params(candidate, fingerprint=None, has_relay=False, car_fw=None): if fingerprint is None: fingerprint = gen_empty_fingerprint() ret = CarInterfaceBase.get_std_params(candidate, fingerprint) ret.carName = "chrysler" ret.safetyModel = car.CarParams.SafetyModel.chrysler + ret.lateralTuning.init('pid') # Chrysler port is a community feature, since we don't own one to test ret.communityFeature = True @@ -38,6 +39,9 @@ def get_params(candidate, fingerprint=None, car_fw=None): ret.steerRatio = 12.7 ret.steerActuatorDelay = 0.2 # in seconds + # dp + ret = common_interface_get_params_lqr(ret) + ret.centerToFront = ret.wheelbase * 0.44 ret.minSteerSpeed = 3.8 # m/s @@ -52,18 +56,21 @@ def get_params(candidate, fingerprint=None, car_fw=None): # mass and CG position, so all cars will have approximately similar dyn behaviors ret.tireStiffnessFront, ret.tireStiffnessRear = scale_tire_stiffness(ret.mass, ret.wheelbase, ret.centerToFront) - ret.enableCamera = True + ret.enableCamera = is_ecu_disconnected(fingerprint[0], FINGERPRINTS, ECU_FINGERPRINT, candidate, Ecu.fwdCamera) or has_relay + print("ECU Camera Simulated: {0}".format(ret.enableCamera)) return ret # returns a car.CarState - def update(self, c, can_strings): + def update(self, c, can_strings, dragonconf): # ******************* do can recv ******************* self.cp.update_strings(can_strings) self.cp_cam.update_strings(can_strings) ret = self.CS.update(self.cp, self.cp_cam) - + # dp + self.dragonconf = dragonconf + ret.cruiseState.enabled = common_interface_atl(ret, dragonconf.dpAtl) ret.canValid = self.cp.can_valid and self.cp_cam.can_valid # speeds @@ -90,6 +97,6 @@ def apply(self, c): if (self.CS.frame == -1): return [] # if we haven't seen a frame 220, then do not update. - can_sends = self.CC.update(c.enabled, self.CS, c.actuators, c.cruiseControl.cancel, c.hudControl.visualAlert) + can_sends = self.CC.update(c.enabled, self.CS, c.actuators, c.cruiseControl.cancel, c.hudControl.visualAlert, self.dragonconf) return can_sends diff --git a/selfdrive/car/chrysler/values.py b/selfdrive/car/chrysler/values.py index 88110f0530a91d..a2449d9c939ed3 100644 --- a/selfdrive/car/chrysler/values.py +++ b/selfdrive/car/chrysler/values.py @@ -91,3 +91,7 @@ class CAR: } STEER_THRESHOLD = 120 + +ECU_FINGERPRINT = { + Ecu.fwdCamera: [0x292], # lkas cmd +} diff --git a/selfdrive/car/ford/carcontroller.py b/selfdrive/car/ford/carcontroller.py index 648fa077410b89..ef226179106176 100644 --- a/selfdrive/car/ford/carcontroller.py +++ b/selfdrive/car/ford/carcontroller.py @@ -2,7 +2,7 @@ from selfdrive.car import make_can_msg from selfdrive.car.ford.fordcan import create_steer_command, create_lkas_ui, spam_cancel_button from opendbc.can.packer import CANPacker - +from common.dp_common import common_controller_ctrl MAX_STEER_DELTA = 1 TOGGLE_DEBUG = False @@ -18,13 +18,29 @@ def __init__(self, dbc_name, CP, VM): self.steer_alert_last = False self.lkas_action = 0 - def update(self, enabled, CS, frame, actuators, visual_alert, pcm_cancel): + # dp + self.last_blinker_on = False + self.blinker_end_frame = 0. + + def update(self, enabled, CS, frame, actuators, visual_alert, pcm_cancel, dragonconf): can_sends = [] steer_alert = visual_alert == car.CarControl.HUDControl.VisualAlert.steerRequired apply_steer = actuators.steer + # dp + blinker_on = CS.out.leftBlinker or CS.out.rightBlinker + if not enabled: + self.blinker_end_frame = 0 + if self.last_blinker_on and not blinker_on: + self.blinker_end_frame = frame + dragonconf.dpSignalOffDelay + apply_steer = common_controller_ctrl(enabled, + dragonconf, + blinker_on or frame < self.blinker_end_frame, + apply_steer, CS.out.vEgo) + self.last_blinker_on = blinker_on + if self.enable_camera: if pcm_cancel: diff --git a/selfdrive/car/ford/carstate.py b/selfdrive/car/ford/carstate.py index 7f34acc9df855c..30581c071c1dd5 100644 --- a/selfdrive/car/ford/carstate.py +++ b/selfdrive/car/ford/carstate.py @@ -8,6 +8,9 @@ WHEEL_RADIUS = 0.33 class CarState(CarStateBase): + def __init__(self, CP): + super().__init__(CP) + def update(self, cp): ret = car.CarState.new_message() ret.wheelSpeeds.rr = cp.vl["WheelSpeed_CG1"]['WhlRr_W_Meas'] * WHEEL_RADIUS diff --git a/selfdrive/car/ford/interface.py b/selfdrive/car/ford/interface.py index 9def1ca86b8d8e..e04ab0588f4c58 100755 --- a/selfdrive/car/ford/interface.py +++ b/selfdrive/car/ford/interface.py @@ -2,10 +2,10 @@ from cereal import car from selfdrive.swaglog import cloudlog from selfdrive.config import Conversions as CV -from selfdrive.car.ford.values import MAX_ANGLE -from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, gen_empty_fingerprint +from selfdrive.car.ford.values import MAX_ANGLE, Ecu, ECU_FINGERPRINT, FINGERPRINTS +from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, is_ecu_disconnected, gen_empty_fingerprint from selfdrive.car.interfaces import CarInterfaceBase - +from common.dp_common import common_interface_atl, common_interface_get_params_lqr class CarInterface(CarInterfaceBase): @@ -14,11 +14,12 @@ def compute_gb(accel, speed): return float(accel) / 3.0 @staticmethod - def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): - ret = CarInterfaceBase.get_std_params(candidate, fingerprint) + def get_params(candidate, fingerprint=gen_empty_fingerprint(), has_relay=False, car_fw=None): + ret = CarInterfaceBase.get_std_params(candidate, fingerprint, has_relay) ret.carName = "ford" ret.safetyModel = car.CarParams.SafetyModel.ford ret.dashcamOnly = True + ret.lateralTuning.init('pid') ret.wheelbase = 2.85 ret.steerRatio = 14.8 @@ -32,6 +33,9 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): ret.centerToFront = ret.wheelbase * 0.44 tire_stiffness_factor = 0.5328 + # dp + ret = common_interface_get_params_lqr(ret) + # TODO: get actual value, for now starting with reasonable value for # civic and scaling by mass and wheelbase ret.rotationalInertia = scale_rot_inertia(ret.mass, ret.wheelbase) @@ -43,18 +47,20 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): ret.steerControlType = car.CarParams.SteerControlType.angle - ret.enableCamera = True + ret.enableCamera = is_ecu_disconnected(fingerprint[0], FINGERPRINTS, ECU_FINGERPRINT, candidate, Ecu.fwdCamera) or has_relay cloudlog.warning("ECU Camera Simulated: %r", ret.enableCamera) return ret # returns a car.CarState - def update(self, c, can_strings): + def update(self, c, can_strings, dragonconf): # ******************* do can recv ******************* self.cp.update_strings(can_strings) ret = self.CS.update(self.cp) - + # dp + self.dragonconf = dragonconf + ret.cruiseState.enabled = common_interface_atl(ret, dragonconf.dpAtl) ret.canValid = self.cp.can_valid # events @@ -73,7 +79,7 @@ def update(self, c, can_strings): def apply(self, c): can_sends = self.CC.update(c.enabled, self.CS, self.frame, c.actuators, - c.hudControl.visualAlert, c.cruiseControl.cancel) + c.hudControl.visualAlert, c.cruiseControl.cancel, self.dragonconf) self.frame += 1 return can_sends diff --git a/selfdrive/car/ford/values.py b/selfdrive/car/ford/values.py index 315c398ab69016..7c4d0aed98b2af 100644 --- a/selfdrive/car/ford/values.py +++ b/selfdrive/car/ford/values.py @@ -15,6 +15,10 @@ class CAR: }], } +ECU_FINGERPRINT = { + Ecu.fwdCamera: [970, 973, 984] +} + DBC = { CAR.FUSION: dbc_dict('ford_fusion_2018_pt', 'ford_fusion_2018_adas'), } diff --git a/selfdrive/car/gm/carcontroller.py b/selfdrive/car/gm/carcontroller.py index 9b8e68fee46d7c..cbf5bee728002f 100644 --- a/selfdrive/car/gm/carcontroller.py +++ b/selfdrive/car/gm/carcontroller.py @@ -6,6 +6,7 @@ from selfdrive.car.gm import gmcan from selfdrive.car.gm.values import DBC, CanBus from opendbc.can.packer import CANPacker +from common.dp_common import common_controller_ctrl VisualAlert = car.CarControl.HUDControl.VisualAlert @@ -51,8 +52,12 @@ def __init__(self, dbc_name, CP, VM): self.packer_obj = CANPacker(DBC[CP.carFingerprint]['radar']) self.packer_ch = CANPacker(DBC[CP.carFingerprint]['chassis']) + # dp + self.last_blinker_on = False + self.blinker_end_frame = 0. + def update(self, enabled, CS, frame, actuators, - hud_v_cruise, hud_show_lanes, hud_show_car, hud_alert): + hud_v_cruise, hud_show_lanes, hud_show_car, hud_alert, dragonconf): P = self.params @@ -69,6 +74,18 @@ def update(self, enabled, CS, frame, actuators, else: apply_steer = 0 + # dp + blinker_on = CS.out.leftBlinker or CS.out.rightBlinker + if not enabled: + self.blinker_end_frame = 0 + if self.last_blinker_on and not blinker_on: + self.blinker_end_frame = frame + dragonconf.dpSignalOffDelay + apply_steer = common_controller_ctrl(enabled, + dragonconf, + blinker_on or frame < self.blinker_end_frame, + apply_steer, CS.out.vEgo) + self.last_blinker_on = blinker_on + self.apply_steer_last = apply_steer idx = (frame // P.STEER_STEP) % 4 diff --git a/selfdrive/car/gm/interface.py b/selfdrive/car/gm/interface.py index 2f7d8f473bfb1e..c5436b46deb32d 100755 --- a/selfdrive/car/gm/interface.py +++ b/selfdrive/car/gm/interface.py @@ -1,10 +1,11 @@ #!/usr/bin/env python3 from cereal import car from selfdrive.config import Conversions as CV -from selfdrive.car.gm.values import CAR, CruiseButtons, \ - AccState -from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, gen_empty_fingerprint +from selfdrive.car.gm.values import CAR, Ecu, ECU_FINGERPRINT, CruiseButtons, \ + AccState, FINGERPRINTS +from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, is_ecu_disconnected, gen_empty_fingerprint from selfdrive.car.interfaces import CarInterfaceBase +from common.dp_common import common_interface_atl, common_interface_get_params_lqr ButtonType = car.CarState.ButtonEvent.Type EventName = car.CarEvent.EventName @@ -16,11 +17,12 @@ def compute_gb(accel, speed): return float(accel) / 4.0 @staticmethod - def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): - ret = CarInterfaceBase.get_std_params(candidate, fingerprint) + def get_params(candidate, fingerprint=gen_empty_fingerprint(), has_relay=False, car_fw=None): + ret = CarInterfaceBase.get_std_params(candidate, fingerprint, has_relay) ret.carName = "gm" ret.safetyModel = car.CarParams.SafetyModel.gm ret.enableCruise = False # stock cruise control is kept off + ret.lateralTuning.init('pid') # GM port is a community feature # TODO: make a port that uses a car harness and it only intercepts the camera @@ -29,7 +31,7 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): # Presence of a camera on the object bus is ok. # Have to go to read_only if ASCM is online (ACC-enabled cars), # or camera is on powertrain bus (LKA cars without ACC). - ret.enableCamera = True + ret.enableCamera = is_ecu_disconnected(fingerprint[0], FINGERPRINTS, ECU_FINGERPRINT, candidate, Ecu.fwdCamera) or has_relay ret.openpilotLongitudinalControl = ret.enableCamera tire_stiffness_factor = 0.444 # not optimized yet @@ -92,6 +94,9 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): ret.steerRatioRear = 0. ret.centerToFront = ret.wheelbase * 0.49 + # dp + ret = common_interface_get_params_lqr(ret) + # TODO: get actual value, for now starting with reasonable value for # civic and scaling by mass and wheelbase ret.rotationalInertia = scale_rot_inertia(ret.mass, ret.wheelbase) @@ -115,11 +120,13 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): return ret # returns a car.CarState - def update(self, c, can_strings): + def update(self, c, can_strings, dragonconf): self.cp.update_strings(can_strings) ret = self.CS.update(self.cp) - + # dp + self.dragonconf = dragonconf + ret.cruiseState.enabled = common_interface_atl(ret, dragonconf.dpAtl) ret.canValid = self.cp.can_valid ret.steeringRateLimited = self.CC.steer_rate_limited if self.CC is not None else False @@ -188,7 +195,7 @@ def apply(self, c): can_sends = self.CC.update(enabled, self.CS, self.frame, c.actuators, hud_v_cruise, c.hudControl.lanesVisible, - c.hudControl.leadVisible, c.hudControl.visualAlert) + c.hudControl.leadVisible, c.hudControl.visualAlert, self.dragonconf) self.frame += 1 return can_sends diff --git a/selfdrive/car/gm/values.py b/selfdrive/car/gm/values.py index 5e50e6166eaf16..efe696f8a6efeb 100644 --- a/selfdrive/car/gm/values.py +++ b/selfdrive/car/gm/values.py @@ -70,6 +70,10 @@ class CanBus: STEER_THRESHOLD = 1.0 +ECU_FINGERPRINT = { + Ecu.fwdCamera: [384, 715] # 384 = "ASCMLKASteeringCmd", 715 = "ASCMGasRegenCmd" +} + DBC = { CAR.HOLDEN_ASTRA: dbc_dict('gm_global_a_powertrain', 'gm_global_a_object', chassis_dbc='gm_global_a_chassis'), CAR.VOLT: dbc_dict('gm_global_a_powertrain', 'gm_global_a_object', chassis_dbc='gm_global_a_chassis'), diff --git a/selfdrive/car/honda/carcontroller.py b/selfdrive/car/honda/carcontroller.py index b73af39a66841c..0ea4f3b5e79ae8 100644 --- a/selfdrive/car/honda/carcontroller.py +++ b/selfdrive/car/honda/carcontroller.py @@ -7,6 +7,7 @@ from selfdrive.car.honda import hondacan from selfdrive.car.honda.values import CruiseButtons, CAR, VISUAL_HUD, HONDA_BOSCH from opendbc.can.packer import CANPacker +from common.dp_common import common_controller_ctrl VisualAlert = car.CarControl.HUDControl.VisualAlert @@ -72,17 +73,17 @@ def process_hud_alert(hud_alert): HUDData = namedtuple("HUDData", ["pcm_accel", "v_cruise", "car", - "lanes", "fcw", "acc_alert", "steer_required"]) + "lanes", "fcw", "acc_alert", "steer_required", "dashed_lanes"]) class CarControllerParams(): def __init__(self, CP): - self.BRAKE_MAX = 1024//4 - self.STEER_MAX = CP.lateralParams.torqueBP[-1] - # mirror of list (assuming first item is zero) for interp of signed request values - assert(CP.lateralParams.torqueBP[0] == 0) - assert(CP.lateralParams.torqueBP[0] == 0) - self.STEER_LOOKUP_BP = [v * -1 for v in CP.lateralParams.torqueBP][1:][::-1] + list(CP.lateralParams.torqueBP) - self.STEER_LOOKUP_V = [v * -1 for v in CP.lateralParams.torqueV][1:][::-1] + list(CP.lateralParams.torqueV) + self.BRAKE_MAX = 1024//4 + self.STEER_MAX = CP.lateralParams.torqueBP[-1] + # mirror of list (assuming first item is zero) for interp of signed request values + assert(CP.lateralParams.torqueBP[0] == 0) + assert(CP.lateralParams.torqueBP[0] == 0) + self.STEER_LOOKUP_BP = [v * -1 for v in CP.lateralParams.torqueBP][1:][::-1] + list(CP.lateralParams.torqueBP) + self.STEER_LOOKUP_V = [v * -1 for v in CP.lateralParams.torqueV][1:][::-1] + list(CP.lateralParams.torqueV) class CarController(): def __init__(self, dbc_name, CP, VM): @@ -96,9 +97,30 @@ def __init__(self, dbc_name, CP, VM): self.params = CarControllerParams(CP) + # dp + self.last_blinker_on = False + self.blinker_end_frame = 0. + self.prev_lead_distance = 0.0 + self.stopped_lead_distance = 0.0 + self.lead_distance_counter = 1 + self.lead_distance_counter_prev = 1 + self.rough_lead_speed = 0.0 + + def rough_speed(self, lead_distance): + if self.prev_lead_distance != lead_distance: + self.lead_distance_counter_prev = self.lead_distance_counter + self.rough_lead_speed += 0.3334 * ( + (lead_distance - self.prev_lead_distance) / self.lead_distance_counter_prev - self.rough_lead_speed) + self.lead_distance_counter = 0.0 + elif self.lead_distance_counter >= self.lead_distance_counter_prev: + self.rough_lead_speed = (self.lead_distance_counter * self.rough_lead_speed) / (self.lead_distance_counter + 1.0) + self.lead_distance_counter += 1.0 + self.prev_lead_distance = lead_distance + return self.rough_lead_speed + def update(self, enabled, CS, frame, actuators, pcm_speed, pcm_override, pcm_cancel_cmd, pcm_accel, - hud_v_cruise, hud_show_lanes, hud_show_car, hud_alert): + hud_v_cruise, hud_show_lanes, dragonconf, hud_show_car, hud_alert): P = self.params @@ -114,7 +136,7 @@ def update(self, enabled, CS, frame, actuators, self.brake_last = rate_limit(brake, self.brake_last, -2., DT_CTRL) # vehicle hud display, wait for one update from 10Hz 0x304 msg - if hud_show_lanes: + if hud_show_lanes and CS.lkMode: hud_lanes = 1 else: hud_lanes = 0 @@ -130,37 +152,65 @@ def update(self, enabled, CS, frame, actuators, fcw_display, steer_required, acc_alert = process_hud_alert(hud_alert) hud = HUDData(int(pcm_accel), int(round(hud_v_cruise)), hud_car, - hud_lanes, fcw_display, acc_alert, steer_required) + hud_lanes, fcw_display, acc_alert, steer_required, CS.lkMode) # **** process the car messages **** # steer torque is converted back to CAN reference (positive when steering right) apply_steer = int(interp(-actuators.steer * P.STEER_MAX, P.STEER_LOOKUP_BP, P.STEER_LOOKUP_V)) - lkas_active = enabled and not CS.steer_not_allowed + lkas_active = enabled and not CS.steer_not_allowed and CS.lkMode # Send CAN commands. can_sends = [] + # dp + blinker_on = CS.out.leftBlinker or CS.out.rightBlinker + if not enabled: + self.blinker_end_frame = 0 + if self.last_blinker_on and not blinker_on: + self.blinker_end_frame = frame + dragonconf.dpSignalOffDelay + apply_steer = common_controller_ctrl(enabled, + dragonconf, + blinker_on or frame < self.blinker_end_frame, + apply_steer, CS.out.vEgo) + self.last_blinker_on = blinker_on + # Send steering command. idx = frame % 4 can_sends.append(hondacan.create_steering_control(self.packer, apply_steer, - lkas_active, CS.CP.carFingerprint, idx, CS.CP.openpilotLongitudinalControl)) + lkas_active, CS.CP.carFingerprint, idx, CS.CP.isPandaBlack, CS.CP.openpilotLongitudinalControl)) # Send dashboard UI commands. - if (frame % 10) == 0: + if not dragonconf.dpAtl and (frame % 10) == 0: idx = (frame//10) % 4 - can_sends.extend(hondacan.create_ui_commands(self.packer, pcm_speed, hud, CS.CP.carFingerprint, CS.is_metric, idx, CS.CP.openpilotLongitudinalControl, CS.stock_hud)) + can_sends.extend(hondacan.create_ui_commands(self.packer, pcm_speed, hud, CS.CP.carFingerprint, CS.is_metric, idx, CS.CP.isPandaBlack, CS.CP.openpilotLongitudinalControl, CS.stock_hud)) if not CS.CP.openpilotLongitudinalControl: if (frame % 2) == 0: idx = frame // 2 - can_sends.append(hondacan.create_bosch_supplemental_1(self.packer, CS.CP.carFingerprint, idx)) + can_sends.append(hondacan.create_bosch_supplemental_1(self.packer, CS.CP.carFingerprint, idx, CS.CP.isPandaBlack)) + if dragonconf.dpAtl: + pass # If using stock ACC, spam cancel command to kill gas when OP disengages. - if pcm_cancel_cmd: - can_sends.append(hondacan.spam_buttons_command(self.packer, CruiseButtons.CANCEL, idx, CS.CP.carFingerprint)) + elif not dragonconf.dpAllowGas and pcm_cancel_cmd: + can_sends.append(hondacan.spam_buttons_command(self.packer, CruiseButtons.CANCEL, idx, CS.CP.carFingerprint, CS.CP.isPandaBlack)) elif CS.out.cruiseState.standstill: - can_sends.append(hondacan.spam_buttons_command(self.packer, CruiseButtons.RES_ACCEL, idx, CS.CP.carFingerprint)) + if CS.CP.carFingerprint in (CAR.ACCORD, CAR.ACCORD_15, CAR.ACCORDH): + rough_lead_speed = self.rough_speed(CS.lead_distance) + if CS.lead_distance > (self.stopped_lead_distance + 15.0) or rough_lead_speed > 0.1: + self.stopped_lead_distance = 0.0 + can_sends.append( + hondacan.spam_buttons_command(self.packer, CruiseButtons.RES_ACCEL, idx, CS.CP.carFingerprint, CS.CP.isPandaBlack)) + elif CS.CP.carFingerprint in (CAR.CIVIC_BOSCH, CAR.CRV_HYBRID): + if CS.hud_lead == 1: + can_sends.append( + hondacan.spam_buttons_command(self.packer, CruiseButtons.RES_ACCEL, idx, CS.CP.carFingerprint, CS.CP.isPandaBlack)) + else: + can_sends.append(hondacan.spam_buttons_command(self.packer, CruiseButtons.RES_ACCEL, idx, CS.CP.carFingerprint, CS.CP.isPandaBlack)) + else: + self.stopped_lead_distance = CS.lead_distance + self.prev_lead_distance = CS.lead_distance else: # Send gas and brake commands. @@ -170,16 +220,17 @@ def update(self, enabled, CS, frame, actuators, if CS.CP.carFingerprint in HONDA_BOSCH: pass # TODO: implement else: - apply_gas = clip(actuators.gas, 0., 1.) - apply_brake = int(clip(self.brake_last * P.BRAKE_MAX, 0, P.BRAKE_MAX - 1)) - pump_on, self.last_pump_ts = brake_pump_hysteresis(apply_brake, self.apply_brake_last, self.last_pump_ts, ts) - can_sends.append(hondacan.create_brake_command(self.packer, apply_brake, pump_on, - pcm_override, pcm_cancel_cmd, hud.fcw, idx, CS.CP.carFingerprint, CS.stock_brake)) - self.apply_brake_last = apply_brake - - if CS.CP.enableGasInterceptor: - # send exactly zero if apply_gas is zero. Interceptor will send the max between read value and apply_gas. - # This prevents unexpected pedal range rescaling - can_sends.append(create_gas_command(self.packer, apply_gas, idx)) + if not dragonconf.dpAtl: + apply_gas = clip(actuators.gas, 0., 1.) + apply_brake = int(clip(self.brake_last * P.BRAKE_MAX, 0, P.BRAKE_MAX - 1)) + pump_on, self.last_pump_ts = brake_pump_hysteresis(apply_brake, self.apply_brake_last, self.last_pump_ts, ts) + can_sends.append(hondacan.create_brake_command(self.packer, apply_brake, pump_on, + pcm_override, pcm_cancel_cmd, hud.fcw, idx, CS.CP.carFingerprint, CS.CP.isPandaBlack, CS.stock_brake)) + self.apply_brake_last = apply_brake + + if CS.CP.enableGasInterceptor: + # send exactly zero if apply_gas is zero. Interceptor will send the max between read value and apply_gas. + # This prevents unexpected pedal range rescaling + can_sends.append(create_gas_command(self.packer, apply_gas, idx)) return can_sends diff --git a/selfdrive/car/honda/carstate.py b/selfdrive/car/honda/carstate.py index 16d85892a621b6..2c90d665396655 100644 --- a/selfdrive/car/honda/carstate.py +++ b/selfdrive/car/honda/carstate.py @@ -22,41 +22,42 @@ def calc_cruise_offset(offset, speed): def get_can_signals(CP): # this function generates lists for signal, messages and initial values signals = [ - ("XMISSION_SPEED", "ENGINE_DATA", 0), - ("WHEEL_SPEED_FL", "WHEEL_SPEEDS", 0), - ("WHEEL_SPEED_FR", "WHEEL_SPEEDS", 0), - ("WHEEL_SPEED_RL", "WHEEL_SPEEDS", 0), - ("WHEEL_SPEED_RR", "WHEEL_SPEEDS", 0), - ("STEER_ANGLE", "STEERING_SENSORS", 0), - ("STEER_ANGLE_RATE", "STEERING_SENSORS", 0), - ("MOTOR_TORQUE", "STEER_MOTOR_TORQUE", 0), - ("STEER_TORQUE_SENSOR", "STEER_STATUS", 0), - ("LEFT_BLINKER", "SCM_FEEDBACK", 0), - ("RIGHT_BLINKER", "SCM_FEEDBACK", 0), - ("GEAR", "GEARBOX", 0), - ("SEATBELT_DRIVER_LAMP", "SEATBELT_STATUS", 1), - ("SEATBELT_DRIVER_LATCHED", "SEATBELT_STATUS", 0), - ("BRAKE_PRESSED", "POWERTRAIN_DATA", 0), - ("BRAKE_SWITCH", "POWERTRAIN_DATA", 0), - ("CRUISE_BUTTONS", "SCM_BUTTONS", 0), - ("ESP_DISABLED", "VSA_STATUS", 1), - ("USER_BRAKE", "VSA_STATUS", 0), - ("BRAKE_HOLD_ACTIVE", "VSA_STATUS", 0), - ("STEER_STATUS", "STEER_STATUS", 5), - ("GEAR_SHIFTER", "GEARBOX", 0), - ("PEDAL_GAS", "POWERTRAIN_DATA", 0), - ("CRUISE_SETTING", "SCM_BUTTONS", 0), - ("ACC_STATUS", "POWERTRAIN_DATA", 0), + ("XMISSION_SPEED", "ENGINE_DATA", 0), + ("WHEEL_SPEED_FL", "WHEEL_SPEEDS", 0), + ("WHEEL_SPEED_FR", "WHEEL_SPEEDS", 0), + ("WHEEL_SPEED_RL", "WHEEL_SPEEDS", 0), + ("WHEEL_SPEED_RR", "WHEEL_SPEEDS", 0), + ("STEER_ANGLE", "STEERING_SENSORS", 0), + ("STEER_ANGLE_RATE", "STEERING_SENSORS", 0), + ("MOTOR_TORQUE", "STEER_MOTOR_TORQUE", 0), + ("STEER_TORQUE_SENSOR", "STEER_STATUS", 0), + ("LEFT_BLINKER", "SCM_FEEDBACK", 0), + ("RIGHT_BLINKER", "SCM_FEEDBACK", 0), + ("GEAR", "GEARBOX", 0), + ("SEATBELT_DRIVER_LAMP", "SEATBELT_STATUS", 1), + ("SEATBELT_DRIVER_LATCHED", "SEATBELT_STATUS", 0), + ("BRAKE_PRESSED", "POWERTRAIN_DATA", 0), + ("BRAKE_SWITCH", "POWERTRAIN_DATA", 0), + ("CRUISE_BUTTONS", "SCM_BUTTONS", 0), + ("ESP_DISABLED", "VSA_STATUS", 1), + ("USER_BRAKE", "VSA_STATUS", 0), + ("BRAKE_HOLD_ACTIVE", "VSA_STATUS", 0), + ("HUD_LEAD", "ACC_HUD", 0), + ("STEER_STATUS", "STEER_STATUS", 5), + ("GEAR_SHIFTER", "GEARBOX", 0), + ("PEDAL_GAS", "POWERTRAIN_DATA", 0), + ("CRUISE_SETTING", "SCM_BUTTONS", 0), + ("ACC_STATUS", "POWERTRAIN_DATA", 0), ] checks = [ - ("ENGINE_DATA", 100), - ("WHEEL_SPEEDS", 50), - ("STEERING_SENSORS", 100), - ("SEATBELT_STATUS", 10), - ("CRUISE", 10), - ("POWERTRAIN_DATA", 100), - ("VSA_STATUS", 50), + ("ENGINE_DATA", 100), + ("WHEEL_SPEEDS", 50), + ("STEERING_SENSORS", 100), + ("SEATBELT_STATUS", 10), + ("CRUISE", 10), + ("POWERTRAIN_DATA", 100), + ("VSA_STATUS", 50), ] if CP.carFingerprint == CAR.ODYSSEY_CHN: @@ -106,11 +107,16 @@ def get_can_signals(CP): checks += [("CRUISE_PARAMS", 10)] else: checks += [("CRUISE_PARAMS", 50)] - if CP.carFingerprint in (CAR.ACCORD, CAR.ACCORD_15, CAR.ACCORDH, CAR.CIVIC_BOSCH, CAR.CIVIC_BOSCH_DIESEL, CAR.CRV_HYBRID, CAR.INSIGHT, CAR.ACURA_RDX_3G): + if CP.carFingerprint in (CAR.ACCORD, CAR.ACCORD_15, CAR.ACCORDH, CAR.INSIGHT): + signals += [("DRIVERS_DOOR_OPEN", "SCM_FEEDBACK", 1), + ("LEAD_DISTANCE", "RADAR_HUD", 0)] + checks += [("RADAR_HUD", 50)] + elif CP.carFingerprint in (CAR.CIVIC_BOSCH, CAR.CIVIC_BOSCH_DIESEL, CAR.CRV_HYBRID, CAR.ACURA_RDX_3G): signals += [("DRIVERS_DOOR_OPEN", "SCM_FEEDBACK", 1)] + checks += [("RADAR_HUD", 50)] elif CP.carFingerprint == CAR.ODYSSEY_CHN: signals += [("DRIVERS_DOOR_OPEN", "SCM_BUTTONS", 1)] - elif CP.carFingerprint == CAR.HRV: + elif CP.carFingerprint in [CAR.HRV, CAR.JADE]: signals += [("DRIVERS_DOOR_OPEN", "SCM_BUTTONS", 1), ("WHEELS_MOVING", "STANDSTILL", 1)] else: @@ -135,7 +141,7 @@ def get_can_signals(CP): signals += [("CAR_GAS", "GAS_PEDAL_2", 0), ("MAIN_ON", "SCM_BUTTONS", 0), ("BRAKE_HOLD_ACTIVE", "VSA_STATUS", 0)] - elif CP.carFingerprint == CAR.HRV: + elif CP.carFingerprint in [CAR.HRV, CAR.JADE]: signals += [("CAR_GAS", "GAS_PEDAL", 0), ("MAIN_ON", "SCM_BUTTONS", 0), ("BRAKE_HOLD_ACTIVE", "VSA_STATUS", 0)] @@ -175,6 +181,10 @@ def __init__(self, CP): self.v_cruise_pcm_prev = 0 self.cruise_mode = 0 + #dp + self.lkMode = True + self.lead_distance = 0. + def update(self, cp, cp_cam, cp_body): ret = car.CarState.new_message() @@ -188,13 +198,17 @@ def update(self, cp, cp_cam, cp_body): # ******************* parse out can ******************* # TODO: find wheels moving bit in dbc - if self.CP.carFingerprint in (CAR.ACCORD, CAR.ACCORD_15, CAR.ACCORDH, CAR.CIVIC_BOSCH, CAR.CIVIC_BOSCH_DIESEL, CAR.CRV_HYBRID, CAR.INSIGHT, CAR.ACURA_RDX_3G): + if self.CP.carFingerprint in (CAR.ACCORD, CAR.ACCORD_15, CAR.ACCORDH, CAR.INSIGHT): + ret.standstill = cp.vl["ENGINE_DATA"]['XMISSION_SPEED'] < 0.1 + ret.doorOpen = bool(cp.vl["SCM_FEEDBACK"]['DRIVERS_DOOR_OPEN']) + self.lead_distance = cp.vl["RADAR_HUD"]['LEAD_DISTANCE'] + elif self.CP.carFingerprint in (CAR.CIVIC_BOSCH, CAR.CIVIC_BOSCH_DIESEL, CAR.CRV_HYBRID, CAR.ACURA_RDX_3G): ret.standstill = cp.vl["ENGINE_DATA"]['XMISSION_SPEED'] < 0.1 ret.doorOpen = bool(cp.vl["SCM_FEEDBACK"]['DRIVERS_DOOR_OPEN']) elif self.CP.carFingerprint == CAR.ODYSSEY_CHN: ret.standstill = cp.vl["ENGINE_DATA"]['XMISSION_SPEED'] < 0.1 ret.doorOpen = bool(cp.vl["SCM_BUTTONS"]['DRIVERS_DOOR_OPEN']) - elif self.CP.carFingerprint == CAR.HRV: + elif self.CP.carFingerprint in [CAR.HRV, CAR.JADE]: ret.doorOpen = bool(cp.vl["SCM_BUTTONS"]['DRIVERS_DOOR_OPEN']) else: ret.standstill = not cp.vl["STANDSTILL"]['WHEELS_MOVING'] @@ -230,6 +244,14 @@ def update(self, cp, cp_cam, cp_body): ret.steeringAngle = cp.vl["STEERING_SENSORS"]['STEER_ANGLE'] ret.steeringRate = cp.vl["STEERING_SENSORS"]['STEER_ANGLE_RATE'] + # dp - when user presses LKAS button on steering wheel + if self.cruise_setting == 1: + if cp.vl["SCM_BUTTONS"]["CRUISE_SETTING"] == 0: + if self.lkMode: + self.lkMode = False + else: + self.lkMode = True + self.cruise_setting = cp.vl["SCM_BUTTONS"]['CRUISE_SETTING'] self.cruise_buttons = cp.vl["SCM_BUTTONS"]['CRUISE_BUTTONS'] @@ -253,7 +275,7 @@ def update(self, cp, cp_cam, cp_body): self.pedal_gas = cp.vl["POWERTRAIN_DATA"]['PEDAL_GAS'] # crv doesn't include cruise control - if self.CP.carFingerprint in (CAR.CRV, CAR.CRV_EU, CAR.HRV, CAR.ODYSSEY, CAR.ACURA_RDX, CAR.RIDGELINE, CAR.PILOT_2019, CAR.ODYSSEY_CHN): + if self.CP.carFingerprint in (CAR.CRV, CAR.CRV_EU, CAR.HRV, CAR.JADE, CAR.ODYSSEY, CAR.ACURA_RDX, CAR.RIDGELINE, CAR.PILOT_2019, CAR.ODYSSEY_CHN): ret.gas = self.pedal_gas / 256. else: ret.gas = cp.vl["GAS_PEDAL_2"]['CAR_GAS'] / 256. @@ -304,6 +326,9 @@ def update(self, cp, cp_cam, cp_body): ret.cruiseState.available = bool(main_on) ret.cruiseState.nonAdaptive = self.cruise_mode != 0 + # afa feature + self.hud_lead = cp.vl["ACC_HUD"]['HUD_LEAD'] + # Gets rid of Pedal Grinding noise when brake is pressed at slow speeds for some models if self.CP.carFingerprint in (CAR.PILOT, CAR.PILOT_2019, CAR.RIDGELINE): if ret.brake > 0.05: @@ -336,7 +361,8 @@ def update(self, cp, cp_cam, cp_body): @staticmethod def get_can_parser(CP): signals, checks = get_can_signals(CP) - bus_pt = 1 if CP.carFingerprint in HONDA_BOSCH else 0 + bus_pt = 1 if CP.isPandaBlack and CP.carFingerprint in HONDA_BOSCH else 0 + checks = [] return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, bus_pt) @staticmethod @@ -361,7 +387,9 @@ def get_cam_can_parser(CP): if CP.carFingerprint in [CAR.CRV, CAR.CRV_EU, CAR.ACURA_RDX, CAR.ODYSSEY_CHN]: checks = [(0x194, 100)] - return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, 2) + bus_cam = 1 if CP.carFingerprint in HONDA_BOSCH and not CP.isPandaBlack else 2 + checks = [] + return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, bus_cam) @staticmethod def get_body_can_parser(CP): diff --git a/selfdrive/car/honda/hondacan.py b/selfdrive/car/honda/hondacan.py index ef256470225a68..e9b9db97688f75 100644 --- a/selfdrive/car/honda/hondacan.py +++ b/selfdrive/car/honda/hondacan.py @@ -7,19 +7,23 @@ # 2 = ACC-CAN - camera side # 3 = F-CAN A - OBDII port -def get_pt_bus(car_fingerprint): - return 1 if car_fingerprint in HONDA_BOSCH else 0 +# CAN bus layout with giraffe +# 0 = F-CAN B - powertrain +# 1 = ACC-CAN - camera side +# 2 = ACC-CAN - radar side +def get_pt_bus(car_fingerprint, has_relay): + return 1 if car_fingerprint in HONDA_BOSCH and has_relay else 0 -def get_lkas_cmd_bus(car_fingerprint, radar_disabled=False): +def get_lkas_cmd_bus(car_fingerprint, has_relay, radar_disabled=False): if radar_disabled: # when radar is disabled, steering commands are sent directly to powertrain bus - return get_pt_bus(car_fingerprint) + return get_pt_bus(car_fingerprint, has_relay) # normally steering commands are sent to radar, which forwards them to powertrain bus - return 0 + return 2 if car_fingerprint in HONDA_BOSCH and not has_relay else 0 -def create_brake_command(packer, apply_brake, pump_on, pcm_override, pcm_cancel_cmd, fcw, idx, car_fingerprint, stock_brake): +def create_brake_command(packer, apply_brake, pump_on, pcm_override, pcm_cancel_cmd, fcw, idx, car_fingerprint, has_relay, stock_brake): # TODO: do we loose pressure if we keep pump off for long? brakelights = apply_brake > 0 brake_rq = apply_brake > 0 @@ -40,13 +44,13 @@ def create_brake_command(packer, apply_brake, pump_on, pcm_override, pcm_cancel_ "AEB_REQ_2": 0, "AEB_STATUS": 0, } - bus = get_pt_bus(car_fingerprint) + bus = get_pt_bus(car_fingerprint, has_relay) return packer.make_can_msg("BRAKE_COMMAND", bus, values, idx) -def create_acc_commands(packer, enabled, accel, gas, idx, stopping, starting, car_fingerprint): +def create_acc_commands(packer, enabled, accel, gas, idx, stopping, starting, car_fingerprint, has_relay): commands = [] - bus = get_pt_bus(car_fingerprint) + bus = get_pt_bus(car_fingerprint, has_relay) control_on = 5 if enabled else 0 # no gas = -30000 @@ -79,31 +83,31 @@ def create_acc_commands(packer, enabled, accel, gas, idx, stopping, starting, ca return commands -def create_steering_control(packer, apply_steer, lkas_active, car_fingerprint, idx, radar_disabled): +def create_steering_control(packer, apply_steer, lkas_active, car_fingerprint, idx, has_relay, radar_disabled): values = { "STEER_TORQUE": apply_steer if lkas_active else 0, "STEER_TORQUE_REQUEST": lkas_active, } - bus = get_lkas_cmd_bus(car_fingerprint, radar_disabled) + bus = get_lkas_cmd_bus(car_fingerprint, has_relay, radar_disabled) return packer.make_can_msg("STEERING_CONTROL", bus, values, idx) -def create_bosch_supplemental_1(packer, car_fingerprint, idx): +def create_bosch_supplemental_1(packer, car_fingerprint, idx, has_relay): # non-active params values = { "SET_ME_X04": 0x04, "SET_ME_X80": 0x80, "SET_ME_X10": 0x10, } - bus = get_lkas_cmd_bus(car_fingerprint) + bus = get_lkas_cmd_bus(car_fingerprint, has_relay) return packer.make_can_msg("BOSCH_SUPPLEMENTAL_1", bus, values, idx) -def create_ui_commands(packer, pcm_speed, hud, car_fingerprint, is_metric, idx, openpilot_longitudinal_control, stock_hud): +def create_ui_commands(packer, pcm_speed, hud, car_fingerprint, is_metric, idx, has_relay, openpilot_longitudinal_control, stock_hud): commands = [] - bus_pt = get_pt_bus(car_fingerprint) + bus_pt = get_pt_bus(car_fingerprint, has_relay) radar_disabled = car_fingerprint in HONDA_BOSCH and openpilot_longitudinal_control - bus_lkas = get_lkas_cmd_bus(car_fingerprint, radar_disabled) + bus_lkas = get_lkas_cmd_bus(car_fingerprint, has_relay, radar_disabled) if openpilot_longitudinal_control: if car_fingerprint in HONDA_BOSCH: @@ -153,10 +157,10 @@ def create_ui_commands(packer, pcm_speed, hud, car_fingerprint, is_metric, idx, return commands -def spam_buttons_command(packer, button_val, idx, car_fingerprint): +def spam_buttons_command(packer, button_val, idx, car_fingerprint, has_relay): values = { 'CRUISE_BUTTONS': button_val, 'CRUISE_SETTING': 0, } - bus = get_pt_bus(car_fingerprint) + bus = get_pt_bus(car_fingerprint, has_relay) return packer.make_can_msg("SCM_BUTTONS", bus, values, idx) diff --git a/selfdrive/car/honda/interface.py b/selfdrive/car/honda/interface.py index 6d474dcd85cf40..1677573304c779 100755 --- a/selfdrive/car/honda/interface.py +++ b/selfdrive/car/honda/interface.py @@ -6,10 +6,12 @@ from selfdrive.swaglog import cloudlog from selfdrive.config import Conversions as CV from selfdrive.controls.lib.events import ET -from selfdrive.car.honda.values import CruiseButtons, CAR, HONDA_BOSCH -from selfdrive.car import STD_CARGO_KG, CivicParams, scale_rot_inertia, scale_tire_stiffness, gen_empty_fingerprint +from selfdrive.car.honda.values import CruiseButtons, CAR, HONDA_BOSCH, Ecu, ECU_FINGERPRINT, FINGERPRINTS +from selfdrive.car import STD_CARGO_KG, CivicParams, scale_rot_inertia, scale_tire_stiffness, is_ecu_disconnected, gen_empty_fingerprint from selfdrive.controls.lib.planner import _A_CRUISE_MAX_V_FOLLOWING from selfdrive.car.interfaces import CarInterfaceBase +from common.dp_common import common_interface_atl, common_interface_get_params_lqr +from common.params import Params A_ACC_MAX = max(_A_CRUISE_MAX_V_FOLLOWING) @@ -119,18 +121,20 @@ def calc_accel_override(a_ego, a_target, v_ego, v_target): return float(max(max_accel, a_target / A_ACC_MAX)) * min(speedLimiter, accelLimiter) @staticmethod - def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # pylint: disable=dangerous-default-value - ret = CarInterfaceBase.get_std_params(candidate, fingerprint) + def get_params(candidate, fingerprint=gen_empty_fingerprint(), has_relay=False, car_fw=[]): # pylint: disable=dangerous-default-value + ret = CarInterfaceBase.get_std_params(candidate, fingerprint, has_relay) ret.carName = "honda" + ret.lateralTuning.init('pid') if candidate in HONDA_BOSCH: - ret.safetyModel = car.CarParams.SafetyModel.hondaBoschHarness - ret.enableCamera = True + ret.safetyModel = car.CarParams.SafetyModel.hondaBoschHarness if has_relay else car.CarParams.SafetyModel.hondaBoschGiraffe + rdr_bus = 0 if has_relay else 2 + ret.enableCamera = is_ecu_disconnected(fingerprint[rdr_bus], FINGERPRINTS, ECU_FINGERPRINT, candidate, Ecu.fwdCamera) or has_relay ret.radarOffCan = True ret.openpilotLongitudinalControl = False else: ret.safetyModel = car.CarParams.SafetyModel.hondaNidec - ret.enableCamera = True + ret.enableCamera = is_ecu_disconnected(fingerprint[0], FINGERPRINTS, ECU_FINGERPRINT, candidate, Ecu.fwdCamera) or has_relay ret.enableGasInterceptor = 0x201 in fingerprint[0] ret.openpilotLongitudinalControl = ret.enableCamera @@ -305,6 +309,20 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py ret.longitudinalTuning.kiBP = [0., 35.] ret.longitudinalTuning.kiV = [0.18, 0.12] + elif candidate == CAR.JADE: + stop_and_go = False + ret.mass = 1557. + STD_CARGO_KG + ret.wheelbase = 2.76 + ret.centerToFront = ret.wheelbase * 0.41 + ret.steerRatio = 15.2 + ret.lateralParams.torqueBP, ret.lateralParams.torqueV = [[0, 4096], [0, 4096]] + tire_stiffness_factor = 0.5 + ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.16], [0.025]] + ret.longitudinalTuning.kpBP = [0., 5., 35.] + ret.longitudinalTuning.kpV = [1.2, 0.8, 0.5] + ret.longitudinalTuning.kiBP = [0., 35.] + ret.longitudinalTuning.kiV = [0.18, 0.12] + elif candidate == CAR.ACURA_RDX: stop_and_go = False ret.mass = 3935. * CV.LB_TO_KG + STD_CARGO_KG @@ -407,6 +425,26 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py else: raise ValueError("unsupported car %s" % candidate) + # dp + if Params().get('dp_honda_eps_mod') == b'1': + if candidate == CAR.CIVIC: + ret.lateralParams.torqueBP, ret.lateralParams.torqueV = [[0, 2566, 8000], [0, 2566, 3840]] + ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.32], [0.1]] #2.5x tuned by @CFranHonda + elif candidate in (CAR.CIVIC_BOSCH, CAR.CIVIC_BOSCH_DIESEL): + ret.lateralParams.torqueBP, ret.lateralParams.torqueV = [[0, 2564, 8000], [0, 2564, 3840]] + ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.32], [0.1]] #2.5 default mod #TMG put your values here + elif candidate in (CAR.ACCORD, CAR.ACCORD_15, CAR.ACCORDH): + ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.3], [0.09]] + elif candidate == CAR.CRV_5G: + ret.lateralParams.torqueBP, ret.lateralParams.torqueV = [[0, 2560, 10000], [0, 2560, 3840]] #tuned by Titanminer (8000) + ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.21], [0.07]] + elif candidate == CAR.CRV_HYBRID: + ret.lateralParams.torqueBP, ret.lateralParams.torqueV = [[0x0, 0xB5, 0x161, 0x2D6, 0x4C0, 0x70D, 0xC42, 0x1058, 0x2C00], [0x0, 0x160, 0x1F0, 0x2E0, 0x378, 0x4A0, 0x5F0, 0x804, 0xF00]] + ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.21], [0.07]] #still needs to finish tuning for the new car + ret.lateralTuning.pid.kf = 0.00004 + + ret = common_interface_get_params_lqr(ret) + # min speed to enable ACC. if car can do stop and go, then set enabling speed # to a negative value, so it won't matter. Otherwise, add 0.5 mph margin to not # conflict with PCM acc @@ -436,7 +474,7 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py return ret # returns a car.CarState - def update(self, c, can_strings): + def update(self, c, can_strings, dragonconf): # ******************* do can recv ******************* self.cp.update_strings(can_strings) self.cp_cam.update_strings(can_strings) @@ -444,7 +482,9 @@ def update(self, c, can_strings): self.cp_body.update_strings(can_strings) ret = self.CS.update(self.cp, self.cp_cam, self.cp_body) - + # dp + self.dragonconf = dragonconf + ret.cruiseState.enabled = common_interface_atl(ret, dragonconf.dpAtl) ret.canValid = self.cp.can_valid and self.cp_cam.can_valid and (self.cp_body is None or self.cp_body.can_valid) ret.yawRate = self.VM.yaw_rate(ret.steeringAngle * CV.DEG_TO_RAD, ret.vEgo) # FIXME: read sendcan for brakelights @@ -452,6 +492,9 @@ def update(self, c, can_strings): ret.brakeLights = bool(self.CS.brake_switch or c.actuators.brake > brakelights_threshold) + # dp + ret.lkMode = self.CS.lkMode + buttonEvents = [] if self.CS.cruise_buttons != self.CS.prev_cruise_buttons: @@ -490,6 +533,8 @@ def update(self, c, can_strings): # events events = self.create_common_events(ret, pcm_enable=False) + if not self.CS.lkMode or (dragonconf.dpAtl and ret.vEgo <= self.CP.minEnableSpeed): + events.add(EventName.manualSteeringRequired) if self.CS.brake_error: events.add(EventName.brakeUnavailable) if self.CS.brake_hold and self.CS.CP.openpilotLongitudinalControl: @@ -506,8 +551,8 @@ def update(self, c, can_strings): and (c.actuators.brake <= 0. or not self.CP.openpilotLongitudinalControl): # non loud alert if cruise disables below 25mph as expected (+ a little margin) if ret.vEgo < self.CP.minEnableSpeed + 2.: - events.add(EventName.speedTooLow) - else: + # events.add(EventName.speedTooLow) + # else: events.add(EventName.cruiseDisabled) if self.CS.CP.minEnableSpeed > 0 and ret.vEgo < 0.001: events.add(EventName.manualRestart) @@ -563,6 +608,7 @@ def apply(self, c): pcm_accel, hud_v_cruise, c.hudControl.lanesVisible, + self.dragonconf, hud_show_car=c.hudControl.leadVisible, hud_alert=c.hudControl.visualAlert) diff --git a/selfdrive/car/honda/values.py b/selfdrive/car/honda/values.py index 5eca73c2d792b5..db6c5db7b8c80e 100644 --- a/selfdrive/car/honda/values.py +++ b/selfdrive/car/honda/values.py @@ -37,6 +37,7 @@ class CAR: CRV_HYBRID = "HONDA CR-V 2019 HYBRID" FIT = "HONDA FIT 2018 EX" HRV = "HONDA HRV 2019 TOURING" + JADE = "HONDA JADE 2017" ODYSSEY = "HONDA ODYSSEY 2018 EX-L" ODYSSEY_CHN = "HONDA ODYSSEY 2019 EXCLUSIVE CHN" ACURA_RDX = "ACURA RDX 2018 ACURAWATCH PLUS" @@ -54,10 +55,10 @@ class CAR: 148: 8, 228: 5, 304: 8, 330: 8, 344: 8, 380: 8, 399: 7, 419: 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.ACCORD_15: [{ - 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 + 148: 8, 228: 5, 229: 8, 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, 513: 8, 545: 6, 576: 8, 577: 8, 579: 8, 580: 8, 582: 8, 583: 8, 585: 8, 586: 8, 640: 8, 641: 8, 642: 8, 643: 8, 644: 8, 645: 8, 646: 8, 647: 8, 648: 8, 649: 8, 650: 8, 651: 8, 652: 8, 653: 8, 654: 8, 655: 8, 656: 8, 657: 8, 658: 8, 659: 8, 660: 8, 661: 8, 662: 4, 663: 8, 712: 8, 713: 8, 714: 8, 715: 8, 716: 8, 717: 8, 718: 8, 719: 8, 720: 8, 721: 8, 722: 8, 723: 8, 724: 8, 725: 8, 726: 8, 727: 8, 728: 8, 729: 8, 730: 8, 731: 8, 732: 8, 733: 8, 734: 8, 735: 8, 736: 8, 737: 8, 738: 8, 739: 8, 740: 8, 741: 8, 742: 8, 743: 8, 744: 8, 745: 8, 746: 8, 747: 8, 748: 8, 749: 8, 750: 8, 751: 8, 752: 8, 753: 8, 754: 8, 755: 8, 756: 8, 757: 8, 758: 8, 759: 8, 760: 8, 761: 8, 762: 8, 763: 8, 764: 8, 765: 8, 766: 8, 767: 8, 773: 7, 777: 8, 780: 8, 804: 8, 806: 8, 808: 8, 829: 5, 862: 8, 884: 8, 891: 8, 927: 8, 929: 8, 1024: 4, 1040: 6, 1056: 8, 1088: 3, 1104: 8, 1302: 8, 1416: 5, 1600: 5, 1601: 8, 1641: 8, 1652: 8, 1872: 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, 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, @@ -87,8 +88,12 @@ class CAR: CAR.CRV: [{ 57: 3, 145: 8, 316: 8, 340: 8, 342: 6, 344: 8, 380: 8, 398: 3, 399: 6, 401: 8, 404: 4, 420: 8, 422: 8, 426: 8, 432: 7, 464: 8, 474: 5, 476: 4, 487: 4, 490: 8, 493: 3, 506: 8, 507: 1, 512: 6, 513: 6, 542: 7, 545: 4, 597: 8, 660: 8, 661: 4, 773: 7, 777: 8, 780: 8, 800: 8, 804: 8, 808: 8, 829: 5, 882: 2, 884: 7, 888: 8, 891: 8, 892: 8, 923: 2, 929: 8, 983: 8, 985: 3, 1024: 5, 1027: 5, 1029: 8, 1033: 5, 1036: 8, 1039: 8, 1057: 5, 1064: 7, 1108: 8, 1125: 8, 1296: 8, 1365: 5, 1424: 5, 1600: 5, 1601: 8, }], - CAR.CRV_5G: [{ - 57: 3, 148: 8, 199: 4, 228: 5, 231: 5, 232: 7, 304: 8, 330: 8, 340: 8, 344: 8, 380: 8, 399: 7, 401: 8, 420: 8, 423: 2, 427: 3, 428: 8, 432: 7, 441: 5, 446: 3, 450: 8, 464: 8, 467: 2, 469: 3, 470: 2, 474: 8, 476: 7, 477: 8, 479: 8, 490: 8, 493: 5, 495: 8, 507: 1, 545: 6, 597: 8, 661: 4, 662: 4, 773: 7, 777: 8, 780: 8, 795: 8, 800: 8, 804: 8, 806: 8, 808: 8, 814: 4, 815: 8, 817: 4, 825: 4, 829: 5, 862: 8, 881: 8, 882: 4, 884: 8, 888: 8, 891: 8, 927: 8, 918: 7, 929: 8, 983: 8, 985: 3, 1024: 5, 1027: 5, 1029: 8, 1036: 8, 1039: 8, 1064: 7, 1108: 8, 1092: 1, 1115: 2, 1125: 8, 1127: 2, 1296: 8, 1302: 8, 1322: 5, 1361: 5, 1365: 5, 1424: 5, 1600: 5, 1601: 8, 1618: 5, 1633: 8, 1670: 5 + CAR.CRV_5G: [ + { + 57: 3, 148: 8, 199: 4, 228: 5, 231: 5, 232: 7, 304: 8, 330: 8, 340: 8, 344: 8, 380: 8, 399: 7, 401: 8, 420: 8, 423: 2, 427: 3, 428: 8, 432: 7, 441: 5, 446: 3, 450: 8, 464: 8, 467: 2, 469: 3, 470: 2, 474: 8, 476: 7, 477: 8, 479: 8, 490: 8, 493: 5, 495: 8, 507: 1, 545: 6, 597: 8, 661: 4, 662: 4, 773: 7, 777: 8, 780: 8, 795: 8, 800: 8, 804: 8, 806: 8, 808: 8, 814: 4, 815: 8, 817: 4, 825: 4, 829: 5, 862: 8, 881: 8, 882: 4, 884: 8, 888: 8, 891: 8, 927: 8, 918: 7, 929: 8, 983: 8, 985: 3, 1024: 5, 1027: 5, 1029: 8, 1036: 8, 1039: 8, 1040: 6, 1056: 8, 1064: 7, 1088: 3, 1108: 8, 1092: 1, 1115: 2, 1125: 8, 1127: 2, 1296: 8, 1302: 8, 1322: 5, 1361: 5, 1365: 5, 1424: 5, 1600: 5, 1601: 8, 1618: 5, 1626: 5, 1627: 5, 1633: 8, 1670: 5 + }, + { + 57: 3, 148: 8, 199: 4, 228: 5, 231: 5, 232: 7, 304: 8, 330: 8, 340: 8, 344: 8, 380: 8, 399: 7, 401: 8, 420: 8, 423: 2, 427: 3, 428: 8, 432: 7, 441: 5, 446: 3, 450: 8, 464: 8, 467: 2, 469: 3, 470: 2, 474: 8, 476: 7, 477: 8, 479: 8, 490: 8, 493: 5, 495: 8, 507: 1, 545: 6, 597: 8, 661: 4, 662: 4, 773: 7, 777: 8, 780: 8, 795: 8, 800: 8, 804: 8, 806: 8, 808: 8, 814: 4, 815: 8, 817: 4, 825: 4, 829: 5, 862: 8, 881: 8, 882: 4, 884: 8, 888: 8, 891: 8, 927: 8, 918: 7, 929: 8, 983: 8, 985: 3, 1024: 4, 1027: 5, 1029: 8, 1036: 8, 1039: 8, 1040: 6, 1056: 8, 1064: 7, 1088: 3, 1108: 8, 1092: 1, 1115: 2, 1125: 8, 1127: 2, 1296: 8, 1302: 8, 1322: 5, 1361: 5, 1365: 5, 1424: 5, 1600: 5, 1601: 8, 1618: 5, 1626: 5, 1627: 5, 1633: 8, 1670: 5 }], # 1057: 5 1024: 5 are also on the OBD2 bus. their lengths differ from the camera's f-can bus. re-fingerprint after obd2 connection is split in panda firmware from bus 1. CAR.CRV_EU: [{ @@ -96,6 +101,10 @@ class CAR: }], CAR.CRV_HYBRID: [{ 57: 3, 148: 8, 228: 5, 304: 8, 330: 8, 344: 8, 380: 8, 387: 8, 388: 8, 399: 7, 408: 6, 415: 6, 419: 8, 420: 8, 427: 3, 428: 8, 432: 7, 441: 5, 450: 8, 464: 8, 477: 8, 479: 8, 490: 8, 495: 8, 525: 8, 531: 8, 545: 6, 662: 4, 773: 7, 777: 8, 780: 8, 804: 8, 806: 8, 808: 8, 814: 4, 829: 5, 833: 6, 862: 8, 884: 8, 891: 8, 927: 8, 929: 8, 930: 8, 931: 8, 1302: 8, 1361: 5, 1365: 5, 1600: 5, 1601: 8, 1626: 5, 1627: 5 + }, + { + # honda breeze hybrid + 57: 3, 148: 8, 228: 5, 229: 8, 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, 490: 8, 495: 8, 513: 8, 525: 8, 531: 8, 545: 6, 560: 8, 576: 8, 577: 8, 579: 8, 580: 8, 582: 8, 583: 8, 585: 8, 586: 8, 640: 8, 641: 8, 642: 8, 643: 8, 644: 8, 645: 8, 646: 8, 647: 8, 648: 8, 649: 8, 650: 8, 651: 8, 652: 8, 653: 8, 654: 8, 655: 8, 656: 8, 657: 8, 658: 8, 659: 8, 660: 8, 661: 8, 662: 4, 663: 8, 712: 8, 713: 8, 714: 8, 715: 8, 716: 8, 717: 8, 718: 8, 719: 8, 720: 8, 721: 8, 722: 8, 723: 8, 724: 8, 725: 8, 726: 8, 727: 8, 728: 8, 729: 8, 730: 8, 731: 8, 732: 8, 733: 8, 734: 8, 735: 8, 736: 8, 737: 8, 738: 8, 739: 8, 740: 8, 741: 8, 742: 8, 743: 8, 744: 8, 745: 8, 746: 8, 747: 8, 748: 8, 749: 8, 750: 8, 751: 8, 752: 8, 753: 8, 754: 8, 755: 8, 756: 8, 757: 8, 758: 8, 759: 8, 760: 8, 761: 8, 762: 8, 763: 8, 764: 8, 765: 8, 766: 8, 767: 8, 773: 7, 777: 8, 780: 8, 804: 8, 806: 8, 808: 8, 814: 4, 829: 5, 833: 6, 862: 8, 884: 8, 891: 8, 927: 8, 929: 8, 985: 3, 1024: 4, 1040: 6, 1056: 8, 1302: 8, 1361: 5, 1365: 5, 1600: 5, 1601: 8, 1641: 8, 1872: 8 }], CAR.FIT: [{ 57: 3, 145: 8, 228: 5, 304: 8, 342: 6, 344: 8, 380: 8, 399: 7, 401: 8, 420: 8, 422: 8, 427: 3, 428: 8, 432: 7, 464: 8, 487: 4, 490: 8, 506: 8, 597: 8, 660: 8, 661: 4, 773: 7, 777: 8, 780: 8, 800: 8, 804: 8, 808: 8, 829: 5, 862: 8, 884: 7, 892: 8, 929: 8, 985: 3, 1024: 5, 1027: 5, 1029: 8, 1036: 8, 1039: 8, 1108: 8, 1322: 5, 1361: 5, 1365: 5, 1424: 5, 1600: 5, 1601: 8 @@ -103,6 +112,9 @@ class CAR: CAR.HRV: [{ 57: 3, 145: 8, 228: 5, 316: 8, 340: 8, 342: 6, 344: 8, 380: 8, 399: 7, 401: 8, 420: 8, 422: 8, 423: 2, 426: 8, 427: 3, 432: 7, 441: 5, 450: 8, 464: 8, 474: 8, 490: 8, 493: 3, 506: 8, 538: 5, 578: 2, 597: 8, 660: 8, 661: 4, 773: 7, 777: 8, 780: 8, 804: 8, 808: 8, 829: 5, 862: 8, 882: 2, 884: 7, 892: 8, 929: 8, 985: 3, 1030: 5, 1033: 5, 1108: 8, 1137: 8, 1348: 5, 1361: 5, 1365: 5, 1600: 5, 1601: 8, 1618: 5 }], + CAR.JADE: [{ + 57: 3, 145: 8, 228: 5, 304: 8, 342: 6, 344: 8, 380: 8, 398: 3, 399: 7, 401: 8, 420: 8, 422: 8, 428: 8, 432: 7, 464: 8, 487: 4, 490: 8, 506: 8, 507: 1, 597: 8, 660: 8, 661: 4, 773: 7, 777: 8, 780: 8, 804: 8, 808: 8, 829: 5, 862: 8, 884: 7, 892: 8, 923: 2, 929: 4, 1057: 5, 1365: 5, 1424: 5, 1600: 5, 1601: 8 + }], # 2018 Odyssey w/ Added Comma Pedal Support (512L & 513L) CAR.ODYSSEY: [{ 57: 3, 148: 8, 228: 5, 229: 4, 316: 8, 342: 6, 344: 8, 380: 8, 399: 7, 411: 5, 419: 8, 420: 8, 427: 3, 432: 7, 450: 8, 463: 8, 464: 8, 476: 4, 490: 8, 506: 8, 512: 6, 513: 6, 542: 7, 545: 6, 597: 8, 662: 4, 773: 7, 777: 8, 780: 8, 795: 8, 800: 8, 804: 8, 806: 8, 808: 8, 817: 4, 819: 7, 821: 5, 825: 4, 829: 5, 837: 5, 856: 7, 862: 8, 871: 8, 881: 8, 882: 4, 884: 8, 891: 8, 892: 8, 905: 8, 923: 2, 927: 8, 929: 8, 963: 8, 965: 8, 966: 8, 967: 8, 983: 8, 985: 3, 1029: 8, 1036: 8, 1052: 8, 1064: 7, 1088: 8, 1089: 8, 1092: 1, 1108: 8, 1110: 8, 1125: 8, 1296: 8, 1302: 8, 1600: 5, 1601: 8, 1612: 5, 1613: 5, 1614: 5, 1615: 8, 1616: 5, 1619: 5, 1623: 5, 1668: 5 @@ -113,6 +125,10 @@ class CAR: }], CAR.ODYSSEY_CHN: [{ 57: 3, 145: 8, 316: 8, 342: 6, 344: 8, 380: 8, 398: 3, 399: 7, 401: 8, 404: 4, 411: 5, 420: 8, 422: 8, 423: 2, 426: 8, 432: 7, 450: 8, 464: 8, 490: 8, 506: 8, 507: 1, 512: 6, 513: 6, 597: 8, 610: 8, 611: 8, 612: 8, 617: 8, 660: 8, 661: 4, 773: 7, 780: 8, 804: 8, 808: 8, 829: 5, 862: 8, 884: 7, 892: 8, 923: 2, 929: 8, 1030: 5, 1137: 8, 1302: 8, 1348: 5, 1361: 5, 1365: 5, 1600: 5, 1601: 8, 1639: 8 + }, + # Odyssey from Shell + { + 57: 3, 145: 8, 316: 8, 342: 6, 344: 8, 380: 8, 398: 3, 399: 7, 401: 8, 408: 6, 411: 5, 415: 6, 420: 8, 422: 8, 423: 2, 426: 8, 432: 7, 450: 8, 464: 8, 490: 8, 507: 1, 597: 8, 610: 8, 611: 8, 612: 8, 617: 8, 660: 8, 661: 4, 773: 7, 804: 8, 808: 8, 884: 7, 892: 8, 923: 2, 929: 8, 1030: 5, 1137: 8, 1302: 8, 1348: 5, 1361: 5, 1365: 5, 1639: 8 }], # 2017 Pilot Touring AND 2016 Pilot EX-L w/ Added Comma Pedal Support (512L & 513L) CAR.PILOT: [{ @@ -433,6 +449,7 @@ class CAR: b'37805-5AN-AJ30\x00\x00', b'37805-5AN-AK20\x00\x00', b'37805-5AN-AR20\x00\x00', + b'37805-5AN-E410\x00\x00', # AlexNoop's Manual CIVIC_BOSCH b'37805-5AN-L940\x00\x00', b'37805-5AN-LF20\x00\x00', b'37805-5AN-LH20\x00\x00', @@ -471,6 +488,7 @@ class CAR: b'57114-TGG-C320\x00\x00', b'57114-TGG-L320\x00\x00', b'57114-TGG-L330\x00\x00', + b'57114-TGL-G130\x00\x00', # AlexNoop's Manual CIVIC_BOSCH b'57114-TGL-G330\x00\x00', ], @@ -480,6 +498,7 @@ class CAR: b'39990-TEZ-T020\x00\x00', b'39990-TGG-A020\x00\x00', b'39990-TGG-A120\x00\x00', + b'39990-TGN-E120\x00\x00', # AlexNoop's Manual CIVIC_BOSCH b'39990-TGL-E130\x00\x00', ], (Ecu.srs, 0x18da53f1, None): [ @@ -488,6 +507,7 @@ class CAR: b'77959-TGG-A020\x00\x00', b'77959-TGG-A030\x00\x00', b'77959-TGG-G010\x00\x00', + b'77959-TGG-A020\x00\x00', ], (Ecu.combinationMeter, 0x18da60f1, None): [ b'78109-TBA-A110\x00\x00', @@ -505,10 +525,12 @@ class CAR: b'78109-TGG-A620\x00\x00', b'78109-TGG-A810\x00\x00', b'78109-TGG-A820\x00\x00', + b'78109-TGG-BA10\x00\x00', # AlexNoop's Manual CIVIC_BOSCH b'78109-TGL-G120\x00\x00', ], (Ecu.fwdRadar, 0x18dab0f1, None): [ b'36802-TBA-A150\x00\x00', + b'36802-TGG-G040\x00\x00', # AlexNoop's Manual CIVIC_BOSCH b'36802-TFJ-G060\x00\x00', b'36802-TGG-A050\x00\x00', b'36802-TGG-A060\x00\x00', @@ -523,6 +545,7 @@ class CAR: b'36161-TGG-A080\x00\x00', b'36161-TGG-A120\x00\x00', b'36161-TGL-G050\x00\x00', + b'36161-TGG-G070\x00\x00', # AlexNoop's Manual CIVIC_BOSCH ], (Ecu.gateway, 0x18daeff1, None): [ b'38897-TBA-A110\x00\x00', @@ -723,6 +746,7 @@ class CAR: (Ecu.gateway, 0x18daeff1, None): [ b'38897-THR-A010\x00\x00', b'38897-THR-A020\x00\x00', + b'38897-TKN-H030\x00\x00', ], (Ecu.programmedFuelInjection, 0x18da10f1, None): [ b'37805-5MR-A250\x00\x00', @@ -734,6 +758,7 @@ class CAR: (Ecu.eps, 0x18da30f1, None): [ b'39990-THR-A020\x00\x00', b'39990-THR-A030\x00\x00', + b'77959-T6A-H140\x00\x00', ], (Ecu.srs, 0x18da53f1, None): [ b'77959-THR-A010\x00\x00', @@ -780,6 +805,7 @@ class CAR: b'78109-THR-AN10\x00\x00', b'78109-THR-C330\x00\x00', b'78109-THR-CE20\x00\x00', + b'78109-TKN-H110\x00\x00' ], (Ecu.shiftByWire, 0x18da0bf1, None): [ b'54008-THR-A020\x00\x00', @@ -980,6 +1006,7 @@ class CAR: CAR.CRV_HYBRID: dbc_dict('honda_crv_hybrid_2019_can_generated', None), CAR.FIT: dbc_dict('honda_fit_ex_2018_can_generated', 'acura_ilx_2016_nidec'), CAR.HRV: dbc_dict('honda_hrv_touring_2019_can_generated', 'acura_ilx_2016_nidec'), + CAR.JADE: dbc_dict('honda_hrv_touring_2019_can_generated', 'acura_ilx_2016_nidec'), CAR.ODYSSEY: dbc_dict('honda_odyssey_exl_2018_generated', 'acura_ilx_2016_nidec'), CAR.ODYSSEY_CHN: dbc_dict('honda_odyssey_extreme_edition_2018_china_can_generated', 'acura_ilx_2016_nidec'), CAR.PILOT: dbc_dict('honda_pilot_touring_2017_can_generated', 'acura_ilx_2016_nidec'), @@ -1004,6 +1031,7 @@ class CAR: CAR.CRV_HYBRID: 1200, CAR.FIT: 1200, CAR.HRV: 1200, + CAR.JADE: 1200, CAR.ODYSSEY: 1200, CAR.ODYSSEY_CHN: 1200, CAR.PILOT: 1200, @@ -1028,6 +1056,7 @@ class CAR: CAR.CRV_HYBRID: 1.025, CAR.FIT: 1., CAR.HRV: 1.025, + CAR.JADE: 1.025, CAR.ODYSSEY: 1., CAR.ODYSSEY_CHN: 1., CAR.PILOT: 1., @@ -1036,4 +1065,10 @@ class CAR: CAR.INSIGHT: 1., } +# msgs sent for steering controller by camera module on can 0. +# those messages are mutually exclusive on CRV and non-CRV cars +ECU_FINGERPRINT = { + Ecu.fwdCamera: [0xE4, 0x194], # steer torque cmd +} + HONDA_BOSCH = set([CAR.ACCORD, CAR.ACCORD_15, CAR.ACCORDH, CAR.CIVIC_BOSCH, CAR.CIVIC_BOSCH_DIESEL, CAR.CRV_5G, CAR.CRV_HYBRID, CAR.INSIGHT, CAR.ACURA_RDX_3G]) diff --git a/selfdrive/car/hyundai/carcontroller.py b/selfdrive/car/hyundai/carcontroller.py index 4a296ab9cb942e..be1b897f16f35e 100644 --- a/selfdrive/car/hyundai/carcontroller.py +++ b/selfdrive/car/hyundai/carcontroller.py @@ -4,6 +4,8 @@ from selfdrive.car.hyundai.hyundaican import create_lkas11, create_clu11, create_lfa_mfa from selfdrive.car.hyundai.values import Buttons, SteerLimitParams, CAR from opendbc.can.packer import CANPacker +from common.dp_common import common_controller_ctrl +from common.params import Params VisualAlert = car.CarControl.HUDControl.VisualAlert @@ -42,8 +44,13 @@ def __init__(self, dbc_name, CP, VM): self.steer_rate_limited = False self.last_resume_frame = 0 + # dp + self.last_blinker_on = False + self.blinker_end_frame = 0. + self.dp_hkg_smart_mdps = Params().get('dp_hkg_smart_mdps') == b'1' + def update(self, enabled, CS, frame, actuators, pcm_cancel_cmd, visual_alert, - left_lane, right_lane, left_lane_depart, right_lane_depart): + left_lane, right_lane, left_lane_depart, right_lane_depart, dragonconf): # Steering Torque new_steer = actuators.steer * self.p.STEER_MAX apply_steer = apply_std_steer_torque_limits(new_steer, self.apply_steer_last, CS.out.steeringTorque, self.p) @@ -53,7 +60,7 @@ def update(self, enabled, CS, frame, actuators, pcm_cancel_cmd, visual_alert, lkas_active = enabled and abs(CS.out.steeringAngle) < 90. # fix for Genesis hard fault at low speed - if CS.out.vEgo < 16.7 and self.car_fingerprint == CAR.HYUNDAI_GENESIS: + if not self.dp_hkg_smart_mdps and CS.out.vEgo < 16.7 and self.car_fingerprint == CAR.HYUNDAI_GENESIS: lkas_active = False if not lkas_active: @@ -65,6 +72,18 @@ def update(self, enabled, CS, frame, actuators, pcm_cancel_cmd, visual_alert, process_hud_alert(enabled, self.car_fingerprint, visual_alert, left_lane, right_lane, left_lane_depart, right_lane_depart) + # dp + blinker_on = CS.out.leftBlinker or CS.out.rightBlinker + if not enabled: + self.blinker_end_frame = 0 + if self.last_blinker_on and not blinker_on: + self.blinker_end_frame = frame + dragonconf.dpSignalOffDelay + apply_steer = common_controller_ctrl(enabled, + dragonconf, + blinker_on or frame < self.blinker_end_frame, + apply_steer, CS.out.vEgo) + self.last_blinker_on = blinker_on + can_sends = [] can_sends.append(create_lkas11(self.packer, frame, self.car_fingerprint, apply_steer, lkas_active, CS.lkas11, sys_warning, sys_state, enabled, diff --git a/selfdrive/car/hyundai/carstate.py b/selfdrive/car/hyundai/carstate.py index b799a13fe309eb..0b8dbe72ea9a01 100644 --- a/selfdrive/car/hyundai/carstate.py +++ b/selfdrive/car/hyundai/carstate.py @@ -1,6 +1,6 @@ import copy from cereal import car -from selfdrive.car.hyundai.values import DBC, STEER_THRESHOLD, FEATURES, EV_HYBRID +from selfdrive.car.hyundai.values import CAR, DBC, STEER_THRESHOLD, FEATURES, EV_HYBRID from selfdrive.car.interfaces import CarStateBase from opendbc.can.parser import CANParser from selfdrive.config import Conversions as CV @@ -37,7 +37,7 @@ def update(self, cp, cp_cam): ret.steerWarning = cp.vl["MDPS12"]['CF_Mdps_ToiUnavail'] != 0 # cruise state - ret.cruiseState.available = True + ret.cruiseState.available = cp.vl["SCC11"]["MainMode_ACC"] != 0 if self.CP.carFingerprint in [CAR.HYUNDAI_GENESIS, CAR.GENESIS_G70, CAR.GENESIS_G80, CAR.GENESIS_G90, CAR.IONIQ] else True ret.cruiseState.enabled = cp.vl["SCC12"]['ACCMode'] != 0 ret.cruiseState.standstill = cp.vl["SCC11"]['SCCInfoDisplay'] == 4. diff --git a/selfdrive/car/hyundai/interface.py b/selfdrive/car/hyundai/interface.py index 4300e61d6701d4..b4142d109b095a 100644 --- a/selfdrive/car/hyundai/interface.py +++ b/selfdrive/car/hyundai/interface.py @@ -1,9 +1,11 @@ #!/usr/bin/env python3 from cereal import car from selfdrive.config import Conversions as CV -from selfdrive.car.hyundai.values import CAR -from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, gen_empty_fingerprint +from selfdrive.car.hyundai.values import Ecu, ECU_FINGERPRINT, CAR, FINGERPRINTS +from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, is_ecu_disconnected, gen_empty_fingerprint from selfdrive.car.interfaces import CarInterfaceBase +from common.dp_common import common_interface_atl, common_interface_get_params_lqr +from common.params import Params class CarInterface(CarInterfaceBase): @@ -12,12 +14,13 @@ def compute_gb(accel, speed): return float(accel) / 3.0 @staticmethod - def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # pylint: disable=dangerous-default-value - ret = CarInterfaceBase.get_std_params(candidate, fingerprint) + def get_params(candidate, fingerprint=gen_empty_fingerprint(), has_relay=False, car_fw=[]): # pylint: disable=dangerous-default-value + ret = CarInterfaceBase.get_std_params(candidate, fingerprint, has_relay) ret.carName = "hyundai" ret.safetyModel = car.CarParams.SafetyModel.hyundai ret.radarOffCan = True + ret.lateralTuning.init('pid') # Most Hyundai car ports are community features for now ret.communityFeature = candidate not in [CAR.SONATA, CAR.PALISADE] @@ -68,16 +71,17 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.25], [0.05]] ret.minSteerSpeed = 32 * CV.MPH_TO_MS elif candidate == CAR.HYUNDAI_GENESIS: - ret.lateralTuning.pid.kf = 0.00005 ret.mass = 2060. + STD_CARGO_KG ret.wheelbase = 3.01 - ret.steerRatio = 16.5 + ret.steerRatio = 15 + # dp - indi value from donfyffe ret.lateralTuning.init('indi') - ret.lateralTuning.indi.innerLoopGain = 3.5 - ret.lateralTuning.indi.outerLoopGain = 2.0 + ret.lateralTuning.indi.innerLoopGain = 3.1 + ret.lateralTuning.indi.outerLoopGain = 2.1 ret.lateralTuning.indi.timeConstant = 1.4 - ret.lateralTuning.indi.actuatorEffectiveness = 2.3 - ret.minSteerSpeed = 60 * CV.KPH_TO_MS + ret.lateralTuning.indi.actuatorEffectiveness = 1.4 + ret.minSteerSpeed = 32 * CV.MPH_TO_MS + ret.minEnableSpeed = 10 * CV.MPH_TO_MS elif candidate == CAR.KONA: ret.lateralTuning.pid.kf = 0.00005 ret.mass = 1275. + STD_CARGO_KG @@ -155,22 +159,29 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py # Genesis elif candidate == CAR.GENESIS_G70: - ret.lateralTuning.init('indi') - ret.lateralTuning.indi.innerLoopGain = 2.5 - ret.lateralTuning.indi.outerLoopGain = 3.5 - ret.lateralTuning.indi.timeConstant = 1.4 - ret.lateralTuning.indi.actuatorEffectiveness = 1.8 - ret.steerActuatorDelay = 0.1 - ret.mass = 1640.0 + STD_CARGO_KG - ret.wheelbase = 2.84 - ret.steerRatio = 13.56 + ret.lateralTuning.init('indi') # TODO: BPs for city speeds - this tuning is great on the highway but a bit lazy in town + ret.lateralTuning.indi.innerLoopGain = 2.4 # higher values steer more + ret.lateralTuning.indi.outerLoopGain = 3.0 # higher values steer more + ret.lateralTuning.indi.timeConstant = 1.0 # lower values steer more + ret.lateralTuning.indi.actuatorEffectiveness = 2.0 # lower values steer more + ret.steerActuatorDelay = 0.4 # 0.08 stock + ret.steerLimitTimer = 0.4 # down from 0.4 + tire_stiffness_factor = 1.0 + ret.steerRateCost = 1.0 + ret.mass = 1825. + STD_CARGO_KG + ret.wheelbase = 2.906 + ret.steerRatio = 14.4 elif candidate == CAR.GENESIS_G80: ret.lateralTuning.pid.kf = 0.00005 ret.mass = 2060. + STD_CARGO_KG ret.wheelbase = 3.01 ret.steerRatio = 16.5 - ret.lateralTuning.pid.kiBP, ret.lateralTuning.pid.kpBP = [[0.], [0.]] - ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.16], [0.01]] + ret.lateralTuning.init('indi') + ret.lateralTuning.indi.innerLoopGain = 3.5 + ret.lateralTuning.indi.outerLoopGain = 2.0 + ret.lateralTuning.indi.timeConstant = 1.4 + ret.lateralTuning.indi.actuatorEffectiveness = 2.3 + ret.minSteerSpeed = 60 * CV.KPH_TO_MS elif candidate == CAR.GENESIS_G90: ret.mass = 2200 ret.wheelbase = 3.15 @@ -178,7 +189,6 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py ret.lateralTuning.pid.kiBP, ret.lateralTuning.pid.kpBP = [[0.], [0.]] ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.16], [0.01]] - # these cars require a special panda safety mode due to missing counters and checksums in the messages if candidate in [CAR.HYUNDAI_GENESIS, CAR.IONIQ_EV_LTD, CAR.IONIQ, CAR.KONA_EV, CAR.KIA_SORENTO, CAR.SONATA_2019, CAR.KIA_NIRO_EV, CAR.KIA_OPTIMA, CAR.VELOSTER, CAR.KIA_STINGER, CAR.GENESIS_G70, CAR.GENESIS_G80]: @@ -186,6 +196,11 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py ret.centerToFront = ret.wheelbase * 0.4 + # dp + if Params().get('dp_hkg_smart_mdps') == b'1': + ret.minSteerSpeed = 0. + ret = common_interface_get_params_lqr(ret) + # TODO: get actual value, for now starting with reasonable value for # civic and scaling by mass and wheelbase ret.rotationalInertia = scale_rot_inertia(ret.mass, ret.wheelbase) @@ -195,27 +210,35 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py ret.tireStiffnessFront, ret.tireStiffnessRear = scale_tire_stiffness(ret.mass, ret.wheelbase, ret.centerToFront, tire_stiffness_factor=tire_stiffness_factor) - ret.enableCamera = True + ret.enableCamera = is_ecu_disconnected(fingerprint[0], FINGERPRINTS, ECU_FINGERPRINT, candidate, Ecu.fwdCamera) or has_relay return ret - def update(self, c, can_strings): + def update(self, c, can_strings, dragonconf): self.cp.update_strings(can_strings) self.cp_cam.update_strings(can_strings) ret = self.CS.update(self.cp, self.cp_cam) + # dp + self.dragonconf = dragonconf + if ret.vEgo >= self.CP.minSteerSpeed: + ret.cruiseState.enabled = common_interface_atl(ret, dragonconf.dpAtl) ret.canValid = self.cp.can_valid and self.cp_cam.can_valid events = self.create_common_events(ret) #TODO: addd abs(self.CS.angle_steers) > 90 to 'steerTempUnavailable' event - # low speed steer alert hysteresis logic (only for cars with steer cut off above 10 m/s) - if ret.vEgo < (self.CP.minSteerSpeed + 2.) and self.CP.minSteerSpeed > 10.: - self.low_speed_alert = True - if ret.vEgo > (self.CP.minSteerSpeed + 4.): - self.low_speed_alert = False - if self.low_speed_alert: - events.add(car.CarEvent.EventName.belowSteerSpeed) + if dragonconf.dpAtl: + if ret.vEgo < self.CP.minSteerSpeed: + events.add(car.CarEvent.EventName.belowSteerSpeed) + else: + # low speed steer alert hysteresis logic (only for cars with steer cut off above 10 m/s) + if ret.vEgo < (self.CP.minSteerSpeed + 2.) and self.CP.minSteerSpeed > 10.: + self.low_speed_alert = True + if ret.vEgo > (self.CP.minSteerSpeed + 4.): + self.low_speed_alert = False + if self.low_speed_alert: + events.add(car.CarEvent.EventName.belowSteerSpeed) ret.events = events.to_msg() @@ -225,6 +248,6 @@ def update(self, c, can_strings): def apply(self, c): can_sends = self.CC.update(c.enabled, self.CS, self.frame, c.actuators, c.cruiseControl.cancel, c.hudControl.visualAlert, c.hudControl.leftLaneVisible, - c.hudControl.rightLaneVisible, c.hudControl.leftLaneDepart, c.hudControl.rightLaneDepart) + c.hudControl.rightLaneVisible, c.hudControl.leftLaneDepart, c.hudControl.rightLaneDepart, self.dragonconf) self.frame += 1 return can_sends diff --git a/selfdrive/car/hyundai/values.py b/selfdrive/car/hyundai/values.py index 8f1512c28b69b2..bb6716626a08b4 100644 --- a/selfdrive/car/hyundai/values.py +++ b/selfdrive/car/hyundai/values.py @@ -3,11 +3,12 @@ from cereal import car from selfdrive.car import dbc_dict Ecu = car.CarParams.Ecu +from common.params import Params # Steer torque limits class SteerLimitParams: def __init__(self, CP): - if CP.carFingerprint in [CAR.SONATA, CAR.PALISADE, CAR.SANTA_FE, CAR.VELOSTER, CAR.GENESIS_G70]: + if Params().get('dp_hkg_smart_mdps') == b'1' or CP.carFingerprint in [CAR.SONATA, CAR.PALISADE, CAR.SANTA_FE, CAR.VELOSTER, CAR.HYUNDAI_GENESIS, CAR.GENESIS_G70]: self.STEER_MAX = 384 else: self.STEER_MAX = 255 @@ -106,7 +107,7 @@ class Buttons: 67: 8, 127: 8, 304: 8, 320: 8, 339: 8, 356: 4, 358: 6, 359: 8, 544: 8, 576: 8, 593: 8, 608: 8, 688: 5, 809: 8, 832: 8, 854: 7, 870: 7, 871: 8, 872: 8, 897: 8, 902: 8, 909: 8, 916: 8, 1040: 8, 1042: 8, 1056: 8, 1057: 8, 1064: 8, 1078: 4, 1107: 5, 1136: 8, 1151: 6, 1168: 7, 1170: 8, 1173: 8, 1184: 8, 1265: 4, 1280: 1, 1281: 4, 1287: 4, 1290: 8, 1292: 8, 1294: 8, 1312: 8, 1322: 8, 1342: 6, 1345: 8, 1348: 8, 1363: 8, 1369: 8, 1371: 8, 1378: 4, 1379: 8, 1384: 8, 1407: 8, 1419: 8, 1425: 2, 1427: 6, 1456: 4, 1470: 8 }], CAR.GENESIS_G70: [{ - 67: 8, 127: 8, 304: 8, 320: 8, 339: 8, 356: 4, 358: 6, 544: 8, 576: 8, 593: 8, 608: 8, 688: 5, 809: 8, 832:8, 854: 7, 870: 7, 871: 8, 872: 8, 897: 8, 902: 8, 909: 8, 916: 8, 1040: 8, 1042: 8, 1056: 8, 1057: 8, 1064: 8, 1078: 4, 1107: 5, 1136: 8, 1151: 6, 1156: 8, 1168: 7, 1170: 8, 1173:8, 1184: 8, 1186: 2, 1191: 2, 1265: 4, 1280: 1, 1287: 4, 1290: 8, 1292: 8, 1294: 8, 1312: 8, 1322: 8, 1342: 6, 1345: 8, 1348: 8, 1363: 8, 1369: 8, 1379: 8, 1384: 8, 1407: 8, 1419:8, 1427: 6, 1456: 4, 1470: 8, 1988: 8, 1996: 8, 2000: 8, 2004: 8, 2008: 8, 2012: 8, 2015: 8 + 67: 8, 127: 8, 304: 8, 320: 8, 339: 8, 356: 4, 358: 6, 544: 8, 576: 8, 593: 8, 608: 8, 688: 5, 809: 8, 832:8, 854: 7, 870: 7, 871: 8, 872: 8, 897: 8, 902: 8, 909: 8, 916: 8, 1040: 8, 1042: 8, 1056: 8, 1057: 8, 1064: 8, 1078: 4, 1107: 5, 1136: 8, 1151: 6, 1156: 8, 1168: 7, 1170: 8, 1173:8, 1184: 8, 1186: 2, 1191: 2, 1265: 4, 1280: 1, 1287: 4, 1290: 8, 1292: 8, 1294: 8, 1312: 8, 1322: 8, 1342: 6, 1345: 8, 1348: 8, 1363: 8, 1369: 8, 1379: 8, 1384: 8, 1407: 8, 1419:8, 1425:2, 1427: 6, 1456: 4, 1470: 8, 1988: 8, 1996: 8, 2000: 8, 2004: 8, 2008: 8, 2012: 8, 2015: 8 }], CAR.GENESIS_G80: [{ 67: 8, 68: 8, 127: 8, 304: 8, 320: 8, 339: 8, 356: 4, 358: 6, 544: 8, 593: 8, 608: 8, 688: 5, 809: 8, 832: 8, 854: 7, 870: 7, 871: 8, 872: 8, 897: 8, 902: 8, 903: 8, 916: 8, 1024: 2, 1040: 8, 1042: 8, 1056: 8, 1057: 8, 1078: 4, 1107: 5, 1136: 8, 1151: 6, 1156: 8, 1168: 7, 1170: 8, 1173: 8, 1184: 8, 1191: 2, 1265: 4, 1280: 1, 1287: 4, 1290: 8, 1292: 8, 1294: 8, 1312: 8, 1322: 8, 1342: 6, 1345: 8, 1348: 8, 1363: 8, 1369: 8, 1370: 8, 1371: 8, 1378: 4, 1384: 8, 1407: 8, 1419: 8, 1425: 2, 1427: 6, 1434: 2, 1456: 4, 1470: 8 @@ -155,8 +156,12 @@ class Buttons: }] } +ECU_FINGERPRINT = { + Ecu.fwdCamera: [832, 1156, 1191, 1342] +} + # Don't use these fingerprints for fingerprinting, they are still used for ECU detection -IGNORED_FINGERPRINTS = [CAR.VELOSTER, CAR.GENESIS_G70, CAR.KONA] +IGNORED_FINGERPRINTS = [CAR.VELOSTER, CAR.KONA] FW_VERSIONS = { CAR.SONATA: { @@ -313,7 +318,7 @@ class Buttons: "use_elect_gears": set([CAR.KIA_NIRO_EV, CAR.KIA_OPTIMA_H, CAR.IONIQ_EV_LTD, CAR.KONA_EV, CAR.IONIQ]), # these cars use the FCA11 message for the AEB and FCW signals, all others use SCC12 - "use_fca": set([CAR.SONATA, CAR.ELANTRA, CAR.ELANTRA_GT_I30, CAR.KIA_STINGER, CAR.IONIQ, CAR.KONA_EV, CAR.KIA_FORTE, CAR.KIA_NIRO_EV, CAR.PALISADE, CAR.GENESIS_G70, CAR.KONA]), + "use_fca": set([CAR.SONATA, CAR.ELANTRA, CAR.ELANTRA_GT_I30, CAR.KIA_STINGER, CAR.KONA_EV, CAR.KIA_FORTE, CAR.KIA_NIRO_EV, CAR.PALISADE, CAR.GENESIS_G70, CAR.KONA]), "use_bsm": set([CAR.SONATA, CAR.PALISADE, CAR.HYUNDAI_GENESIS, CAR.GENESIS_G70, CAR.GENESIS_G80, CAR.GENESIS_G90, CAR.KONA]), } diff --git a/selfdrive/car/interfaces.py b/selfdrive/car/interfaces.py index f7078ed238233e..1e4bf8a2a493c2 100644 --- a/selfdrive/car/interfaces.py +++ b/selfdrive/car/interfaces.py @@ -33,6 +33,8 @@ def __init__(self, CP, CarController, CarState): if CarController is not None: self.CC = CarController(self.cp.dbc_name, CP, self.VM) + self.dragonconf = None + @staticmethod def calc_accel_override(a_ego, a_target, v_ego, v_target): return 1. @@ -42,15 +44,15 @@ def compute_gb(accel, speed): raise NotImplementedError @staticmethod - def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): + def get_params(candidate, fingerprint=gen_empty_fingerprint(), has_relay=False, car_fw=None): raise NotImplementedError # returns a set of default params to avoid repetition in car specific params @staticmethod - def get_std_params(candidate, fingerprint): + def get_std_params(candidate, fingerprint, has_relay): ret = car.CarParams.new_message() ret.carFingerprint = candidate - ret.isPandaBlack = True # TODO: deprecate this field + ret.isPandaBlack = has_relay # standard ALC params ret.steerControlType = car.CarParams.SteerControlType.torque @@ -78,7 +80,7 @@ def get_std_params(candidate, fingerprint): return ret # returns a car.CarState, pass in car.CarControl - def update(self, c, can_strings): + def update(self, c, can_strings, dragonconf): raise NotImplementedError # return sendcan, pass in a car.CarControl @@ -92,26 +94,30 @@ def create_common_events(self, cs_out, extra_gears=[], gas_resume_speed=-1, pcm_ events.add(EventName.doorOpen) if cs_out.seatbeltUnlatched: events.add(EventName.seatbeltNotLatched) - if cs_out.gearShifter != GearShifter.drive and cs_out.gearShifter not in extra_gears: + if self.dragonconf.dpGearCheck and cs_out.gearShifter != GearShifter.drive and cs_out.gearShifter not in extra_gears: events.add(EventName.wrongGear) if cs_out.gearShifter == GearShifter.reverse: events.add(EventName.reverseGear) - if not cs_out.cruiseState.available: + if not self.dragonconf.dpAtl and not cs_out.cruiseState.available: events.add(EventName.wrongCarMode) if cs_out.espDisabled: events.add(EventName.espDisabled) - if cs_out.gasPressed: + if cs_out.gasPressed and not self.dragonconf.dpAllowGas and not self.dragonconf.dpAtl: events.add(EventName.gasPressed) if cs_out.stockFcw: events.add(EventName.stockFcw) if cs_out.stockAeb: events.add(EventName.stockAeb) - if cs_out.vEgo > MAX_CTRL_SPEED: + if cs_out.vEgo > self.dragonconf.dpMaxCtrlSpeed: events.add(EventName.speedTooHigh) if cs_out.cruiseState.nonAdaptive: events.add(EventName.wrongCruiseMode) - if cs_out.steerError: + if not self.dragonconf.dpLatCtrl: + events.add(EventName.manualSteeringRequired) + elif self.dragonconf.dpSteeringOnSignal and (cs_out.leftBlinker or cs_out.rightBlinker): + events.add(EventName.manualSteeringRequiredBlinkersOn) + elif cs_out.steerError: events.add(EventName.steerUnavailable) elif cs_out.steerWarning: events.add(EventName.steerTempUnavailable) @@ -119,9 +125,15 @@ def create_common_events(self, cs_out, extra_gears=[], gas_resume_speed=-1, pcm_ # Disable on rising edge of gas or brake. Also disable on brake when speed > 0. # Optionally allow to press gas at zero speed to resume. # e.g. Chrysler does not spam the resume button yet, so resuming with gas is handy. FIXME! - if (cs_out.gasPressed and (not self.CS.out.gasPressed) and cs_out.vEgo > gas_resume_speed) or \ - (cs_out.brakePressed and (not self.CS.out.brakePressed or not cs_out.standstill)): - events.add(EventName.pedalPressed) + if self.dragonconf.dpAtl: + pass + elif self.dragonconf.dpAllowGas: + if cs_out.brakePressed and (not self.CS.out.brakePressed or not cs_out.standstill): + events.add(EventName.pedalPressed) + else: + if (cs_out.gasPressed and (not self.CS.out.gasPressed) and cs_out.vEgo > gas_resume_speed) or \ + (cs_out.brakePressed and (not self.CS.out.brakePressed or not cs_out.standstill)): + events.add(EventName.pedalPressed) # we engage when pcm is active (rising edge) if pcm_enable: diff --git a/selfdrive/car/mazda/carcontroller.py b/selfdrive/car/mazda/carcontroller.py index 20d80e519adf5c..0ccc75af80cc50 100644 --- a/selfdrive/car/mazda/carcontroller.py +++ b/selfdrive/car/mazda/carcontroller.py @@ -2,6 +2,7 @@ from selfdrive.car.mazda.values import SteerLimitParams, Buttons from opendbc.can.packer import CANPacker from selfdrive.car import apply_std_steer_torque_limits +from common.dp_common import common_controller_ctrl class CarController(): def __init__(self, dbc_name, CP, VM): @@ -9,7 +10,11 @@ def __init__(self, dbc_name, CP, VM): self.packer = CANPacker(dbc_name) self.steer_rate_limited = False - def update(self, enabled, CS, frame, actuators): + # dp + self.last_blinker_on = False + self.blinker_end_frame = 0. + + def update(self, enabled, CS, frame, actuators, dragonconf): """ Controls thread """ can_sends = [] @@ -36,6 +41,18 @@ def update(self, enabled, CS, frame, actuators): # Send at a rate of 5hz until we sync with stock ACC state can_sends.append(mazdacan.create_button_cmd(self.packer, CS.CP.carFingerprint, Buttons.CANCEL)) + # dp + blinker_on = CS.out.leftBlinker or CS.out.rightBlinker + if not enabled: + self.blinker_end_frame = 0 + if self.last_blinker_on and not blinker_on: + self.blinker_end_frame = frame + dragonconf.dpSignalOffDelay + apply_steer = common_controller_ctrl(enabled, + dragonconf, + blinker_on or frame < self.blinker_end_frame, + apply_steer, CS.out.vEgo) + self.last_blinker_on = blinker_on + self.apply_steer_last = apply_steer can_sends.append(mazdacan.create_steering_control(self.packer, CS.CP.carFingerprint, diff --git a/selfdrive/car/mazda/interface.py b/selfdrive/car/mazda/interface.py index fc1219453b5fd4..0a3a075399d2a1 100755 --- a/selfdrive/car/mazda/interface.py +++ b/selfdrive/car/mazda/interface.py @@ -1,9 +1,10 @@ #!/usr/bin/env python3 from cereal import car from selfdrive.config import Conversions as CV -from selfdrive.car.mazda.values import CAR, LKAS_LIMITS -from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, gen_empty_fingerprint +from selfdrive.car.mazda.values import CAR, LKAS_LIMITS, FINGERPRINTS, ECU_FINGERPRINT, Ecu +from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, gen_empty_fingerprint, is_ecu_disconnected from selfdrive.car.interfaces import CarInterfaceBase +from common.dp_common import common_interface_atl, common_interface_get_params_lqr ButtonType = car.CarState.ButtonEvent.Type EventName = car.CarEvent.EventName @@ -15,11 +16,12 @@ def compute_gb(accel, speed): return float(accel) / 4.0 @staticmethod - def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): - ret = CarInterfaceBase.get_std_params(candidate, fingerprint) + def get_params(candidate, fingerprint=gen_empty_fingerprint(), has_relay=False, car_fw=None): + ret = CarInterfaceBase.get_std_params(candidate, fingerprint, has_relay) ret.carName = "mazda" ret.safetyModel = car.CarParams.SafetyModel.mazda + ret.lateralTuning.init('pid') ret.dashcamOnly = True @@ -56,6 +58,9 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): # No steer below disable speed ret.minSteerSpeed = LKAS_LIMITS.DISABLE_SPEED * CV.KPH_TO_MS + # dp + ret = common_interface_get_params_lqr(ret) + ret.centerToFront = ret.wheelbase * 0.41 # TODO: get actual value, for now starting with reasonable value for @@ -67,17 +72,20 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): ret.tireStiffnessFront, ret.tireStiffnessRear = scale_tire_stiffness(ret.mass, ret.wheelbase, ret.centerToFront, tire_stiffness_factor=tire_stiffness_factor) - ret.enableCamera = True + ret.enableCamera = is_ecu_disconnected(fingerprint[0], FINGERPRINTS, ECU_FINGERPRINT, candidate, Ecu.fwdCamera) or has_relay return ret # returns a car.CarState - def update(self, c, can_strings): + def update(self, c, can_strings, dragonconf): self.cp.update_strings(can_strings) self.cp_cam.update_strings(can_strings) ret = self.CS.update(self.cp, self.cp_cam) + # dp + self.dragonconf = dragonconf + ret.cruiseState.enabled = common_interface_atl(ret, dragonconf.dpAtl) ret.canValid = self.cp.can_valid and self.cp_cam.can_valid # events @@ -95,6 +103,6 @@ def update(self, c, can_strings): return self.CS.out def apply(self, c): - can_sends = self.CC.update(c.enabled, self.CS, self.frame, c.actuators) + can_sends = self.CC.update(c.enabled, self.CS, self.frame, c.actuators, self.dragonconf) self.frame += 1 return can_sends diff --git a/selfdrive/car/mazda/values.py b/selfdrive/car/mazda/values.py index 81c2b2b4a43fdb..b958664cb86d69 100644 --- a/selfdrive/car/mazda/values.py +++ b/selfdrive/car/mazda/values.py @@ -71,6 +71,9 @@ class Buttons: ], } +ECU_FINGERPRINT = { + Ecu.fwdCamera: [579], # steer torque cmd +} DBC = { CAR.CX5: dbc_dict('mazda_2017', None), diff --git a/selfdrive/car/mock/interface.py b/selfdrive/car/mock/interface.py index f75d1c58ffcd26..db665874be572f 100755 --- a/selfdrive/car/mock/interface.py +++ b/selfdrive/car/mock/interface.py @@ -33,8 +33,8 @@ def compute_gb(accel, speed): return accel @staticmethod - def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): - ret = CarInterfaceBase.get_std_params(candidate, fingerprint) + def get_params(candidate, fingerprint=gen_empty_fingerprint(), has_relay=False, car_fw=None): + ret = CarInterfaceBase.get_std_params(candidate, fingerprint, has_relay) ret.carName = "mock" ret.safetyModel = car.CarParams.SafetyModel.noOutput ret.mass = 1700. @@ -48,7 +48,7 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): return ret # returns a car.CarState - def update(self, c, can_strings): + def update(self, c, can_strings, dragonconf): # get basic data from phone and gps since CAN isn't connected sensors = messaging.recv_sock(self.sensor) if sensors is not None: diff --git a/selfdrive/car/nissan/carcontroller.py b/selfdrive/car/nissan/carcontroller.py index 5838d67ae3241f..b67a5749987c27 100644 --- a/selfdrive/car/nissan/carcontroller.py +++ b/selfdrive/car/nissan/carcontroller.py @@ -3,6 +3,7 @@ from selfdrive.car.nissan import nissancan from opendbc.can.packer import CANPacker from selfdrive.car.nissan.values import CAR, STEER_THRESHOLD +from common.dp_common import common_controller_ctrl # Steer angle limits ANGLE_DELTA_BP = [0., 5., 15.] @@ -23,8 +24,12 @@ def __init__(self, dbc_name, CP, VM): self.packer = CANPacker(dbc_name) + # dp + self.last_blinker_on = False + self.blinker_end_frame = 0. + def update(self, enabled, CS, frame, actuators, cruise_cancel, hud_alert, - left_line, right_line, left_lane_depart, right_lane_depart): + left_line, right_line, left_lane_depart, right_lane_depart, dragonconf): """ Controls thread """ # Send CAN commands. @@ -63,6 +68,18 @@ def update(self, enabled, CS, frame, actuators, cruise_cancel, hud_alert, apply_angle = CS.out.steeringAngle self.lkas_max_torque = 0 + # dp + blinker_on = CS.out.leftBlinker or CS.out.rightBlinker + if not enabled: + self.blinker_end_frame = 0 + if self.last_blinker_on and not blinker_on: + self.blinker_end_frame = frame + dragonconf.dpSignalOffDelay + apply_angle = common_controller_ctrl(enabled, + dragonconf, + blinker_on or frame < self.blinker_end_frame, + apply_angle, CS.out.vEgo) + self.last_blinker_on = blinker_on + self.last_angle = apply_angle if not enabled and acc_active: diff --git a/selfdrive/car/nissan/interface.py b/selfdrive/car/nissan/interface.py index 9f2ac20e0a5844..d63dded10b693a 100644 --- a/selfdrive/car/nissan/interface.py +++ b/selfdrive/car/nissan/interface.py @@ -3,6 +3,7 @@ from selfdrive.car.nissan.values import CAR from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, gen_empty_fingerprint from selfdrive.car.interfaces import CarInterfaceBase +from common.dp_common import common_interface_atl, common_interface_get_params_lqr class CarInterface(CarInterfaceBase): def __init__(self, CP, CarController, CarState): @@ -14,11 +15,12 @@ def compute_gb(accel, speed): return float(accel) / 4.0 @staticmethod - def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): + def get_params(candidate, fingerprint=gen_empty_fingerprint(), has_relay=False, car_fw=None): - ret = CarInterfaceBase.get_std_params(candidate, fingerprint) + ret = CarInterfaceBase.get_std_params(candidate, fingerprint, has_relay) ret.carName = "nissan" ret.safetyModel = car.CarParams.SafetyModel.nissan + ret.lateralTuning.init('pid') # Nissan port is a community feature, since we don't own one to test ret.communityFeature = True @@ -45,6 +47,9 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): ret.centerToFront = ret.wheelbase * 0.44 ret.steerRatio = 17 + # dp + ret = common_interface_get_params_lqr(ret) + ret.steerControlType = car.CarParams.SteerControlType.angle ret.radarOffCan = True @@ -59,13 +64,15 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): return ret # returns a car.CarState - def update(self, c, can_strings): + def update(self, c, can_strings, dragonconf): self.cp.update_strings(can_strings) self.cp_cam.update_strings(can_strings) self.cp_adas.update_strings(can_strings) ret = self.CS.update(self.cp, self.cp_adas, self.cp_cam) - + # dp + self.dragonconf = dragonconf + ret.cruiseState.enabled = common_interface_atl(ret, dragonconf.dpAtl) ret.canValid = self.cp.can_valid and self.cp_adas.can_valid and self.cp_cam.can_valid buttonEvents = [] @@ -87,6 +94,6 @@ def apply(self, c): can_sends = self.CC.update(c.enabled, self.CS, self.frame, c.actuators, c.cruiseControl.cancel, c.hudControl.visualAlert, c.hudControl.leftLaneVisible, c.hudControl.rightLaneVisible, - c.hudControl.leftLaneDepart, c.hudControl.rightLaneDepart) + c.hudControl.leftLaneDepart, c.hudControl.rightLaneDepart, self.dragonconf) self.frame += 1 return can_sends diff --git a/selfdrive/car/subaru/carcontroller.py b/selfdrive/car/subaru/carcontroller.py index 744fd0bcc9ddbb..cad02e8654f23b 100644 --- a/selfdrive/car/subaru/carcontroller.py +++ b/selfdrive/car/subaru/carcontroller.py @@ -2,6 +2,7 @@ from selfdrive.car.subaru import subarucan from selfdrive.car.subaru.values import DBC, PREGLOBAL_CARS from opendbc.can.packer import CANPacker +from common.dp_common import common_controller_ctrl class CarControllerParams(): @@ -27,7 +28,11 @@ def __init__(self, dbc_name, CP, VM): self.params = CarControllerParams() self.packer = CANPacker(DBC[CP.carFingerprint]['pt']) - def update(self, enabled, CS, frame, actuators, pcm_cancel_cmd, visual_alert, left_line, right_line): + # dp + self.last_blinker_on = False + self.blinker_end_frame = 0. + + def update(self, enabled, CS, frame, actuators, pcm_cancel_cmd, visual_alert, left_line, right_line, dragonconf): can_sends = [] @@ -45,6 +50,18 @@ def update(self, enabled, CS, frame, actuators, pcm_cancel_cmd, visual_alert, le if not enabled: apply_steer = 0 + # dp + blinker_on = CS.out.leftBlinker or CS.out.rightBlinker + if not enabled: + self.blinker_end_frame = 0 + if self.last_blinker_on and not blinker_on: + self.blinker_end_frame = frame + dragonconf.dpSignalOffDelay + apply_steer = common_controller_ctrl(enabled, + dragonconf, + blinker_on or frame < self.blinker_end_frame, + apply_steer, CS.out.vEgo) + self.last_blinker_on = blinker_on + if CS.CP.carFingerprint in PREGLOBAL_CARS: can_sends.append(subarucan.create_preglobal_steering_control(self.packer, apply_steer, frame, self.params.STEER_STEP)) else: diff --git a/selfdrive/car/subaru/carstate.py b/selfdrive/car/subaru/carstate.py index 3be516ed3395ce..a240610fa6218a 100644 --- a/selfdrive/car/subaru/carstate.py +++ b/selfdrive/car/subaru/carstate.py @@ -146,7 +146,7 @@ def get_can_parser(CP): ("Dashlights", 10), ("CruiseControl", 50), ] - + checks = [] return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, 0) @staticmethod @@ -226,5 +226,5 @@ def get_cam_can_parser(CP): ("ES_Distance", 20), ("ES_LKAS_State", 10), ] - + checks = [] return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, 2) diff --git a/selfdrive/car/subaru/interface.py b/selfdrive/car/subaru/interface.py index 8012624a3c914b..d6cefd6a0c43ac 100644 --- a/selfdrive/car/subaru/interface.py +++ b/selfdrive/car/subaru/interface.py @@ -3,6 +3,7 @@ from selfdrive.car.subaru.values import CAR, PREGLOBAL_CARS from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, gen_empty_fingerprint from selfdrive.car.interfaces import CarInterfaceBase +from common.dp_common import common_interface_atl, common_interface_get_params_lqr class CarInterface(CarInterfaceBase): @@ -11,11 +12,12 @@ def compute_gb(accel, speed): return float(accel) / 4.0 @staticmethod - def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): - ret = CarInterfaceBase.get_std_params(candidate, fingerprint) + def get_params(candidate, fingerprint=gen_empty_fingerprint(), has_relay=False, car_fw=None): + ret = CarInterfaceBase.get_std_params(candidate, fingerprint, has_relay) ret.carName = "subaru" ret.radarOffCan = True + ret.lateralTuning.init('pid') if candidate in PREGLOBAL_CARS: ret.safetyModel = car.CarParams.SafetyModel.subaruLegacy @@ -26,6 +28,8 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): ret.communityFeature = True ret.dashcamOnly = candidate in PREGLOBAL_CARS + # force openpilot to fake the stock camera, since car harness is not supported yet and old style giraffe (with switches) + # was never released ret.enableCamera = True ret.steerRateCost = 0.7 @@ -92,6 +96,9 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): ret.lateralTuning.pid.kiBP, ret.lateralTuning.pid.kpBP = [[0., 10., 20.], [0., 10., 20.]] ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.01, 0.05, 0.2], [0.003, 0.018, 0.025]] + # dp + ret = common_interface_get_params_lqr(ret) + # TODO: get actual value, for now starting with reasonable value for # civic and scaling by mass and wheelbase ret.rotationalInertia = scale_rot_inertia(ret.mass, ret.wheelbase) @@ -103,12 +110,14 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): return ret # returns a car.CarState - def update(self, c, can_strings): + def update(self, c, can_strings, dragonconf): self.cp.update_strings(can_strings) self.cp_cam.update_strings(can_strings) ret = self.CS.update(self.cp, self.cp_cam) - + # dp + self.dragonconf = dragonconf + ret.cruiseState.enabled = common_interface_atl(ret, dragonconf.dpAtl) ret.canValid = self.cp.can_valid and self.cp_cam.can_valid ret.steeringRateLimited = self.CC.steer_rate_limited if self.CC is not None else False @@ -120,6 +129,6 @@ def update(self, c, can_strings): def apply(self, c): can_sends = self.CC.update(c.enabled, self.CS, self.frame, c.actuators, c.cruiseControl.cancel, c.hudControl.visualAlert, - c.hudControl.leftLaneVisible, c.hudControl.rightLaneVisible) + c.hudControl.leftLaneVisible, c.hudControl.rightLaneVisible, self.dragonconf) self.frame += 1 return can_sends diff --git a/selfdrive/car/subaru/values.py b/selfdrive/car/subaru/values.py index 937728d88588f1..8cbb6fe72dacb1 100644 --- a/selfdrive/car/subaru/values.py +++ b/selfdrive/car/subaru/values.py @@ -78,6 +78,10 @@ class CAR: CAR.OUTBACK_PREGLOBAL_2018: 75, } +ECU_FINGERPRINT = { + Ecu.fwdCamera: [290, 356], # steer torque cmd +} + DBC = { CAR.ASCENT: dbc_dict('subaru_global_2017_generated', None), CAR.IMPREZA: dbc_dict('subaru_global_2017_generated', None), diff --git a/selfdrive/car/toyota/carcontroller.py b/selfdrive/car/toyota/carcontroller.py index 96e25013eac97b..9d0a4d89484556 100644 --- a/selfdrive/car/toyota/carcontroller.py +++ b/selfdrive/car/toyota/carcontroller.py @@ -6,13 +6,14 @@ create_fcw_command from selfdrive.car.toyota.values import Ecu, CAR, STATIC_MSGS, SteerLimitParams from opendbc.can.packer import CANPacker +from common.dp_common import common_controller_ctrl VisualAlert = car.CarControl.HUDControl.VisualAlert # Accel limits ACCEL_HYST_GAP = 0.02 # don't change accel command for small oscilalitons within this value -ACCEL_MAX = 1.5 # 1.5 m/s2 -ACCEL_MIN = -3.0 # 3 m/s2 +ACCEL_MAX = 2.0 # 2.0 m/s2 +ACCEL_MIN = -3.5 # -3.5 m/s2 ACCEL_SCALE = max(ACCEL_MAX, -ACCEL_MIN) def accel_hysteresis(accel, accel_steady, enabled): @@ -49,8 +50,12 @@ def __init__(self, dbc_name, CP, VM): self.packer = CANPacker(dbc_name) + # dp + self.last_blinker_on = False + self.blinker_end_frame = 0. + def update(self, enabled, CS, frame, actuators, pcm_cancel_cmd, hud_alert, - left_line, right_line, lead, left_lane_depart, right_lane_depart): + left_line, right_line, lead, left_lane_depart, right_lane_depart, dragonconf): # *** compute control surfaces *** @@ -78,7 +83,7 @@ def update(self, enabled, CS, frame, actuators, pcm_cancel_cmd, hud_alert, self.last_fault_frame = frame # Cut steering for 2s after fault - if not enabled or (frame - self.last_fault_frame < 200): + if not enabled or (frame - self.last_fault_frame < 100) or abs(CS.out.steeringRate) > 100 or (abs(CS.out.steeringAngle) > 150 and CS.CP.carFingerprint in [CAR.RAV4H, CAR.PRIUS]): apply_steer = 0 apply_steer_req = 0 else: @@ -89,12 +94,24 @@ def update(self, enabled, CS, frame, actuators, pcm_cancel_cmd, hud_alert, pcm_cancel_cmd = 1 # on entering standstill, send standstill request - if CS.out.standstill and not self.last_standstill: + if not dragonconf.dpToyotaSng and CS.out.standstill and not self.last_standstill: self.standstill_req = True if CS.pcm_acc_status != 8: # pcm entered standstill or it's disabled self.standstill_req = False + # dp + blinker_on = CS.out.leftBlinker or CS.out.rightBlinker + if not enabled: + self.blinker_end_frame = 0 + if self.last_blinker_on and not blinker_on: + self.blinker_end_frame = frame + dragonconf.dpSignalOffDelay + apply_steer = common_controller_ctrl(enabled, + dragonconf, + blinker_on or frame < self.blinker_end_frame, + apply_steer, CS.out.vEgo) + self.last_blinker_on = blinker_on + self.last_steer = apply_steer self.last_accel = apply_accel self.last_standstill = CS.out.standstill @@ -120,12 +137,13 @@ def update(self, enabled, CS, frame, actuators, pcm_cancel_cmd, hud_alert, lead = lead or CS.out.vEgo < 12. # at low speed we always assume the lead is present do ACC can be engaged # Lexus IS uses a different cancellation message - if pcm_cancel_cmd and CS.CP.carFingerprint == CAR.LEXUS_IS: - can_sends.append(create_acc_cancel_command(self.packer)) - elif CS.CP.openpilotLongitudinalControl: - can_sends.append(create_accel_command(self.packer, apply_accel, pcm_cancel_cmd, self.standstill_req, lead)) - else: - can_sends.append(create_accel_command(self.packer, 0, pcm_cancel_cmd, False, lead)) + if not dragonconf.dpAtl: + if pcm_cancel_cmd and CS.CP.carFingerprint == CAR.LEXUS_IS: + can_sends.append(create_acc_cancel_command(self.packer)) + elif CS.CP.openpilotLongitudinalControl: + can_sends.append(create_accel_command(self.packer, apply_accel, pcm_cancel_cmd, self.standstill_req, lead)) + else: + can_sends.append(create_accel_command(self.packer, 0, pcm_cancel_cmd, False, lead)) if (frame % 2 == 0) and (CS.CP.enableGasInterceptor): # send exactly zero if apply_gas is zero. Interceptor will send the max between read value and apply_gas. @@ -147,8 +165,17 @@ def update(self, enabled, CS, frame, actuators, pcm_cancel_cmd, hud_alert, # forcing the pcm to disengage causes a bad fault sound so play a good sound instead send_ui = True + # dp + if dragonconf.dpToyotaLdw: + dragon_left_lane_depart = left_lane_depart + dragon_right_lane_depart = right_lane_depart + else: + dragon_left_lane_depart = False + dragon_right_lane_depart = False + + if (frame % 100 == 0 or send_ui) and Ecu.fwdCamera in self.fake_ecus: - can_sends.append(create_ui_command(self.packer, steer_alert, pcm_cancel_cmd, left_line, right_line, left_lane_depart, right_lane_depart)) + can_sends.append(create_ui_command(self.packer, steer_alert, pcm_cancel_cmd, left_line, right_line, dragon_left_lane_depart, dragon_right_lane_depart)) if frame % 100 == 0 and Ecu.dsu in self.fake_ecus: can_sends.append(create_fcw_command(self.packer, fcw_alert)) diff --git a/selfdrive/car/toyota/carstate.py b/selfdrive/car/toyota/carstate.py index 4cf84904e733c3..dad75518c53acc 100644 --- a/selfdrive/car/toyota/carstate.py +++ b/selfdrive/car/toyota/carstate.py @@ -5,6 +5,7 @@ from opendbc.can.parser import CANParser from selfdrive.config import Conversions as CV from selfdrive.car.toyota.values import CAR, DBC, STEER_THRESHOLD, TSS2_CAR, NO_STOP_TIMER_CAR +from common.params import Params class CarState(CarStateBase): @@ -13,13 +14,16 @@ def __init__(self, CP): can_define = CANDefine(DBC[CP.carFingerprint]['pt']) self.shifter_values = can_define.dv["GEAR_PACKET"]['GEAR'] + # dp + self.dp_toyota_zss = Params().get('dp_toyota_zss') == b'1' + # All TSS2 car have the accurate sensor - self.accurate_steer_angle_seen = CP.carFingerprint in TSS2_CAR + self.accurate_steer_angle_seen = CP.carFingerprint in TSS2_CAR or CP.carFingerprint in [CAR.LEXUS_ISH] or self.dp_toyota_zss # On NO_DSU cars but not TSS2 cars the cp.vl["STEER_TORQUE_SENSOR"]['STEER_ANGLE'] # is zeroed to where the steering angle is at start. # Need to apply an offset as soon as the steering angle measurements are both received - self.needs_angle_offset = CP.carFingerprint not in TSS2_CAR + self.needs_angle_offset = CP.carFingerprint not in TSS2_CAR or CP.carFingerprint in [CAR.LEXUS_ISH] or self.dp_toyota_zss self.angle_offset = 0. def update(self, cp, cp_cam): @@ -34,6 +38,9 @@ def update(self, cp, cp_cam): if self.CP.enableGasInterceptor: ret.gas = (cp.vl["GAS_SENSOR"]['INTERCEPTOR_GAS'] + cp.vl["GAS_SENSOR"]['INTERCEPTOR_GAS2']) / 2. ret.gasPressed = ret.gas > 15 + elif self.CP.carFingerprint in [CAR.LEXUS_ISH, CAR.LEXUS_GSH]: + ret.gas = cp.vl["GAS_PEDAL_ALT"]['GAS_PEDAL'] + ret.gasPressed = ret.gas > 1e-5 else: ret.gas = cp.vl["GAS_PEDAL"]['GAS_PEDAL'] ret.gasPressed = cp.vl["PCM_CRUISE"]['GAS_RELEASED'] == 0 @@ -52,11 +59,14 @@ def update(self, cp, cp_cam): self.accurate_steer_angle_seen = True if self.accurate_steer_angle_seen: - ret.steeringAngle = cp.vl["STEER_TORQUE_SENSOR"]['STEER_ANGLE'] - self.angle_offset + if self.dp_toyota_zss: + ret.steeringAngle = cp.vl["SECONDARY_STEER_ANGLE"]['ZORRO_STEER'] - self.angle_offset + else: + ret.steeringAngle = cp.vl["STEER_TORQUE_SENSOR"]['STEER_ANGLE'] - self.angle_offset if self.needs_angle_offset: angle_wheel = cp.vl["STEER_ANGLE_SENSOR"]['STEER_ANGLE'] + cp.vl["STEER_ANGLE_SENSOR"]['STEER_FRACTION'] - if abs(angle_wheel) > 1e-3 and abs(ret.steeringAngle) > 1e-3: + if (abs(angle_wheel) > 1e-3 and abs(ret.steeringAngle) > 1e-3) or self.dp_toyota_zss: self.needs_angle_offset = False self.angle_offset = ret.steeringAngle - angle_wheel else: @@ -74,15 +84,23 @@ def update(self, cp, cp_cam): ret.steeringPressed = abs(ret.steeringTorque) > STEER_THRESHOLD ret.steerWarning = cp.vl["EPS_STATUS"]['LKA_STATE'] not in [1, 5] - if self.CP.carFingerprint == CAR.LEXUS_IS: + if self.CP.carFingerprint in [CAR.LEXUS_IS, CAR.LEXUS_NXT]: ret.cruiseState.available = cp.vl["DSU_CRUISE"]['MAIN_ON'] != 0 ret.cruiseState.speed = cp.vl["DSU_CRUISE"]['SET_SPEED'] * CV.KPH_TO_MS self.low_speed_lockout = False + elif self.CP.carFingerprint in [CAR.LEXUS_ISH, CAR.LEXUS_GSH]: + ret.cruiseState.available = cp.vl["PCM_CRUISE_ALT"]['MAIN_ON'] != 0 + ret.cruiseState.speed = cp.vl["PCM_CRUISE_ALT"]['SET_SPEED'] * CV.KPH_TO_MS + self.low_speed_lockout = False else: ret.cruiseState.available = cp.vl["PCM_CRUISE_2"]['MAIN_ON'] != 0 ret.cruiseState.speed = cp.vl["PCM_CRUISE_2"]['SET_SPEED'] * CV.KPH_TO_MS self.low_speed_lockout = cp.vl["PCM_CRUISE_2"]['LOW_SPEED_LOCKOUT'] == 2 - self.pcm_acc_status = cp.vl["PCM_CRUISE"]['CRUISE_STATE'] + if self.CP.carFingerprint in [CAR.LEXUS_ISH, CAR.LEXUS_GSH]: + # Lexus ISH does not have CRUISE_STATUS value (always 0), so we use CRUISE_ACTIVE value instead + self.pcm_acc_status = cp.vl["PCM_CRUISE"]['CRUISE_ACTIVE'] + else: + self.pcm_acc_status = cp.vl["PCM_CRUISE"]['CRUISE_STATE'] if self.CP.carFingerprint in NO_STOP_TIMER_CAR or self.CP.enableGasInterceptor: # ignore standstill in hybrid vehicles, since pcm allows to restart without # receiving any special command. Also if interceptor is detected @@ -143,8 +161,8 @@ def get_can_parser(CP): ] checks = [ - ("BRAKE_MODULE", 40), - ("GAS_PEDAL", 33), + #("BRAKE_MODULE", 40), + #("GAS_PEDAL", 33), ("WHEEL_SPEEDS", 80), ("STEER_ANGLE_SENSOR", 80), ("PCM_CRUISE", 33), @@ -152,7 +170,27 @@ def get_can_parser(CP): ("EPS_STATUS", 25), ] - if CP.carFingerprint == CAR.LEXUS_IS: + if CP.carFingerprint in [CAR.LEXUS_ISH, CAR.LEXUS_GSH]: + signals.append(("GAS_PEDAL", "GAS_PEDAL_ALT", 0)) + signals.append(("MAIN_ON", "PCM_CRUISE_ALT", 0)) + signals.append(("SET_SPEED", "PCM_CRUISE_ALT", 0)) + signals.append(("AUTO_HIGH_BEAM", "LIGHT_STALK_ISH", 0)) + checks += [ + ("BRAKE_MODULE", 50), + ("GAS_PEDAL_ALT", 50), + ("PCM_CRUISE_ALT", 1), + ] + else: + signals += [ + ("AUTO_HIGH_BEAM", "LIGHT_STALK", 0), + ("GAS_PEDAL", "GAS_PEDAL", 0), + ] + checks += [ + ("BRAKE_MODULE", 40), + ("GAS_PEDAL", 33), + ] + + if CP.carFingerprint in [CAR.LEXUS_IS, CAR.LEXUS_NXT]: signals.append(("MAIN_ON", "DSU_CRUISE", 0)) signals.append(("SET_SPEED", "DSU_CRUISE", 0)) checks.append(("DSU_CRUISE", 5)) @@ -177,6 +215,10 @@ def get_can_parser(CP): signals += [("R_ADJACENT", "BSM", 0)] signals += [("R_APPROACHING", "BSM", 0)] + if Params().get('dp_toyota_zss') == b'1': + signals += [("ZORRO_STEER", "SECONDARY_STEER_ANGLE", 0)] + + checks = [] return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, 0) @staticmethod @@ -191,5 +233,5 @@ def get_cam_can_parser(CP): checks = [ ("STEERING_LKA", 42) ] - + checks = [] return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, 2) diff --git a/selfdrive/car/toyota/interface.py b/selfdrive/car/toyota/interface.py index 1fa84f9155f062..424e7dc85db01b 100755 --- a/selfdrive/car/toyota/interface.py +++ b/selfdrive/car/toyota/interface.py @@ -5,17 +5,25 @@ from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, is_ecu_disconnected, gen_empty_fingerprint from selfdrive.swaglog import cloudlog from selfdrive.car.interfaces import CarInterfaceBase +from common.dp_common import common_interface_atl, common_interface_get_params_lqr +from common.params import Params EventName = car.CarEvent.EventName class CarInterface(CarInterfaceBase): + def __init__(self, CP, CarController, CarState): + super().__init__(CP, CarController, CarState) + + # dp + self.dp_cruise_speed = 0. + @staticmethod def compute_gb(accel, speed): return float(accel) / 3.0 @staticmethod - def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # pylint: disable=dangerous-default-value - ret = CarInterfaceBase.get_std_params(candidate, fingerprint) + def get_params(candidate, fingerprint=gen_empty_fingerprint(), has_relay=False, car_fw=[]): # pylint: disable=dangerous-default-value + ret = CarInterfaceBase.get_std_params(candidate, fingerprint, has_relay) ret.carName = "toyota" ret.safetyModel = car.CarParams.SafetyModel.toyota @@ -49,6 +57,9 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py ret.steerRatio = 16.88 # 14.5 is spec end-to-end tire_stiffness_factor = 0.5533 ret.mass = 3650. * CV.LB_TO_KG + STD_CARGO_KG # mean between normal and hybrid + if ret.enableGasInterceptor: + ret.longitudinalTuning.kpV = [0.4, 0.36, 0.325] # arne's tune. + ret.longitudinalTuning.kiV = [0.195, 0.10] ret.lateralTuning.init('lqr') ret.lateralTuning.lqr.scale = 1500.0 @@ -263,9 +274,48 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.35], [0.15]] ret.lateralTuning.pid.kf = 0.00007818594 + elif candidate == CAR.LEXUS_ISH: + stop_and_go = True # set to true because it's a hybrid + ret.safetyParam = 130 + ret.wheelbase = 2.79908 + ret.steerRatio = 13.3 + tire_stiffness_factor = 0.444 + ret.mass = 3736.8 * CV.LB_TO_KG + STD_CARGO_KG + ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.3], [0.05]] + ret.lateralTuning.pid.kf = 0.00006 + + elif candidate == CAR.LEXUS_GSH: + stop_and_go = True # set to true because it's a hybrid + ret.safetyParam = 130 + ret.wheelbase = 2.84988 + ret.steerRatio = 14.35 # range from 11.5 - 17.2, lets try 14.35 + tire_stiffness_factor = 0.444 + ret.mass = 4112 * CV.LB_TO_KG + STD_CARGO_KG + ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.3], [0.05]] + ret.lateralTuning.pid.kf = 0.00006 + + elif candidate == CAR.LEXUS_NXT: + stop_and_go = True + ret.safetyParam = 100 + ret.wheelbase = 2.66 + ret.steerRatio = 14.7 + tire_stiffness_factor = 0.444 # not optimized yet + ret.mass = 4070 * CV.LB_TO_KG + STD_CARGO_KG + ret.lateralTuning.pid.kpV, ret.lateralTuning.pid.kiV = [[0.3], [0.05]] + ret.lateralTuning.pid.kf = 0.00006 + ret.steerRateCost = 1. ret.centerToFront = ret.wheelbase * 0.44 + # dp + ret = common_interface_get_params_lqr(ret) + + if candidate == CAR.PRIUS and Params().get('dp_toyota_zss') == b'1': + ret.mass = 3370. * CV.LB_TO_KG + STD_CARGO_KG + if Params().get('dp_lqr') == b'0': + ret.lateralTuning.indi.timeConstant = 0.1 + ret.steerRateCost = 0.5 + # TODO: get actual value, for now starting with reasonable value for # civic and scaling by mass and wheelbase ret.rotationalInertia = scale_rot_inertia(ret.mass, ret.wheelbase) @@ -275,7 +325,7 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py ret.tireStiffnessFront, ret.tireStiffnessRear = scale_tire_stiffness(ret.mass, ret.wheelbase, ret.centerToFront, tire_stiffness_factor=tire_stiffness_factor) - ret.enableCamera = True + ret.enableCamera = is_ecu_disconnected(fingerprint[0], FINGERPRINTS, ECU_FINGERPRINT, candidate, Ecu.fwdCamera) or has_relay # Detect smartDSU, which intercepts ACC_CMD from the DSU allowing openpilot to send it smartDsu = 0x2FF in fingerprint[0] # In TSS2 cars the camera does long control @@ -314,12 +364,25 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py return ret # returns a car.CarState - def update(self, c, can_strings): + def update(self, c, can_strings, dragonconf): # ******************* do can recv ******************* self.cp.update_strings(can_strings) self.cp_cam.update_strings(can_strings) ret = self.CS.update(self.cp, self.cp_cam) + # dp + self.dragonconf = dragonconf + ret.cruiseState.enabled = common_interface_atl(ret, dragonconf.dpAtl) + if ret.cruiseState.enabled and dragonconf.dpToyotaLowestCruiseOverride and ret.cruiseState.speed < dragonconf.dpToyotaLowestCruiseOverrideAt * CV.KPH_TO_MS: + if dragonconf.dpToyotaLowestCruiseOverrideVego: + if self.dp_cruise_speed == 0.: + ret.cruiseState.speed = self.dp_cruise_speed = max( dragonconf.dpToyotaLowestCruiseOverrideSpeed * CV.KPH_TO_MS,ret.vEgo) + else: + ret.cruiseState.speed = self.dp_cruise_speed + else: + ret.cruiseState.speed = dragonconf.dpToyotaLowestCruiseOverrideSpeed * CV.KPH_TO_MS + else: + self.dp_cruise_speed = 0. ret.canValid = self.cp.can_valid and self.cp_cam.can_valid ret.steeringRateLimited = self.CC.steer_rate_limited if self.CC is not None else False @@ -327,6 +390,8 @@ def update(self, c, can_strings): # events events = self.create_common_events(ret) + # if self.cp_cam.can_invalid_cnt >= 200 and self.CP.enableCamera and not self.CP.isPandaBlack: + # events.add(EventName.invalidGiraffeToyotaDEPRECATED) if self.CS.low_speed_lockout and self.CP.openpilotLongitudinalControl: events.add(EventName.lowSpeedLockout) if ret.vEgo < self.CP.minEnableSpeed and self.CP.openpilotLongitudinalControl: @@ -351,7 +416,7 @@ def apply(self, c): c.actuators, c.cruiseControl.cancel, c.hudControl.visualAlert, c.hudControl.leftLaneVisible, c.hudControl.rightLaneVisible, c.hudControl.leadVisible, - c.hudControl.leftLaneDepart, c.hudControl.rightLaneDepart) + c.hudControl.leftLaneDepart, c.hudControl.rightLaneDepart, self.dragonconf) self.frame += 1 return can_sends diff --git a/selfdrive/car/toyota/values.py b/selfdrive/car/toyota/values.py index 924e02efd137df..c6120264d26752 100644 --- a/selfdrive/car/toyota/values.py +++ b/selfdrive/car/toyota/values.py @@ -41,6 +41,10 @@ class CAR: RAV4H_TSS2 = "TOYOTA RAV4 HYBRID 2019" LEXUS_NXH = "LEXUS NX300H 2018" LEXUS_NX = "LEXUS NX300 2018" + LEXUS_ISH = "LEXUS IS300h 2017" + LEXUS_GSH = "LEXUS GS450h 2017" + LEXUS_NXT = "LEXUS NX200T 2015" + # addr: (ecu, cars, bus, 1/freq*100, vl) STATIC_MSGS = [ @@ -82,36 +86,52 @@ class CAR: 36: 8, 37: 8, 170: 8, 180: 8, 186: 4, 355: 5, 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, 742: 8, 743: 8, 767: 4, 800: 8, 830: 7, 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, 921: 8, 922: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 979: 2, 998: 5, 999: 7, 1000: 8, 1001: 8, 1008: 2, 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, 1207: 8, 1227: 8, 1235: 8, 1263: 8, 1279: 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, 1664: 8, 1728: 8, 1745: 8, 1779: 8 }], CAR.PRIUS: [{ - 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 8, 426: 6, 452: 8, 466: 8, 467: 8, 512: 6, 513: 6, 550: 8, 552: 4, 560: 7, 562: 6, 581: 5, 608: 8, 610: 8, 614: 8, 643: 7, 658: 8, 713: 8, 740: 5, 742: 8, 743: 8, 767: 4, 800: 8, 810: 2, 814: 8, 824: 2, 829: 2, 830: 7, 835: 8, 836: 8, 845: 5, 863: 8, 869: 7, 870: 7, 871: 2, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 918: 8, 921: 8, 933: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 974: 8, 975: 5, 993: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1005: 2, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 8, 1082: 8, 1083: 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, 1175: 8, 1227: 8, 1228: 8, 1235: 8, 1237: 8, 1264: 8, 1279: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1595: 8, 1777: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 + 35: 8, 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 8, 426: 6, 452: 8, 466: 8, 467: 8, 512: 6, 513: 6, 550: 8, 552: 4, 560: 7, 562: 6, 581: 5, 608: 8, 610: 8, 614: 8, 643: 7, 658: 8, 713: 8, 740: 5, 742: 8, 743: 8, 767: 4, 800: 8, 810: 2, 814: 8, 824: 2, 829: 2, 830: 7, 835: 8, 836: 8, 845: 5, 863: 8, 869: 7, 870: 7, 871: 2, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 918: 8, 921: 8, 933: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 974: 8, 975: 5, 993: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1005: 2, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 8, 1082: 8, 1083: 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, 1175: 8, 1227: 8, 1228: 8, 1235: 8, 1237: 8, 1264: 8, 1279: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1595: 8, 1777: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 }, #2019 LE { - 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 8, 426: 6, 452: 8, 466: 8, 467: 8, 550: 8, 552: 4, 560: 7, 562: 6, 581: 5, 608: 8, 610: 8, 614: 8, 643: 7, 658: 8, 713: 8, 740: 5, 742: 8, 743: 8, 767: 4, 800: 8, 810: 2, 814: 8, 829: 2, 830: 7, 835: 8, 836: 8, 863: 8, 865: 8, 869: 7, 870: 7, 871: 2, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 918: 8, 921: 8, 933: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 975: 5, 993: 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, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 8, 1082: 8, 1083: 8, 1084: 8, 1085: 8, 1086: 8, 1114: 8, 1132: 8, 1161: 8, 1162: 8, 1163: 8, 1175: 8, 1227: 8, 1228: 8, 1235: 8, 1237: 8, 1279: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1592: 8, 1595: 8, 1777: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 + 35: 8, 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 8, 426: 6, 452: 8, 466: 8, 467: 8, 550: 8, 552: 4, 560: 7, 562: 6, 581: 5, 608: 8, 610: 8, 614: 8, 643: 7, 658: 8, 713: 8, 740: 5, 742: 8, 743: 8, 767: 4, 800: 8, 810: 2, 814: 8, 829: 2, 830: 7, 835: 8, 836: 8, 863: 8, 865: 8, 869: 7, 870: 7, 871: 2, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 918: 8, 921: 8, 933: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 975: 5, 993: 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, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 8, 1082: 8, 1083: 8, 1084: 8, 1085: 8, 1086: 8, 1114: 8, 1132: 8, 1161: 8, 1162: 8, 1163: 8, 1175: 8, 1227: 8, 1228: 8, 1235: 8, 1237: 8, 1279: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1592: 8, 1595: 8, 1777: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 }, # 2020 Prius Prime LE { - 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 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, 740: 5, 742: 8, 743: 8, 764: 8, 767: 4, 800: 8, 810: 2, 824: 8, 829: 2, 830: 7, 835: 8, 836: 8, 863: 8, 865: 8, 869: 7, 870: 7, 871: 2, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 921: 8, 933: 8, 934: 8, 935: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 974: 8, 975: 5, 993: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 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, 1227: 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, 1595: 8, 1649: 8, 1777: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 + 35: 8, 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 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, 740: 5, 742: 8, 743: 8, 764: 8, 767: 4, 800: 8, 810: 2, 824: 8, 829: 2, 830: 7, 835: 8, 836: 8, 863: 8, 865: 8, 869: 7, 870: 7, 871: 2, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 921: 8, 933: 8, 934: 8, 935: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 974: 8, 975: 5, 993: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 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, 1227: 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, 1595: 8, 1649: 8, 1777: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 }, #2020 Prius Prime Limited { - 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 8, 426: 6, 452: 8, 466: 8, 467: 8, 550: 8, 552: 4, 560: 7, 562: 6, 581: 5, 608: 8, 610: 8, 614: 8, 643: 7, 658: 8, 713: 8, 740: 5, 742: 8, 743: 8, 767: 4, 800: 8, 810: 2, 814: 8, 824: 2, 829: 2, 830: 7, 835: 8, 836: 8, 863: 8, 865: 8, 869: 7, 870: 7, 871: 2, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 918: 8, 921: 8, 933: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 974: 8, 975: 5, 993: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 8, 1082: 8, 1083: 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, 1175: 8, 1227: 8, 1228: 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, 1777: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8, 2015: 8, 2024: 8, 2026: 8, 2027: 8, 2029: 8, 2030: 8, 2031: 8 + 35: 8, 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 8, 426: 6, 452: 8, 466: 8, 467: 8, 550: 8, 552: 4, 560: 7, 562: 6, 581: 5, 608: 8, 610: 8, 614: 8, 643: 7, 658: 8, 713: 8, 740: 5, 742: 8, 743: 8, 767: 4, 800: 8, 810: 2, 814: 8, 824: 2, 829: 2, 830: 7, 835: 8, 836: 8, 863: 8, 865: 8, 869: 7, 870: 7, 871: 2, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 918: 8, 921: 8, 933: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 974: 8, 975: 5, 993: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 8, 1082: 8, 1083: 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, 1175: 8, 1227: 8, 1228: 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, 1777: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8, 2015: 8, 2024: 8, 2026: 8, 2027: 8, 2029: 8, 2030: 8, 2031: 8 }, #2020 Central Europe Prime { - 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 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, 740: 5, 742: 8, 743: 8, 764: 8, 767: 4, 800: 8, 810: 2, 818: 8, 824: 8, 829: 2, 830: 7, 835: 8, 836: 8, 845: 5, 863: 8, 865: 8, 869: 7, 870: 7, 871: 2, 889: 8, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 921: 8, 933: 8, 934: 8, 935: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 8, 974: 8, 975: 5, 993: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1056: 8, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 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, 1227: 8, 1235: 8, 1237: 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, 1595: 8, 1777: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8 + 35: 8, 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 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, 740: 5, 742: 8, 743: 8, 764: 8, 767: 4, 800: 8, 810: 2, 818: 8, 824: 8, 829: 2, 830: 7, 835: 8, 836: 8, 845: 5, 863: 8, 865: 8, 869: 7, 870: 7, 871: 2, 889: 8, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 921: 8, 933: 8, 934: 8, 935: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 8, 974: 8, 975: 5, 993: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1056: 8, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 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, 1227: 8, 1235: 8, 1237: 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, 1595: 8, 1777: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8 }, #2017 German Prius { - 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 8, 426: 6, 452: 8, 466: 8, 467: 8, 550: 8, 552: 4, 560: 7, 562: 6, 581: 5, 608: 8, 610: 8, 614: 8, 643: 7, 658: 8, 713: 8, 740: 5, 742: 8, 743: 8, 767: 4, 800: 8, 810: 2, 814: 8, 829: 2, 830: 7, 835: 8, 836: 8, 845: 5, 863: 8, 869: 7, 870: 7, 871: 2, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 918: 8, 921: 8, 933: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 975: 5, 993: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1005: 2, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1071: 8, 1077: 8, 1082: 8, 1083: 8, 1084: 8, 1085: 8, 1086: 8, 1114: 8, 1132: 8, 1161: 8, 1162: 8, 1163: 8, 1175: 8, 1227: 8, 1228: 8, 1235: 8, 1237: 8, 1264: 8, 1279: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1595: 8, 1777: 8, 1779: 8, 1792: 8, 1767: 4, 1863: 8, 1904: 8, 1912: 8, 1984: 8, 1988: 8, 1990: 8, 1992: 8, 1996: 8, 1998: 8, 2002: 8, 2010: 8, 2015: 8, 2016: 8, 2018: 8, 2024: 8, 2026: 8, 2030: 8 + 35: 8, 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 8, 426: 6, 452: 8, 466: 8, 467: 8, 550: 8, 552: 4, 560: 7, 562: 6, 581: 5, 608: 8, 610: 8, 614: 8, 643: 7, 658: 8, 713: 8, 740: 5, 742: 8, 743: 8, 767: 4, 800: 8, 810: 2, 814: 8, 829: 2, 830: 7, 835: 8, 836: 8, 845: 5, 863: 8, 869: 7, 870: 7, 871: 2, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 918: 8, 921: 8, 933: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 975: 5, 993: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1005: 2, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1071: 8, 1077: 8, 1082: 8, 1083: 8, 1084: 8, 1085: 8, 1086: 8, 1114: 8, 1132: 8, 1161: 8, 1162: 8, 1163: 8, 1175: 8, 1227: 8, 1228: 8, 1235: 8, 1237: 8, 1264: 8, 1279: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1595: 8, 1777: 8, 1779: 8, 1792: 8, 1767: 4, 1863: 8, 1904: 8, 1912: 8, 1984: 8, 1988: 8, 1990: 8, 1992: 8, 1996: 8, 1998: 8, 2002: 8, 2010: 8, 2015: 8, 2016: 8, 2018: 8, 2024: 8, 2026: 8, 2030: 8 + }, + # Taiwan 2020 Prius 4.5 + { + 35: 8, 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 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, 740: 5, 742: 8, 743: 8, 764: 8, 800: 8, 810: 2, 818: 8, 824: 8, 829: 2, 830: 7, 835: 8, 836: 8, 845: 5, 863: 8, 865: 8, 869: 7, 870: 7, 871: 2, 889: 8, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 921: 8, 933: 8, 934: 8, 935: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 975: 5, 993: 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, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1227: 8, 1235: 8, 1237: 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, 1593: 8, 1595: 8, 1777: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8 + }, + # Taiwan Prius 4.5 + { + 35: 8, 36: 8, 37: 8, 166: 8, 170: 8, 180: 8, 295: 8, 296: 8, 426: 6, 452: 8, 466: 8, 467: 8, 512: 6, 513: 6, 550: 8, 552: 4, 560: 7, 562: 6, 581: 5, 608: 8, 610: 8, 643: 7, 713: 8, 740: 5, 742: 8, 743: 8, 764: 8, 800: 8, 810: 2, 818: 8, 824: 8, 829: 2, 830: 7, 835: 8, 836: 8, 845: 5, 863: 8, 865: 8, 869: 7, 870: 7, 871: 2, 889: 8, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 921: 8, 933: 8, 934: 8, 935: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 975: 5, 993: 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, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1227: 8, 1235: 8, 1237: 8, 1264: 8, 1279: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1592: 8, 1595: 8, 1777: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8, 1872: 8, 1880: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 }], #Corolla w/ added Pedal Support (512L and 513L) CAR.COROLLA: [{ 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, 608: 8, 610: 5, 643: 7, 705: 8, 740: 5, 767: 4, 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: 2, 921: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 4, 956: 8, 979: 2, 992: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1017: 8, 1041: 8, 1042: 8, 1043: 8, 1044: 8, 1056: 8, 1059: 1, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1196: 8, 1227: 8, 1235: 8, 1279: 8, 1552: 8, 1553: 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, 1596: 8, 1597: 8, 1600: 8, 1664: 8, 1728: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8, 2016: 8, 2017: 8, 2018: 8, 2019: 8, 2020: 8, 2021: 8, 2022: 8, 2023: 8, 2024: 8 + }, + #2015 Corolla w/ select 2017 ECU's + { + 32: 4, 36: 8, 37: 8, 170: 8, 180: 8, 186: 4, 426: 6, 452: 8, 456: 8, 464: 8, 466: 8, 467: 8, 513: 6, 547: 8, 548: 8, 552: 4, 608: 8, 610: 5, 611: 7, 705: 8, 740: 5, 800: 8, 849: 4, 852: 1, 865: 8, 871: 2, 896: 8, 897: 8, 898: 8, 899: 8, 900: 6, 902: 6, 903: 8, 905: 8, 906: 5, 910: 8, 911: 8, 916: 2, 921: 8, 928: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 4, 956: 8, 976: 1, 979: 2, 998: 5, 999: 7, 1000: 8, 1001: 8, 1017: 8, 1024: 8, 1042: 8, 1043: 8, 1044: 8, 1056: 8, 1059: 1, 1076: 8, 1077: 8, 1078: 8, 1079: 8, 1088: 8, 1090: 8, 1091: 8, 1161: 8, 1162: 8, 1163: 8, 1196: 8, 1217: 8, 1219: 8, 1222: 8, 1224: 8, 1235: 8, 1244: 8, 1245: 8, 1279: 8, 1552: 8, 1553: 8, 1555: 8, 1556: 8, 1557: 8, 1560: 8, 1561: 8, 1562: 8, 1564: 8, 1568: 8, 1569: 8, 1570: 8, 1571: 8, 1572: 8, 1574: 8, 1592: 8, 1596: 8, 1597: 8, 1600: 8, 1664: 8, 1761: 8, 1762: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8, 643: 7 }], CAR.LEXUS_RX: [{ # 2016 Lexus RX 350 36: 8, 37: 8, 114: 5, 119: 6, 120: 4, 170: 8, 180: 8, 186: 4, 426: 6, 452: 8, 464: 8, 466: 8, 467: 8, 544: 4, 550: 8, 552: 4, 562: 6, 608: 8, 610: 5, 643: 7, 705: 8, 740: 5, 742: 8, 743: 8, 767: 4, 800: 8, 810: 2, 812: 3, 818: 8, 819: 8, 820: 8, 821: 8, 822: 8, 830: 7, 835: 8, 836: 8, 845: 5, 869: 7, 870: 7, 871: 2, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 918: 8, 921: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1059: 1, 1063: 8, 1077: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1227: 8, 1228: 8, 1235: 8, 1237: 8, 1263: 8, 1264: 8, 1279: 8, 1349: 8, 1350: 8, 1351: 8, 1413: 8, 1414: 8, 1415: 8, 1416: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1575: 8, 1595: 8, 1777: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8, 2015: 8, 2016: 8, 2024: 8 }, + { + # RX300 China + 36: 8, 37: 8, 114: 5, 119: 6, 120: 4, 170: 8, 180: 8, 186: 4, 355: 5, 426: 6, 452: 8, 464: 8, 466: 8, 467: 8, 544: 4, 550: 8, 552: 4, 562: 6, 608: 8, 610: 5, 643: 7, 705: 8, 740: 5, 742: 8, 743: 8, 744: 8, 800: 8, 810: 2, 812: 3, 830: 7, 835: 8, 836: 8, 845: 5, 869: 7, 870: 7, 871: 2, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 918: 8, 921: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1059: 1, 1063: 8, 1077: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1227: 8, 1228: 8, 1235: 8, 1237: 8, 1279: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1575: 8, 1595: 8, 1777: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 + }, # 2017 Lexus RX 350 { 36: 8, 37: 8, 114: 5, 119: 6, 120: 4, 170: 8, 180: 8, 186: 4, 426: 6, 452: 8, 464: 8, 466: 8, 467: 8, 544: 4, 550: 8, 552: 4, 562: 6, 608: 8, 610: 5, 643: 7, 658: 8, 705: 8, 740: 5, 742: 8, 743: 8, 767: 4, 800: 8, 810: 2, 812: 3, 814: 8, 818: 8, 819: 8, 820: 8, 821: 8, 822: 8, 830: 7, 835: 8, 836: 8, 869: 7, 870: 7, 871: 2, 898: 8, 900: 6, 902: 6, 905: 8, 918: 8, 921: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1059: 1, 1063: 8, 1077: 8, 1082: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1227: 8, 1228: 8, 1235: 8, 1237: 8, 1263: 8, 1264: 8, 1279: 8, 1349: 8, 1350: 8, 1351: 8, 1413: 8, 1414: 8, 1415: 8, 1416: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1575: 8, 1595: 8, 1777: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 @@ -161,6 +181,10 @@ class CAR: { # 2019 XSE 36: 8, 37: 8, 170: 8, 180: 8, 186: 4, 426: 6, 452: 8, 464: 8, 466: 8, 467: 8, 544: 4, 550: 8, 552: 4, 562: 6, 608: 8, 610: 8, 643: 7, 658: 8, 705: 8, 728: 8, 740: 5, 761: 8, 764: 8, 767: 4, 800: 8, 810: 2, 812: 8, 814: 8, 818: 8, 822: 8, 824: 8, 830: 7, 835: 8, 836: 8, 865: 8, 869: 7, 870: 7, 871: 2, 888: 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, 942: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 976: 1, 983: 8, 984: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1002: 8, 1011: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1059: 1, 1076: 8, 1077: 8, 1082: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1228: 8, 1235: 8, 1237: 8, 1263: 8, 1264: 8, 1279: 8, 1412: 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, 1745: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8, 1792: 8, 1767: 4, 1808: 8, 1816: 8, 1872: 8, 1880: 8, 1904: 8, 1912: 8, 1937: 8, 1945: 8, 1953: 8, 1961: 8, 1968: 8, 1976: 8, 1990: 8, 1998: 8, 2015: 8, 2016: 8, 2024: 8 + }, + # China 2018 Camry 2.5 from superdongle + { + 36: 8, 37: 8, 119: 6, 170: 8, 180: 8, 186: 4, 355: 5, 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, 761: 8, 764: 8, 800: 8, 810: 2, 812: 8, 818: 8, 824: 8, 830: 7, 835: 8, 836: 8, 869: 7, 870: 7, 871: 2, 888: 8, 889: 8, 898: 8, 900: 6, 902: 6, 905: 8, 913: 8, 918: 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, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1059: 1, 1076: 8, 1077: 8, 1112: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1235: 8, 1264: 8, 1279: 8, 1541: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1595: 8, 1745: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 }], CAR.CAMRYH: [ #SE, LE and LE with Blindspot Monitor @@ -189,6 +213,10 @@ class CAR: # 2018 Highlander Limited Platinum { 36: 8, 37: 8, 114: 5, 119: 6, 120: 4, 170: 8, 180: 8, 186: 4, 238: 4, 355: 5, 426: 6, 452: 8, 464: 8, 466: 8, 467: 8, 544: 4, 545: 5, 550: 8, 552: 4, 608: 8, 610: 5, 643: 7, 705: 8, 725: 2, 740: 5, 767: 4, 800: 8, 835: 8, 836: 8, 849: 4, 869: 7, 870: 7, 871: 2, 896: 8, 900: 6, 902: 6, 905: 8, 911: 8, 916: 3, 918: 7, 921: 8, 922: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 979: 2, 998: 5, 999: 7, 1000: 8, 1001: 8, 1008: 2, 1014: 8, 1017: 8, 1020: 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, 1182: 8, 1183: 8, 1189: 8, 1190: 8, 1191: 8, 1192: 8, 1196: 8, 1197: 8, 1198: 8, 1199: 8, 1206: 8, 1207: 8, 1212: 8, 1227: 8, 1235: 8, 1237: 8, 1263: 8, 1279: 8, 1408: 8, 1409: 8, 1410: 8, 1552: 8, 1553: 8, 1554: 8, 1556: 8, 1557: 8, 1561: 8, 1562: 8, 1568: 8, 1569: 8, 1570: 8, 1571: 8, 1572: 8, 1584: 8, 1585: 8, 1589: 8, 1592: 8, 1593: 8, 1595: 8, 1599: 8, 1656: 8, 1728: 8, 1745: 8, 1779: 8, 1872: 8, 1880: 8, 1904: 8, 1912: 8, 1988: 8, 1990: 8, 1996: 8, 1998: 8, 2015: 8, 2016: 8, 2024: 8 + }, + # 2018 China Highlander from toyboxZ + { + 36: 8, 37: 8, 114: 5, 119: 6, 120: 4, 170: 8, 180: 8, 186: 4, 238: 4, 355: 5, 426: 6, 452: 8, 464: 8, 466: 8, 467: 8, 544: 4, 550: 8, 552: 4, 562: 6, 608: 8, 610: 5, 643: 7, 705: 8, 725: 2, 740: 5, 800: 8, 835: 8, 836: 8, 845: 5, 849: 4, 869: 7, 870: 7, 871: 2, 896: 8, 900: 6, 902: 6, 905: 8, 911: 8, 913: 8, 916: 3, 918: 7, 921: 8, 922: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 979: 2, 998: 5, 999: 7, 1000: 8, 1001: 8, 1008: 2, 1017: 8, 1020: 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, 1182: 8, 1183: 8, 1189: 8, 1190: 8, 1191: 8, 1192: 8, 1196: 8, 1197: 8, 1198: 8, 1199: 8, 1200: 8, 1201: 8, 1202: 8, 1203: 8, 1206: 8, 1207: 8, 1212: 8, 1227: 8, 1235: 8, 1279: 8, 1408: 8, 1409: 8, 1410: 8, 1552: 8, 1553: 8, 1554: 8, 1556: 8, 1557: 8, 1561: 8, 1568: 8, 1569: 8, 1570: 8, 1571: 8, 1572: 8, 1584: 8, 1589: 8, 1592: 8, 1593: 8, 1595: 8, 1599: 8, 1728: 8, 1745: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8, 2015: 8, 2016: 8, 2024: 8 }], CAR.HIGHLANDER_TSS2: [{ # 2020 highlander limited @@ -215,11 +243,27 @@ class CAR: # 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, 767: 4, 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 + }, + # China 2020 RAV4 from superdongle + { + 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, 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, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1063: 8, 1071: 8, 1082: 8, 1084: 8, 1085: 8, 1086: 8, 1112: 8, 1114: 8, 1132: 8, 1161: 8, 1162: 8, 1163: 8, 1172: 8, 1235: 8, 1263: 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, 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, 767: 4, 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, 913: 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 + }, + #2020 AURIS with LTA, number of messages: + { + 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, 765: 8, 800: 8, 810: 2, 812: 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, 921: 8, 942: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 976: 1, 1002: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1059: 1, 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, 1595: 8, 1745: 8, 1775: 8, 1779: 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 Chinese Levin (Petrol) from Shell + 36: 8, 37: 8, 170: 8, 180: 8, 186: 4, 355: 5, 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, 810: 2, 812: 8, 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, 921: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 976: 1, 1002: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1059: 1, 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, 1600: 8, 1649: 8, 1745: 8, 1775: 8, 1779: 8, 1808: 8, 1816: 8, 1904: 8, 1912: 8, 1984: 8, 1992: 8, 2002: 8 }], CAR.COROLLAH_TSS2: [ # 2019 Taiwan Altis Hybrid @@ -229,10 +273,18 @@ class CAR: # 2019 Chinese Levin 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, 767: 4, 800: 8, 810: 2, 812: 8, 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, 921: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 975: 5, 993: 8, 1002: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1057: 8, 1059: 1, 1071: 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, 1600: 8, 1649: 8, 1745: 8, 1775: 8, 1779: 8 + }, + # Taiwan Altis Hybrid by Fish + { + 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, 942: 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_ES_TSS2: [{ 36: 8, 37: 8, 114: 5, 119: 6, 120: 4, 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, 658: 8, 705: 8, 728: 8, 740: 5, 761: 8, 764: 8, 765: 8, 767: 4, 800: 8, 810: 2, 812: 8, 814: 8, 818: 8, 824: 8, 830: 7, 835: 8, 836: 8, 865: 8, 869: 7, 870: 7, 871: 2, 877: 8, 881: 8, 882: 8, 885: 8, 889: 8, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 913: 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, 1076: 8, 1077: 8, 1082: 8, 1114: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1172: 8, 1228: 8, 1235: 8, 1237: 8, 1264: 8, 1279: 8, 1541: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1575: 8, 1592: 8, 1594: 8, 1595: 8, 1649: 8, 1696: 8, 1775: 8, 1777: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8, + }, + # 2019 Lexus ES200 from Shell + { + 36: 8, 37: 8, 119: 6, 120: 4, 170: 8, 180: 8, 186: 4, 355: 5, 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, 761: 8, 764: 8, 765: 8, 800: 8, 810: 2, 812: 8, 818: 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, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 913: 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, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1059: 1, 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, 1264: 8, 1279: 8, 1541: 8, 1552: 8, 1553: 8, 1556: 8, 1557: 8, 1568: 8, 1570: 8, 1571: 8, 1572: 8, 1575: 8, 1592: 8, 1594: 8, 1595: 8, 1775: 8, 1777: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 }], CAR.LEXUS_ESH_TSS2: [ { @@ -245,15 +297,19 @@ class CAR: # XLE AWD 2018 { 36: 8, 37: 8, 114: 5, 119: 6, 120: 4, 170: 8, 180: 8, 186: 4, 238: 4, 426: 6, 452: 8, 464: 8, 466: 8, 467: 8, 544: 4, 545: 5, 548: 8, 550: 8, 552: 4, 562: 4, 608: 8, 610: 5, 643: 7, 705: 8, 725: 2, 740: 5, 764: 8, 767: 4, 800: 8, 824: 8, 835: 8, 836: 8, 849: 4, 869: 7, 870: 7, 871: 2, 896: 8, 900: 6, 902: 6, 905: 8, 911: 8, 916: 1, 921: 8, 933: 8, 944: 6, 945: 8, 951: 8, 955: 8, 956: 8, 979: 2, 992: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1002: 8, 1008: 2, 1014: 8, 1017: 8, 1041: 8, 1042: 8, 1043: 8, 1056: 8, 1059: 1, 1076: 8, 1077: 8, 1114: 8, 1160: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1176: 8, 1177: 8, 1178: 8, 1179: 8, 1180: 8, 1181: 8, 1182: 8, 1183: 8, 1191: 8, 1192: 8, 1196: 8, 1197: 8, 1198: 8, 1199: 8, 1200: 8, 1201: 8, 1202: 8, 1203: 8, 1212: 8, 1227: 8, 1235: 8, 1237: 8, 1279: 8, 1552: 8, 1553: 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, 1656: 8, 1664: 8, 1666: 8, 1667: 8, 1728: 8, 1745: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 + }, + { + # Canada 2018 Sienna LTD + 36: 8, 37: 8, 114: 5, 119: 6, 120: 4, 170: 8, 180: 8, 186: 4, 238: 4, 426: 6, 452: 8, 464: 8, 466: 8, 467: 8, 544: 4, 545: 5, 548: 8, 550: 8, 552: 4, 562: 4, 608: 8, 610: 5, 643: 7, 705: 8, 725: 2, 740: 5, 764: 8, 800: 8, 818: 8, 822: 8, 824: 8, 835: 8, 836: 8, 849: 4, 869: 7, 870: 7, 871: 2, 888: 8, 889: 8, 891: 8, 896: 8, 900: 6, 902: 6, 905: 8, 911: 8, 916: 1, 918: 7, 921: 8, 933: 8, 944: 6, 945: 8, 951: 8, 955: 8, 956: 8, 979: 2, 992: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1002: 8, 1008: 2, 1014: 8, 1017: 8, 1041: 8, 1042: 8, 1043: 8, 1056: 8, 1059: 1, 1076: 8, 1077: 8, 1114: 8, 1160: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1176: 8, 1177: 8, 1178: 8, 1179: 8, 1180: 8, 1181: 8, 1182: 8, 1183: 8, 1191: 8, 1192: 8, 1196: 8, 1197: 8, 1198: 8, 1199: 8, 1200: 8, 1201: 8, 1202: 8, 1203: 8, 1212: 8, 1227: 8, 1228: 8, 1235: 8, 1237: 8, 1263: 8, 1264: 8, 1279: 8, 1552: 8, 1553: 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, 1656: 8, 1664: 8, 1728: 8, 1745: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 }], CAR.LEXUS_IS: [ - # IS300 2018 + # IS200T 2017 TW { - 36: 8, 37: 8, 114: 5, 119: 6, 120: 4, 170: 8, 180: 8, 186: 4, 238: 4, 400: 6, 426: 6, 452: 8, 464: 8, 466: 8, 467: 5, 544: 4, 550: 8, 552: 4, 608: 8, 610: 5, 643: 7, 705: 8, 740: 5, 767: 4, 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: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 979: 2, 992: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1005: 2, 1008: 2, 1009: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1043: 8, 1044: 8, 1056: 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, 1182: 8, 1183: 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, 1235: 8, 1237: 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, 1590: 8, 1592: 8, 1593: 8, 1595: 8, 1599: 8, 1648: 8, 1666: 8, 1667: 8, 1728: 8, 1745: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 + 36: 8, 37: 8, 114: 5, 119: 6, 120: 4, 170: 8, 180: 8, 186: 4, 355: 5, 400: 6, 426: 6, 452: 8, 464: 8, 466: 8, 467: 5, 544: 4, 550: 8, 552: 4, 608: 8, 610: 5, 643: 7, 705: 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: 8, 922: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 979: 2, 992: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1005: 2, 1008: 2, 1009: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1043: 8, 1044: 8, 1056: 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, 1182: 8, 1183: 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, 1207: 8, 1208: 8, 1212: 8, 1227: 8, 1235: 8, 1237: 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, 1745: 8, 1779: 8 }, - # IS300H 2017 + # IS300 2018 { - 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, 767: 4, 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 + 36: 8, 37: 8, 114: 5, 119: 6, 120: 4, 170: 8, 180: 8, 186: 4, 238: 4, 400: 6, 426: 6, 452: 8, 464: 8, 466: 8, 467: 5, 544: 4, 550: 8, 552: 4, 608: 8, 610: 5, 643: 7, 705: 8, 740: 5, 767:4, 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: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 979: 2, 992: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1005: 2, 1008: 2, 1009: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1043: 8, 1044: 8, 1056: 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, 1182: 8, 1183: 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, 1235: 8, 1237: 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, 1590: 8, 1592: 8, 1593: 8, 1595: 8, 1599: 8, 1648: 8, 1666: 8, 1667: 8, 1728: 8, 1745: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 }], CAR.RAV4H_TSS2: [ #Hybrid Limited @@ -263,6 +319,10 @@ class CAR: ], CAR.LEXUS_CTH: [{ 36: 8, 37: 8, 170: 8, 180: 8, 288: 8, 426: 6, 452: 8, 466: 8, 467: 8, 548: 8, 552: 4, 560: 7, 581: 5, 608: 8, 610: 5, 643: 7, 713: 8, 740: 5, 800: 8, 810: 2, 832: 8, 835: 8, 836: 8, 849: 4, 869: 7, 870: 7, 871: 2, 897: 8, 900: 6, 902: 6, 905: 8, 911: 8, 916: 1, 921: 8, 933: 8, 944: 6, 945: 8, 950: 8, 951: 8, 953: 3, 955: 4, 956: 8, 979: 2, 992: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1017: 8, 1041: 8, 1042: 8, 1043: 8, 1056: 8, 1057: 8, 1059: 1, 1076: 8, 1077: 8, 1114: 8, 1116: 8, 1160: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1176: 8, 1177: 8, 1178: 8, 1179: 8, 1180: 8, 1181: 8, 1184: 8, 1185: 8, 1186: 8, 1190: 8, 1191: 8, 1192: 8, 1227: 8, 1235: 8, 1279: 8, 1552: 8, 1553: 8, 1554: 8, 1555: 8, 1556: 8, 1557: 8, 1558: 8, 1561: 8, 1562: 8, 1568: 8, 1569: 8, 1570: 8, 1571: 8, 1572: 8, 1575: 8, 1584: 8, 1589: 8, 1592: 8, 1593: 8, 1595: 8, 1664: 8, 1728: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 + }, + # Taiwan CT200h FP from CloudJ + { + 36: 8, 37: 8, 170: 8, 180: 8, 288: 8, 426: 6, 452: 8, 466: 8, 467: 8, 548: 8, 552: 4, 560: 7, 581: 5, 608: 8, 610: 5, 643: 7, 713: 8, 740: 5, 800: 8, 810: 2, 832: 8, 835: 8, 836: 8, 849: 4, 869: 7, 870: 7, 871: 2, 900: 6, 902: 6, 905: 8, 911: 8, 916: 1, 918: 7, 921: 8, 933: 8, 944: 6, 945: 8, 950: 8, 951: 8, 953: 3, 955: 4, 956: 8, 979: 2, 992: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1017: 8, 1041: 8, 1042: 8, 1043: 8, 1056: 8, 1057: 8, 1059: 1, 1076: 8, 1077: 8, 1112: 8, 1114: 8, 1116: 8, 1160: 8, 1161: 8, 1162: 8, 1163: 8, 1164: 8, 1165: 8, 1166: 8, 1167: 8, 1176: 8, 1177: 8, 1178: 8, 1179: 8, 1180: 8, 1181: 8, 1184: 8, 1185: 8, 1186: 8, 1190: 8, 1191: 8, 1192: 8, 1227: 8, 1235: 8, 1279: 8, 1552: 8, 1553: 8, 1554: 8, 1555: 8, 1556: 8, 1557: 8, 1558: 8, 1561: 8, 1562: 8, 1568: 8, 1569: 8, 1570: 8, 1571: 8, 1572: 8, 1575: 8, 1584: 8, 1589: 8, 1592: 8, 1593: 8, 1595: 8, 1664: 8, 1728: 8, 1779: 8 }], CAR.LEXUS_NXH: [{ 36: 8, 37: 8, 170: 8, 180: 8, 295: 8, 296: 8, 426: 6, 452: 8, 466: 8, 467: 8, 550: 8, 552: 4, 560: 7, 562: 6, 581: 5, 608: 8, 610: 5, 643: 7, 713: 8, 740: 5, 742: 8, 743: 8, 764: 8, 800: 8, 810: 2, 812: 3, 818: 8, 822: 8, 824: 8, 835: 8, 836: 8, 845: 5, 849: 4, 869: 7, 870: 7, 871: 2, 889: 8, 891: 8, 896: 8, 897: 8, 900: 6, 902: 6, 905: 8, 911: 8, 913: 8, 916: 3, 918: 8, 921: 8, 933: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 3, 955: 8, 956: 8, 979: 2, 987: 8, 992: 8, 998: 5, 999: 7, 1000: 8, 1001: 8, 1002: 8, 1006: 8, 1014: 8, 1017: 8, 1020: 8, 1041: 8, 1042: 8, 1043: 8, 1056: 8, 1057: 8, 1059: 1, 1076: 8, 1077: 8, 1082: 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, 1189: 8, 1190: 8, 1191: 8, 1192: 8, 1195: 8, 1196: 8, 1197: 8, 1198: 8, 1199: 8, 1206: 8, 1208: 8, 1212: 8, 1227: 8, 1228: 8, 1232: 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, 1568: 8, 1569: 8, 1570: 8, 1571: 8, 1572: 8, 1575: 8, 1584: 8, 1589: 8, 1592: 8, 1593: 8, 1595: 8, 1599: 8, 1656: 8, 1728: 8, 1745: 8, 1777: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 @@ -272,7 +332,18 @@ class CAR: }], CAR.PRIUS_TSS2: [{ 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, 614: 8, 643: 7, 658: 8, 713: 8, 740: 5, 742: 8, 743: 8, 764: 8, 765: 8, 800: 8, 810: 2, 814: 8, 824: 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, 896: 8, 898: 8, 900: 6, 902: 6, 905: 8, 918: 8, 921: 8, 933: 8, 934: 8, 935: 8, 944: 8, 945: 8, 950: 8, 951: 8, 953: 8, 955: 8, 956: 8, 971: 7, 975: 5, 993: 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, 1057: 8, 1059: 1, 1071: 8, 1076: 8, 1077: 8, 1082: 8, 1083: 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, 1175: 8, 1228: 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, 1593: 8, 1595: 8, 1649: 8, 1653: 8, 1654: 8, 1655: 8, 1775: 8, 1777: 8, 1779: 8, 1786: 8, 1787: 8, 1788: 8, 1789: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 - }] + }], + CAR.LEXUS_ISH: [{ + # IS300H 2017 + 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, 767: 4, 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.LEXUS_GSH: [{ + # GS450H 2017 + 36: 8, 37: 8, 38: 8, 42: 8, 44: 8, 170: 8, 180: 8, 295: 8, 296: 8, 426: 6, 452: 8, 466: 8, 548: 8, 550: 2, 552: 4, 560: 7, 581: 5, 608: 8, 610: 5, 643: 7, 713: 8, 740: 5, 744: 8, 800: 8, 810: 2, 812: 3, 832: 8, 836: 8, 845: 5, 849: 4, 864: 1, 869: 7, 870: 7, 871: 2, 896: 8, 897: 8, 900: 6, 902: 6, 905: 8, 911: 8, 913: 8, 916: 2, 917: 4, 918: 7, 919: 1, 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, 1014: 8, 1017: 8, 1041: 8, 1042: 8, 1043: 8, 1056: 8, 1057: 8, 1059: 1, 1112: 8, 1114: 8, 1116: 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, 1182: 8, 1183: 8, 1184: 8, 1185: 8, 1186: 8, 1187: 8, 1188: 8, 1189: 8, 1190: 8, 1191: 8, 1192: 8, 1193: 8, 1195: 8, 1196: 8, 1197: 8, 1198: 8, 1199: 8, 1200: 8, 1201: 8, 1206: 8, 1208: 8, 1226: 8, 1227: 8, 1235: 8, 1237: 8, 1250: 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, 1596: 8, 1597: 8, 1599: 8, 1664: 8, 1728: 8, 1779: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 + }], + CAR.LEXUS_NXT: [{ + 36: 8, 37: 8, 114: 5, 119: 6, 120: 4, 170: 8, 180: 8, 186: 4, 238: 4, 426: 6, 452: 8, 464: 8, 466: 7, 544: 4, 550: 8, 562: 4, 608: 8, 610: 5, 643: 7, 705: 8, 725: 2, 740: 5, 800: 8, 810: 2, 812: 3, 836: 8, 845: 5, 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: 8, 933: 8, 944: 8, 945: 8, 951: 8, 955: 8, 956: 8, 979: 2, 998: 5, 999: 7, 1000: 8, 1001: 8, 1008: 2, 1009: 8, 1014: 8, 1017: 8, 1041: 8, 1042: 8, 1044: 8, 1056: 8, 1059: 1, 1112: 8, 1114: 8, 1176: 8, 1177: 8, 1178: 8, 1179: 8, 1180: 8, 1181: 8, 1182: 8, 1183: 8, 1184: 8, 1185: 8, 1186: 8, 1189: 8, 1190: 8, 1191: 8, 1192: 8, 1195: 8, 1196: 8, 1197: 8, 1198: 8, 1199: 8, 1200: 8, 1201: 8, 1202: 8, 1203: 8, 1206: 8, 1208: 8, 1212: 8, 1227: 8, 1235: 8, 1237: 8, 1263: 8, 1552: 8, 1553: 8, 1555: 8, 1556: 8, 1557: 8, 1561: 8, 1568: 8, 1569: 8, 1570: 8, 1571: 8, 1572: 8, 1575: 8, 1584: 8, 1592: 8, 1593: 8, 1595: 8, 1599: 8, 1656: 8, 1728: 8, 1745: 8, 1904: 8, 1912: 8, 1990: 8, 1998: 8 + }], } # Don't use theses fingerprints for fingerprinting, they are still needed for ECU detection @@ -364,6 +435,7 @@ class CAR: }, CAR.CAMRYH: { (Ecu.engine, 0x700, None): [ + b'\x018966306N9000\x00\x00\x00\x00', # from a358063504 @wechat b'\x018966333N4300\x00\x00\x00\x00', b'\x018966333X0000\x00\x00\x00\x00', b'\x028966306B2100\x00\x00\x00\x00897CF3302002\x00\x00\x00\x00', @@ -392,6 +464,7 @@ class CAR: b'8821F0601200 ', b'8821F0601300 ', b'8821F0603400 ', + b'8821F0603600 ', # from a358063504 @wechat b'8821F0604200 ', b'8821F0606200 ', b'8821F0607200 ', @@ -413,6 +486,7 @@ class CAR: b'8821F0601200 ', b'8821F0601300 ', b'8821F0603400 ', + b'8821F0603600 ', # from a358063504 @wechat b'8821F0604200 ', b'8821F0606200 ', b'8821F0607200 ', @@ -439,6 +513,7 @@ class CAR: b'\x01896631017200\x00\x00\x00\x00', b'\x0189663F413100\x00\x00\x00\x00', b'\x0189663F414100\x00\x00\x00\x00', + b'\x0189663F421100\x00\x00\x00\x00', # 2018 China Toyota CHR ], (Ecu.dsu, 0x791, None): [ b'8821F0W01000 ', @@ -448,6 +523,7 @@ class CAR: b'8821FF405100 ', b'8821FF406000 ', b'8821F0W01100 ', + b'8821FF403100 ', # 2018 China Toyota CHR ], (Ecu.esp, 0x7b0, None): [ b'F152610020\x00\x00\x00\x00\x00\x00', @@ -457,10 +533,12 @@ class CAR: b'F1526F4073\x00\x00\x00\x00\x00\x00', b'F1526F4121\x00\x00\x00\x00\x00\x00', b'F1526F4122\x00\x00\x00\x00\x00\x00', + b'F1526F4100\x00\x00\x00\x00\x00\x00', # 2018 China Toyota CHR ], (Ecu.eps, 0x7a1, None): [ b'8965B10011\x00\x00\x00\x00\x00\x00', b'8965B10040\x00\x00\x00\x00\x00\x00', + b'8965B10020\x00\x00\x00\x00\x00\x00', # 2018 China Toyota CHR ], (Ecu.engine, 0x7e0, None): [ b'\x033F401100\x00\x00\x00\x00\x00\x00\x00\x00A0202000\x00\x00\x00\x00\x00\x00\x00\x00895231203102\x00\x00\x00\x00', @@ -475,11 +553,13 @@ class CAR: b'8821FF405100 ', b'8821FF406000 ', b'8821F0W01100 ', + b'8821FF403100 ', # 2018 China Toyota CHR ], (Ecu.fwdCamera, 0x750, 0x6d): [ b'8646FF401800 ', b'8646FF404000 ', b'8646FF406000 ', + b'8646FF403100 ', # 2018 China Toyota CHR ], }, CAR.CHRH: { @@ -613,6 +693,7 @@ class CAR: b'\x028966312Q4000\x00\x00\x00\x008966A4703000\x00\x00\x00\x00', b'\x038966312L7000\x00\x00\x00\x008966A4703000\x00\x00\x00\x00897CF1205001\x00\x00\x00\x00', b'\x038966312N1000\x00\x00\x00\x008966A4703000\x00\x00\x00\x00897CF1203001\x00\x00\x00\x00', + b'\x02896630ZN8000\x00\x00\x00\x008966A4703000\x00\x00\x00\x00', # Brazil 2020 Corolla Hybrid FPv2 from berno22 ], (Ecu.eps, 0x7a1, None): [ b'8965B12361\x00\x00\x00\x00\x00\x00', @@ -622,6 +703,7 @@ class CAR: b'\x018965B12500\x00\x00\x00\x00\x00\x00', b'\x018965B12520\x00\x00\x00\x00\x00\x00', b'\x018965B12530\x00\x00\x00\x00\x00\x00', + b'\x018965B12490\x00\x00\x00\x00\x00\x00', # Brazil 2020 Corolla Hybrid FPv2 from berno22 ], (Ecu.esp, 0x7b0, None): [ b'F152612590\x00\x00\x00\x00\x00\x00', @@ -633,6 +715,7 @@ class CAR: b'F152612A10\x00\x00\x00\x00\x00\x00', b'F152642540\x00\x00\x00\x00\x00\x00', b'F152612A00\x00\x00\x00\x00\x00\x00', + b'F152612820\x00\x00\x00\x00\x00\x00', # Brazil 2020 Corolla Hybrid FPv2 from berno22 ], (Ecu.fwdRadar, 0x750, 0xf): [ b'\x018821F3301100\x00\x00\x00\x00', @@ -1060,6 +1143,7 @@ class CAR: b'\x01896630852100\x00\x00\x00\x00', b'\x01896630859000\x00\x00\x00\x00', b'\x01896630860000\x00\x00\x00\x00', + b'\x01896630852000\x00\x00\x00\x00', # 2018 Toyota Sienna LTD fingerprint (v2) by ming-feng ], (Ecu.eps, 0x7a1, None): [ b'8965B45070\x00\x00\x00\x00\x00\x00', @@ -1322,8 +1406,11 @@ class CAR: CAR.LEXUS_NXH: dbc_dict('lexus_nx300h_2018_pt_generated', 'toyota_adas'), CAR.LEXUS_NX: dbc_dict('lexus_nx300_2018_pt_generated', 'toyota_adas'), CAR.PRIUS_TSS2: dbc_dict('toyota_nodsu_hybrid_pt_generated', 'toyota_tss2_adas'), + CAR.LEXUS_ISH: dbc_dict('lexus_is300h_2017_pt_generated', 'toyota_adas'), + CAR.LEXUS_GSH: dbc_dict('lexus_is300h_2017_pt_generated', 'toyota_adas'), + CAR.LEXUS_NXT: dbc_dict('lexus_nxt_2015_pt_generated', 'toyota_adas'), } -NO_DSU_CAR = set([CAR.CHR, CAR.CHRH, CAR.CAMRY, CAR.CAMRYH, CAR.RAV4_TSS2, CAR.COROLLA_TSS2, CAR.COROLLAH_TSS2, CAR.LEXUS_ES_TSS2, CAR.LEXUS_ESH_TSS2, CAR.RAV4H_TSS2, CAR.LEXUS_RX_TSS2, CAR.LEXUS_RXH_TSS2, CAR.HIGHLANDER_TSS2, CAR.HIGHLANDERH_TSS2]) +NO_DSU_CAR = set([CAR.CHR, CAR.CHRH, CAR.CAMRY, CAR.CAMRYH, CAR.RAV4_TSS2, CAR.COROLLA_TSS2, CAR.COROLLAH_TSS2, CAR.LEXUS_ES_TSS2, CAR.LEXUS_ESH_TSS2, CAR.RAV4H_TSS2, CAR.LEXUS_RX_TSS2, CAR.LEXUS_RXH_TSS2, CAR.HIGHLANDER_TSS2, CAR.HIGHLANDERH_TSS2, CAR.LEXUS_NXT]) TSS2_CAR = set([CAR.RAV4_TSS2, CAR.COROLLA_TSS2, CAR.COROLLAH_TSS2, CAR.LEXUS_ES_TSS2, CAR.LEXUS_ESH_TSS2, CAR.RAV4H_TSS2, CAR.LEXUS_RX_TSS2, CAR.LEXUS_RXH_TSS2, CAR.HIGHLANDER_TSS2, CAR.HIGHLANDERH_TSS2, CAR.PRIUS_TSS2]) -NO_STOP_TIMER_CAR = set([CAR.RAV4H, CAR.HIGHLANDERH, CAR.HIGHLANDER, CAR.RAV4_TSS2, CAR.COROLLA_TSS2, CAR.COROLLAH_TSS2, CAR.LEXUS_ES_TSS2, CAR.LEXUS_ESH_TSS2, CAR.SIENNA, CAR.RAV4H_TSS2, CAR.LEXUS_RX_TSS2, CAR.LEXUS_RXH_TSS2, CAR.HIGHLANDER_TSS2, CAR.HIGHLANDERH_TSS2, CAR.PRIUS_TSS2]) # no resume button press required +NO_STOP_TIMER_CAR = set([CAR.RAV4H, CAR.HIGHLANDERH, CAR.HIGHLANDER, CAR.RAV4_TSS2, CAR.COROLLA_TSS2, CAR.COROLLAH_TSS2, CAR.LEXUS_ES_TSS2, CAR.LEXUS_ESH_TSS2, CAR.SIENNA, CAR.RAV4H_TSS2, CAR.LEXUS_RX_TSS2, CAR.LEXUS_RXH_TSS2, CAR.HIGHLANDER_TSS2, CAR.HIGHLANDERH_TSS2, CAR.LEXUS_NXT, CAR.PRIUS_TSS2]) # no resume button press required diff --git a/selfdrive/car/volkswagen/carcontroller.py b/selfdrive/car/volkswagen/carcontroller.py index 5bb5dcc1094e05..b5beca18b942ea 100644 --- a/selfdrive/car/volkswagen/carcontroller.py +++ b/selfdrive/car/volkswagen/carcontroller.py @@ -1,8 +1,9 @@ from cereal import car from selfdrive.car import apply_std_steer_torque_limits from selfdrive.car.volkswagen import volkswagencan -from selfdrive.car.volkswagen.values import DBC, CANBUS, MQB_LDW_MESSAGES, BUTTON_STATES, CarControllerParams +from selfdrive.car.volkswagen.values import DBC, CANBUS, NWL, MQB_LDW_MESSAGES, BUTTON_STATES, CarControllerParams from opendbc.can.packer import CANPacker +from common.dp_common import common_controller_ctrl class CarController(): @@ -10,6 +11,16 @@ def __init__(self, dbc_name, CP, VM): self.apply_steer_last = 0 self.packer_pt = CANPacker(DBC[CP.carFingerprint]['pt']) + self.acc_bus = CANBUS.pt if CP.networkLocation == NWL.fwdCamera else CANBUS.cam + + if CP.safetyModel == car.CarParams.SafetyModel.volkswagen: + self.create_steering_control = volkswagencan.create_mqb_steering_control + self.create_acc_buttons_control = volkswagencan.create_mqb_acc_buttons_control + self.create_hud_control = volkswagencan.create_mqb_hud_control + elif CP.safetyModel == car.CarParams.SafetyModel.volkswagenPq: + self.create_steering_control = volkswagencan.create_pq_steering_control + self.create_acc_buttons_control = volkswagencan.create_pq_acc_buttons_control + self.create_hud_control = volkswagencan.create_pq_hud_control self.hcaSameTorqueCount = 0 self.hcaEnabledFrameCount = 0 @@ -20,7 +31,11 @@ def __init__(self, dbc_name, CP, VM): self.steer_rate_limited = False - def update(self, enabled, CS, frame, actuators, visual_alert, audible_alert, leftLaneVisible, rightLaneVisible): + # dp + self.last_blinker_on = False + self.blinker_end_frame = 0. + + def update(self, enabled, CS, frame, actuators, visual_alert, audible_alert, leftLaneVisible, rightLaneVisible, dragonconf): """ Controls thread """ P = CarControllerParams @@ -94,9 +109,24 @@ def update(self, enabled, CS, frame, actuators, visual_alert, audible_alert, lef hcaEnabled = False apply_steer = 0 + # dp + # timebomb + if CS.out.stopSteering: + apply_steer = 0 + blinker_on = CS.out.leftBlinker or CS.out.rightBlinker + if not enabled: + self.blinker_end_frame = 0 + if self.last_blinker_on and not blinker_on: + self.blinker_end_frame = frame + dragonconf.dpSignalOffDelay + apply_steer = common_controller_ctrl(enabled, + dragonconf, + blinker_on or frame < self.blinker_end_frame, + apply_steer, CS.out.vEgo) + self.last_blinker_on = blinker_on + self.apply_steer_last = apply_steer idx = (frame / P.HCA_STEP) % 16 - can_sends.append(volkswagencan.create_mqb_steering_control(self.packer_pt, CANBUS.pt, apply_steer, + can_sends.append(self.create_steering_control(self.packer_pt, CANBUS.pt, apply_steer, idx, hcaEnabled)) #-------------------------------------------------------------------------- @@ -117,9 +147,11 @@ def update(self, enabled, CS, frame, actuators, visual_alert, audible_alert, lef else: hud_alert = MQB_LDW_MESSAGES["none"] - can_sends.append(volkswagencan.create_mqb_hud_control(self.packer_pt, CANBUS.pt, hcaEnabled, + can_sends.append(self.create_hud_control(self.packer_pt, CANBUS.pt, hcaEnabled, CS.out.steeringPressed, hud_alert, leftLaneVisible, - rightLaneVisible)) + rightLaneVisible, CS.ldw_lane_warning_left, + CS.ldw_lane_warning_right, CS.ldw_side_dlc_tlc, + CS.ldw_dlc, CS.ldw_tlc)) #-------------------------------------------------------------------------- # # @@ -176,7 +208,7 @@ def update(self, enabled, CS, frame, actuators, visual_alert, audible_alert, lef if self.graMsgSentCount == 0: self.graMsgStartFramePrev = frame idx = (CS.graMsgBusCounter + 1) % 16 - can_sends.append(volkswagencan.create_mqb_acc_buttons_control(self.packer_pt, CANBUS.pt, self.graButtonStatesToSend, CS, idx)) + can_sends.append(self.create_acc_buttons_control(self.packer_pt, self.acc_bus, self.graButtonStatesToSend, CS, idx)) self.graMsgSentCount += 1 if self.graMsgSentCount >= P.GRA_VBP_COUNT: self.graButtonStatesToSend = None diff --git a/selfdrive/car/volkswagen/carstate.py b/selfdrive/car/volkswagen/carstate.py index a994130929ad15..f3bc649e5262aa 100644 --- a/selfdrive/car/volkswagen/carstate.py +++ b/selfdrive/car/volkswagen/carstate.py @@ -4,16 +4,33 @@ from selfdrive.car.interfaces import CarStateBase from opendbc.can.parser import CANParser from opendbc.can.can_define import CANDefine -from selfdrive.car.volkswagen.values import DBC, CANBUS, BUTTON_STATES, CarControllerParams +from selfdrive.car.volkswagen.values import DBC, CANBUS, NWL, TRANS, GEAR, BUTTON_STATES, CarControllerParams class CarState(CarStateBase): def __init__(self, CP): super().__init__(CP) can_define = CANDefine(DBC[CP.carFingerprint]['pt']) - self.shifter_values = can_define.dv["Getriebe_11"]['GE_Fahrstufe'] + + if CP.safetyModel == car.CarParams.SafetyModel.volkswagenPq: + # Configure for PQ35/PQ46/NMS network messaging + self.get_can_parser = self.get_pq_can_parser + self.get_cam_can_parser = self.get_pq_cam_can_parser + self.update = self.update_pq + if CP.transmissionType == TRANS.automatic: + self.shifter_values = can_define.dv["Getriebe_1"]['Waehlhebelposition__Getriebe_1_'] + else: + # Configure for MQB network messaging (default) + self.get_can_parser = self.get_mqb_can_parser + self.get_cam_can_parser = self.get_mqb_cam_can_parser + self.update = self.update_mqb + if CP.transmissionType == TRANS.automatic: + self.shifter_values = can_define.dv["Getriebe_11"]['GE_Fahrstufe'] + elif CP.transmissionType == TRANS.direct: + self.shifter_values = can_define.dv["EV_Gearshift"]['GearPosition'] + self.buttonStates = BUTTON_STATES.copy() - def update(self, pt_cp): + def update_mqb(self, pt_cp, cam_cp, acc_cp, trans_type): ret = car.CarState.new_message() # Update vehicle speed and acceleration from ABS wheel speeds. ret.wheelSpeeds.fl = pt_cp.vl["ESP_19"]['ESP_VL_Radgeschw_02'] * CV.KPH_TO_MS @@ -28,9 +45,9 @@ def update(self, pt_cp): # Update steering angle, rate, yaw rate, and driver input torque. VW send # the sign/direction in a separate signal so they must be recombined. - ret.steeringAngle = pt_cp.vl["LWI_01"]['LWI_Lenkradwinkel'] * (1, -1)[int(pt_cp.vl["LWI_01"]['LWI_VZ_Lenkradwinkel'])] - ret.steeringRate = pt_cp.vl["LWI_01"]['LWI_Lenkradw_Geschw'] * (1, -1)[int(pt_cp.vl["LWI_01"]['LWI_VZ_Lenkradwinkel'])] - ret.steeringTorque = pt_cp.vl["EPS_01"]['Driver_Strain'] * (1, -1)[int(pt_cp.vl["EPS_01"]['Driver_Strain_VZ'])] + ret.steeringAngle = pt_cp.vl["LH_EPS_03"]['EPS_Berechneter_LW'] * (1, -1)[int(pt_cp.vl["LH_EPS_03"]['EPS_VZ_BLW'])] + ret.steeringRate = pt_cp.vl["LWI_01"]['LWI_Lenkradw_Geschw'] * (1, -1)[int(pt_cp.vl["LWI_01"]['LWI_VZ_Lenkradw_Geschw'])] + ret.steeringTorque = pt_cp.vl["LH_EPS_03"]['EPS_Lenkmoment'] * (1, -1)[int(pt_cp.vl["LH_EPS_03"]['EPS_VZ_Lenkmoment'])] * 100.0 ret.steeringPressed = abs(ret.steeringTorque) > CarControllerParams.STEER_DRIVER_ALLOWANCE ret.yawRate = pt_cp.vl["ESP_02"]['ESP_Gierrate'] * (1, -1)[int(pt_cp.vl["ESP_02"]['ESP_VZ_Gierrate'])] * CV.DEG_TO_RAD @@ -41,9 +58,23 @@ def update(self, pt_cp): ret.brakePressed = bool(pt_cp.vl["ESP_05"]['ESP_Fahrer_bremst']) ret.brakeLights = bool(pt_cp.vl["ESP_05"]['ESP_Status_Bremsdruck']) + # Additional safety checks performed in CarInterface. + self.parkingBrakeSet = bool(pt_cp.vl["Kombi_01"]['KBI_Handbremse']) # FIXME: need to include an EPB check as well + ret.espDisabled = pt_cp.vl["ESP_21"]['ESP_Tastung_passiv'] != 0 + # Update gear and/or clutch position data. - can_gear_shifter = int(pt_cp.vl["Getriebe_11"]['GE_Fahrstufe']) - ret.gearShifter = self.parse_gear_shifter(self.shifter_values.get(can_gear_shifter, None)) + if trans_type == TRANS.automatic: + ret.gearShifter = self.parse_gear_shifter(self.shifter_values.get(pt_cp.vl["Getriebe_11"]['GE_Fahrstufe'], None)) + elif trans_type == TRANS.direct: + ret.gearShifter = self.parse_gear_shifter(self.shifter_values.get(pt_cp.vl["EV_Gearshift"]['GearPosition'], None)) + elif trans_type == TRANS.manual: + ret.clutchPressed = not pt_cp.vl["Motor_14"]['MO_Kuppl_schalter'] + reverse_light = bool(pt_cp.vl["Gateway_72"]['BCM1_Rueckfahrlicht_Schalter']) + # TODO: consider gating an OP minimum engage speed on whether the clutch is pressed, to prevent stalling + if reverse_light: + ret.gearShifter = GEAR.reverse + else: + ret.gearShifter = GEAR.drive # Update door and trunk/hatch lid open status. ret.doorOpen = any([pt_cp.vl["Gateway_72"]['ZV_FT_offen'], @@ -60,6 +91,29 @@ def update(self, pt_cp): # We use the speed preference for OP. self.displayMetricUnits = not pt_cp.vl["Einheiten_01"]["KBI_MFA_v_Einheit_02"] + # Stock FCW is considered active if a warning is displayed to the driver + # or the release bit for brake-jerk warning is set. Stock AEB considered + # active if the partial braking or target braking release bits are set. + # Ref: VW SSP 890253 "Volkswagen Driver Assistance Systems V2", "Front + # Assist with Braking: Golf Family" (applies to all MQB) + ret.stockFcw = bool(acc_cp.vl["ACC_10"]["AWV2_Freigabe"]) + ret.stockAeb = any([bool(acc_cp.vl["ACC_10"]["ANB_Teilbremsung_Freigabe"]), + bool(acc_cp.vl["ACC_10"]["ANB_Zielbremsung_Freigabe"])]) + + # Consume blind-spot radar info/warning LED states, if available + ret.leftBlindspot = any([bool(acc_cp.vl["SWA_01"]["SWA_Infostufe_SWA_li"]), + bool(acc_cp.vl["SWA_01"]["SWA_Warnung_SWA_li"])]) + ret.rightBlindspot = any([bool(acc_cp.vl["SWA_01"]["SWA_Infostufe_SWA_re"]), + bool(acc_cp.vl["SWA_01"]["SWA_Warnung_SWA_re"])]) + + # Consume SWA (Lane Change Assist) relevant info from factory LDW message + # to pass along to the blind spot radar controller + self.ldw_lane_warning_left = bool(cam_cp.vl["LDW_02"]["LDW_SW_Warnung_links"]) + self.ldw_lane_warning_right = bool(cam_cp.vl["LDW_02"]["LDW_SW_Warnung_rechts"]) + self.ldw_side_dlc_tlc = bool(cam_cp.vl["LDW_02"]["LDW_Seite_DLCTLC"]) + self.ldw_dlc = cam_cp.vl["LDW_02"]["LDW_DLC"] + self.ldw_tlc = cam_cp.vl["LDW_02"]["LDW_TLC"] + # Update ACC radar status. accStatus = pt_cp.vl["TSK_06"]['TSK_Status'] if accStatus == 2: @@ -77,7 +131,7 @@ def update(self, pt_cp): # Update ACC setpoint. When the setpoint is zero or there's an error, the # radar sends a set-speed of ~90.69 m/s / 203mph. - ret.cruiseState.speed = pt_cp.vl["ACC_02"]['SetSpeed'] + ret.cruiseState.speed = acc_cp.vl["ACC_02"]["ACC_Wunschgeschw"] * CV.KPH_TO_MS if ret.cruiseState.speed > 90: ret.cruiseState.speed = 0 @@ -98,27 +152,127 @@ def update(self, pt_cp): self.graTypHauptschalter = pt_cp.vl["GRA_ACC_01"]['GRA_Typ_Hauptschalter'] self.graButtonTypeInfo = pt_cp.vl["GRA_ACC_01"]['GRA_ButtonTypeInfo'] self.graTipStufe2 = pt_cp.vl["GRA_ACC_01"]['GRA_Tip_Stufe_2'] + self.graTyp468 = pt_cp.vl["GRA_ACC_01"]['GRA_Typ468'] # Pick up the GRA_ACC_01 CAN message counter so we can sync to it for # later cruise-control button spamming. self.graMsgBusCounter = pt_cp.vl["GRA_ACC_01"]['COUNTER'] # Check to make sure the electric power steering rack is configured to # accept and respond to HCA_01 messages and has not encountered a fault. - self.steeringFault = not pt_cp.vl["EPS_01"]["HCA_Ready"] + self.steeringFault = not pt_cp.vl["LH_EPS_03"]["EPS_HCA_Status"] + + return ret + + def update_pq(self, pt_cp, cam_cp, acc_cp, trans_type): + ret = car.CarState.new_message() + # Update vehicle speed and acceleration from ABS wheel speeds. + ret.wheelSpeeds.fl = pt_cp.vl["Bremse_3"]['Radgeschw__VL_4_1'] * CV.KPH_TO_MS + ret.wheelSpeeds.fr = pt_cp.vl["Bremse_3"]['Radgeschw__VR_4_1'] * CV.KPH_TO_MS + ret.wheelSpeeds.rl = pt_cp.vl["Bremse_3"]['Radgeschw__HL_4_1'] * CV.KPH_TO_MS + ret.wheelSpeeds.rr = pt_cp.vl["Bremse_3"]['Radgeschw__HR_4_1'] * CV.KPH_TO_MS + + ret.vEgoRaw = float(np.mean([ret.wheelSpeeds.fl, ret.wheelSpeeds.fr, ret.wheelSpeeds.rl, ret.wheelSpeeds.rr])) + ret.vEgo, ret.aEgo = self.update_speed_kf(ret.vEgoRaw) + + ret.standstill = ret.vEgoRaw < 0.1 + + # Update steering angle, rate, yaw rate, and driver input torque. VW send + # the sign/direction in a separate signal so they must be recombined. + ret.steeringAngle = pt_cp.vl["Lenkhilfe_3"]['LH3_BLW'] * (1, -1)[int(pt_cp.vl["Lenkhilfe_3"]['LH3_BLWSign'])] + ret.steeringRate = pt_cp.vl["Lenkwinkel_1"]['Lenkradwinkel_Geschwindigkeit'] * (1, -1)[int(pt_cp.vl["Lenkwinkel_1"]['Lenkradwinkel_Geschwindigkeit_S'])] + ret.steeringTorque = pt_cp.vl["Lenkhilfe_3"]['LH3_LM'] * (1, -1)[int(pt_cp.vl["Lenkhilfe_3"]['LH3_LMSign'])] + ret.steeringPressed = abs(ret.steeringTorque) > CarControllerParams.STEER_DRIVER_ALLOWANCE + ret.yawRate = pt_cp.vl["Bremse_5"]['Giergeschwindigkeit'] * (1, -1)[int(pt_cp.vl["Bremse_5"]['Vorzeichen_der_Giergeschwindigk'])] * CV.DEG_TO_RAD + + # Update gas, brakes, and gearshift. + ret.gas = pt_cp.vl["Motor_3"]['Fahrpedal_Rohsignal'] / 100.0 + ret.gasPressed = ret.gas > 0 + ret.brake = pt_cp.vl["Bremse_5"]['Bremsdruck'] / 250.0 # FIXME: this is pressure in Bar, not sure what OP expects + ret.brakePressed = bool(pt_cp.vl["Motor_2"]['Bremstestschalter']) + ret.brakeLights = bool(pt_cp.vl["Motor_2"]['Bremslichtschalter']) # Additional safety checks performed in CarInterface. - self.parkingBrakeSet = bool(pt_cp.vl["Kombi_01"]['KBI_Handbremse']) # FIXME: need to include an EPB check as well - ret.espDisabled = pt_cp.vl["ESP_21"]['ESP_Tastung_passiv'] != 0 + self.parkingBrakeSet = bool(pt_cp.vl["Kombi_1"]['Bremsinfo']) # FIXME: need to include an EPB check as well + ret.espDisabled = bool(pt_cp.vl["Bremse_1"]['ESP_Passiv_getastet']) + + # Update gear and/or clutch position data. + if trans_type == TRANS.automatic: + ret.gearShifter = self.parse_gear_shifter(self.shifter_values.get(pt_cp.vl["Getriebe_1"]['Waehlhebelposition__Getriebe_1_'], None)) + elif trans_type == TRANS.manual: + ret.clutchPressed = not pt_cp.vl["Motor_1"]['Kupplungsschalter'] + reverse_light = bool(pt_cp.vl["Gate_Komf_1"]['GK1_Rueckfahr']) + # TODO: verify this synthesis has the desired behavior. + # In particular, should we neutral disengage during normal gear changes? + # Also, what happens if we're rolling backwards with the clutch pressed + # in a gear other than reverse? + if reverse_light: + ret.gearShifter = GEAR.reverse + elif ret.standstill and self.parkingBrakeSet: + ret.gearShifter = GEAR.park + elif ret.clutchPressed: + ret.gearShifter = GEAR.neutral + else: + ret.gearShifter = GEAR.drive + + # Update door and trunk/hatch lid open status. + # TODO: need to locate signals for other three doors if possible + ret.doorOpen = bool(pt_cp.vl["Gate_Komf_1"]['GK1_Fa_Tuerkont']) + + # Update seatbelt fastened status. + ret.seatbeltUnlatched = not bool(pt_cp.vl["Airbag_1"]["Gurtschalter_Fahrer"]) + + # Update driver preference for metric. VW stores many different unit + # preferences, including separate units for for distance vs. speed. + # We use the speed preference for OP. + self.displayMetricUnits = not pt_cp.vl["Einheiten_1"]["MFA_v_Einheit_02"] + + # Update ACC radar status. + # FIXME: This is unfinished and not fully correct, need to improve further + ret.cruiseState.available = bool(pt_cp.vl["GRA_neu"]['Hauptschalter']) + ret.cruiseState.enabled = True if pt_cp.vl["Motor_2"]['GRA_Status'] in [1, 2] else False + + # Update ACC setpoint. When the setpoint reads as 255, the driver has not + # yet established an ACC setpoint, so treat it as zero. + ret.cruiseState.speed = acc_cp.vl["ACC_GRA_Anziege"]['ACA_V_Wunsch'] * CV.KPH_TO_MS + if ret.cruiseState.speed > 70: # 255 kph in m/s == no current setpoint + ret.cruiseState.speed = 0 + + # Update control button states for turn signals and ACC controls. + self.buttonStates["accelCruise"] = bool(pt_cp.vl["GRA_neu"]['Kurz_Tip_up']) or bool(pt_cp.vl["GRA_neu"]['Lang_Tip_up']) + self.buttonStates["decelCruise"] = bool(pt_cp.vl["GRA_neu"]['Kurz_Tip_down']) or bool(pt_cp.vl["GRA_neu"]['Lang_Tip_down']) + self.buttonStates["cancel"] = bool(pt_cp.vl["GRA_neu"]['Abbrechen']) + self.buttonStates["setCruise"] = bool(pt_cp.vl["GRA_neu"]['Setzen']) + self.buttonStates["resumeCruise"] = bool(pt_cp.vl["GRA_neu"]['Wiederaufnahme']) + self.buttonStates["gapAdjustCruise"] = bool(pt_cp.vl["GRA_neu"]['Zeitlueckenverstellung']) + ret.leftBlinker = bool(pt_cp.vl["Gate_Komf_1"]['GK1_Blinker_li']) + ret.rightBlinker = bool(pt_cp.vl["Gate_Komf_1"]['GK1_Blinker_re']) + + # Read ACC hardware button type configuration info that has to pass thru + # to the radar. Ends up being different for steering wheel buttons vs + # third stalk type controls. + # TODO: Check to see what info we need to passthru and spoof on PQ + self.graHauptschalter = pt_cp.vl["GRA_neu"]['Hauptschalter'] + self.graTypHauptschalter = False + self.graButtonTypeInfo = False + self.graTipStufe2 = False + # Pick up the GRA_ACC_01 CAN message counter so we can sync to it for + # later cruise-control button spamming. + # FIXME: will need msg counter and checksum algo to spoof GRA_neu + self.graMsgBusCounter = 0 + + # Check to make sure the electric power steering rack is configured to + # accept and respond to HCA_01 messages and has not encountered a fault. + self.steeringFault = pt_cp.vl["Lenkhilfe_2"]['LH2_Sta_HCA'] not in [3, 5] return ret @staticmethod - def get_can_parser(CP): + def get_mqb_can_parser(CP): # this function generates lists for signal, messages and initial values signals = [ # sig_name, sig_address, default - ("LWI_Lenkradwinkel", "LWI_01", 0), # Absolute steering angle - ("LWI_VZ_Lenkradwinkel", "LWI_01", 0), # Steering angle sign + ("EPS_Berechneter_LW", "LH_EPS_03", 0), # Absolute steering angle + ("EPS_VZ_BLW", "LH_EPS_03", 0), # Steering angle sign ("LWI_Lenkradw_Geschw", "LWI_01", 0), # Absolute steering rate ("LWI_VZ_Lenkradw_Geschw", "LWI_01", 0), # Steering rate sign ("ESP_VL_Radgeschw_02", "ESP_19", 0), # ABS wheel speed, front left @@ -134,25 +288,19 @@ def get_can_parser(CP): ("ZV_HD_offen", "Gateway_72", 0), # Trunk or hatch open ("BH_Blinker_li", "Gateway_72", 0), # Left turn signal on ("BH_Blinker_re", "Gateway_72", 0), # Right turn signal on - ("GE_Fahrstufe", "Getriebe_11", 0), # Auto trans gear selector position ("AB_Gurtschloss_FA", "Airbag_02", 0), # Seatbelt status, driver ("AB_Gurtschloss_BF", "Airbag_02", 0), # Seatbelt status, passenger ("ESP_Fahrer_bremst", "ESP_05", 0), # Brake pedal pressed ("ESP_Status_Bremsdruck", "ESP_05", 0), # Brakes applied ("ESP_Bremsdruck", "ESP_05", 0), # Brake pressure applied ("MO_Fahrpedalrohwert_01", "Motor_20", 0), # Accelerator pedal value - ("MO_Kuppl_schalter", "Motor_14", 0), # Clutch switch - ("Driver_Strain", "EPS_01", 0), # Absolute driver torque input - ("Driver_Strain_VZ", "EPS_01", 0), # Driver torque input sign - ("HCA_Ready", "EPS_01", 0), # Steering rack HCA support configured + ("EPS_Lenkmoment", "LH_EPS_03", 0), # Absolute driver torque input + ("EPS_VZ_Lenkmoment", "LH_EPS_03", 0), # Driver torque input sign + ("EPS_HCA_Status", "LH_EPS_03", 0), # Steering rack ready to process HCA commands ("ESP_Tastung_passiv", "ESP_21", 0), # Stability control disabled ("KBI_MFA_v_Einheit_02", "Einheiten_01", 0), # MPH vs KMH speed display ("KBI_Handbremse", "Kombi_01", 0), # Manual handbrake applied ("TSK_Status", "TSK_06", 0), # ACC engagement status from drivetrain coordinator - ("TSK_Fahrzeugmasse_02", "Motor_16", 0), # Estimated vehicle mass from drivetrain coordinator - ("ACC_Status_ACC", "ACC_06", 0), # ACC engagement status - ("ACC_Typ", "ACC_06", 0), # ACC type (follow to stop, stop&go) - ("SetSpeed", "ACC_02", 0), # ACC set speed ("GRA_Hauptschalter", "GRA_ACC_01", 0), # ACC button, on/off ("GRA_Abbrechen", "GRA_ACC_01", 0), # ACC button, cancel ("GRA_Tip_Setzen", "GRA_ACC_01", 0), # ACC button, set @@ -162,47 +310,185 @@ def get_can_parser(CP): ("GRA_Verstellung_Zeitluecke", "GRA_ACC_01", 0), # ACC button, time gap adj ("GRA_Typ_Hauptschalter", "GRA_ACC_01", 0), # ACC main button type ("GRA_Tip_Stufe_2", "GRA_ACC_01", 0), # unknown related to stalk type + ("GRA_Typ468", "GRA_ACC_01", 0), # Set/Resume button behavior as overloaded coast/accel?? ("GRA_ButtonTypeInfo", "GRA_ACC_01", 0), # unknown related to stalk type ("COUNTER", "GRA_ACC_01", 0), # GRA_ACC_01 CAN message counter ] checks = [ # sig_address, frequency - ("LWI_01", 100), # From J500 Steering Assist with integrated sensors - ("EPS_01", 100), # From J500 Steering Assist with integrated sensors - ("ESP_19", 100), # From J104 ABS/ESP controller - ("ESP_05", 50), # From J104 ABS/ESP controller - ("ESP_21", 50), # From J104 ABS/ESP controller - ("ACC_06", 50), # From J428 ACC radar control module - ("Motor_20", 50), # From J623 Engine control module - ("TSK_06", 50), # From J623 Engine control module - ("GRA_ACC_01", 33), # From J??? steering wheel control buttons - ("ACC_02", 17), # From J428 ACC radar control module - ("Getriebe_11", 20), # From J743 Auto transmission control module - ("Gateway_72", 10), # From J533 CAN gateway (aggregated data) - ("Motor_14", 10), # From J623 Engine control module - ("Airbag_02", 5), # From J234 Airbag control module - ("Kombi_01", 2), # From J285 Instrument cluster - ("Motor_16", 2), # From J623 Engine control module - ("Einheiten_01", 1), # From J??? not known if gateway, cluster, or BCM + ("LWI_01", 100), # From J500 Steering Assist with integrated sensors + ("LH_EPS_03", 100), # From J500 Steering Assist with integrated sensors + ("ESP_19", 100), # From J104 ABS/ESP controller + ("ESP_05", 50), # From J104 ABS/ESP controller + ("ESP_21", 50), # From J104 ABS/ESP controller + ("Motor_20", 50), # From J623 Engine control module + ("TSK_06", 50), # From J623 Engine control module + ("GRA_ACC_01", 33), # From J??? steering wheel control buttons + ("Gateway_72", 10), # From J533 CAN gateway (aggregated data) + ("Airbag_02", 5), # From J234 Airbag control module + ("Kombi_01", 2), # From J285 Instrument cluster + ("Einheiten_01", 1), # From J??? not known if gateway, cluster, or BCM ] + if CP.transmissionType == TRANS.automatic: + signals += [("GE_Fahrstufe", "Getriebe_11", 0)] # Auto trans gear selector position + checks += [("Getriebe_11", 20)] # From J743 Auto transmission control module + elif CP.transmissionType == TRANS.direct: + signals += [("GearPosition", "EV_Gearshift", 0)] # EV gear selector position + checks += [("EV_Gearshift", 10)] # From J??? unknown EV control module + elif CP.transmissionType == TRANS.manual: + signals += [("MO_Kuppl_schalter", "Motor_14", 0), # Clutch switch + ("BCM1_Rueckfahrlicht_Schalter", "Gateway_72", 0)] # Reverse light from BCM + checks += [("Motor_14", 10)] # From J623 Engine control module + + if CP.networkLocation == NWL.fwdCamera: + # Extended CAN devices other than the camera are here on CANBUS.pt + # FIXME: gate SWA_01 checks on module being detected, and reduce duplicate network location code + signals += [("AWV2_Priowarnung", "ACC_10", 0), # FCW related + ("AWV2_Freigabe", "ACC_10", 0), # FCW related + ("ANB_Teilbremsung_Freigabe", "ACC_10", 0), # AEB related + ("ANB_Zielbremsung_Freigabe", "ACC_10", 0), # AEB related + ("SWA_Infostufe_SWA_li", "SWA_01", 0), # Blindspot object info, left + ("SWA_Warnung_SWA_li", "SWA_01", 0), # Blindspot object warning, left + ("SWA_Infostufe_SWA_re", "SWA_01", 0), # Blindspot object info, right + ("SWA_Warnung_SWA_re", "SWA_01", 0), # Blindspot object warning, right + ("ACC_Wunschgeschw", "ACC_02", 0)] # ACC set speed + checks += [("ACC_10", 50), # From J428 ACC radar control module + # FIXME: SWA_01 should be checked when we have better detection of installed hardware + #("SWA_01", 20), # From J1086 Lane Change Assist module + ("ACC_02", 17)] # From J428 ACC radar control module + + checks = [] return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, CANBUS.pt) # A single signal is monitored from the camera CAN bus, and then ignored, # so the presence of CAN traffic can be verified with cam_cp.valid. @staticmethod - def get_cam_can_parser(CP): + def get_pq_can_parser(CP): + signals = [ + # sig_name, sig_address, default + ("LH3_BLW", "Lenkhilfe_3", 0), # Absolute steering angle + ("LH3_BLWSign", "Lenkhilfe_3", 0), # Steering angle sign + ("LH3_LM", "Lenkhilfe_3", 0), # Absolute driver torque input + ("LH3_LMSign", "Lenkhilfe_3", 0), # Driver torque input sign + ("LH2_Sta_HCA", "Lenkhilfe_2", 0), # Steering rack HCA status + ("Lenkradwinkel_Geschwindigkeit", "Lenkwinkel_1", 0), # Absolute steering rate + ("Lenkradwinkel_Geschwindigkeit_S", "Lenkwinkel_1", 0), # Steering rate sign + ("Radgeschw__VL_4_1", "Bremse_3", 0), # ABS wheel speed, front left + ("Radgeschw__VR_4_1", "Bremse_3", 0), # ABS wheel speed, front right + ("Radgeschw__HL_4_1", "Bremse_3", 0), # ABS wheel speed, rear left + ("Radgeschw__HR_4_1", "Bremse_3", 0), # ABS wheel speed, rear right + ("Giergeschwindigkeit", "Bremse_5", 0), # Absolute yaw rate + ("Vorzeichen_der_Giergeschwindigk", "Bremse_5", 0), # Yaw rate sign + ("GK1_Fa_Tuerkont", "Gate_Komf_1", 0), # Door open, driver + # TODO: locate passenger and rear door states + ("GK1_Blinker_li", "Gate_Komf_1", 0), # Left turn signal on + ("GK1_Blinker_re", "Gate_Komf_1", 0), # Right turn signal on + ("Gurtschalter_Fahrer", "Airbag_1", 0), # Seatbelt status, driver + ("Gurtschalter_Beifahrer", "Airbag_1", 0), # Seatbelt status, passenger + ("Bremstestschalter", "Motor_2", 0), # Brake pedal pressed (brake light test switch) + ("Bremslichtschalter", "Motor_2", 0), # Brakes applied (brake light switch) + ("Bremsdruck", "Bremse_5", 0), # Brake pressure applied + ("Vorzeichen_Bremsdruck", "Bremse_5", 0), # Brake pressure applied sign (???) + ("Fahrpedal_Rohsignal", "Motor_3", 0), # Accelerator pedal value + ("ESP_Passiv_getastet", "Bremse_1", 0), # Stability control disabled + ("MFA_v_Einheit_02", "Einheiten_1", 0), # MPH vs KMH speed display + ("Bremsinfo", "Kombi_1", 0), # Manual handbrake applied + ("GRA_Status", "Motor_2", 0), # ACC engagement status + ("Hauptschalter", "GRA_neu", 0), # ACC button, on/off + ("Abbrechen", "GRA_neu", 0), # ACC button, cancel + ("Setzen", "GRA_neu", 0), # ACC button, set + ("Lang_Tip_up", "GRA_neu", 0), # ACC button, increase or accel, long press + ("Lang_Tip_down", "GRA_neu", 0), # ACC button, decrease or decel, long press + ("Kurz_Tip_up", "GRA_neu", 0), # ACC button, increase or accel, short press + ("Kurz_Tip_down", "GRA_neu", 0), # ACC button, decrease or decel, short press + ("Wiederaufnahme", "GRA_neu", 0), # ACC button, resume + ("Zeitlueckenverstellung", "GRA_neu", 0), # ACC button, time gap adj + ] + + checks = [ + # sig_address, frequency + ("Bremse_3", 100), # From J104 ABS/ESP controller + ("Lenkhilfe_3", 100), # From J500 Steering Assist with integrated sensors + ("Lenkwinkel_1", 100), # From J500 Steering Assist with integrated sensors + ("Motor_3", 100), # From J623 Engine control module + ("Airbag_1", 50), # From J234 Airbag control module + ("Bremse_5", 50), # From J104 ABS/ESP controller + ("GRA_neu", 50), # From J??? steering wheel control buttons + ("Kombi_1", 50), # From J285 Instrument cluster + ("Motor_2", 50), # From J623 Engine control module + ("Lenkhilfe_2", 20), # From J500 Steering Assist with integrated sensors + ("Gate_Komf_1", 10), # From J533 CAN gateway + ("Einheiten_1", 1), # From J??? cluster or gateway + ] + + if CP.transmissionType == TRANS.automatic: + signals += [("Waehlhebelposition__Getriebe_1_", "Getriebe_1", 0)] # Auto trans gear selector position + checks += [("Getriebe_1", 100)] # From J743 Auto transmission control module + elif CP.transmissionType == TRANS.manual: + signals += [("Kupplungsschalter", "Motor_1", 0), # Clutch switch + ("GK1_Rueckfahr", "Gate_Komf_1", 0)] # Reverse light from BCM + checks += [("Motor_1", 100)] # From J623 Engine control module + + if CP.networkLocation == NWL.fwdCamera: + # The ACC radar is here on CANBUS.pt + signals += [("ACA_V_Wunsch", "ACC_GRA_Anziege", 0)] # ACC set speed + checks += [("ACC_GRA_Anziege", 25)] # From J428 ACC radar control module + + checks = [] + return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, CANBUS.pt) + + @staticmethod + def get_mqb_cam_can_parser(CP): + # FIXME: gate LDW_02 checks on module being detected signals = [ # sig_name, sig_address, default - ("Kombi_Lamp_Green", "LDW_02", 0), # Lane Assist status LED + ("LDW_SW_Warnung_links", "LDW_02", 0), # Blind spot in warning mode on left side due to lane departure + ("LDW_SW_Warnung_rechts", "LDW_02", 0), # Blind spot in warning mode on right side due to lane departure + ("LDW_Seite_DLCTLC", "LDW_02", 0), # Direction of most likely lane departure (left or right) + ("LDW_DLC", "LDW_02", 0), # Lane departure, distance to line crossing + ("LDW_TLC", "LDW_02", 0), # Lane departure, time to line crossing ] checks = [ # sig_address, frequency - ("LDW_02", 10) # From R242 Driver assistance camera + # FIXME: LDW_02 should be checked when we have better detection of installed hardware + #("LDW_02", 10), # From R242 Driver assistance camera ] + if CP.networkLocation == NWL.gateway: + # All Extended CAN devices are here on CANBUS.cam + # FIXME: gate SWA_01 checks on module being detected, and reduce duplicate network location code + signals += [("AWV2_Priowarnung", "ACC_10", 0), # FCW related + ("AWV2_Freigabe", "ACC_10", 0), # FCW related + ("ANB_Teilbremsung_Freigabe", "ACC_10", 0), # AEB related + ("ANB_Zielbremsung_Freigabe", "ACC_10", 0), # AEB related + ("SWA_Infostufe_SWA_li", "SWA_01", 0), # Blindspot object info, left + ("SWA_Warnung_SWA_li", "SWA_01", 0), # Blindspot object warning, left + ("SWA_Infostufe_SWA_re", "SWA_01", 0), # Blindspot object info, right + ("SWA_Warnung_SWA_re", "SWA_01", 0), # Blindspot object warning, right + ("ACC_Wunschgeschw", "ACC_02", 0)] # ACC set speed + checks += [("ACC_10", 50), # From J428 ACC radar control module + # FIXME: SWA_01 should be checked when we have better detection of installed hardware + #("SWA_01", 20), # From J1086 Lane Change Assist module + ("ACC_02", 17)] # From J428 ACC radar control module + + checks = [] + return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, CANBUS.cam) + + @staticmethod + def get_pq_cam_can_parser(CP): + # TODO: Need to monitor LKAS camera, if present, for TLC/DLC/warning signals for passthru to SWA + signals = [] + checks = [] + + if CP.networkLocation == NWL.gateway: + # The ACC radar is here on CANBUS.cam + signals += [("ACA_V_Wunsch", "ACC_GRA_Anziege", 0)] # ACC set speed + checks += [("ACC_GRA_Anziege", 25)] # From J428 ACC radar control module + + checks = [] return CANParser(DBC[CP.carFingerprint]['pt'], signals, checks, CANBUS.cam) diff --git a/selfdrive/car/volkswagen/interface.py b/selfdrive/car/volkswagen/interface.py index 252306322bf56c..2cda5f4a335610 100644 --- a/selfdrive/car/volkswagen/interface.py +++ b/selfdrive/car/volkswagen/interface.py @@ -1,9 +1,9 @@ from cereal import car -from selfdrive.car.volkswagen.values import CAR, BUTTON_STATES +from selfdrive.car.volkswagen.values import CAR, BUTTON_STATES, NWL, TRANS, GEAR, MQB_CARS, PQ_CARS from selfdrive.car import STD_CARGO_KG, scale_rot_inertia, scale_tire_stiffness, gen_empty_fingerprint from selfdrive.car.interfaces import CarInterfaceBase +from common.dp_common import common_interface_atl, common_interface_get_params_lqr -GEAR = car.CarState.GearShifter EventName = car.CarEvent.EventName class CarInterface(CarInterfaceBase): @@ -11,44 +11,88 @@ def __init__(self, CP, CarController, CarState): super().__init__(CP, CarController, CarState) self.displayMetricUnitsPrev = None + self.gas_pressed_prev = False + self.brake_pressed_prev = False + self.cruise_enabled_prev = False + self.low_speed_alert = False self.buttonStatesPrev = BUTTON_STATES.copy() + # Set up an alias to PT/CAM parser for ACC depending on its detected network location + self.cp_acc = self.cp if CP.networkLocation == NWL.fwdCamera else self.cp_cam + + # timebomb_counter mod + self.timebomb_counter = 0 + self.wheel_grabbed = False + self.timebomb_bypass_counter = 0 + @staticmethod def compute_gb(accel, speed): return float(accel) / 4.0 @staticmethod - def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): - ret = CarInterfaceBase.get_std_params(candidate, fingerprint) + def get_params(candidate, fingerprint=gen_empty_fingerprint(), has_relay=False, car_fw=None): + ret = CarInterfaceBase.get_std_params(candidate, fingerprint, has_relay) - # VW port is a community feature, since we don't own one to test - ret.communityFeature = True - - if candidate == CAR.GOLF: - # Set common MQB parameters that will apply globally - ret.carName = "volkswagen" - ret.radarOffCan = True + # Set global default parameters + ret.radarOffCan = True + ret.enableCamera = True # Stock camera detection doesn't apply to VW + ret.steerRateCost = 1.0 + ret.steerActuatorDelay = 0.05 # Hopefully all racks are similar here + ret.steerLimitTimer = 0.4 + + # Override these per-car as necessary + ret.lateralTuning.pid.kpBP = [0.] + ret.lateralTuning.pid.kiBP = [0.] + ret.lateralTuning.pid.kpV = [0.6] + ret.lateralTuning.pid.kiV = [0.2] + ret.lateralTuning.pid.kf = 0.00006 + + # PER-PLATFORM PARAMETERS - DO NOT EDIT HERE TO TUNE INDIVIDUAL VEHICLES + ret.carName = "volkswagen" + + if candidate in MQB_CARS: + # Configurations shared between all MQB vehicles ret.safetyModel = car.CarParams.SafetyModel.volkswagen - # Additional common MQB parameters that may be overridden per-vehicle - ret.steerRateCost = 1.0 - ret.steerActuatorDelay = 0.05 # Hopefully all MQB racks are similar here - ret.steerLimitTimer = 0.4 - - ret.lateralTuning.pid.kpBP = [0.] - ret.lateralTuning.pid.kiBP = [0.] - - ret.mass = 1500 + STD_CARGO_KG + # Determine installed network location and trans type from fingerprint + ret.networkLocation = NWL.fwdCamera if 0x122 in fingerprint[0] else NWL.gateway + if 0xAD in fingerprint[0]: # Getriebe_11 + ret.transmissionType = TRANS.automatic + elif 0x187 in fingerprint[0]: # EV_Gearshift + ret.transmissionType = TRANS.direct + else: # No trans at all + ret.transmissionType = TRANS.manual + + elif candidate in PQ_CARS: + # Configurations shared between all PQ35/PQ46/NMS vehicles + ret.safetyModel = car.CarParams.SafetyModel.volkswagenPq + + # Determine installed network location and trans type from fingerprint + ret.networkLocation = NWL.fwdCamera if 0x368 in fingerprint[0] else NWL.gateway + if 0x440 in fingerprint[0]: # Getriebe_1 + ret.transmissionType = TRANS.automatic + else: # No trans at all + ret.transmissionType = TRANS.manual + + # PER-VEHICLE PARAMETERS - EDIT HERE TO TUNE INDIVIDUAL VEHICLES + + if candidate == CAR.GENERICMQB: + # FIXME: Defaulting to VW Golf Mk7 as a baseline. + ret.mass = 1500 + STD_CARGO_KG # Average, varies on trim/package ret.wheelbase = 2.64 - ret.centerToFront = ret.wheelbase * 0.45 + ret.centerToFront = ret.wheelbase * 0.45 # Estimated ret.steerRatio = 15.6 - ret.lateralTuning.pid.kf = 0.00006 - ret.lateralTuning.pid.kpV = [0.6] - ret.lateralTuning.pid.kiV = [0.2] tire_stiffness_factor = 1.0 - ret.enableCamera = True # Stock camera detection doesn't apply to VW - ret.transmissionType = car.CarParams.TransmissionType.automatic + elif candidate == CAR.GENERICPQ: + ret.mass = 1375 + STD_CARGO_KG # Average, varies on trim/package + ret.wheelbase = 2.58 + ret.centerToFront = ret.wheelbase * 0.45 # Estimated + ret.steerRatio = 15.6 + tire_stiffness_factor = 1.0 + + # dp + ret = common_interface_get_params_lqr(ret) # TODO: get actual value, for now starting with reasonable value for # civic and scaling by mass and wheelbase @@ -62,7 +106,7 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None): return ret # returns a car.CarState - def update(self, c, can_strings): + def update(self, c, can_strings, dragonconf): buttonEvents = [] # Process the most recent CAN message traffic, and check for validity @@ -71,7 +115,14 @@ def update(self, c, can_strings): self.cp.update_strings(can_strings) self.cp_cam.update_strings(can_strings) - ret = self.CS.update(self.cp) + ret = self.CS.update(self.cp, self.cp_cam, self.cp_acc, self.CP.transmissionType) + ret.canValid = self.cp.can_valid # FIXME: Restore cp_cam valid check after proper LKAS camera detect + ret.steeringRateLimited = self.CC.steer_rate_limited if self.CC is not None else False + + # dp + self.dragonconf = dragonconf + ret.cruiseState.enabled = common_interface_atl(ret, dragonconf.dpAtl) + ret.canValid = self.cp.can_valid and self.cp_cam.can_valid ret.steeringRateLimited = self.CC.steer_rate_limited if self.CC is not None else False @@ -98,10 +149,44 @@ def update(self, c, can_strings): if self.CS.steeringFault: events.add(EventName.steerTempUnavailable) + # Engagement and longitudinal control using stock ACC. Make sure OP is + # disengaged if stock ACC is disengaged. + if not ret.cruiseState.enabled: + events.add(EventName.pcmDisable) + # Attempt OP engagement only on rising edge of stock ACC engagement. + elif not self.cruise_enabled_prev: + events.add(EventName.pcmEnable) + + if dragonconf.dpTimebombAssist: + ret.stopSteering = False + if ret.cruiseState.enabled: + self.timebomb_counter += 1 + else: + self.timebomb_counter = 0 + self.timebomb_bypass_counter = 0 + + if self.timebomb_counter >= 33000: # 330*100 time in seconds until counter threshold for timebombWarn alert + if not self.wheel_grabbed: + events.add(EventName.timebombWarn) + if self.wheel_grabbed or ret.steeringPressed: + self.wheel_grabbed = True + ret.stopSteering = True + self.timebomb_bypass_counter += 1 + if self.timebomb_bypass_counter >= 300: # 3*100 time alloted for bypass + self.wheel_grabbed = False + self.timebomb_counter = 0 + self.timebomb_bypass_counter = 0 + events.add(EventName.timebombBypassed) + else: + events.add(EventName.timebombBypassing) + ret.events = events.to_msg() ret.buttonEvents = buttonEvents # update previous car states + self.gas_pressed_prev = ret.gasPressed + self.brake_pressed_prev = ret.brakePressed + self.cruise_enabled_prev = ret.cruiseState.enabled self.displayMetricUnitsPrev = self.CS.displayMetricUnits self.buttonStatesPrev = self.CS.buttonStates.copy() @@ -113,6 +198,6 @@ def apply(self, c): c.hudControl.visualAlert, c.hudControl.audibleAlert, c.hudControl.leftLaneVisible, - c.hudControl.rightLaneVisible) + c.hudControl.rightLaneVisible, self.dragonconf) self.frame += 1 return can_sends diff --git a/selfdrive/car/volkswagen/values.py b/selfdrive/car/volkswagen/values.py index d99d7810261247..0e793c37a8a27e 100644 --- a/selfdrive/car/volkswagen/values.py +++ b/selfdrive/car/volkswagen/values.py @@ -1,6 +1,7 @@ # flake8: noqa from selfdrive.car import dbc_dict +from cereal import car class CarControllerParams: HCA_STEP = 2 # HCA_01 message frequency 50Hz @@ -24,6 +25,10 @@ class CANBUS: pt = 0 cam = 2 +NWL = car.CarParams.NetworkLocation +TRANS = car.CarParams.TransmissionType +GEAR = car.CarState.GearShifter + BUTTON_STATES = { "accelCruise": False, "decelCruise": False, @@ -46,15 +51,35 @@ class CANBUS: } class CAR: - GOLF = "VOLKSWAGEN GOLF" + GENERICMQB = "Generic Volkswagen MQB Platform Vehicle" + GENERICPQ = "Generic Volkswagen PQ35/PQ46/NMS Platform Vehicle" +# Mega-fingerprint used to identify any and all MQB platform vehicles. Specific +# make and model characteristics are looked up from the VIN later. +# Note: 1471:8 observed as 1471:4 on a 2019 Jetta, and we can't carry both in one FP, effect TBD FINGERPRINTS = { - CAR.GOLF: [ - # 76b83eb0245de90e|2019-10-21--17-40-42 - jyoung8607 car - {64: 8, 134: 8, 159: 8, 173: 8, 178: 8, 253: 8, 257: 8, 260: 8, 262: 8, 264: 8, 278: 8, 279: 8, 283: 8, 286: 8, 288: 8, 289: 8, 290: 8, 294: 8, 299: 8, 302: 8, 346: 8, 385: 8, 418: 8, 427: 8, 668: 8, 679: 8, 681: 8, 695: 8, 779: 8, 780: 8, 783: 8, 792: 8, 795: 8, 804: 8, 806: 8, 807: 8, 808: 8, 809: 8, 870: 8, 896: 8, 897: 8, 898: 8, 901: 8, 917: 8, 919: 8, 949: 8, 958: 8, 960: 4, 981: 8, 987: 8, 988: 8, 991: 8, 997: 8, 1000: 8, 1019: 8, 1120: 8, 1122: 8, 1123: 8, 1124: 8, 1153: 8, 1162: 8, 1175: 8, 1312: 8, 1385: 8, 1413: 8, 1440: 5, 1514: 8, 1515: 8, 1520: 8, 1600: 8, 1601: 8, 1603: 8, 1605: 8, 1624: 8, 1626: 8, 1629: 8, 1631: 8, 1646: 8, 1648: 8, 1712: 6, 1714: 8, 1716: 8, 1717: 8, 1719: 8, 1720: 8, 1721: 8 - }], + + CAR.GENERICMQB: [ + {178: 8, 1600: 8, 1601: 8, 1603: 8, 1605: 8, 695: 8, 1624: 8, 1626: 8, 1629: 8, 1631: 8, 1122: 8, 1123: 8, 1124: 8, 1646: 8, 1648: 8, 1153: 8, 134: 8, 1162: 8, 1175: 8, 159: 8, 795: 8, 679: 8, 681: 8, 173: 8, 1712: 6, 1714: 8, 1716: 8, 1717: 8, 1719: 8, 1720: 8, 1721: 8, 1312: 8, 806: 8, 253: 8, 1792: 8, 257: 8, 260: 8, 262: 8, 897: 8, 264: 8, 779: 8, 780: 8, 783: 8, 278: 8, 279: 8, 792: 8, 283: 8, 285: 8, 286: 8, 901: 8, 288: 8, 289: 8, 290: 8, 804: 8, 294: 8, 807: 8, 808: 8, 809: 8, 299: 8, 302: 8, 1351: 8, 346: 8, 870: 8, 1385: 8, 896: 8, 64: 8, 898: 8, 1413: 8, 917: 8, 919: 8, 927: 8, 1440: 5, 929: 8, 930: 8, 427: 8, 949: 8, 958: 8, 960: 4, 418: 8, 981: 8, 987: 8, 988: 8, 991: 8, 997: 8, 1000: 8, 1514: 8, 1515: 8, 1520: 8, 1019: 8, 385: 8, 668: 8, 1120: 8, 1438: 8, 1461: 8, 391: 8, 1511: 8, 1516: 8, 568: 8, 569: 8, 826: 8, 827: 8, 1156: 8, 1157: 8, 1158: 8, 1471: 8, 1635: 8, 376: 8, 295: 8, 791: 8, 799: 8, 838: 8, 389: 8, 840: 8, 841: 8, 842: 8, 843: 8, 844: 8, 845: 8, 314: 8, 787: 8, 788: 8, 789: 8, 802: 8, 839: 8, 1332: 8, 1872: 8, 1976: 8, 1977: 8, 1985: 8, 2015: 8, 592: 8, 593: 8, 594: 8, 595: 8, 596: 8, 684: 8, 572:8, 573: 8, 828: 8, 913: 8}, + # 2018 skoda kodiaq from @Gold + {64: 8, 134: 8, 159: 8, 173: 8, 178: 8, 253: 8, 257: 8, 260: 8, 262: 8, 278: 8, 279: 8, 283: 8, 286: 8, 288: 8, 289: 8, 290: 8, 294: 8, 299: 8, 302: 8, 346: 8, 385: 8, 418: 8, 427: 8, 573: 8, 668: 8, 679: 8, 681: 8, 684: 8, 695: 8, 779: 8, 780: 8, 783: 8, 792: 8, 795: 8, 804: 8, 806: 8, 807: 8, 808: 8, 809: 8, 828: 8, 870: 8, 896: 8, 897: 8, 898: 8, 901: 8, 917: 8, 919: 8, 949: 8, 958: 8, 960: 4, 981: 8, 987: 8, 988: 8, 991: 8, 997: 8, 1000: 8, 1019: 8, 1120: 8, 1153: 8, 1162: 8, 1175: 8, 1312: 8, 1385: 8, 1413: 8, 1440: 5, 1514: 8, 1515: 8, 1520: 8, 1529: 8, 1600: 8, 1601: 8, 1603: 8, 1605: 8, 1624: 8, 1626: 8, 1629: 8, 1631: 8, 1646: 8, 1648: 8, 1712: 6, 1714: 8, 1716: 8, 1717: 8, 1719: 8, 1720: 8, 1721: 8 } + ], + + CAR.GENERICPQ: [ + # kamold, Edgy, austinc3030, Roy_001 + {80: 4, 194: 8, 208: 6, 210: 5, 294: 8, 416: 8, 428: 8, 640: 8, 648: 8, 800: 8, 835: 3, 870: 8, 872: 8, 878: 8, 896: 8, 906: 4, 912: 8, 914: 8, 919: 8, 928: 8, 978: 7, 1056: 8, 1088: 8, 1152: 8, 1175: 8, 1184: 8, 1192: 8, 1312: 8, 1386: 8, 1392: 5, 1394: 1, 1408: 8, 1440: 8, 1463: 8, 1470: 5, 1472: 8, 1488: 8, 1490: 8, 1500: 8, 1550: 2, 1651: 3, 1652: 8, 1654: 2, 1658: 4, 1691: 3, 1736: 2, 1757: 8, 1824: 7, 1845: 7, 2000: 8, 1420: 8}, + # cd (powertrain CAN direct) + {16: 7, 17: 7, 80: 4, 174: 8, 194: 8, 208: 6, 416: 8, 428: 8, 640: 8, 648: 8, 672: 8, 800: 8, 896: 8, 906: 4, 912: 8, 914: 8, 915: 8, 919: 8, 928: 8, 946: 8, 976: 6, 978: 7, 1056: 8, 1152: 8, 1160: 8, 1162: 8, 1164: 8, 1175: 8, 1184: 8, 1192: 8, 1306: 8, 1312: 8, 1344: 8, 1360: 8, 1386: 8, 1392: 5, 1394: 1, 1408: 8, 1416: 8, 1420: 8, 1423: 8, 1440: 8, 1463: 8, 1488: 8, 1490: 8, 1494: 2, 1500: 8, 1504: 8, 1523: 8, 1527: 4, 1654: 2, 1658: 2, 1754: 8, 1824: 7, 1827: 7, 2000: 8}, + {80: 4, 194: 8, 208: 6, 210: 5, 416: 8, 428: 8, 640: 8, 648: 8, 695: 8, 800: 8, 835: 3, 870: 8, 872: 8, 878: 8, 896: 8, 906: 4, 912: 8, 914: 8, 928: 8, 954: 8, 978: 7, 1056: 8, 1088: 8, 1152: 8, 1175: 8, 1184: 8, 1192: 8, 1312: 8, 1386: 8, 1392: 5, 1394: 1, 1408: 8, 1440: 8, 1463: 8, 1470: 5, 1472: 8, 1488: 8, 1490: 8, 1500: 8, 1550: 2, 1650: 8, 1651: 4, 1652: 8, 1691: 4, 1757: 3, 1824: 7, 1845: 7, 2000: 8}, + {80: 4, 194: 8, 208: 6, 210: 5, 416: 8, 428: 8, 640: 8, 648: 8, 695: 8, 800: 8, 835: 3, 870: 8, 872: 8, 878: 8, 896: 8, 906: 4, 912: 8, 914: 8, 928: 8, 954: 8, 978: 7, 1056: 8, 1088: 8, 1152: 8, 1175: 8, 1184: 8, 1192: 8, 1312: 8, 1386: 8, 1392: 5, 1394: 1, 1408: 8, 1440: 8, 1463: 8, 1470: 5, 1472: 8, 1488: 8, 1490: 8, 1500: 8, 1550: 2, 1650: 5, 1651: 3, 1652: 8, 1691: 3, 1736: 2, 1757: 8, 1824: 7, 1845: 7, 2000: 8}, + {80: 4, 194: 8, 208: 6, 210: 5, 416: 8, 428: 8, 640: 8, 648: 8, 695: 8, 800: 8, 835: 3, 870: 8, 872: 8, 878: 8, 896: 8, 906: 4, 912: 8, 914: 8, 928: 8, 954: 8, 978: 7, 1056: 8, 1088: 8, 1152: 8, 1175: 8, 1184: 8, 1192: 8, 1312: 8, 1386: 8, 1392: 5, 1394: 1, 1408: 8, 1440: 8, 1463: 8, 1470: 5, 1472: 8, 1488: 8, 1490: 8, 1500: 8, 1550: 2, 1650: 4, 1651: 3, 1652: 8, 1691: 2, 1736: 2, 1757: 3, 1824: 7, 1845: 7, 2000: 8}, + ], } +MQB_CARS = [CAR.GENERICMQB] +PQ_CARS = [CAR.GENERICPQ] + DBC = { - CAR.GOLF: dbc_dict('vw_mqb_2010', None), + CAR.GENERICMQB: dbc_dict('vw_mqb_2010', None), + CAR.GENERICPQ: dbc_dict('vw_golf_mk4', None), } diff --git a/selfdrive/car/volkswagen/volkswagencan.py b/selfdrive/car/volkswagen/volkswagencan.py index 3cd47a0957ee12..e9f5e4fb848db2 100644 --- a/selfdrive/car/volkswagen/volkswagencan.py +++ b/selfdrive/car/volkswagen/volkswagencan.py @@ -1,36 +1,39 @@ -# CAN controls for MQB platform Volkswagen, Audi, Skoda and SEAT. -# PQ35/PQ46/NMS, and any future MLB, to come later. +# ----------------------------------------------------------------------- # +# # +# CAN message packing for MQB vehicles # +# # +# ----------------------------------------------------------------------- # def create_mqb_steering_control(packer, bus, apply_steer, idx, lkas_enabled): values = { - "SET_ME_0X3": 0x3, - "Assist_Torque": abs(apply_steer), - "Assist_Requested": lkas_enabled, - "Assist_VZ": 1 if apply_steer < 0 else 0, - "HCA_Available": 1, - "HCA_Standby": not lkas_enabled, - "HCA_Active": lkas_enabled, - "SET_ME_0XFE": 0xFE, - "SET_ME_0X07": 0x07, + "HCA_System_Status": 0x3, + "LM_Offset": abs(apply_steer), + "LM_Offset_Valid": lkas_enabled, + "LM_Offsign": 1 if apply_steer < 0 else 0, + "HCA_Control_Status": 0x5 if lkas_enabled else 0x3, } return packer.make_can_msg("HCA_01", bus, values, idx) -def create_mqb_hud_control(packer, bus, hca_enabled, steering_pressed, hud_alert, leftLaneVisible, rightLaneVisible): - +def create_mqb_hud_control(packer, bus, hca_enabled, steering_pressed, hud_alert, left_lane_visible, right_lane_visible, + ldw_lane_warning_left, ldw_lane_warning_right, ldw_side_dlc_tlc, ldw_dlc, ldw_tlc): if hca_enabled: - leftlanehud = 3 if leftLaneVisible else 1 - rightlanehud = 3 if rightLaneVisible else 1 + left_lane_hud = 3 if left_lane_visible else 1 + right_lane_hud = 3 if right_lane_visible else 1 else: - leftlanehud = 2 if leftLaneVisible else 1 - rightlanehud = 2 if rightLaneVisible else 1 + left_lane_hud = 2 if left_lane_visible else 1 + right_lane_hud = 2 if right_lane_visible else 1 values = { - "LDW_Unknown": 2, # FIXME: possible speed or attention relationship - "Kombi_Lamp_Orange": 1 if hca_enabled and steering_pressed else 0, - "Kombi_Lamp_Green": 1 if hca_enabled and not steering_pressed else 0, - "Left_Lane_Status": leftlanehud, - "Right_Lane_Status": rightlanehud, - "Alert_Message": hud_alert, + "LDW_Status_LED_gelb": 1 if hca_enabled and steering_pressed else 0, + "LDW_Status_LED_gruen": 1 if hca_enabled and not steering_pressed else 0, + "LDW_SW_Info_links": left_lane_hud, + "LDW_SW_Info_rechts": right_lane_hud, + "LDW_Texte": hud_alert, + "LDW_SW_Warnung_links": ldw_lane_warning_left, + "LDW_SW_Warnung_rechts": ldw_lane_warning_right, + "LDW_Seite_DLCTLC": ldw_side_dlc_tlc, + "LDW_DLC": ldw_dlc, + "LDW_TLC": ldw_tlc } return packer.make_can_msg("LDW_02", bus, values) @@ -46,6 +49,49 @@ def create_mqb_acc_buttons_control(packer, bus, buttonStatesToSend, CS, idx): "GRA_Typ_Hauptschalter": CS.graTypHauptschalter, "GRA_Codierung": 2, "GRA_Tip_Stufe_2": CS.graTipStufe2, + "GRA_Typ468": CS.graTyp468, "GRA_ButtonTypeInfo": CS.graButtonTypeInfo } return packer.make_can_msg("GRA_ACC_01", bus, values, idx) + +# ----------------------------------------------------------------------- # +# # +# CAN message packing for PQ35/PQ46/NMS vehicles # +# # +# ----------------------------------------------------------------------- # + +def create_pq_steering_control(packer, bus, apply_steer, idx, lkas_enabled): + values = { + "HCA_Zaehler": idx, + "LM_Offset": abs(apply_steer), + "LM_OffSign": 1 if apply_steer < 0 else 0, + "HCA_Status": 5 if (lkas_enabled and apply_steer != 0) else 3, + "Vib_Freq": 16, + } + + dat = packer.make_can_msg("HCA_1", bus, values)[2] + values["HCA_Checksumme"] = dat[1] ^ dat[2] ^ dat[3] ^ dat[4] + return packer.make_can_msg("HCA_1", bus, values) + +def create_pq_hud_control(packer, bus, hca_enabled, steering_pressed, hud_alert, left_lane_visible, right_lane_visible, + ldw_lane_warning_left, ldw_lane_warning_right, ldw_side_dlc_tlc, ldw_dlc, ldw_tlc): + if hca_enabled: + left_lane_hud = 3 if left_lane_visible else 1 + right_lane_hud = 3 if right_lane_visible else 1 + else: + left_lane_hud = 2 if left_lane_visible else 1 + right_lane_hud = 2 if right_lane_visible else 1 + + values = { + "Right_Lane_Status": right_lane_hud, + "Left_Lane_Status": left_lane_hud, + "SET_ME_X1": 1, + "Kombi_Lamp_Orange": 1 if hca_enabled and steering_pressed else 0, + "Kombi_Lamp_Green": 1 if hca_enabled and not steering_pressed else 0, + } + return packer.make_can_msg("LDW_1", bus, values) + +pass + +def create_pq_acc_buttons_control(packer, bus, buttonStatesToSend, CS, idx): + pass diff --git a/selfdrive/common/framebuffer.cc b/selfdrive/common/framebuffer.cc index 30ef7ae8ea2319..a88305c06a7774 100644 --- a/selfdrive/common/framebuffer.cc +++ b/selfdrive/common/framebuffer.cc @@ -37,6 +37,17 @@ extern "C" void framebuffer_swap(FramebufferState *s) { assert(glGetError() == GL_NO_ERROR); } +extern "C" void framebuffer_swap_layer(FramebufferState *s, int32_t layer) { + status_t status; + SurfaceComposerClient::openGlobalTransaction(); + status = s->control->setLayer(layer); + SurfaceComposerClient::closeGlobalTransaction(); + assert(status == 0); + + s->s = s->control->getSurface(); + assert(s->s != NULL); +} + extern "C" bool set_brightness(int brightness) { char bright[64]; snprintf(bright, sizeof(bright), "%d", brightness); diff --git a/selfdrive/common/framebuffer.h b/selfdrive/common/framebuffer.h index 45053bbb14a5bb..8a96e097c329d0 100644 --- a/selfdrive/common/framebuffer.h +++ b/selfdrive/common/framebuffer.h @@ -12,6 +12,7 @@ FramebufferState* framebuffer_init( void framebuffer_set_power(FramebufferState *s, int mode); void framebuffer_swap(FramebufferState *s); +void framebuffer_swap_layer(FramebufferState *s, int32_t layer); bool set_brightness(int brightness); /* Display power modes */ diff --git a/selfdrive/controls/controlsd.py b/selfdrive/controls/controlsd.py index 22e63a798b598a..dcb195ac797ed0 100755 --- a/selfdrive/controls/controlsd.py +++ b/selfdrive/controls/controlsd.py @@ -2,7 +2,7 @@ import os from cereal import car, log from common.hardware import HARDWARE -from common.numpy_fast import clip +from common.numpy_fast import clip, interp from common.realtime import sec_since_boot, config_realtime_process, Priority, Ratekeeper, DT_CTRL from common.profiler import Profiler from common.params import Params, put_nonblocking @@ -39,11 +39,17 @@ LaneChangeDirection = log.PathPlan.LaneChangeDirection EventName = car.CarEvent.EventName +LEAD_AWAY_STATE_OFF = 0 +LEAD_AWAY_STATE_ON = 1 +LEAD_AWAY_STATE_ALERTED = 2 + class Controls: def __init__(self, sm=None, pm=None, can_sock=None): config_realtime_process(3, Priority.CTRL_HIGH) + params = Params() + # Setup sockets self.pm = pm if self.pm is None: @@ -52,8 +58,10 @@ def __init__(self, sm=None, pm=None, can_sock=None): self.sm = sm if self.sm is None: - self.sm = messaging.SubMaster(['thermal', 'health', 'model', 'liveCalibration', 'frontFrame', - 'dMonitoringState', 'plan', 'pathPlan', 'liveLocationKalman']) + socks = ['thermal', 'health', 'model', 'liveCalibration', 'radarState', 'frontFrame', + 'dMonitoringState', 'plan', 'pathPlan', 'liveLocationKalman', 'dragonConf'] + ignore_alive = None if params.get('dp_driver_monitor') == b'1' else ['dMonitoringState'] + self.sm = messaging.SubMaster(socks, ignore_alive=ignore_alive) self.can_sock = can_sock if can_sock is None: @@ -61,16 +69,18 @@ def __init__(self, sm=None, pm=None, can_sock=None): self.can_sock = messaging.sub_sock('can', timeout=can_timeout) # wait for one health and one CAN packet + hw_type = messaging.recv_one(self.sm.sock['health']).health.hwType + has_relay = hw_type in [HwType.blackPanda, HwType.uno, HwType.dos] print("Waiting for CAN messages...") get_one_can(self.can_sock) - self.CI, self.CP = get_car(self.can_sock, self.pm.sock['sendcan']) + self.CI, self.CP = get_car(self.can_sock, self.pm.sock['sendcan'], has_relay) # read params params = Params() self.is_metric = params.get("IsMetric", encoding='utf8') == "1" self.is_ldw_enabled = params.get("IsLdwEnabled", encoding='utf8') == "1" - internet_needed = (params.get("Offroad_ConnectivityNeeded", encoding='utf8') is not None) and (params.get("DisableUpdates") != b"1") + internet_needed = False #(params.get("Offroad_ConnectivityNeeded", encoding='utf8') is not None) and (params.get("DisableUpdates") != b"1") community_feature_toggle = params.get("CommunityFeaturesToggle", encoding='utf8') == "1" openpilot_enabled_toggle = params.get("OpenpilotEnabledToggle", encoding='utf8') == "1" passive = params.get("Passive", encoding='utf8') == "1" or \ @@ -100,12 +110,14 @@ def __init__(self, sm=None, pm=None, can_sock=None): self.LoC = LongControl(self.CP, self.CI.compute_gb) self.VM = VehicleModel(self.CP) - if self.CP.lateralTuning.which() == 'pid': - self.LaC = LatControlPID(self.CP) + if params.get('dp_lqr') == b'1': + self.LaC = LatControlLQR(self.CP) elif self.CP.lateralTuning.which() == 'indi': self.LaC = LatControlINDI(self.CP) elif self.CP.lateralTuning.which() == 'lqr': self.LaC = LatControlLQR(self.CP) + elif self.CP.lateralTuning.which() == 'pid': + self.LaC = LatControlPID(self.CP) self.state = State.disabled self.enabled = False @@ -131,19 +143,34 @@ def __init__(self, sm=None, pm=None, can_sock=None): self.startup_event = get_startup_event(car_recognized, controller_available) - if not sounds_available: - self.events.add(EventName.soundsUnavailable, static=True) - if internet_needed: - self.events.add(EventName.internetConnectivityNeeded, static=True) + # if not sounds_available: + # self.events.add(EventName.soundsUnavailable, static=True) + # if internet_needed: + # self.events.add(EventName.internetConnectivityNeeded, static=True) if community_feature_disallowed: self.events.add(EventName.communityFeatureDisallowed, static=True) if not car_recognized: self.events.add(EventName.carUnrecognized, static=True) + # if hw_type == HwType.whitePanda: + # self.events.add(EventName.whitePandaUnsupportedDEPRECATED, static=True) # controlsd is driven by can recv, expected at 100Hz self.rk = Ratekeeper(100, print_delay_threshold=None) self.prof = Profiler(False) # off by default + # dp + self.dp_lead_count = 0 + self.dp_camera_offset = CAMERA_OFFSET * 100 + self.sm['dragonConf'].dpAtl = False + self.sm['dragonConf'].dpCameraOffset = 6 + + self.dp_lead_away_alert = params.get('dp_lead_car_away_alert') == b'1' + self.dp_lead_away_min_speed = 80 # kph + self.dp_lead_away_alert_lead_count = 0 + self.dp_lead_away_alert_nolead_count = 0 + + self.dp_lead_away_state = LEAD_AWAY_STATE_OFF + def update_events(self, CS): """Compute carEvents from carState""" @@ -192,15 +219,15 @@ def update_events(self, CS): self.events.add(EventName.laneChangeBlocked) else: if direction == LaneChangeDirection.left: - self.events.add(EventName.preLaneChangeLeft) + self.events.add(EventName.preLaneChangeLeftALC if self.sm['pathPlan'].dpALCAllowed else EventName.preLaneChangeLeft) else: - self.events.add(EventName.preLaneChangeRight) + self.events.add(EventName.preLaneChangeRightALC if self.sm['pathPlan'].dpALCAllowed else EventName.preLaneChangeRight) elif self.sm['pathPlan'].laneChangeState in [LaneChangeState.laneChangeStarting, LaneChangeState.laneChangeFinishing]: self.events.add(EventName.laneChange) if self.can_rcv_error or (not CS.canValid and self.sm.frame > 5 / DT_CTRL): - self.events.add(EventName.canError) + self.events.add(EventName.pcmDisable if self.sm['dragonConf'].dpAtl else EventName.canError) if (self.sm['health'].safetyModel != self.CP.safetyModel and self.sm.frame > 2 / DT_CTRL) or \ self.mismatch_counter >= 200: self.events.add(EventName.controlsMismatch) @@ -210,14 +237,14 @@ def update_events(self, CS): elif not self.sm.all_alive_and_valid(): self.events.add(EventName.commIssue) if not self.sm['pathPlan'].mpcSolutionValid: - self.events.add(EventName.plannerError) - if not self.sm['liveLocationKalman'].sensorsOK and not NOSENSOR: - if self.sm.frame > 5 / DT_CTRL: # Give locationd some time to receive all the inputs - self.events.add(EventName.sensorDataInvalid) - if not self.sm['liveLocationKalman'].gpsOK and (self.distance_traveled > 1000): - # Not show in first 1 km to allow for driving out of garage. This event shows after 5 minutes - if not (SIMULATION or NOSENSOR): # TODO: send GPS in carla - self.events.add(EventName.noGps) + self.events.add(EventName.steerTempUnavailable if self.sm['dragonConf'].dpAtl else EventName.plannerError) + # if not self.sm['liveLocationKalman'].sensorsOK and not NOSENSOR: + # if self.sm.frame > 5 / DT_CTRL: # Give locationd some time to receive all the inputs + # self.events.add(EventName.sensorDataInvalid) + # if not self.sm['liveLocationKalman'].gpsOK and (self.distance_traveled > 1000): + # # Not show in first 1 km to allow for driving out of garage. This event shows after 5 minutes + # if not (SIMULATION or NOSENSOR): # TODO: send GPS in carla + # self.events.add(EventName.noGps) if not self.sm['pathPlan'].paramsValid: self.events.add(EventName.vehicleModelInvalid) if not self.sm['liveLocationKalman'].posenetOK: @@ -239,16 +266,51 @@ def update_events(self, CS): self.events.add(EventName.modeldLagging) # Only allow engagement with brake pressed when stopped behind another stopped car - if CS.brakePressed and self.sm['plan'].vTargetFuture >= STARTING_TARGET_SPEED \ + if not self.sm['dragonConf'].dpAtl and CS.brakePressed and self.sm['plan'].vTargetFuture >= STARTING_TARGET_SPEED \ and self.CP.openpilotLongitudinalControl and CS.vEgo < 0.3: self.events.add(EventName.noTarget) + if self.dp_lead_away_alert: + current_speed = CS.vEgo * 3.6 + + if CS.brakePressed or current_speed < self.dp_lead_away_min_speed or self.dp_lead_away_state == LEAD_AWAY_STATE_ALERTED: + self.dp_lead_away_alert_lead_count = 0 + self.dp_lead_away_alert_nolead_count = 0 + self.dp_lead_away_state = LEAD_AWAY_STATE_OFF + + if current_speed >= self.dp_lead_away_min_speed: + nolead_count = interp(current_speed, [self.dp_lead_away_min_speed, 100], [300, 100]) + # when car had lead for 5 more secs and lead move away for 3 secs + if self.dp_lead_away_state == LEAD_AWAY_STATE_OFF and self.sm['plan'].hasLead: + self.dp_lead_away_alert_lead_count += 1 + elif self.dp_lead_away_state == LEAD_AWAY_STATE_ON and not self.sm['plan'].hasLead: + self.dp_lead_away_alert_nolead_count += 1 + + if self.dp_lead_away_state == LEAD_AWAY_STATE_OFF and self.dp_lead_away_alert_lead_count >= 300: + self.dp_lead_away_state = LEAD_AWAY_STATE_ON + elif self.dp_lead_away_state == LEAD_AWAY_STATE_ON and self.dp_lead_away_alert_nolead_count >= nolead_count: + self.events.add(EventName.leadCarMoving) + self.dp_lead_away_state = LEAD_AWAY_STATE_ALERTED + + # dp lead car moving alert + if self.sm['dragonConf'].dpLeadCarAlert: + if not self.CP.radarOffCan and self.sm['plan'].hasLead and CS.vEgo <= 0.01 and 0.3 >= abs(self.sm['plan'].vTarget) >= 0: + self.dp_lead_count += 1 + else: + self.dp_lead_count = 0 + + if self.dp_lead_count >= 300 and abs(self.sm['plan'].vTargetFuture) >= 0.1: + self.events.add(EventName.leadCarMoving) + + if CS.vEgo > 0. or CS.gearShifter in [car.CarState.GearShifter.reverse, car.CarState.GearShifter.park]: + self.dp_lead_count = 0 + def data_sample(self): """Receive data from sockets and update carState""" # Update carState from CAN can_strs = messaging.drain_sock_raw(self.can_sock, wait_for_one=True) - CS = self.CI.update(self.CC, can_strs) + CS = self.CI.update(self.CC, can_strs, self.sm['dragonConf']) self.sm.update(0) @@ -266,7 +328,7 @@ def data_sample(self): if not self.enabled: self.mismatch_counter = 0 - if not self.sm['health'].controlsAllowed and self.enabled: + if not self.sm['dragonConf'].dpAtl and not self.sm['health'].controlsAllowed and self.enabled: self.mismatch_counter += 1 self.distance_traveled += CS.vEgo * DT_CTRL @@ -365,7 +427,7 @@ def state_control(self, CS): if not self.active: self.LaC.reset() - self.LoC.reset(v_pid=CS.vEgo) + self.LoC.reset(v_pid=plan.vTargetFuture) plan_age = DT_CTRL * (self.sm.frame - self.sm.rcv_frame['plan']) # no greater than dt mpc + dt, to prevent too high extraps @@ -375,7 +437,7 @@ def state_control(self, CS): v_acc_sol = plan.vStart + dt * (a_acc_sol + plan.aStart) / 2.0 # Gas/Brake PID loop - actuators.gas, actuators.brake = self.LoC.update(self.active, CS, v_acc_sol, plan.vTargetFuture, a_acc_sol, self.CP) + actuators.gas, actuators.brake = self.LoC.update(self.active, CS, v_acc_sol, plan.vTargetFuture, a_acc_sol, self.CP, self.sm) # Steering PID loop and lateral MPC actuators.steer, actuators.steerAngle, lac_log = self.LaC.update(self.active, CS, self.CP, path_plan) @@ -389,14 +451,15 @@ def state_control(self, CS): self.saturated_count = 0 # Send a "steering required alert" if saturation count has reached the limit - if (lac_log.saturated and not CS.steeringPressed) or \ - (self.saturated_count > STEER_ANGLE_SATURATION_TIMEOUT): - # Check if we deviated from the path - left_deviation = actuators.steer > 0 and path_plan.dPoly[3] > 0.1 - right_deviation = actuators.steer < 0 and path_plan.dPoly[3] < -0.1 + if self.sm['dragonConf'].dpLatCtrl and self.sm['dragonConf'].dpSteeringLimitAlert: + if (lac_log.saturated and not CS.steeringPressed) or \ + (self.saturated_count > STEER_ANGLE_SATURATION_TIMEOUT): + # Check if we deviated from the path + left_deviation = actuators.steer > 0 and path_plan.dPoly[3] > 0.1 + right_deviation = actuators.steer < 0 and path_plan.dPoly[3] < -0.1 - if left_deviation or right_deviation: - self.events.add(EventName.steerSaturated) + if left_deviation or right_deviation: + self.events.add(EventName.steerSaturated) return actuators, v_acc_sol, a_acc_sol, lac_log @@ -433,10 +496,12 @@ def publish_logs(self, CS, start_time, actuators, v_acc, a_acc, lac_log): meta = self.sm['model'].meta if len(meta.desirePrediction) and ldw_allowed: + if self.sm.updated['dragonConf']: + self.dp_camera_offset = self.sm['dragonConf'].dpCameraOffset * 0.01 if self.sm['dragonConf'].dpCameraOffset != 0 else 0 l_lane_change_prob = meta.desirePrediction[Desire.laneChangeLeft - 1] r_lane_change_prob = meta.desirePrediction[Desire.laneChangeRight - 1] - l_lane_close = left_lane_visible and (self.sm['pathPlan'].lPoly[3] < (1.08 - CAMERA_OFFSET)) - r_lane_close = right_lane_visible and (self.sm['pathPlan'].rPoly[3] > -(1.08 + CAMERA_OFFSET)) + l_lane_close = left_lane_visible and (self.sm['pathPlan'].lPoly[3] < (1.08 - self.dp_camera_offset)) + r_lane_close = right_lane_visible and (self.sm['pathPlan'].rPoly[3] > -(1.08 + self.dp_camera_offset)) CC.hudControl.leftLaneDepart = bool(l_lane_change_prob > LANE_DEPARTURE_THRESHOLD and l_lane_close) CC.hudControl.rightLaneDepart = bool(r_lane_change_prob > LANE_DEPARTURE_THRESHOLD and r_lane_close) diff --git a/selfdrive/controls/lib/dynamic_follow/__init__.py b/selfdrive/controls/lib/dynamic_follow/__init__.py new file mode 100644 index 00000000000000..cb18c343d9b314 --- /dev/null +++ b/selfdrive/controls/lib/dynamic_follow/__init__.py @@ -0,0 +1,340 @@ +import math +import numpy as np +from common.realtime import sec_since_boot +from selfdrive.controls.lib.drive_helpers import MPC_COST_LONG +from common.numpy_fast import interp, clip +from selfdrive.config import Conversions as CV +from common.params import Params +from common.dp_time import LAST_MODIFIED_DYNAMIC_FOLLOW +from common.dp_common import get_last_modified, param_get, param_get_if_updated + +from selfdrive.controls.lib.dynamic_follow.auto_df import predict +from selfdrive.controls.lib.dynamic_follow.support import LeadData, CarData, dfData, dfProfiles +travis = False + +# dp +PROFILE_AUTO = 4 +PROFILE_LONG = 3 +PROFILE_NORMAL = 2 +PROFILE_SHORT = 1 +PROFILE_OFF = 0 + +class DynamicFollow: + def __init__(self, mpc_id): + self.mpc_id = mpc_id + self.df_profiles = dfProfiles() + self.global_df_mod = 1. + self.min_TR = 0.9 + + # Model variables + mpc_rate = 1 / 20. + self.model_scales = {'v_ego': [-0.06112159043550491, 37.96522521972656], 'a_lead': [-3.109330892562866, 3.3612186908721924], 'v_lead': [0.0, 35.27671432495117], 'x_lead': [2.4600000381469727, 141.44000244140625]} + self.predict_rate = 1 / 4. + self.skip_every = round(0.25 / mpc_rate) + self.model_input_len = round(45 / mpc_rate) + + # Dynamic follow variables + self.default_TR = 1.8 + self.TR = 1.8 + # self.v_lead_retention = 2.0 # keep only last x seconds + self.v_ego_retention = 2.5 + self.v_rel_retention = 1.5 + + self.sng_TR = 1.8 # reacceleration stop and go TR + self.sng_speed = 18.0 * CV.MPH_TO_MS + + # dp params + self.last_ts = 0. + self.modified = None + self.last_modified = None + self.last_modified_check = None + self.dp_dynamic_follow = PROFILE_OFF + self.dp_dynamic_follow_last_modified = None + self.dp_dynamic_follow_multiplier_last_modified = None + self.dp_dynamic_follow_min_tr_last_modified = None + self.params = Params() + + self._setup_changing_variables() + + def _setup_changing_variables(self): + self.TR = self.default_TR + self.model_profile = None + + self.sng = False + self.car_data = CarData() + self.lead_data = LeadData() + self.df_data = dfData() # dynamic follow data + + self.last_cost = 0.0 + self.last_predict_time = 0.0 + self.auto_df_model_data = [] + self._get_live_params() # so they're defined just in case + + def update(self, CS, libmpc): + self._get_live_params() + self._update_car(CS) + self._get_profiles() + + if not self.lead_data.status or self.dp_dynamic_follow == PROFILE_OFF: + self.TR = self.default_TR + else: + self._store_df_data() + self.TR = self._get_TR() + + if not travis: + self._change_cost(libmpc) + + return self.TR + + def _get_profiles(self): + """This receives profile change updates from dfManager and runs the auto-df prediction if auto mode""" + if self.dp_dynamic_follow == PROFILE_AUTO: # todo: find some way to share prediction between the two mpcs to reduce processing overhead + self._get_pred() # sets self.model_profile, all other checks are inside function + + def _norm(self, x, name): + self.x = x + return np.interp(x, self.model_scales[name], [0, 1]) + + def _change_cost(self, libmpc): + TRs = [0.9, 1.8, 2.7] + costs = [1.0, 0.115, 0.05] + cost = interp(self.TR, TRs, costs) + if self.last_cost != cost: + libmpc.change_tr(MPC_COST_LONG.TTC, cost, MPC_COST_LONG.ACCELERATION, MPC_COST_LONG.JERK) + self.last_cost = cost + + def _store_df_data(self): + cur_time = sec_since_boot() + # Store custom relative accel over time + if self.lead_data.status: + if self.lead_data.new_lead: + self.df_data.v_rels = [] # reset when new lead + else: + self.df_data.v_rels = self._remove_old_entries(self.df_data.v_rels, cur_time, self.v_rel_retention) + self.df_data.v_rels.append({'v_ego': self.car_data.v_ego, 'v_lead': self.lead_data.v_lead, 'time': cur_time}) + + # Store our velocity for better sng + self.df_data.v_egos = self._remove_old_entries(self.df_data.v_egos, cur_time, self.v_ego_retention) + self.df_data.v_egos.append({'v_ego': self.car_data.v_ego, 'time': cur_time}) + + # Store data for auto-df model + self.auto_df_model_data.append([self._norm(self.car_data.v_ego, 'v_ego'), + self._norm(self.lead_data.v_lead, 'v_lead'), + self._norm(self.lead_data.a_lead, 'a_lead'), + self._norm(self.lead_data.x_lead, 'x_lead')]) + while len(self.auto_df_model_data) > self.model_input_len: + del self.auto_df_model_data[0] + + def _get_pred(self): + cur_time = sec_since_boot() + if self.car_data.cruise_enabled and self.lead_data.status: + if cur_time - self.last_predict_time > self.predict_rate: + if len(self.auto_df_model_data) == self.model_input_len: + pred = predict(np.array(self.auto_df_model_data[::self.skip_every], dtype=np.float32).flatten()) + self.last_predict_time = cur_time + self.model_profile = int(np.argmax(pred)) + + def _remove_old_entries(self, lst, cur_time, retention): + return [sample for sample in lst if cur_time - sample['time'] <= retention] + + def _calculate_relative_accel_new(self): + # """ + # Moving window returning the following: (final relative velocity - initial relative velocity) / dT with a few extra mods + # Output properties: + # When the lead is starting to decelerate, and our car remains the same speed, the output decreases (and vice versa) + # However when our car finally starts to decelerate at the same rate as the lead car, the output will move to near 0 + # >>> a = [(15 - 18), (14 - 17)] + # >>> (a[-1] - a[0]) / 1 + # > 0.0 + # """ + min_consider_time = 0.5 # minimum amount of time required to consider calculation + if len(self.df_data.v_rels) > 0: # if not empty + elapsed_time = self.df_data.v_rels[-1]['time'] - self.df_data.v_rels[0]['time'] + if elapsed_time > min_consider_time: + x = [-2.6822, -1.7882, -0.8941, -0.447, -0.2235, 0.0, 0.2235, 0.447, 0.8941, 1.7882, 2.6822] + y = [0.3245, 0.277, 0.11075, 0.08106, 0.06325, 0.0, -0.09, -0.09375, -0.125, -0.3, -0.35] + + v_lead_start = self.df_data.v_rels[0]['v_lead'] # setup common variables + v_ego_start = self.df_data.v_rels[0]['v_ego'] + v_lead_end = self.df_data.v_rels[-1]['v_lead'] + v_ego_end = self.df_data.v_rels[-1]['v_ego'] + + v_ego_change = v_ego_end - v_ego_start + v_lead_change = v_lead_end - v_lead_start + + if v_lead_change - v_ego_change == 0 or v_lead_change + v_ego_change == 0: + return None + + initial_v_rel = v_lead_start - v_ego_start + cur_v_rel = v_lead_end - v_ego_end + delta_v_rel = (cur_v_rel - initial_v_rel) / elapsed_time + + neg_pos = False + if v_ego_change == 0 or v_lead_change == 0: # FIXME: this all is a mess, but works. need to simplify + lead_factor = v_lead_change / (v_lead_change - v_ego_change) + + elif (v_ego_change < 0) != (v_lead_change < 0): # one is negative and one is positive, or ^ = XOR + lead_factor = v_lead_change / (v_lead_change - v_ego_change) + if v_ego_change > 0 > v_lead_change: + delta_v_rel = -delta_v_rel # switch when appropriate + neg_pos = True + + elif v_ego_change * v_lead_change > 0: # both are negative or both are positive + lead_factor = v_lead_change / (v_lead_change + v_ego_change) + if v_ego_change > 0 and v_lead_change > 0: # both are positive + if v_ego_change < v_lead_change: + delta_v_rel = -delta_v_rel # switch when appropriate + elif v_ego_change > v_lead_change: # both are negative and v_ego_change > v_lead_change + delta_v_rel = -delta_v_rel + + else: + raise Exception('Uncovered case! Should be impossible to be be here') + + if not neg_pos: # negative and positive require different mod code to be correct + rel_vel_mod = (-delta_v_rel * abs(lead_factor)) + (delta_v_rel * (1 - abs(lead_factor))) + else: + rel_vel_mod = math.copysign(delta_v_rel, v_lead_change - v_ego_change) * lead_factor + + calc_mod = np.interp(rel_vel_mod, x, y) + if v_lead_end > v_ego_end and calc_mod >= 0: + # if we're accelerating quicker than lead but lead is still faster, reduce mod + # todo: could remove this since we restrict this mod where called + x = np.array([0, 2, 4, 8]) * CV.MPH_TO_MS + y = [1.0, -0.25, -0.65, -0.95] + v_rel_mod = np.interp(v_lead_end - v_ego_end, x, y) + calc_mod *= v_rel_mod + return calc_mod + return None + + def global_profile_mod(self, profile_mod_x, profile_mod_pos, profile_mod_neg, x_vel, y_dist): + """ + This function modifies the y_dist list used by dynamic follow in accordance with global_df_mod + It also intelligently adjusts the profile mods at each breakpoint based on the change in TR + """ + if self.global_df_mod == 1.: + return profile_mod_pos, profile_mod_neg, y_dist + global_df_mod = 1 - self.global_df_mod + + # Calculate new TRs + speeds = [0, self.sng_speed, 18, x_vel[-1]] # [0, 18 mph, ~40 mph, highest profile mod speed (~78 mph)] + mods = [0, 0.1, 0.7, 1] # how much to limit global_df_mod at each speed, 1 is full effect + y_dist_new = [y - (y * global_df_mod * np.interp(x, speeds, mods)) for x, y in zip(x_vel, y_dist)] + + # Calculate how to change profile mods based on change in TR + # eg. if df mod is 0.7, then increase positive mod and decrease negative mod + calc_profile_mods = [(np.interp(mod_x, x_vel, y_dist) - np.interp(mod_x, x_vel, y_dist_new) + 1) for mod_x in profile_mod_x] + profile_mod_pos = [mod_pos * mod for mod_pos, mod in zip(profile_mod_pos, calc_profile_mods)] + profile_mod_neg = [mod_neg * ((1 - mod) + 1) for mod_neg, mod in zip(profile_mod_neg, calc_profile_mods)] + + return profile_mod_pos, profile_mod_neg, y_dist_new + + def _get_TR(self): + x_vel = [0.0, 1.8627, 3.7253, 5.588, 7.4507, 9.3133, 11.5598, 13.645, 22.352, 31.2928, 33.528, 35.7632, 40.2336] # velocities + profile_mod_x = [2.2352, 13.4112, 24.5872, 35.7632] # profile mod speeds, mph: [5., 30., 55., 80.] + + if self.dp_dynamic_follow == PROFILE_AUTO: # decide which profile to use, model profile will be updated before this + # df is 0 = traffic, 1 = relaxed, 2 = roadtrip, 3 = auto + # dp is 0 = off, 1 = short, 2 = normal, 3 = long, 4 = auto + # if it's model profile, we need to convert it + if self.model_profile is None: + # when its none, we use normal instead + df_profile = PROFILE_NORMAL + else: + df_profile = self.model_profile + 1 + else: + df_profile = self.dp_dynamic_follow + + if df_profile == PROFILE_LONG: + y_dist = [1.3978, 1.4132, 1.4318, 1.4536, 1.485, 1.5229, 1.5819, 1.6203, 1.7238, 1.8231, 1.8379, 1.8495, 1.8535] # TRs + profile_mod_pos = [0.92, 0.7, 0.25, 0.15] + profile_mod_neg = [1.1, 1.3, 2.0, 2.3] + elif df_profile == PROFILE_SHORT: # for in congested traffic + x_vel = [0.0, 1.892, 3.7432, 5.8632, 8.0727, 10.7301, 14.343, 17.6275, 22.4049, 28.6752, 34.8858, 40.35] + # y_dist = [1.3781, 1.3791, 1.3802, 1.3825, 1.3984, 1.4249, 1.4194, 1.3162, 1.1916, 1.0145, 0.9855, 0.9562] # original + # y_dist = [1.3781, 1.3791, 1.3112, 1.2442, 1.2306, 1.2112, 1.2775, 1.1977, 1.0963, 0.9435, 0.9067, 0.8749] # avg. 7.3 ft closer from 18 to 90 mph + y_dist = [1.3781, 1.3791, 1.3457, 1.3134, 1.3145, 1.318, 1.3485, 1.257, 1.144, 0.979, 0.9461, 0.9156] + profile_mod_pos = [1.05, 1.55, 2.6, 3.75] + profile_mod_neg = [0.84, .275, 0.1, 0.05] + elif df_profile == PROFILE_NORMAL: # default to relaxed/stock + y_dist = [1.385, 1.394, 1.406, 1.421, 1.444, 1.474, 1.516, 1.534, 1.546, 1.568, 1.579, 1.593, 1.614] + profile_mod_pos = [1.0] * 4 + profile_mod_neg = [1.0] * 4 + else: + raise Exception('Unknown profile type: {}'.format(df_profile)) + + # Global df mod + profile_mod_pos, profile_mod_neg, y_dist = self.global_profile_mod(profile_mod_x, profile_mod_pos, profile_mod_neg, x_vel, y_dist) + + # Profile modifications - Designed so that each profile reacts similarly to changing lead dynamics + profile_mod_pos = interp(self.car_data.v_ego, profile_mod_x, profile_mod_pos) + profile_mod_neg = interp(self.car_data.v_ego, profile_mod_x, profile_mod_neg) + + if self.car_data.v_ego > self.sng_speed: # keep sng distance until we're above sng speed again + self.sng = False + + if (self.car_data.v_ego >= self.sng_speed or self.df_data.v_egos[0]['v_ego'] >= self.car_data.v_ego) and not self.sng: + # if above 15 mph OR we're decelerating to a stop, keep shorter TR. when we reaccelerate, use sng_TR and slowly decrease + TR = interp(self.car_data.v_ego, x_vel, y_dist) + else: # this allows us to get closer to the lead car when stopping, while being able to have smooth stop and go when reaccelerating + self.sng = True + x = [self.sng_speed * 0.7, self.sng_speed] # decrease TR between 12.6 and 18 mph from 1.8s to defined TR above at 18mph while accelerating + y = [self.sng_TR, interp(self.sng_speed, x_vel, y_dist)] + TR = interp(self.car_data.v_ego, x, y) + + TR_mods = [] + # Dynamic follow modifications (the secret sauce) + x = [-26.8224, -20.0288, -15.6871, -11.1965, -7.8645, -4.9472, -3.0541, -2.2244, -1.5045, -0.7908, -0.3196, 0.0, 0.5588, 1.3682, 1.898, 2.7316, 4.4704] # relative velocity values + y = [.76, 0.62323, 0.49488, 0.40656, 0.32227, 0.23914, 0.12269, 0.10483, 0.08074, 0.04886, 0.0072, 0.0, -0.05648, -0.0792, -0.15675, -0.23289, -0.315] # modification values + TR_mods.append(interp(self.lead_data.v_lead - self.car_data.v_ego, x, y)) + + x = [-4.4795, -2.8122, -1.5727, -1.1129, -0.6611, -0.2692, 0.0, 0.1466, 0.5144, 0.6903, 0.9302] # lead acceleration values + y = [0.24, 0.16, 0.092, 0.0515, 0.0305, 0.022, 0.0, -0.0153, -0.042, -0.053, -0.059] # modification values + TR_mods.append(interp(self.lead_data.a_lead, x, y)) + + rel_accel_mod = self._calculate_relative_accel_new() + if rel_accel_mod is not None: # if available + deadzone = 2 * CV.MPH_TO_MS + if self.lead_data.v_lead - deadzone > self.car_data.v_ego: + TR_mods.append(rel_accel_mod) + + x = [self.sng_speed / 5.0, self.sng_speed] # as we approach 0, apply x% more distance + y = [1.05, 1.0] + profile_mod_pos *= interp(self.car_data.v_ego, x, y) # but only for currently positive mods + + TR_mod = sum([mod * profile_mod_neg if mod < 0 else mod * profile_mod_pos for mod in TR_mods]) # alter TR modification according to profile + TR += TR_mod + + if self.car_data.left_blinker or self.car_data.right_blinker and df_profile != self.df_profiles.traffic: + x = [8.9408, 22.352, 31.2928] # 20, 50, 70 mph + y = [1.0, .75, .65] + TR *= interp(self.car_data.v_ego, x, y) # reduce TR when changing lanes + + return float(clip(TR, self.min_TR, 2.7)) + + def update_lead(self, v_lead=None, a_lead=None, x_lead=None, status=False, new_lead=False): + self.lead_data.v_lead = v_lead + self.lead_data.a_lead = a_lead + self.lead_data.x_lead = x_lead + + self.lead_data.status = status + self.lead_data.new_lead = new_lead + + def _update_car(self, CS): + self.car_data.v_ego = CS.vEgo + self.car_data.a_ego = CS.aEgo + + self.car_data.left_blinker = CS.leftBlinker + self.car_data.right_blinker = CS.rightBlinker + self.car_data.cruise_enabled = CS.cruiseState.enabled + + def _get_live_params(self): + self.last_modified_check, self.modified = get_last_modified(LAST_MODIFIED_DYNAMIC_FOLLOW, self.last_modified_check, self.modified) + if self.last_modified != self.modified: + self.dp_dynamic_follow, self.dp_dynamic_follow_last_modified = param_get_if_updated("dp_dynamic_follow", "int", self.dp_dynamic_follow, self.dp_dynamic_follow_last_modified) + self.global_df_mod, self.dp_dynamic_follow_multiplier_last_modified = param_get_if_updated("dp_dynamic_follow_multiplier", "float", self.global_df_mod, self.dp_dynamic_follow_multiplier_last_modified) + if self.global_df_mod != 1.: + self.global_df_mod = clip(self.global_df_mod, .85, 1.2) + self.min_TR, self.dp_dynamic_follow_min_tr_last_modified = param_get_if_updated("dp_dynamic_follow_min_tr", "float", self.min_TR, self.dp_dynamic_follow_min_tr_last_modified) + if self.min_TR != .9: + self.min_TR = clip(self.min_TR, .85, 1.6) + self.last_modified = self.modified \ No newline at end of file diff --git a/selfdrive/controls/lib/dynamic_follow/auto_df.py b/selfdrive/controls/lib/dynamic_follow/auto_df.py new file mode 100644 index 00000000000000..7e7ddcff194a02 --- /dev/null +++ b/selfdrive/controls/lib/dynamic_follow/auto_df.py @@ -0,0 +1,20 @@ +""" + Generated using Konverter: https://github.com/ShaneSmiskol/Konverter +""" + +import numpy as np + +wb = np.load('/data/openpilot/selfdrive/controls/lib/dynamic_follow/auto_df_weights.npz', allow_pickle=True) +w, b = wb['wb'] + +def softmax(x): + return np.exp(x) / np.sum(np.exp(x), axis=0) + +def predict(x): + l0 = np.dot(x, w[0]) + b[0] + l0 = np.maximum(0, l0) + l1 = np.dot(l0, w[1]) + b[1] + l1 = np.maximum(0, l1) + l2 = np.dot(l1, w[2]) + b[2] + l2 = softmax(l2) + return l2 \ No newline at end of file diff --git a/selfdrive/controls/lib/dynamic_follow/auto_df_weights.npz b/selfdrive/controls/lib/dynamic_follow/auto_df_weights.npz new file mode 100644 index 00000000000000..da367c5e6886d2 Binary files /dev/null and b/selfdrive/controls/lib/dynamic_follow/auto_df_weights.npz differ diff --git a/selfdrive/controls/lib/dynamic_follow/support.py b/selfdrive/controls/lib/dynamic_follow/support.py new file mode 100644 index 00000000000000..2737c7cc7b1d82 --- /dev/null +++ b/selfdrive/controls/lib/dynamic_follow/support.py @@ -0,0 +1,31 @@ +class LeadData: + v_lead = None + x_lead = None + a_lead = None + status = False + new_lead = False + + +class CarData: + v_ego = 0.0 + a_ego = 0.0 + + left_blinker = False + right_blinker = False + cruise_enabled = True + + +class dfData: + v_egos = [] + v_rels = [] + + +class dfProfiles: + traffic = 0 + relaxed = 1 + roadtrip = 2 + auto = 3 + to_profile = {0: 'traffic', 1: 'relaxed', 2: 'roadtrip', 3: 'auto'} + to_idx = {v: k for k, v in to_profile.items()} + + default = relaxed \ No newline at end of file diff --git a/selfdrive/controls/lib/dynamic_gas.py b/selfdrive/controls/lib/dynamic_gas.py new file mode 100644 index 00000000000000..df3f41404e95e6 --- /dev/null +++ b/selfdrive/controls/lib/dynamic_gas.py @@ -0,0 +1,78 @@ +import numpy as np +from common.numpy_fast import clip, interp + +# dp +DP_OFF = 0 +DP_ECO = 1 +DP_NORMAL = 2 +DP_SPORT = 3 + +class DynamicGas: + def __init__(self, CP): + self.CP = CP + self.candidate = self.CP.carFingerprint + self.lead_data = {'v_rel': None, 'a_lead': None, 'x_lead': None, 'status': False} + self.blinker_status = False + self.dp_profile = DP_OFF + self.set_profile() + + def update(self, CS, sm): + v_ego = CS.vEgo + self.handle_passable(CS, sm) + + current_dp_profile = sm['dragonConf'].dpAccelProfile + if self.dp_profile != current_dp_profile: + self.dp_profile = current_dp_profile + self.set_profile() + + if self.dp_profile == DP_OFF: + return float(interp(v_ego, self.CP.gasMaxBP, self.CP.gasMaxV)) + + gas = interp(v_ego, self.gasMaxBP, self.gasMaxV) + if self.lead_data['status']: # if lead + x = [0.0, 0.24588812499999999, 0.432818589, 0.593044697, 0.730381365, 1.050833588, 1.3965, 1.714627481] # relative velocity mod + y = [0.9901, 0.905, 0.8045, 0.625, 0.431, 0.2083, .0667, 0] + gas_mod = -(gas * interp(self.lead_data['v_rel'], x, y)) + + x = [0.44704, 1.1176, 1.34112] # lead accel mod + y = [1.0, 0.75, 0.625] # maximum we can reduce gas_mod is 40 percent (never increases mod) + gas_mod *= interp(self.lead_data['a_lead'], x, y) + + # as lead gets further from car, lessen gas mod/reduction + x = [(i+v_ego) for i in self.x_lead_mod_x ] + gas_mod *= interp(self.lead_data['x_lead'],x , self.x_lead_mod_y) + gas = gas + gas_mod + + if (self.blinker_status and self.lead_data['v_rel'] >= 0 ): + x = [8.9408, 22.352, 31.2928] # 20, 50, 70 mph + y = [1.0, 1.115, 1.225] + gas *= interp(v_ego, x, y) + + return float(clip(gas, 0.0, 1.0)) + + def set_profile(self): + self.x_lead_mod_y = [1.0, 0.75, 0.5, 0.25, 0.0] # as lead gets further from car, lessen gas mod/reduction + x = [0.0, 1.4082, 2.80311, 4.22661, 5.38271, 6.16561, 7.24781, 8.28308, 10.24465, 12.96402, 15.42303, 18.11903, 20.11703, 24.46614, 29.05805, 32.71015, 35.76326, 40] + if self.dp_profile == DP_ECO: + #km/h[0, 5, 10, 15, 19, 22, 25, 29, 36, 43, 54, 64, 72, 87, 104, 117, 128 144] + y = [0.38, 0.40, 0.38, 0.33, 0.33, 0.32, 0.31, 0.30, 0.27, 0.25, 0.24, 0.21, 0.20, 0.20, 0.19, 0.19, 0.17, 0.15] + self.x_lead_mod_x = [8.1, 12.15, 25.24, 35 , 50 ] + elif self.dp_profile == DP_SPORT: + #km/h[0, 5, 10, 15, 19, 22, 25, 29, 36, 43, 54, 64, 72, 87, 104, 117, 128 144] + y = [0.65, 0.67, 0.63, 0.50, 0.53, 0.53, 0.5229, 0.51784, 0.50765, 0.48, 0.496, 0.509, 0.525, 0.538, 0.45, 0.421, 0.42,0.35] + self.x_lead_mod_x = [4.1, 6.15, 8.24, 10 , 15 ] + else: + #km/h[0, 5, 10, 15, 19, 22, 25, 29, 36, 43, 54, 64, 72, 87, 104, 117, 128 144] + y = [0.45, 0.42, 0.38, 0.33, 0.3, 0.32, 0.31, 0.30, 0.30, 0.28, 0.24, 0.21, 0.20, 0.20, 0.19, 0.19, 0.17, 0.15] + self.x_lead_mod_x = [7.1, 10.15, 12.24, 15 , 20 ] + + y = [interp(i, [0.2, (0.2 + 0.45) / 2, 0.45], [1.075 * i, i * 1.05, i]) for i in y] + self.gasMaxBP, self.gasMaxV = x, y + + def handle_passable(self, CS, sm): + self.blinker_status = CS.leftBlinker or CS.rightBlinker + lead_one = sm['radarState'].leadOne + self.lead_data['v_rel'] = lead_one.vRel + self.lead_data['a_lead'] = lead_one.aLeadK + self.lead_data['x_lead'] = lead_one.dRel + self.lead_data['status'] = sm['plan'].hasLead # this fixes radarstate always reporting a lead, thanks to arne diff --git a/selfdrive/controls/lib/events.py b/selfdrive/controls/lib/events.py index d0b10ec84e1c5d..83c4653a8d69b8 100644 --- a/selfdrive/controls/lib/events.py +++ b/selfdrive/controls/lib/events.py @@ -1,4 +1,7 @@ +# This Python file uses the following encoding: utf-8 +# -*- coding: utf-8 -*- from enum import IntEnum +from functools import total_ordering from typing import Dict, Union, Callable, Any from cereal import log, car @@ -6,6 +9,8 @@ from common.realtime import DT_CTRL from selfdrive.config import Conversions as CV from selfdrive.locationd.calibrationd import MIN_SPEED_FILTER +from common.i18n import events +_ = events() AlertSize = log.ControlsState.AlertSize AlertStatus = log.ControlsState.AlertStatus @@ -140,21 +145,21 @@ def __gt__(self, alert2) -> bool: class NoEntryAlert(Alert): def __init__(self, alert_text_2, audible_alert=AudibleAlert.chimeError, visual_alert=VisualAlert.none, duration_hud_alert=2.): - super().__init__("openpilot Unavailable", alert_text_2, AlertStatus.normal, + super().__init__(_("openpilot Unavailable"), alert_text_2, AlertStatus.normal, AlertSize.mid, Priority.LOW, visual_alert, audible_alert, .4, duration_hud_alert, 3.) class SoftDisableAlert(Alert): def __init__(self, alert_text_2): - super().__init__("TAKE CONTROL IMMEDIATELY", alert_text_2, + super().__init__(_("TAKE CONTROL IMMEDIATELY"), alert_text_2, AlertStatus.critical, AlertSize.full, Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, 2., 2.), class ImmediateDisableAlert(Alert): - def __init__(self, alert_text_2, alert_text_1="TAKE CONTROL IMMEDIATELY"): + def __init__(self, alert_text_2, alert_text_1=_("TAKE CONTROL IMMEDIATELY")): super().__init__(alert_text_1, alert_text_2, AlertStatus.critical, AlertSize.full, Priority.HIGHEST, VisualAlert.steerRequired, @@ -179,8 +184,8 @@ def below_steer_speed_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: speed = int(round(CP.minSteerSpeed * (CV.MS_TO_KPH if metric else CV.MS_TO_MPH))) unit = "km/h" if metric else "mph" return Alert( - "TAKE CONTROL", - "Steer Unavailable Below %d %s" % (speed, unit), + _("TAKE CONTROL"), + _("Steer Unavailable Below %(speed)d %(unit)s") % ({"speed": speed, "unit": unit}), AlertStatus.userPrompt, AlertSize.mid, Priority.MID, VisualAlert.steerRequired, AudibleAlert.none, 0., 0.4, .3) @@ -188,23 +193,23 @@ def calibration_incomplete_alert(CP: car.CarParams, sm: messaging.SubMaster, met speed = int(MIN_SPEED_FILTER * (CV.MS_TO_KPH if metric else CV.MS_TO_MPH)) unit = "km/h" if metric else "mph" return Alert( - "Calibration in Progress: %d%%" % sm['liveCalibration'].calPerc, - "Drive Above %d %s" % (speed, unit), + _("Calibration in Progress: %d%%") % sm['liveCalibration'].calPerc, + _("Drive Above %(speed)d %(unit)s") % ({"speed": speed, "unit": unit}), AlertStatus.normal, AlertSize.mid, Priority.LOWEST, VisualAlert.none, AudibleAlert.none, 0., 0., .2) def no_gps_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: bool) -> Alert: gps_integrated = sm['health'].hwType in [log.HealthData.HwType.uno, log.HealthData.HwType.dos] return Alert( - "Poor GPS reception", - "If sky is visible, contact support" if gps_integrated else "Check GPS antenna placement", + _("Poor GPS reception"), + _("If sky is visible, contact support") if gps_integrated else _("Check GPS antenna placement"), AlertStatus.normal, AlertSize.mid, Priority.LOWER, VisualAlert.none, AudibleAlert.none, 0., 0., .2, creation_delay=300.) def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: bool) -> Alert: - text = "Cruise Mode Disabled" + text = _("Cruise Mode Disabled") if CP.carName == "honda": - text = "Main Switch Off" + text = _("Main Switch Off") return NoEntryAlert(text, duration_hud_alert=0.) EVENTS: Dict[int, Dict[str, Union[Alert, Callable[[Any, messaging.SubMaster, bool], Alert]]]] = { @@ -214,7 +219,7 @@ def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: boo EventName.debugAlert: { ET.PERMANENT: Alert( - "DEBUG ALERT", + _("DEBUG ALERT"), "", AlertStatus.userPrompt, AlertSize.mid, Priority.LOW, VisualAlert.none, AudibleAlert.none, .1, .1, .1), @@ -222,40 +227,40 @@ def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: boo EventName.startup: { ET.PERMANENT: Alert( - "Be ready to take over at any time", - "Always keep hands on wheel and eyes on road", + _("Be ready to take over at any time"), + _("Always keep hands on wheel and eyes on road"), AlertStatus.normal, AlertSize.mid, Priority.LOWER, VisualAlert.none, AudibleAlert.none, 0., 0., 15.), }, EventName.startupMaster: { ET.PERMANENT: Alert( - "WARNING: This branch is not tested", - "Always keep hands on wheel and eyes on road", + _("WARNING: This branch is not tested"), + _("Always keep hands on wheel and eyes on road"), AlertStatus.userPrompt, AlertSize.mid, Priority.LOWER, VisualAlert.none, AudibleAlert.none, 0., 0., 15.), }, EventName.startupNoControl: { ET.PERMANENT: Alert( - "Dashcam mode", - "Always keep hands on wheel and eyes on road", + _("Dashcam mode"), + _("Always keep hands on wheel and eyes on road"), AlertStatus.normal, AlertSize.mid, Priority.LOWER, VisualAlert.none, AudibleAlert.none, 0., 0., 15.), }, EventName.startupNoCar: { ET.PERMANENT: Alert( - "Dashcam mode for unsupported car", - "Always keep hands on wheel and eyes on road", + _("Dashcam mode for unsupported car"), + _("Always keep hands on wheel and eyes on road"), AlertStatus.normal, AlertSize.mid, Priority.LOWER, VisualAlert.none, AudibleAlert.none, 0., 0., 15.), }, EventName.invalidLkasSetting: { ET.PERMANENT: Alert( - "Stock LKAS is turned on", - "Turn off stock LKAS to engage", + _("Stock LKAS is turned on"), + _("Turn off stock LKAS to engage"), AlertStatus.normal, AlertSize.mid, Priority.LOWER, VisualAlert.none, AudibleAlert.none, 0., 0., .2), }, @@ -263,48 +268,48 @@ def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: boo EventName.communityFeatureDisallowed: { # LOW priority to overcome Cruise Error ET.PERMANENT: Alert( - "Community Feature Detected", - "Enable Community Features in Developer Settings", + _("Community Feature Detected"), + _("Enable Community Features in Developer Settings"), AlertStatus.normal, AlertSize.mid, Priority.LOW, VisualAlert.none, AudibleAlert.none, 0., 0., .2), }, EventName.carUnrecognized: { ET.PERMANENT: Alert( - "Dashcam Mode", - "Car Unrecognized", + _("Dashcam Mode"), + _("Car Unrecognized"), AlertStatus.normal, AlertSize.mid, Priority.LOWEST, VisualAlert.none, AudibleAlert.none, 0., 0., .2), }, EventName.stockAeb: { ET.PERMANENT: Alert( - "BRAKE!", - "Stock AEB: Risk of Collision", + _("BRAKE!"), + _("Stock AEB: Risk of Collision"), AlertStatus.critical, AlertSize.full, Priority.HIGHEST, VisualAlert.fcw, AudibleAlert.none, 1., 2., 2.), }, EventName.stockFcw: { ET.PERMANENT: Alert( - "BRAKE!", - "Stock FCW: Risk of Collision", + _("BRAKE!"), + _("Stock FCW: Risk of Collision"), AlertStatus.critical, AlertSize.full, Priority.HIGHEST, VisualAlert.fcw, AudibleAlert.none, 1., 2., 2.), }, EventName.fcw: { ET.PERMANENT: Alert( - "BRAKE!", - "Risk of Collision", + _("BRAKE!"), + _("Risk of Collision"), AlertStatus.critical, AlertSize.full, Priority.HIGHEST, VisualAlert.fcw, AudibleAlert.chimeWarningRepeat, 1., 2., 2.), }, EventName.ldw: { ET.PERMANENT: Alert( - "TAKE CONTROL", - "Lane Departure Detected", + _("TAKE CONTROL"), + _("Lane Departure Detected"), AlertStatus.userPrompt, AlertSize.mid, Priority.LOW, VisualAlert.steerRequired, AudibleAlert.chimePrompt, 1., 2., 3.), }, @@ -313,7 +318,7 @@ def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: boo EventName.gasPressed: { ET.PRE_ENABLE: Alert( - "openpilot will not brake while gas pressed", + _("openpilot will not brake while gas pressed"), "", AlertStatus.normal, AlertSize.small, Priority.LOWEST, VisualAlert.none, AudibleAlert.none, .0, .0, .1, creation_delay=1.), @@ -321,7 +326,7 @@ def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: boo EventName.vehicleModelInvalid: { ET.WARNING: Alert( - "Vehicle Parameter Identification Failed", + _("Vehicle Parameter Identification Failed"), "", AlertStatus.normal, AlertSize.small, Priority.LOWEST, VisualAlert.steerRequired, AudibleAlert.none, .0, .0, .1), @@ -329,15 +334,15 @@ def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: boo EventName.steerTempUnavailableMute: { ET.WARNING: Alert( - "TAKE CONTROL", - "Steering Temporarily Unavailable", + _("TAKE CONTROL"), + _("Steering Temporarily Unavailable"), AlertStatus.userPrompt, AlertSize.mid, Priority.LOW, VisualAlert.none, AudibleAlert.none, .2, .2, .2), }, EventName.preDriverDistracted: { ET.WARNING: Alert( - "KEEP EYES ON ROAD: Driver Distracted", + _("KEEP EYES ON ROAD: Driver Distracted"), "", AlertStatus.normal, AlertSize.small, Priority.LOW, VisualAlert.steerRequired, AudibleAlert.none, .0, .1, .1), @@ -345,23 +350,23 @@ def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: boo EventName.promptDriverDistracted: { ET.WARNING: Alert( - "KEEP EYES ON ROAD", - "Driver Distracted", + _("KEEP EYES ON ROAD"), + _("Driver Distracted"), AlertStatus.userPrompt, AlertSize.mid, Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarning2Repeat, .1, .1, .1), }, EventName.driverDistracted: { ET.WARNING: Alert( - "DISENGAGE IMMEDIATELY", - "Driver Distracted", + _("DISENGAGE IMMEDIATELY"), + _("Driver Distracted"), AlertStatus.critical, AlertSize.full, Priority.HIGH, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, .1, .1), }, EventName.preDriverUnresponsive: { ET.WARNING: Alert( - "TOUCH STEERING WHEEL: No Face Detected", + _("TOUCH STEERING WHEEL: No Face Detected"), "", AlertStatus.normal, AlertSize.small, Priority.LOW, VisualAlert.steerRequired, AudibleAlert.none, .0, .1, .1, alert_rate=0.75), @@ -369,40 +374,40 @@ def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: boo EventName.promptDriverUnresponsive: { ET.WARNING: Alert( - "TOUCH STEERING WHEEL", - "Driver Unresponsive", + _("TOUCH STEERING WHEEL"), + _("Driver Unresponsive"), AlertStatus.userPrompt, AlertSize.mid, Priority.MID, VisualAlert.steerRequired, AudibleAlert.chimeWarning2Repeat, .1, .1, .1), }, EventName.driverUnresponsive: { ET.WARNING: Alert( - "DISENGAGE IMMEDIATELY", - "Driver Unresponsive", + _("DISENGAGE IMMEDIATELY"), + _("Driver Unresponsive"), AlertStatus.critical, AlertSize.full, Priority.HIGH, VisualAlert.steerRequired, AudibleAlert.chimeWarningRepeat, .1, .1, .1), }, EventName.driverMonitorLowAcc: { ET.WARNING: Alert( - "CHECK DRIVER FACE VISIBILITY", - "Driver Monitoring Uncertain", + _("CHECK DRIVER FACE VISIBILITY"), + _("Driver Monitoring Uncertain"), AlertStatus.normal, AlertSize.mid, - Priority.LOW, VisualAlert.steerRequired, AudibleAlert.none, .4, 0., 1.5), + Priority.LOW, VisualAlert.steerRequired, AudibleAlert.none, .4, 0., 1.), }, EventName.manualRestart: { ET.WARNING: Alert( - "TAKE CONTROL", - "Resume Driving Manually", + _("TAKE CONTROL"), + _("Resume Driving Manually"), AlertStatus.userPrompt, AlertSize.mid, Priority.LOW, VisualAlert.none, AudibleAlert.none, 0., 0., .2), }, EventName.resumeRequired: { ET.WARNING: Alert( - "STOPPED", - "Press Resume to Move", + _("STOPPED"), + _("Press Resume to Move"), AlertStatus.userPrompt, AlertSize.mid, Priority.LOW, VisualAlert.none, AudibleAlert.none, 0., 0., .2), }, @@ -413,46 +418,50 @@ def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: boo EventName.preLaneChangeLeft: { ET.WARNING: Alert( - "Steer Left to Start Lane Change", - "Monitor Other Vehicles", + _("Steer Left to Start Lane Change"), + _("Monitor Other Vehicles"), AlertStatus.normal, AlertSize.mid, Priority.LOW, VisualAlert.steerRequired, AudibleAlert.none, .0, .1, .1, alert_rate=0.75), }, EventName.preLaneChangeRight: { ET.WARNING: Alert( - "Steer Right to Start Lane Change", - "Monitor Other Vehicles", + _("Steer Right to Start Lane Change"), + _("Monitor Other Vehicles"), AlertStatus.normal, AlertSize.mid, Priority.LOW, VisualAlert.steerRequired, AudibleAlert.none, .0, .1, .1, alert_rate=0.75), }, EventName.laneChangeBlocked: { ET.WARNING: Alert( - "Car Detected in Blindspot", - "Monitor Other Vehicles", + _("Car Detected in Blindspot"), + _("Monitor Other Vehicles"), AlertStatus.normal, AlertSize.mid, Priority.LOW, VisualAlert.steerRequired, AudibleAlert.none, .0, .1, .1), }, EventName.laneChange: { ET.WARNING: Alert( - "Changing Lane", - "Monitor Other Vehicles", + _("Changing Lane"), + _("Monitor Other Vehicles"), AlertStatus.normal, AlertSize.mid, Priority.LOW, VisualAlert.steerRequired, AudibleAlert.none, .0, .1, .1), }, EventName.steerSaturated: { ET.WARNING: Alert( - "TAKE CONTROL", - "Turn Exceeds Steering Limit", + _("TAKE CONTROL"), + _("Turn Exceeds Steering Limit"), AlertStatus.userPrompt, AlertSize.mid, Priority.LOW, VisualAlert.steerRequired, AudibleAlert.chimePrompt, 1., 1., 1.), }, EventName.fanMalfunction: { - ET.PERMANENT: NormalPermanentAlert("Fan Malfunction", "Contact Support"), + ET.PERMANENT: NormalPermanentAlert(_("Fan Malfunction"), _("Contact Support")), + }, + + EventName.cameraMalfunction: { + ET.PERMANENT: NormalPermanentAlert(_("Camera Malfunction"), _("Contact Support")), }, EventName.cameraMalfunction: { @@ -479,17 +488,17 @@ def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: boo EventName.brakeHold: { ET.USER_DISABLE: EngagementAlert(AudibleAlert.chimeDisengage), - ET.NO_ENTRY: NoEntryAlert("Brake Hold Active"), + ET.NO_ENTRY: NoEntryAlert(_("Brake Hold Active")), }, EventName.parkBrake: { ET.USER_DISABLE: EngagementAlert(AudibleAlert.chimeDisengage), - ET.NO_ENTRY: NoEntryAlert("Park Brake Engaged"), + ET.NO_ENTRY: NoEntryAlert(_("Park Brake Engaged")), }, EventName.pedalPressed: { ET.USER_DISABLE: EngagementAlert(AudibleAlert.chimeDisengage), - ET.NO_ENTRY: NoEntryAlert("Pedal Pressed During Attempt", + ET.NO_ENTRY: NoEntryAlert(_("Pedal Pressed During Attempt"), visual_alert=VisualAlert.brakePressed), }, @@ -500,40 +509,40 @@ def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: boo EventName.wrongCruiseMode: { ET.USER_DISABLE: EngagementAlert(AudibleAlert.chimeDisengage), - ET.NO_ENTRY: NoEntryAlert("Enable Adaptive Cruise"), + ET.NO_ENTRY: NoEntryAlert(_("Enable Adaptive Cruise")), }, EventName.steerTempUnavailable: { ET.WARNING: Alert( - "TAKE CONTROL", - "Steering Temporarily Unavailable", + _("TAKE CONTROL"), + _("Steering Temporarily Unavailable"), AlertStatus.userPrompt, AlertSize.mid, Priority.LOW, VisualAlert.steerRequired, AudibleAlert.chimeWarning1, .4, 2., 3.), - ET.NO_ENTRY: NoEntryAlert("Steering Temporarily Unavailable", + ET.NO_ENTRY: NoEntryAlert(_("Steering Temporarily Unavailable"), duration_hud_alert=0.), }, EventName.outOfSpace: { ET.PERMANENT: Alert( - "Out of Storage", + _("Out of Storage"), "", AlertStatus.normal, AlertSize.small, Priority.LOWER, VisualAlert.none, AudibleAlert.none, 0., 0., .2), - ET.NO_ENTRY: NoEntryAlert("Out of Storage Space", + ET.NO_ENTRY: NoEntryAlert(_("Out of Storage Space"), duration_hud_alert=0.), }, EventName.belowEngageSpeed: { - ET.NO_ENTRY: NoEntryAlert("Speed Too Low"), + ET.NO_ENTRY: NoEntryAlert(_("Speed Too Low")), }, EventName.sensorDataInvalid: { ET.PERMANENT: Alert( - "No Data from Device Sensors", - "Reboot your Device", + _("No Data from Device Sensors"), + _("Reboot your Device"), AlertStatus.normal, AlertSize.mid, Priority.LOWER, VisualAlert.none, AudibleAlert.none, 0., 0., .2, creation_delay=1.), - ET.NO_ENTRY: NoEntryAlert("No Data from Device Sensors"), + ET.NO_ENTRY: NoEntryAlert(_("No Data from Device Sensors")), }, EventName.noGps: { @@ -541,213 +550,283 @@ def wrong_car_mode_alert(CP: car.CarParams, sm: messaging.SubMaster, metric: boo }, EventName.soundsUnavailable: { - ET.PERMANENT: NormalPermanentAlert("Speaker not found", "Reboot your Device"), + ET.PERMANENT: NormalPermanentAlert(_("Speaker not found"), _("Reboot your Device")), ET.NO_ENTRY: NoEntryAlert("Speaker not found"), }, EventName.tooDistracted: { - ET.NO_ENTRY: NoEntryAlert("Distraction Level Too High"), + ET.NO_ENTRY: NoEntryAlert(_("Distraction Level Too High")), }, EventName.overheat: { ET.PERMANENT: Alert( - "System Overheated", + _("System Overheated"), "", AlertStatus.normal, AlertSize.small, Priority.LOWER, VisualAlert.none, AudibleAlert.none, 0., 0., .2), - ET.SOFT_DISABLE: SoftDisableAlert("System Overheated"), - ET.NO_ENTRY: NoEntryAlert("System Overheated"), + ET.SOFT_DISABLE: SoftDisableAlert(_("System Overheated")), + ET.NO_ENTRY: NoEntryAlert(_("System Overheated")), }, EventName.wrongGear: { - ET.SOFT_DISABLE: SoftDisableAlert("Gear not D"), - ET.NO_ENTRY: NoEntryAlert("Gear not D"), + ET.SOFT_DISABLE: SoftDisableAlert(_("Gear not D")), + ET.NO_ENTRY: NoEntryAlert(_("Gear not D")), }, EventName.calibrationInvalid: { - ET.PERMANENT: NormalPermanentAlert("Calibration Invalid", "Remount Device and Recalibrate"), - ET.SOFT_DISABLE: SoftDisableAlert("Calibration Invalid: Remount Device & Recalibrate"), - ET.NO_ENTRY: NoEntryAlert("Calibration Invalid: Remount Device & Recalibrate"), + ET.PERMANENT: NormalPermanentAlert(_("Calibration Invalid"), _("Remount Device and Recalibrate")), + ET.SOFT_DISABLE: SoftDisableAlert(_("Calibration Invalid: Remount Device & Recalibrate")), + ET.NO_ENTRY: NoEntryAlert(_("Calibration Invalid: Remount Device & Recalibrate")), }, EventName.calibrationIncomplete: { ET.PERMANENT: calibration_incomplete_alert, - ET.SOFT_DISABLE: SoftDisableAlert("Calibration in Progress"), - ET.NO_ENTRY: NoEntryAlert("Calibration in Progress"), + ET.SOFT_DISABLE: SoftDisableAlert(_("Calibration in Progress")), + ET.NO_ENTRY: NoEntryAlert(_("Calibration in Progress")), }, EventName.doorOpen: { - ET.SOFT_DISABLE: SoftDisableAlert("Door Open"), - ET.NO_ENTRY: NoEntryAlert("Door Open"), + ET.SOFT_DISABLE: SoftDisableAlert(_("Door Open")), + ET.NO_ENTRY: NoEntryAlert(_("Door Open")), }, EventName.seatbeltNotLatched: { - ET.SOFT_DISABLE: SoftDisableAlert("Seatbelt Unlatched"), - ET.NO_ENTRY: NoEntryAlert("Seatbelt Unlatched"), + ET.SOFT_DISABLE: SoftDisableAlert(_("Seatbelt Unlatched")), + ET.NO_ENTRY: NoEntryAlert(_("Seatbelt Unlatched")), }, EventName.espDisabled: { - ET.SOFT_DISABLE: SoftDisableAlert("ESP Off"), - ET.NO_ENTRY: NoEntryAlert("ESP Off"), + ET.SOFT_DISABLE: SoftDisableAlert(_("ESP Off")), + ET.NO_ENTRY: NoEntryAlert(_("ESP Off")), }, EventName.lowBattery: { - ET.SOFT_DISABLE: SoftDisableAlert("Low Battery"), - ET.NO_ENTRY: NoEntryAlert("Low Battery"), + ET.SOFT_DISABLE: SoftDisableAlert(_("Low Battery")), + ET.NO_ENTRY: NoEntryAlert(_("Low Battery")), }, EventName.commIssue: { - ET.SOFT_DISABLE: SoftDisableAlert("Communication Issue between Processes"), - ET.NO_ENTRY: NoEntryAlert("Communication Issue between Processes", + ET.SOFT_DISABLE: SoftDisableAlert(_("Communication Issue between Processes")), + ET.NO_ENTRY: NoEntryAlert(_("Communication Issue between Processes"), audible_alert=AudibleAlert.chimeDisengage), }, EventName.radarCommIssue: { - ET.SOFT_DISABLE: SoftDisableAlert("Radar Communication Issue"), - ET.NO_ENTRY: NoEntryAlert("Radar Communication Issue", + ET.SOFT_DISABLE: SoftDisableAlert(_("Radar Communication Issue")), + ET.NO_ENTRY: NoEntryAlert(_("Radar Communication Issue"), audible_alert=AudibleAlert.chimeDisengage), }, EventName.radarCanError: { - ET.SOFT_DISABLE: SoftDisableAlert("Radar Error: Restart the Car"), - ET.NO_ENTRY: NoEntryAlert("Radar Error: Restart the Car"), + ET.SOFT_DISABLE: SoftDisableAlert(_("Radar Error: Restart the Car")), + ET.NO_ENTRY: NoEntryAlert(_("Radar Error: Restart the Car")), }, EventName.radarFault: { - ET.SOFT_DISABLE: SoftDisableAlert("Radar Error: Restart the Car"), - ET.NO_ENTRY : NoEntryAlert("Radar Error: Restart the Car"), + ET.SOFT_DISABLE: SoftDisableAlert(_("Radar Error: Restart the Car")), + ET.NO_ENTRY : NoEntryAlert(_("Radar Error: Restart the Car")), }, EventName.modeldLagging: { - ET.SOFT_DISABLE: SoftDisableAlert("Driving model lagging"), - ET.NO_ENTRY : NoEntryAlert("Driving model lagging"), + ET.SOFT_DISABLE: SoftDisableAlert(_("Driving model lagging")), + ET.NO_ENTRY : NoEntryAlert(_("Driving model lagging")), }, EventName.posenetInvalid: { - ET.SOFT_DISABLE: SoftDisableAlert("Model Output Uncertain"), - ET.NO_ENTRY: NoEntryAlert("Model Output Uncertain"), + ET.SOFT_DISABLE: SoftDisableAlert(_("Model Output Uncertain")), + ET.NO_ENTRY: NoEntryAlert(_("Model Output Uncertain")), }, EventName.deviceFalling: { - ET.SOFT_DISABLE: SoftDisableAlert("Device Fell Off Mount"), - ET.NO_ENTRY: NoEntryAlert("Device Fell Off Mount"), + ET.SOFT_DISABLE: SoftDisableAlert(_("Device Fell Off Mount")), + ET.NO_ENTRY: NoEntryAlert(_("Device Fell Off Mount")), }, EventName.lowMemory: { - ET.SOFT_DISABLE: SoftDisableAlert("Low Memory: Reboot Your Device"), - ET.PERMANENT: NormalPermanentAlert("Low Memory", "Reboot your Device"), - ET.NO_ENTRY : NoEntryAlert("Low Memory: Reboot Your Device", + ET.SOFT_DISABLE: SoftDisableAlert(_("Low Memory: Reboot Your Device")), + ET.PERMANENT: NormalPermanentAlert(_("Low Memory"), _("Reboot your Device")), + ET.NO_ENTRY : NoEntryAlert(_("Low Memory: Reboot Your Device"), audible_alert=AudibleAlert.chimeDisengage), }, EventName.controlsFailed: { - ET.IMMEDIATE_DISABLE: ImmediateDisableAlert("Controls Failed"), - ET.NO_ENTRY: NoEntryAlert("Controls Failed"), + ET.IMMEDIATE_DISABLE: ImmediateDisableAlert(_("Controls Failed")), + ET.NO_ENTRY: NoEntryAlert(_("Controls Failed")), }, EventName.controlsMismatch: { - ET.IMMEDIATE_DISABLE: ImmediateDisableAlert("Controls Mismatch"), + ET.IMMEDIATE_DISABLE: ImmediateDisableAlert(_("Controls Mismatch")), }, EventName.canError: { - ET.IMMEDIATE_DISABLE: ImmediateDisableAlert("CAN Error: Check Connections"), + ET.IMMEDIATE_DISABLE: ImmediateDisableAlert(_("CAN Error: Check Connections")), ET.PERMANENT: Alert( - "CAN Error: Check Connections", + _("CAN Error: Check Connections"), "", AlertStatus.normal, AlertSize.small, Priority.LOW, VisualAlert.none, AudibleAlert.none, 0., 0., .2, creation_delay=1.), - ET.NO_ENTRY: NoEntryAlert("CAN Error: Check Connections"), + ET.NO_ENTRY: NoEntryAlert(_("CAN Error: Check Connections")), }, EventName.steerUnavailable: { - ET.IMMEDIATE_DISABLE: ImmediateDisableAlert("LKAS Fault: Restart the Car"), + ET.IMMEDIATE_DISABLE: ImmediateDisableAlert(_("LKAS Fault: Restart the Car")), ET.PERMANENT: Alert( - "LKAS Fault: Restart the car to engage", + _("LKAS Fault: Restart the car to engage"), "", AlertStatus.normal, AlertSize.small, Priority.LOWER, VisualAlert.none, AudibleAlert.none, 0., 0., .2), - ET.NO_ENTRY: NoEntryAlert("LKAS Fault: Restart the Car"), + ET.NO_ENTRY: NoEntryAlert(_("LKAS Fault: Restart the Car")), }, EventName.brakeUnavailable: { - ET.IMMEDIATE_DISABLE: ImmediateDisableAlert("Cruise Fault: Restart the Car"), + ET.IMMEDIATE_DISABLE: ImmediateDisableAlert(_("Cruise Fault: Restart the Car")), ET.PERMANENT: Alert( - "Cruise Fault: Restart the car to engage", + _("Cruise Fault: Restart the car to engage"), "", AlertStatus.normal, AlertSize.small, Priority.LOWER, VisualAlert.none, AudibleAlert.none, 0., 0., .2), - ET.NO_ENTRY: NoEntryAlert("Cruise Fault: Restart the Car"), + ET.NO_ENTRY: NoEntryAlert(_("Cruise Fault: Restart the Car")), }, EventName.reverseGear: { ET.PERMANENT: Alert( - "Reverse\nGear", + _("Reverse\nGear"), "", AlertStatus.normal, AlertSize.full, Priority.LOWEST, VisualAlert.none, AudibleAlert.none, 0., 0., .2, creation_delay=0.5), - ET.IMMEDIATE_DISABLE: ImmediateDisableAlert("Reverse Gear"), - ET.NO_ENTRY: NoEntryAlert("Reverse Gear"), + ET.IMMEDIATE_DISABLE: ImmediateDisableAlert(_("Reverse Gear")), + ET.NO_ENTRY: NoEntryAlert(_("Reverse Gear")), }, EventName.cruiseDisabled: { - ET.IMMEDIATE_DISABLE: ImmediateDisableAlert("Cruise Is Off"), + ET.IMMEDIATE_DISABLE: ImmediateDisableAlert(_("Cruise Is Off")), }, EventName.plannerError: { - ET.IMMEDIATE_DISABLE: ImmediateDisableAlert("Planner Solution Error"), - ET.NO_ENTRY: NoEntryAlert("Planner Solution Error"), + ET.IMMEDIATE_DISABLE: ImmediateDisableAlert(_("Planner Solution Error")), + ET.NO_ENTRY: NoEntryAlert(_("Planner Solution Error")), }, EventName.relayMalfunction: { ET.IMMEDIATE_DISABLE: ImmediateDisableAlert("Harness Malfunction"), - ET.PERMANENT: NormalPermanentAlert("Harness Malfunction", "Check Hardware"), - ET.NO_ENTRY: NoEntryAlert("Harness Malfunction"), + ET.PERMANENT: NormalPermanentAlert(_("Harness Malfunction"), _("Check Hardware")), + ET.NO_ENTRY: NoEntryAlert(_("Harness Malfunction")), }, EventName.noTarget: { ET.IMMEDIATE_DISABLE: Alert( - "openpilot Canceled", - "No close lead car", + _("openpilot Canceled"), + _("No close lead car"), AlertStatus.normal, AlertSize.mid, Priority.HIGH, VisualAlert.none, AudibleAlert.chimeDisengage, .4, 2., 3.), - ET.NO_ENTRY : NoEntryAlert("No Close Lead Car"), + ET.NO_ENTRY : NoEntryAlert(_("No Close Lead Car")), }, EventName.speedTooLow: { ET.IMMEDIATE_DISABLE: Alert( - "openpilot Canceled", - "Speed too low", + _("openpilot Canceled"), + _("Speed too low"), AlertStatus.normal, AlertSize.mid, Priority.HIGH, VisualAlert.none, AudibleAlert.chimeDisengage, .4, 2., 3.), }, EventName.speedTooHigh: { ET.WARNING: Alert( - "Speed Too High", - "Slow down to resume operation", + _("Speed Too High"), + _("Slow down to resume operation"), AlertStatus.normal, AlertSize.mid, Priority.HIGH, VisualAlert.steerRequired, AudibleAlert.none, 2.2, 3., 4.), ET.NO_ENTRY: Alert( - "Speed Too High", - "Slow down to engage", + _("Speed Too High"), + _("Slow down to engage"), AlertStatus.normal, AlertSize.mid, Priority.LOW, VisualAlert.none, AudibleAlert.chimeError, .4, 2., 3.), }, # TODO: this is unclear, update check only happens offroad EventName.internetConnectivityNeeded: { - ET.PERMANENT: NormalPermanentAlert("Connect to Internet", "An Update Check Is Required to Engage"), - ET.NO_ENTRY: NoEntryAlert("Connect to Internet", + ET.PERMANENT: NormalPermanentAlert(_("Connect to Internet"), _("An Update Check Is Required to Engage")), + ET.NO_ENTRY: NoEntryAlert(_("Connect to Internet"), audible_alert=AudibleAlert.chimeDisengage), }, EventName.lowSpeedLockout: { ET.PERMANENT: Alert( - "Cruise Fault: Restart the car to engage", + _("Cruise Fault: Restart the car to engage"), "", AlertStatus.normal, AlertSize.small, Priority.LOWER, VisualAlert.none, AudibleAlert.none, 0., 0., .2), - ET.NO_ENTRY: NoEntryAlert("Cruise Fault: Restart the Car"), + ET.NO_ENTRY: NoEntryAlert(_("Cruise Fault: Restart the Car")), }, + # dp + EventName.preLaneChangeLeftALC: { + ET.WARNING: Alert( + _("Left ALC will start in 3s"), + _("Monitor Other Vehicles"), + AlertStatus.normal, AlertSize.mid, + Priority.LOW, VisualAlert.steerRequired, AudibleAlert.chimeWarning2, .1, .1, .1, alert_rate=0.75), + }, + + EventName.preLaneChangeRightALC: { + ET.WARNING: Alert( + _("Right ALC will start in 3s"), + _("Monitor Other Vehicles"), + AlertStatus.normal, AlertSize.mid, + Priority.LOW, VisualAlert.steerRequired, AudibleAlert.chimeWarning2, .1, .1, .1, alert_rate=0.75), + }, + + EventName.manualSteeringRequired: { + ET.WARNING: Alert( + _("STEERING REQUIRED: Lane Keeping OFF"), + "", + AlertStatus.normal, AlertSize.small, + Priority.LOW, VisualAlert.none, AudibleAlert.none, .0, .1, .1, alert_rate=0.25), + }, + + EventName.manualSteeringRequiredBlinkersOn: { + ET.WARNING: Alert( + _("STEERING REQUIRED: Blinkers ON"), + "", + AlertStatus.normal, AlertSize.small, + Priority.LOW, VisualAlert.none, AudibleAlert.none, .0, .1, .1, alert_rate=0.25), + }, + + EventName.leadCarMoving: { + ET.PERMANENT: Alert( + _("Lead Car Is Moving"), + "", + AlertStatus.userPrompt, AlertSize.small, + Priority.LOW, VisualAlert.steerRequired, AudibleAlert.chimePrompt, .1, .1, .1), + ET.WARNING: Alert( + _("Lead Car Is Moving"), + "", + AlertStatus.userPrompt, AlertSize.small, + Priority.LOW, VisualAlert.steerRequired, AudibleAlert.chimePrompt, .1, .1, .1), + }, + + # timebomb + EventName.timebombWarn: { + ET.WARNING: Alert( + _("WARNING"), + _("Grab wheel to start bypass"), + AlertStatus.normal, AlertSize.mid, + Priority.LOW, VisualAlert.steerRequired, AudibleAlert.chimeWarning1, .4, 2., 3.), + }, + + EventName.timebombBypassing: { + ET.WARNING: Alert( + _("BYPASSING"), + _("HOLD WHEEL"), + AlertStatus.normal, AlertSize.mid, + Priority.LOW, VisualAlert.steerRequired, AudibleAlert.chimeWarning1, .4, 2., 3.), + }, + + EventName.timebombBypassed: { + ET.WARNING: Alert( + _("Bypassed!"), + _("Release wheel when ready"), + AlertStatus.normal, AlertSize.mid, + Priority.LOW, VisualAlert.steerRequired, AudibleAlert.chimeWarning1, 3., 2., 3.), + }, } diff --git a/selfdrive/controls/lib/lane_planner.py b/selfdrive/controls/lib/lane_planner.py index 789ef8571fa036..af77c29deefa77 100644 --- a/selfdrive/controls/lib/lane_planner.py +++ b/selfdrive/controls/lib/lane_planner.py @@ -1,6 +1,8 @@ from common.numpy_fast import interp import numpy as np from cereal import log +from common.dp_common import get_last_modified, param_get_if_updated +from common.dp_time import LAST_MODIFIED_LANE_PLANNER CAMERA_OFFSET = 0.06 # m from center car to camera @@ -28,9 +30,9 @@ def __init__(self): self.p_poly = [0., 0., 0., 0.] self.d_poly = [0., 0., 0., 0.] - self.lane_width_estimate = 3.7 + self.lane_width_estimate = 2.85 self.lane_width_certainty = 1.0 - self.lane_width = 3.7 + self.lane_width = 2.85 self.l_prob = 0. self.r_prob = 0. @@ -44,6 +46,13 @@ def __init__(self): self._path_pinv = compute_path_pinv() self.x_points = np.arange(50) + # dp + self.dp_camera_offset = CAMERA_OFFSET * 100 + self.last_modified_dp_camera_offset = None + self.modified = None + self.last_modified = None + self.last_modified_check = None + def parse_model(self, md): if len(md.leftLane.poly): self.l_poly = np.array(md.leftLane.poly) @@ -64,8 +73,14 @@ def parse_model(self, md): def update_d_poly(self, v_ego): # only offset left and right lane lines; offsetting p_poly does not make sense - self.l_poly[3] += CAMERA_OFFSET - self.r_poly[3] += CAMERA_OFFSET + self.last_modified_check, self.modified = get_last_modified(LAST_MODIFIED_LANE_PLANNER, self.last_modified_check, self.modified) + if self.last_modified != self.modified: + self.dp_camera_offset, self.last_modified_dp_camera_offset = param_get_if_updated("dp_camera_offset", "int", self.dp_camera_offset, self.last_modified_dp_camera_offset) + self.last_modified = self.modified + offset = self.dp_camera_offset * 0.01 if self.dp_camera_offset != 0 else 0 + self.l_poly[3] += offset + self.r_poly[3] += offset + self.p_poly[3] += offset # Reduce reliance on lanelines that are too far apart or # will be in a few seconds @@ -89,7 +104,7 @@ def update_d_poly(self, v_ego): self.lane_width_certainty += 0.05 * (l_prob * r_prob - self.lane_width_certainty) current_lane_width = abs(self.l_poly[3] - self.r_poly[3]) self.lane_width_estimate += 0.005 * (current_lane_width - self.lane_width_estimate) - speed_lane_width = interp(v_ego, [0., 31.], [2.8, 3.5]) + speed_lane_width = interp(v_ego, [0., 14., 20.], [2.5, 3., 3.5]) # German Standards self.lane_width = self.lane_width_certainty * self.lane_width_estimate + \ (1 - self.lane_width_certainty) * speed_lane_width diff --git a/selfdrive/controls/lib/long_mpc.py b/selfdrive/controls/lib/long_mpc.py index f9bf15cc048067..2bd3a761d1b705 100644 --- a/selfdrive/controls/lib/long_mpc.py +++ b/selfdrive/controls/lib/long_mpc.py @@ -7,6 +7,7 @@ from selfdrive.controls.lib.radar_helpers import _LEAD_ACCEL_TAU from selfdrive.controls.lib.longitudinal_mpc import libmpc_py from selfdrive.controls.lib.drive_helpers import MPC_COST_LONG +from selfdrive.controls.lib.dynamic_follow import DynamicFollow LOG_MPC = os.environ.get('LOG_MPC', False) @@ -14,7 +15,7 @@ class LongitudinalMpc(): def __init__(self, mpc_id): self.mpc_id = mpc_id - + self.dynamic_follow = DynamicFollow(mpc_id) self.setup_mpc() self.v_mpc = 0.0 self.v_mpc_future = 0.0 @@ -77,11 +78,13 @@ def update(self, pm, CS, lead): self.libmpc.init_with_simulation(self.v_mpc, x_lead, v_lead, a_lead, self.a_lead_tau) self.new_lead = True + self.dynamic_follow.update_lead(v_lead, a_lead, x_lead, lead.status, self.new_lead) self.prev_lead_status = True self.prev_lead_x = x_lead self.cur_state[0].x_l = x_lead self.cur_state[0].v_l = v_lead else: + self.dynamic_follow.update_lead(new_lead=self.new_lead) self.prev_lead_status = False # Fake a fast lead car, so mpc keeps running self.cur_state[0].x_l = 50.0 @@ -91,7 +94,8 @@ def update(self, pm, CS, lead): # Calculate mpc t = sec_since_boot() - n_its = self.libmpc.run_mpc(self.cur_state, self.mpc_solution, self.a_lead_tau, a_lead) + TR = self.dynamic_follow.update(CS, self.libmpc) # update dynamic follow + n_its = self.libmpc.run_mpc(self.cur_state, self.mpc_solution, self.a_lead_tau, a_lead, TR) duration = int((sec_since_boot() - t) * 1e9) if LOG_MPC: diff --git a/selfdrive/controls/lib/longcontrol.py b/selfdrive/controls/lib/longcontrol.py index f31dcb05bfc1e0..e1edbb8c6bc930 100644 --- a/selfdrive/controls/lib/longcontrol.py +++ b/selfdrive/controls/lib/longcontrol.py @@ -1,6 +1,8 @@ from cereal import log from common.numpy_fast import clip, interp from selfdrive.controls.lib.pid import PIController +from common.params import Params +from selfdrive.controls.lib.dynamic_gas import DynamicGas LongCtrlState = log.ControlsState.LongControlState @@ -62,18 +64,27 @@ def __init__(self, CP, compute_gb): convert=compute_gb) self.v_pid = 0.0 self.last_output_gb = 0.0 + #dynamic_gas + params = Params() + self.dp_dynamic_gas = (params.get('dp_dynamic_gas') == b'1') + if self.dp_dynamic_gas: + self.dynamic_gas = DynamicGas(CP) def reset(self, v_pid): """Reset PID controller and change setpoint""" self.pid.reset() self.v_pid = v_pid - def update(self, active, CS, v_target, v_target_future, a_target, CP): + def update(self, active, CS, v_target, v_target_future, a_target, CP, sm): """Update longitudinal control. This updates the state machine and runs a PID loop""" # Actuation limits gas_max = interp(CS.vEgo, CP.gasMaxBP, CP.gasMaxV) brake_max = interp(CS.vEgo, CP.brakeMaxBP, CP.brakeMaxV) + #dynamic_gas + if self.dp_dynamic_gas: + gas_max = self.dynamic_gas.update(CS, sm) + # Update state machine output_gb = self.last_output_gb self.long_control_state = long_control_state_trans(active, self.long_control_state, CS.vEgo, @@ -82,7 +93,7 @@ def update(self, active, CS, v_target, v_target_future, a_target, CP): v_ego_pid = max(CS.vEgo, MIN_CAN_SPEED) # Without this we get jumps, CAN bus reports 0 when speed < 0.3 - if self.long_control_state == LongCtrlState.off or CS.gasPressed: + if self.long_control_state == LongCtrlState.off or CS.gasPressed or CS.brakePressed: self.reset(v_ego_pid) output_gb = 0. diff --git a/selfdrive/controls/lib/longitudinal_mpc/lib_mpc_export/acado_solver.c b/selfdrive/controls/lib/longitudinal_mpc/lib_mpc_export/acado_solver.c index 8cfc06f3b8ef70..ba05c6a7e984ed 100644 --- a/selfdrive/controls/lib/longitudinal_mpc/lib_mpc_export/acado_solver.c +++ b/selfdrive/controls/lib/longitudinal_mpc/lib_mpc_export/acado_solver.c @@ -68,7 +68,7 @@ acadoWorkspace.evGu[lRun1 * 3 + 2] = acadoWorkspace.state[14]; return ret; } -void acado_evaluateLSQ(const real_t* in, real_t* out) +void acado_evaluateLSQ(const real_t* in, real_t* out, double TR) { const real_t* xd = in; const real_t* u = in + 3; @@ -78,29 +78,29 @@ real_t* a = acadoWorkspace.objAuxVar; /* Compute intermediate quantities: */ a[0] = (sqrt((xd[1]+(real_t)(5.0000000000000000e-01)))); -a[1] = (exp(((real_t)(2.9999999999999999e-01)*(((((((xd[1]*(real_t)(1.8000000000000000e+00))-((od[1]-xd[1])*(real_t)(1.8000000000000000e+00)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))+(real_t)(4.0000000000000000e+00))-(od[0]-xd[0]))/(a[0]+(real_t)(1.0000000000000001e-01)))))); +a[1] = (exp(((real_t)(2.9999999999999999e-01)*(((((((xd[1]*(real_t)(TR))-((od[1]-xd[1])*(real_t)(TR)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))+(real_t)(4.0000000000000000e+00))-(od[0]-xd[0]))/(a[0]+(real_t)(1.0000000000000001e-01)))))); a[2] = ((real_t)(1.0000000000000000e+00)/(a[0]+(real_t)(1.0000000000000001e-01))); -a[3] = (exp(((real_t)(2.9999999999999999e-01)*(((((((xd[1]*(real_t)(1.8000000000000000e+00))-((od[1]-xd[1])*(real_t)(1.8000000000000000e+00)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))+(real_t)(4.0000000000000000e+00))-(od[0]-xd[0]))/(a[0]+(real_t)(1.0000000000000001e-01)))))); +a[3] = (exp(((real_t)(2.9999999999999999e-01)*(((((((xd[1]*(real_t)(TR))-((od[1]-xd[1])*(real_t)(TR)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))+(real_t)(4.0000000000000000e+00))-(od[0]-xd[0]))/(a[0]+(real_t)(1.0000000000000001e-01)))))); a[4] = (((real_t)(2.9999999999999999e-01)*(((real_t)(0.0000000000000000e+00)-((real_t)(0.0000000000000000e+00)-(real_t)(1.0000000000000000e+00)))*a[2]))*a[3]); a[5] = ((real_t)(1.0000000000000000e+00)/(real_t)(1.9620000000000001e+01)); a[6] = (1.0/sqrt((xd[1]+(real_t)(5.0000000000000000e-01)))); a[7] = (a[6]*(real_t)(5.0000000000000000e-01)); a[8] = (a[2]*a[2]); -a[9] = (((real_t)(2.9999999999999999e-01)*(((((real_t)(1.8000000000000000e+00)-((real_t)(-1.8000000000000000e+00)))+((xd[1]+xd[1])*a[5]))*a[2])-((((((((xd[1]*(real_t)(1.8000000000000000e+00))-((od[1]-xd[1])*(real_t)(1.8000000000000000e+00)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))+(real_t)(4.0000000000000000e+00))-(od[0]-xd[0]))*a[7])*a[8])))*a[3]); +a[9] = (((real_t)(2.9999999999999999e-01)*(((((real_t)(TR)-((real_t)(-TR)))+((xd[1]+xd[1])*a[5]))*a[2])-((((((((xd[1]*(real_t)(TR))-((od[1]-xd[1])*(real_t)(TR)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))+(real_t)(4.0000000000000000e+00))-(od[0]-xd[0]))*a[7])*a[8])))*a[3]); a[10] = ((real_t)(1.0000000000000000e+00)/(((real_t)(5.0000000000000003e-02)*xd[1])+(real_t)(5.0000000000000000e-01))); a[11] = ((real_t)(1.0000000000000000e+00)/(real_t)(1.9620000000000001e+01)); a[12] = (a[10]*a[10]); /* Compute outputs: */ out[0] = (a[1]-(real_t)(1.0000000000000000e+00)); -out[1] = (((od[0]-xd[0])-((real_t)(4.0000000000000000e+00)+((((xd[1]*(real_t)(1.8000000000000000e+00))-((od[1]-xd[1])*(real_t)(1.8000000000000000e+00)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))))/(((real_t)(5.0000000000000003e-02)*xd[1])+(real_t)(5.0000000000000000e-01))); +out[1] = (((od[0]-xd[0])-((real_t)(4.0000000000000000e+00)+((((xd[1]*(real_t)(TR))-((od[1]-xd[1])*(real_t)(TR)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))))/(((real_t)(5.0000000000000003e-02)*xd[1])+(real_t)(5.0000000000000000e-01))); out[2] = (xd[2]*(((real_t)(1.0000000000000001e-01)*xd[1])+(real_t)(1.0000000000000000e+00))); out[3] = (u[0]*(((real_t)(1.0000000000000001e-01)*xd[1])+(real_t)(1.0000000000000000e+00))); out[4] = a[4]; out[5] = a[9]; out[6] = (real_t)(0.0000000000000000e+00); out[7] = (((real_t)(0.0000000000000000e+00)-(real_t)(1.0000000000000000e+00))*a[10]); -out[8] = ((((real_t)(0.0000000000000000e+00)-(((real_t)(1.8000000000000000e+00)-((real_t)(-1.8000000000000000e+00)))+((xd[1]+xd[1])*a[11])))*a[10])-((((od[0]-xd[0])-((real_t)(4.0000000000000000e+00)+((((xd[1]*(real_t)(1.8000000000000000e+00))-((od[1]-xd[1])*(real_t)(1.8000000000000000e+00)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))))*(real_t)(5.0000000000000003e-02))*a[12])); +out[8] = ((((real_t)(0.0000000000000000e+00)-(((real_t)(TR)-((real_t)(-TR)))+((xd[1]+xd[1])*a[11])))*a[10])-((((od[0]-xd[0])-((real_t)(4.0000000000000000e+00)+((((xd[1]*(real_t)(TR))-((od[1]-xd[1])*(real_t)(TR)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))))*(real_t)(5.0000000000000003e-02))*a[12])); out[9] = (real_t)(0.0000000000000000e+00); out[10] = (real_t)(0.0000000000000000e+00); out[11] = (xd[2]*(real_t)(1.0000000000000001e-01)); @@ -114,7 +114,7 @@ out[18] = (real_t)(0.0000000000000000e+00); out[19] = (((real_t)(1.0000000000000001e-01)*xd[1])+(real_t)(1.0000000000000000e+00)); } -void acado_evaluateLSQEndTerm(const real_t* in, real_t* out) +void acado_evaluateLSQEndTerm(const real_t* in, real_t* out, double TR) { const real_t* xd = in; const real_t* od = in + 3; @@ -123,28 +123,28 @@ real_t* a = acadoWorkspace.objAuxVar; /* Compute intermediate quantities: */ a[0] = (sqrt((xd[1]+(real_t)(5.0000000000000000e-01)))); -a[1] = (exp(((real_t)(2.9999999999999999e-01)*(((((((xd[1]*(real_t)(1.8000000000000000e+00))-((od[1]-xd[1])*(real_t)(1.8000000000000000e+00)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))+(real_t)(4.0000000000000000e+00))-(od[0]-xd[0]))/(a[0]+(real_t)(1.0000000000000001e-01)))))); +a[1] = (exp(((real_t)(2.9999999999999999e-01)*(((((((xd[1]*(real_t)(TR))-((od[1]-xd[1])*(real_t)(TR)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))+(real_t)(4.0000000000000000e+00))-(od[0]-xd[0]))/(a[0]+(real_t)(1.0000000000000001e-01)))))); a[2] = ((real_t)(1.0000000000000000e+00)/(a[0]+(real_t)(1.0000000000000001e-01))); -a[3] = (exp(((real_t)(2.9999999999999999e-01)*(((((((xd[1]*(real_t)(1.8000000000000000e+00))-((od[1]-xd[1])*(real_t)(1.8000000000000000e+00)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))+(real_t)(4.0000000000000000e+00))-(od[0]-xd[0]))/(a[0]+(real_t)(1.0000000000000001e-01)))))); +a[3] = (exp(((real_t)(2.9999999999999999e-01)*(((((((xd[1]*(real_t)(TR))-((od[1]-xd[1])*(real_t)(TR)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))+(real_t)(4.0000000000000000e+00))-(od[0]-xd[0]))/(a[0]+(real_t)(1.0000000000000001e-01)))))); a[4] = (((real_t)(2.9999999999999999e-01)*(((real_t)(0.0000000000000000e+00)-((real_t)(0.0000000000000000e+00)-(real_t)(1.0000000000000000e+00)))*a[2]))*a[3]); a[5] = ((real_t)(1.0000000000000000e+00)/(real_t)(1.9620000000000001e+01)); a[6] = (1.0/sqrt((xd[1]+(real_t)(5.0000000000000000e-01)))); a[7] = (a[6]*(real_t)(5.0000000000000000e-01)); a[8] = (a[2]*a[2]); -a[9] = (((real_t)(2.9999999999999999e-01)*(((((real_t)(1.8000000000000000e+00)-((real_t)(-1.8000000000000000e+00)))+((xd[1]+xd[1])*a[5]))*a[2])-((((((((xd[1]*(real_t)(1.8000000000000000e+00))-((od[1]-xd[1])*(real_t)(1.8000000000000000e+00)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))+(real_t)(4.0000000000000000e+00))-(od[0]-xd[0]))*a[7])*a[8])))*a[3]); +a[9] = (((real_t)(2.9999999999999999e-01)*(((((real_t)(TR)-((real_t)(-TR)))+((xd[1]+xd[1])*a[5]))*a[2])-((((((((xd[1]*(real_t)(TR))-((od[1]-xd[1])*(real_t)(TR)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))+(real_t)(4.0000000000000000e+00))-(od[0]-xd[0]))*a[7])*a[8])))*a[3]); a[10] = ((real_t)(1.0000000000000000e+00)/(((real_t)(5.0000000000000003e-02)*xd[1])+(real_t)(5.0000000000000000e-01))); a[11] = ((real_t)(1.0000000000000000e+00)/(real_t)(1.9620000000000001e+01)); a[12] = (a[10]*a[10]); /* Compute outputs: */ out[0] = (a[1]-(real_t)(1.0000000000000000e+00)); -out[1] = (((od[0]-xd[0])-((real_t)(4.0000000000000000e+00)+((((xd[1]*(real_t)(1.8000000000000000e+00))-((od[1]-xd[1])*(real_t)(1.8000000000000000e+00)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))))/(((real_t)(5.0000000000000003e-02)*xd[1])+(real_t)(5.0000000000000000e-01))); +out[1] = (((od[0]-xd[0])-((real_t)(4.0000000000000000e+00)+((((xd[1]*(real_t)(TR))-((od[1]-xd[1])*(real_t)(TR)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))))/(((real_t)(5.0000000000000003e-02)*xd[1])+(real_t)(5.0000000000000000e-01))); out[2] = (xd[2]*(((real_t)(1.0000000000000001e-01)*xd[1])+(real_t)(1.0000000000000000e+00))); out[3] = a[4]; out[4] = a[9]; out[5] = (real_t)(0.0000000000000000e+00); out[6] = (((real_t)(0.0000000000000000e+00)-(real_t)(1.0000000000000000e+00))*a[10]); -out[7] = ((((real_t)(0.0000000000000000e+00)-(((real_t)(1.8000000000000000e+00)-((real_t)(-1.8000000000000000e+00)))+((xd[1]+xd[1])*a[11])))*a[10])-((((od[0]-xd[0])-((real_t)(4.0000000000000000e+00)+((((xd[1]*(real_t)(1.8000000000000000e+00))-((od[1]-xd[1])*(real_t)(1.8000000000000000e+00)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))))*(real_t)(5.0000000000000003e-02))*a[12])); +out[7] = ((((real_t)(0.0000000000000000e+00)-(((real_t)(TR)-((real_t)(-TR)))+((xd[1]+xd[1])*a[11])))*a[10])-((((od[0]-xd[0])-((real_t)(4.0000000000000000e+00)+((((xd[1]*(real_t)(TR))-((od[1]-xd[1])*(real_t)(TR)))+((xd[1]*xd[1])/(real_t)(1.9620000000000001e+01)))-((od[1]*od[1])/(real_t)(1.9620000000000001e+01)))))*(real_t)(5.0000000000000003e-02))*a[12])); out[8] = (real_t)(0.0000000000000000e+00); out[9] = (real_t)(0.0000000000000000e+00); out[10] = (xd[2]*(real_t)(1.0000000000000001e-01)); @@ -207,7 +207,7 @@ tmpQN1[7] = + tmpQN2[6]*tmpFx[1] + tmpQN2[7]*tmpFx[4] + tmpQN2[8]*tmpFx[7]; tmpQN1[8] = + tmpQN2[6]*tmpFx[2] + tmpQN2[7]*tmpFx[5] + tmpQN2[8]*tmpFx[8]; } -void acado_evaluateObjective( ) +void acado_evaluateObjective( double TR ) { int runObj; for (runObj = 0; runObj < 20; ++runObj) @@ -219,7 +219,7 @@ acadoWorkspace.objValueIn[3] = acadoVariables.u[runObj]; acadoWorkspace.objValueIn[4] = acadoVariables.od[runObj * 2]; acadoWorkspace.objValueIn[5] = acadoVariables.od[runObj * 2 + 1]; -acado_evaluateLSQ( acadoWorkspace.objValueIn, acadoWorkspace.objValueOut ); +acado_evaluateLSQ( acadoWorkspace.objValueIn, acadoWorkspace.objValueOut, TR ); acadoWorkspace.Dy[runObj * 4] = acadoWorkspace.objValueOut[0]; acadoWorkspace.Dy[runObj * 4 + 1] = acadoWorkspace.objValueOut[1]; acadoWorkspace.Dy[runObj * 4 + 2] = acadoWorkspace.objValueOut[2]; @@ -235,7 +235,7 @@ acadoWorkspace.objValueIn[1] = acadoVariables.x[61]; acadoWorkspace.objValueIn[2] = acadoVariables.x[62]; acadoWorkspace.objValueIn[3] = acadoVariables.od[40]; acadoWorkspace.objValueIn[4] = acadoVariables.od[41]; -acado_evaluateLSQEndTerm( acadoWorkspace.objValueIn, acadoWorkspace.objValueOut ); +acado_evaluateLSQEndTerm( acadoWorkspace.objValueIn, acadoWorkspace.objValueOut, TR ); acadoWorkspace.DyN[0] = acadoWorkspace.objValueOut[0]; acadoWorkspace.DyN[1] = acadoWorkspace.objValueOut[1]; @@ -4589,12 +4589,12 @@ acado_multEDu( &(acadoWorkspace.E[ 624 ]), &(acadoWorkspace.x[ 21 ]), &(acadoVar acado_multEDu( &(acadoWorkspace.E[ 627 ]), &(acadoWorkspace.x[ 22 ]), &(acadoVariables.x[ 60 ]) ); } -int acado_preparationStep( ) +int acado_preparationStep( double TR ) { int ret; ret = acado_modelSimulation(); -acado_evaluateObjective( ); +acado_evaluateObjective( TR ); acado_condensePrep( ); return ret; } @@ -4726,7 +4726,7 @@ kkt += fabs(acadoWorkspace.ubA[index] * prd); return kkt; } -real_t acado_getObjective( ) +real_t acado_getObjective( TR ) { real_t objVal; @@ -4746,7 +4746,7 @@ acadoWorkspace.objValueIn[3] = acadoVariables.u[lRun1]; acadoWorkspace.objValueIn[4] = acadoVariables.od[lRun1 * 2]; acadoWorkspace.objValueIn[5] = acadoVariables.od[lRun1 * 2 + 1]; -acado_evaluateLSQ( acadoWorkspace.objValueIn, acadoWorkspace.objValueOut ); +acado_evaluateLSQ( acadoWorkspace.objValueIn, acadoWorkspace.objValueOut, TR ); acadoWorkspace.Dy[lRun1 * 4] = acadoWorkspace.objValueOut[0] - acadoVariables.y[lRun1 * 4]; acadoWorkspace.Dy[lRun1 * 4 + 1] = acadoWorkspace.objValueOut[1] - acadoVariables.y[lRun1 * 4 + 1]; acadoWorkspace.Dy[lRun1 * 4 + 2] = acadoWorkspace.objValueOut[2] - acadoVariables.y[lRun1 * 4 + 2]; @@ -4757,7 +4757,7 @@ acadoWorkspace.objValueIn[1] = acadoVariables.x[61]; acadoWorkspace.objValueIn[2] = acadoVariables.x[62]; acadoWorkspace.objValueIn[3] = acadoVariables.od[40]; acadoWorkspace.objValueIn[4] = acadoVariables.od[41]; -acado_evaluateLSQEndTerm( acadoWorkspace.objValueIn, acadoWorkspace.objValueOut ); +acado_evaluateLSQEndTerm( acadoWorkspace.objValueIn, acadoWorkspace.objValueOut, TR ); acadoWorkspace.DyN[0] = acadoWorkspace.objValueOut[0] - acadoVariables.yN[0]; acadoWorkspace.DyN[1] = acadoWorkspace.objValueOut[1] - acadoVariables.yN[1]; acadoWorkspace.DyN[2] = acadoWorkspace.objValueOut[2] - acadoVariables.yN[2]; diff --git a/selfdrive/controls/lib/longitudinal_mpc/libmpc_py.py b/selfdrive/controls/lib/longitudinal_mpc/libmpc_py.py index c40b4e071eb640..fd8947ff0131af 100644 --- a/selfdrive/controls/lib/longitudinal_mpc/libmpc_py.py +++ b/selfdrive/controls/lib/longitudinal_mpc/libmpc_py.py @@ -29,8 +29,9 @@ def _get_libmpc(mpc_id): void init(double ttcCost, double distanceCost, double accelerationCost, double jerkCost); void init_with_simulation(double v_ego, double x_l, double v_l, double a_l, double l); + void change_tr(double ttcCost, double distanceCost, double accelerationCost, double jerkCost); int run_mpc(state_t * x0, log_t * solution, - double l, double a_l_0); + double l, double a_l_0, double TR); """) return (ffi, ffi.dlopen(libmpc_fn)) diff --git a/selfdrive/controls/lib/longitudinal_mpc/longitudinal_mpc.c b/selfdrive/controls/lib/longitudinal_mpc/longitudinal_mpc.c index d4bfee8c8aac0d..02d8693e451f2f 100644 --- a/selfdrive/controls/lib/longitudinal_mpc/longitudinal_mpc.c +++ b/selfdrive/controls/lib/longitudinal_mpc/longitudinal_mpc.c @@ -68,6 +68,25 @@ void init(double ttcCost, double distanceCost, double accelerationCost, double j } +void change_tr(double ttcCost, double distanceCost, double accelerationCost, double jerkCost){ + int i; + const int STEP_MULTIPLIER = 3; + + for (i = 0; i < N; i++) { + int f = 1; + if (i > 4){ + f = STEP_MULTIPLIER; + } + acadoVariables.W[16 * i + 0] = ttcCost * f; // exponential cost for time-to-collision (ttc) + acadoVariables.W[16 * i + 5] = distanceCost * f; // desired distance + acadoVariables.W[16 * i + 10] = accelerationCost * f; // acceleration + acadoVariables.W[16 * i + 15] = jerkCost * f; // jerk + } + acadoVariables.WN[0] = ttcCost * STEP_MULTIPLIER; // exponential cost for danger zone + acadoVariables.WN[4] = distanceCost * STEP_MULTIPLIER; // desired distance + acadoVariables.WN[8] = accelerationCost * STEP_MULTIPLIER; // acceleration +} + void init_with_simulation(double v_ego, double x_l_0, double v_l_0, double a_l_0, double l){ int i; @@ -112,7 +131,7 @@ void init_with_simulation(double v_ego, double x_l_0, double v_l_0, double a_l_0 for (i = 0; i < NYN; ++i) acadoVariables.yN[ i ] = 0.0; } -int run_mpc(state_t * x0, log_t * solution, double l, double a_l_0){ +int run_mpc(state_t * x0, log_t * solution, double l, double a_l_0, double TR){ // Calculate lead vehicle predictions int i; double t = 0.; @@ -152,7 +171,7 @@ int run_mpc(state_t * x0, log_t * solution, double l, double a_l_0){ acadoVariables.x[1] = acadoVariables.x0[1] = x0->v_ego; acadoVariables.x[2] = acadoVariables.x0[2] = x0->a_ego; - acado_preparationStep(); + acado_preparationStep(TR); acado_feedbackStep(); for (i = 0; i <= N; i++){ @@ -164,7 +183,7 @@ int run_mpc(state_t * x0, log_t * solution, double l, double a_l_0){ solution->j_ego[i] = acadoVariables.u[i]; } } - solution->cost = acado_getObjective(); + solution->cost = acado_getObjective(TR); // Dont shift states here. Current solution is closer to next timestep than if // we shift by 0.2 seconds. diff --git a/selfdrive/controls/lib/pathplanner.py b/selfdrive/controls/lib/pathplanner.py index a58eae0054ddf5..17ac87271c2904 100644 --- a/selfdrive/controls/lib/pathplanner.py +++ b/selfdrive/controls/lib/pathplanner.py @@ -63,6 +63,13 @@ def __init__(self, CP): self.lane_change_ll_prob = 1.0 self.prev_one_blinker = False + # dp + self.dragon_auto_lc_allowed = False + self.dragon_auto_lc_timer = None + self.dragon_auto_lc_delay = 2. + self.dp_continuous_auto_lc = False + self.dp_did_auto_lc = False + def setup_mpc(self): self.libmpc = libmpc_py.libmpc self.libmpc.init(MPC_COST_LAT.PATH, MPC_COST_LAT.LANE, MPC_COST_LAT.HEADING, self.steer_rate_cost) @@ -100,7 +107,7 @@ def update(self, sm, pm, CP, VM): # Lane change logic one_blinker = sm['carState'].leftBlinker != sm['carState'].rightBlinker - below_lane_change_speed = v_ego < LANE_CHANGE_SPEED_MIN + below_lane_change_speed = v_ego < (sm['dragonConf'].dpAssistedLcMinMph * CV.MPH_TO_MS) if sm['carState'].leftBlinker: self.lane_change_direction = LaneChangeDirection.left @@ -120,6 +127,34 @@ def update(self, sm, pm, CP, VM): lane_change_prob = self.LP.l_lane_change_prob + self.LP.r_lane_change_prob + # dp alc + cur_time = sec_since_boot() + if not below_lane_change_speed and sm['dragonConf'].dpAutoLc and v_ego >= (sm['dragonConf'].dpAutoLcMinMph * CV.MPH_TO_MS): + # we allow auto lc when speed reached dragon_auto_lc_min_mph + self.dragon_auto_lc_allowed = True + else: + # if too slow, we reset all the variables + self.dragon_auto_lc_allowed = False + self.dragon_auto_lc_timer = None + + # disable auto lc when continuous is off and already did auto lc once + if self.dragon_auto_lc_allowed and not sm['dragonConf'].dpAutoLcCont and self.dp_did_auto_lc: + self.dragon_auto_lc_allowed = False + + if self.dragon_auto_lc_allowed: + if self.dragon_auto_lc_timer is None: + # we only set timer when in preLaneChange state, dragon_auto_lc_delay delay + if self.lane_change_state == LaneChangeState.preLaneChange: + self.dragon_auto_lc_timer = cur_time + sm['dragonConf'].dpAutoLcDelay + elif cur_time >= self.dragon_auto_lc_timer: + # if timer is up, we set torque_applied to True to fake user input + torque_applied = True + self.dp_did_auto_lc = True + + # we reset the timers when torque is applied regardless + if torque_applied: + self.dragon_auto_lc_timer = None + # State transitions # off if self.lane_change_state == LaneChangeState.off and one_blinker and not self.prev_one_blinker and not below_lane_change_speed: @@ -150,11 +185,17 @@ def update(self, sm, pm, CP, VM): elif self.lane_change_ll_prob > 0.99: self.lane_change_state = LaneChangeState.off + # dp when finishing, we reset timer to none. + self.dragon_auto_lc_timer = None + if self.lane_change_state in [LaneChangeState.off, LaneChangeState.preLaneChange]: self.lane_change_timer = 0.0 else: self.lane_change_timer += DT_MDL + if self.prev_one_blinker and not one_blinker: + self.dp_did_auto_lc = False + self.prev_one_blinker = one_blinker desire = DESIRES[self.lane_change_direction][self.lane_change_state] @@ -203,7 +244,7 @@ def update(self, sm, pm, CP, VM): plan_solution_valid = self.solution_invalid_cnt < 2 plan_send = messaging.new_message('pathPlan') - plan_send.valid = sm.all_alive_and_valid(service_list=['carState', 'controlsState', 'liveParameters', 'model']) + plan_send.valid = sm.all_alive_and_valid(service_list=['carState', 'controlsState', 'liveParameters', 'model', 'dragonConf']) plan_send.pathPlan.laneWidth = float(self.LP.lane_width) plan_send.pathPlan.dPoly = [float(x) for x in self.LP.d_poly] plan_send.pathPlan.lPoly = [float(x) for x in self.LP.l_poly] @@ -220,6 +261,7 @@ def update(self, sm, pm, CP, VM): plan_send.pathPlan.desire = desire plan_send.pathPlan.laneChangeState = self.lane_change_state plan_send.pathPlan.laneChangeDirection = self.lane_change_direction + plan_send.pathPlan.dpALCAllowed = self.dragon_auto_lc_allowed pm.send('pathPlan', plan_send) diff --git a/selfdrive/controls/lib/pid.py b/selfdrive/controls/lib/pid.py index 916b95c9ea0c4b..72800102a1c2e0 100644 --- a/selfdrive/controls/lib/pid.py +++ b/selfdrive/controls/lib/pid.py @@ -10,7 +10,7 @@ def apply_deadzone(error, deadzone): error = 0. return error -class PIController(): +class PIController: def __init__(self, k_p, k_i, k_f=1., pos_limit=None, neg_limit=None, rate=100, sat_limit=0.8, convert=None): self._k_p = k_p # proportional gain self._k_i = k_i # integral gain @@ -86,3 +86,101 @@ def update(self, setpoint, measurement, speed=0.0, check_saturation=True, overri self.control = clip(control, self.neg_limit, self.pos_limit) return self.control + + +class PIDController: + def __init__(self, k_p, k_i, k_d, k_f=1., pos_limit=None, neg_limit=None, rate=100, sat_limit=0.8, convert=None): + self.enable_long_derivative = False + self._k_p = k_p # proportional gain + self._k_i = k_i # integral gain + self._k_d = k_d # derivative gain + self.k_f = k_f # feedforward gain + + self.max_accel_d = 0.22352 # 0.5 mph/s + + self.pos_limit = pos_limit + self.neg_limit = neg_limit + + self.sat_count_rate = 1.0 / rate + self.i_unwind_rate = 0.3 / rate + self.rate = 1.0 / rate + self.sat_limit = sat_limit + self.convert = convert + + self.reset() + + @property + def k_p(self): + return interp(self.speed, self._k_p[0], self._k_p[1]) + + @property + def k_i(self): + return interp(self.speed, self._k_i[0], self._k_i[1]) + + @property + def k_d(self): + return interp(self.speed, self._k_d[0], self._k_d[1]) + + def _check_saturation(self, control, check_saturation, error): + saturated = (control < self.neg_limit) or (control > self.pos_limit) + + if saturated and check_saturation and abs(error) > 0.1: + self.sat_count += self.sat_count_rate + else: + self.sat_count -= self.sat_count_rate + + self.sat_count = clip(self.sat_count, 0.0, 1.0) + + return self.sat_count > self.sat_limit + + def reset(self): + self.p = 0.0 + self.id = 0.0 + self.f = 0.0 + self.sat_count = 0.0 + self.saturated = False + self.control = 0 + self.last_setpoint = 0.0 + self.last_error = 0.0 + + def update(self, setpoint, measurement, speed=0.0, check_saturation=True, override=False, feedforward=0., deadzone=0., freeze_integrator=False): + self.speed = speed + + error = float(apply_deadzone(setpoint - measurement, deadzone)) + + self.p = error * self.k_p + self.f = feedforward * self.k_f + + if override: + self.id -= self.i_unwind_rate * float(np.sign(self.id)) + else: + i = self.id + error * self.k_i * self.rate + control = self.p + self.f + i + + if self.convert is not None: + control = self.convert(control, speed=self.speed) + + # Update when changing i will move the control away from the limits + # or when i will move towards the sign of the error + if ((error >= 0 and (control <= self.pos_limit or i < 0.0)) or \ + (error <= 0 and (control >= self.neg_limit or i > 0.0))) and \ + not freeze_integrator: + self.id = i + + if self.enable_long_derivative: + if abs(setpoint - self.last_setpoint) / self.rate < self.max_accel_d: # if setpoint isn't changing much + d = self.k_d * (error - self.last_error) + if (self.id > 0 and self.id + d >= 0) or (self.id < 0 and self.id + d <= 0): # if changing integral doesn't make it cross zero + self.id += d + + control = self.p + self.f + self.id + if self.convert is not None: + control = self.convert(control, speed=self.speed) + + self.saturated = self._check_saturation(control, check_saturation, error) + + self.last_setpoint = float(setpoint) + self.last_error = float(error) + + self.control = clip(control, self.neg_limit, self.pos_limit) + return self.control \ No newline at end of file diff --git a/selfdrive/controls/lib/planner.py b/selfdrive/controls/lib/planner.py index 0412df36d30b2c..9f655e0e9835cc 100755 --- a/selfdrive/controls/lib/planner.py +++ b/selfdrive/controls/lib/planner.py @@ -15,6 +15,8 @@ from selfdrive.controls.lib.long_mpc import LongitudinalMpc from selfdrive.controls.lib.drive_helpers import V_CRUISE_MAX +MAX_SPEED = 255.0 + LON_MPC_STEP = 0.2 # first step is 0.2s AWARENESS_DECEL = -0.2 # car smoothly decel at .2m/s^2 when user is distracted @@ -33,6 +35,46 @@ _A_TOTAL_MAX_V = [1.7, 3.2] _A_TOTAL_MAX_BP = [20., 40.] +# 75th percentile +SPEED_PERCENTILE_IDX = 7 + +# dp +DP_OFF = 0 +DP_ECO = 1 +DP_NORMAL = 2 +DP_SPORT = 3 +# accel profile by @arne182 +_DP_CRUISE_MIN_V = [-2.0, -1.5, -1.0, -0.7, -0.5] +_DP_CRUISE_MIN_V_ECO = [-1.0, -0.7, -0.6, -0.5, -0.3] +_DP_CRUISE_MIN_V_SPORT = [-3.0, -2.6, -2.3, -2.0, -1.0] +_DP_CRUISE_MIN_V_FOLLOWING = [-4.0, -4.0, -3.5, -2.5, -2.0] +_DP_CRUISE_MIN_BP = [0.0, 5.0, 10.0, 20.0, 55.0] + +_DP_CRUISE_MAX_V = [2.0, 2.0, 1.5, .5, .3] +_DP_CRUISE_MAX_V_ECO = [0.8, 0.9, 1.0, 0.4, 0.2] +_DP_CRUISE_MAX_V_SPORT = [3.0, 3.5, 3.0, 2.0, 2.0] +_DP_CRUISE_MAX_V_FOLLOWING = [1.6, 1.4, 1.4, .7, .3] +_DP_CRUISE_MAX_BP = [0., 5., 10., 20., 55.] + +# Lookup table for turns +_DP_TOTAL_MAX_V = [3.3, 3.0, 3.9] +_DP_TOTAL_MAX_BP = [0., 25., 55.] + +def dp_calc_cruise_accel_limits(v_ego, following, dp_profile): + if following: + a_cruise_min = interp(v_ego, _DP_CRUISE_MIN_BP, _DP_CRUISE_MIN_V_FOLLOWING) + a_cruise_max = interp(v_ego, _DP_CRUISE_MAX_BP, _DP_CRUISE_MAX_V_FOLLOWING) + else: + if dp_profile == DP_ECO: + a_cruise_min = interp(v_ego, _DP_CRUISE_MIN_BP, _DP_CRUISE_MIN_V_ECO) + a_cruise_max = interp(v_ego, _DP_CRUISE_MAX_BP, _DP_CRUISE_MAX_V_ECO) + elif dp_profile == DP_SPORT: + a_cruise_min = interp(v_ego, _DP_CRUISE_MIN_BP, _DP_CRUISE_MIN_V_SPORT) + a_cruise_max = interp(v_ego, _DP_CRUISE_MAX_BP, _DP_CRUISE_MAX_V_SPORT) + else: + a_cruise_min = interp(v_ego, _DP_CRUISE_MIN_BP, _DP_CRUISE_MIN_V) + a_cruise_max = interp(v_ego, _DP_CRUISE_MAX_BP, _DP_CRUISE_MAX_V) + return np.vstack([a_cruise_min, a_cruise_max]) def calc_cruise_accel_limits(v_ego, following): a_cruise_min = interp(v_ego, _A_CRUISE_MIN_BP, _A_CRUISE_MIN_V) @@ -80,9 +122,20 @@ def __init__(self, CP): self.params = Params() self.first_loop = True + # dp + self.dp_profile = DP_OFF + # dp - slow on curve from 0.7.6.1 + self.dp_slow_on_curve = False + self.v_model = 0.0 + self.a_model = 0.0 + def choose_solution(self, v_cruise_setpoint, enabled): if enabled: - solutions = {'cruise': self.v_cruise} + # dp - slow on curve from 0.7.6.1 + if self.dp_slow_on_curve: + solutions = {'model': self.v_model, 'cruise': self.v_cruise} + else: + solutions = {'cruise': self.v_cruise} if self.mpc1.prev_lead_status: solutions['mpc1'] = self.mpc1.v_mpc if self.mpc2.prev_lead_status: @@ -101,6 +154,10 @@ def choose_solution(self, v_cruise_setpoint, enabled): elif slowest == 'cruise': self.v_acc = self.v_cruise self.a_acc = self.a_cruise + # dp - slow on curve from 0.7.6.1 + elif self.dp_slow_on_curve and slowest == 'model': + self.v_acc = self.v_model + self.a_acc = self.a_model self.v_acc_future = min([self.mpc1.v_mpc_future, self.mpc2.v_mpc_future, v_cruise_setpoint]) @@ -122,9 +179,36 @@ def update(self, sm, pm, CP, VM, PP): enabled = (long_control_state == LongCtrlState.pid) or (long_control_state == LongCtrlState.stopping) following = lead_1.status and lead_1.dRel < 45.0 and lead_1.vLeadK > v_ego and lead_1.aLeadK > 0.0 + # dp + self.dp_profile = sm['dragonConf'].dpAccelProfile + self.dp_slow_on_curve = sm['dragonConf'].dpSlowOnCurve + + # dp - slow on curve from 0.7.6.1 + if self.dp_slow_on_curve and len(sm['model'].path.poly): + path = list(sm['model'].path.poly) + + # Curvature of polynomial https://en.wikipedia.org/wiki/Curvature#Curvature_of_the_graph_of_a_function + # y = a x^3 + b x^2 + c x + d, y' = 3 a x^2 + 2 b x + c, y'' = 6 a x + 2 b + # k = y'' / (1 + y'^2)^1.5 + # TODO: compute max speed without using a list of points and without numpy + y_p = 3 * path[0] * self.path_x**2 + 2 * path[1] * self.path_x + path[2] + y_pp = 6 * path[0] * self.path_x + 2 * path[1] + curv = y_pp / (1. + y_p**2)**1.5 + + a_y_max = 2.975 - v_ego * 0.0375 # ~1.85 @ 75mph, ~2.6 @ 25mph + v_curvature = np.sqrt(a_y_max / np.clip(np.abs(curv), 1e-4, None)) + model_speed = np.min(v_curvature) + model_speed = max(20.0 * CV.MPH_TO_MS, model_speed) # Don't slow down below 20mph + else: + model_speed = MAX_SPEED + # Calculate speed for normal cruise control - if enabled and not self.first_loop and not sm['carState'].gasPressed: - accel_limits = [float(x) for x in calc_cruise_accel_limits(v_ego, following)] + pedal_pressed = sm['carState'].gasPressed or sm['carState'].brakePressed + if enabled and not self.first_loop and not pedal_pressed: + if self.dp_profile == DP_OFF: + accel_limits = [float(x) for x in calc_cruise_accel_limits(v_ego, following)] + else: + accel_limits = [float(x) for x in dp_calc_cruise_accel_limits(v_ego, following, self.dp_profile)] jerk_limits = [min(-0.1, accel_limits[0]), max(0.1, accel_limits[1])] # TODO: make a separate lookup for jerk tuning accel_limits_turns = limit_accel_in_turns(v_ego, sm['carState'].steeringAngle, accel_limits, self.CP) @@ -138,6 +222,12 @@ def update(self, sm, pm, CP, VM, PP): accel_limits_turns[1], accel_limits_turns[0], jerk_limits[1], jerk_limits[0], LON_MPC_STEP) + # dp - slow on curve from 0.7.6.1 + if self.dp_slow_on_curve: + self.v_model, self.a_model = speed_smoother(self.v_acc_start, self.a_acc_start, + model_speed, 2*accel_limits[1], + accel_limits[0], 2*jerk_limits[1], jerk_limits[0], + LON_MPC_STEP) # cruise speed can't be negative even is user is distracted self.v_cruise = max(self.v_cruise, 0.) diff --git a/selfdrive/controls/lib/vehicle_model.py b/selfdrive/controls/lib/vehicle_model.py index dc3d1f4b2528cd..390d639ff7c034 100755 --- a/selfdrive/controls/lib/vehicle_model.py +++ b/selfdrive/controls/lib/vehicle_model.py @@ -16,6 +16,7 @@ from numpy.linalg import solve from typing import Tuple from cereal import car +from common.params import Params class VehicleModel: @@ -34,13 +35,17 @@ def __init__(self, CP: car.CarParams): self.cF_orig = CP.tireStiffnessFront self.cR_orig = CP.tireStiffnessRear + # dp + self.sR_orig = CP.steerRatio + self.dp_sr_learner = Params().get('dp_sr_learner') == b'1' + self.update_params(1.0, CP.steerRatio) def update_params(self, stiffness_factor: float, steer_ratio: float) -> None: """Update the vehicle model with a new stiffness factor and steer ratio""" self.cF = stiffness_factor * self.cF_orig self.cR = stiffness_factor * self.cR_orig - self.sR = steer_ratio + self.sR = steer_ratio if self.dp_sr_learner else self.sR_orig def steady_state_sol(self, sa: float, u: float) -> np.ndarray: """Returns the steady state solution. diff --git a/selfdrive/controls/plannerd.py b/selfdrive/controls/plannerd.py index 1f19266f1bad4b..7e20fb8c0dfd07 100755 --- a/selfdrive/controls/plannerd.py +++ b/selfdrive/controls/plannerd.py @@ -23,7 +23,7 @@ def plannerd_thread(sm=None, pm=None): VM = VehicleModel(CP) if sm is None: - sm = messaging.SubMaster(['carState', 'controlsState', 'radarState', 'model', 'liveParameters'], + sm = messaging.SubMaster(['carState', 'controlsState', 'radarState', 'model', 'liveParameters', 'dragonConf'], poll=['radarState', 'model']) if pm is None: @@ -34,6 +34,10 @@ def plannerd_thread(sm=None, pm=None): sm['liveParameters'].steerRatio = CP.steerRatio sm['liveParameters'].stiffnessFactor = 1.0 + # dp + sm['dragonConf'].dpSlowOnCurve = False + sm['dragonConf'].dpAccelProfile = 0 + while True: sm.update() diff --git a/selfdrive/controls/radard.py b/selfdrive/controls/radard.py index 6cb5f36a0a5c9c..710c315b83f252 100755 --- a/selfdrive/controls/radard.py +++ b/selfdrive/controls/radard.py @@ -164,7 +164,7 @@ def update(self, sm, rr, enable_lead): radarState.radarErrors = list(rr.errors) radarState.controlsStateMonoTime = sm.logMonoTime['controlsState'] - if enable_lead: + if True: radarState.leadOne = get_lead(self.v_ego, self.ready, clusters, sm['model'].lead, low_speed_override=True) radarState.leadTwo = get_lead(self.v_ego, self.ready, clusters, sm['model'].leadFuture, low_speed_override=False) return dat diff --git a/selfdrive/crash.py b/selfdrive/crash.py index 22d6aa068029bd..9fbcb57f9380a7 100644 --- a/selfdrive/crash.py +++ b/selfdrive/crash.py @@ -3,7 +3,13 @@ import sys import threading import capnp -from selfdrive.version import version, dirty +from selfdrive.version import version, dirty, origin, branch +from datetime import datetime +import traceback +from common.params import Params +import requests +from common.dp_common import is_online +CRASHES_DIR = '/sdcard/crash_logs/' from selfdrive.swaglog import cloudlog from common.hardware import PC @@ -23,18 +29,47 @@ def install(): else: from raven import Client from raven.transport.http import HTTPTransport - client = Client('https://1994756b5e6f41cf939a4c65de45f4f2:cefebaf3a8aa40d182609785f7189bd7@app.getsentry.com/77924', - install_sys_hook=False, transport=HTTPTransport, release=version, tags={'dirty': dirty}) + params = Params() + try: + dongle_id = params.get("DongleId").decode('utf8') + except AttributeError: + dongle_id = "None" + try: + ip = requests.get('https://checkip.amazonaws.com/', timeout=3).text.strip() if is_online() else '255.255.255.255' + except: + ip = "255.255.255.255" + error_tags = {'dirty': dirty, 'username': dongle_id, 'dongle_id': dongle_id, 'branch': branch, 'remote': origin} + + client = Client('http://7107f046f45b4b4f9b277d0684bc9281@sentry.dragonpilot.cn:9000/2', + install_sys_hook=False, transport=HTTPTransport, release=version, tags=error_tags) def capture_exception(*args, **kwargs): + save_exception(traceback.format_exc()) exc_info = sys.exc_info() if not exc_info[0] is capnp.lib.capnp.KjException: client.captureException(*args, **kwargs) cloudlog.error("crash", exc_info=kwargs.get('exc_info', 1)) + # dp - from @ShaneSmiskol, save log into local directory + def save_exception(exc_text): + if not os.path.exists(CRASHES_DIR): + os.mkdir(CRASHES_DIR) + log_file = '{}/{}'.format(CRASHES_DIR, datetime.now().strftime('%Y-%m-%d--%H-%M-%S.%f.log')[:-3]) + with open(log_file, 'w') as f: + f.write(exc_text) + print('Logged current crash to {}'.format(log_file)) + def bind_user(**kwargs): client.user_context(kwargs) + def capture_warning(warning_string): + bind_user(id=dongle_id, ip_address=ip) + client.captureMessage(warning_string, level='warning') + + def capture_info(info_string): + bind_user(id=dongle_id, ip_address=ip) + client.captureMessage(info_string, level='info') + def bind_extra(**kwargs): client.extra_context(kwargs) diff --git a/selfdrive/dragonpilot/LICENSE.md b/selfdrive/dragonpilot/LICENSE.md new file mode 100644 index 00000000000000..76e9bfcbb600e9 --- /dev/null +++ b/selfdrive/dragonpilot/LICENSE.md @@ -0,0 +1,21 @@ +The MIT License + +Copyright (c) 2019-, Rick Lan, dragonpilot community, and a number of other of contributors. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. \ No newline at end of file diff --git a/selfdrive/dragonpilot/appd.py b/selfdrive/dragonpilot/appd.py new file mode 100644 index 00000000000000..a49d6728c8edbd --- /dev/null +++ b/selfdrive/dragonpilot/appd.py @@ -0,0 +1,497 @@ +#!/usr/bin/env python3.7 +import time +import subprocess +import cereal +import cereal.messaging as messaging +ThermalStatus = cereal.log.ThermalData.ThermalStatus +from selfdrive.swaglog import cloudlog +from common.params import Params, put_nonblocking +params = Params() +from math import floor +import re +import os +from common.dp_common import is_online +from common.dp_conf import get_struct_name +from common.realtime import sec_since_boot +import psutil + +is_online = is_online() +auto_update = params.get("dp_app_auto_update", encoding='utf8') == "1" + +class App(): + + # app type + TYPE_GPS = 0 + TYPE_SERVICE = 1 + TYPE_FULLSCREEN = 2 + TYPE_UTIL = 3 + TYPE_ANDROID_AUTO = 4 + + # manual switch stats + MANUAL_OFF = -1 + MANUAL_IDLE = 0 + MANUAL_ON = 1 + + def appops_set(self, package, op, mode): + self.system(f"LD_LIBRARY_PATH= appops set {package} {op} {mode}") + + def pm_grant(self, package, permission): + self.system(f"pm grant {package} {permission}") + + def set_package_permissions(self): + if self.permissions is not None: + for permission in self.permissions: + self.pm_grant(self.app, permission) + if self.opts is not None: + for opt in self.opts: + self.appops_set(self.app, opt, "allow") + + def __init__(self, app, start_cmd, enable_param, auto_run_param, manual_ctrl_param, app_type, check_crash, permissions, opts): + self.app = app + # main activity + self.start_cmd = start_cmd + # read enable param + self.enable_param = enable_param + self.enable_struct = get_struct_name(enable_param) if enable_param is not None else None + # read auto run param + self.auto_run_struct = get_struct_name(auto_run_param) if auto_run_param is not None else None + # read manual run param + self.manual_ctrl_param = manual_ctrl_param if manual_ctrl_param is not None else None + self.manual_ctrl_struct = get_struct_name(manual_ctrl_param) if manual_ctrl_param is not None else None + # if it's a service app, we do not kill if device is too hot + self.app_type = app_type + # app permissions + self.permissions = permissions + # app options + self.opts = opts + + self.own_apk = "/sdcard/apks/" + self.app + ".apk" + self.has_own_apk = os.path.exists(self.own_apk) + self.is_installed = False + self.is_enabled = False + self.last_is_enabled = False + self.is_auto_runnable = False + self.is_running = False + self.manual_ctrl_status = self.MANUAL_IDLE + self.manually_ctrled = False + self.init = False + self.check_crash = check_crash + + def is_crashed(self): + return getattr(self, self.enable_param + "_is_crashed")() + + def dp_app_hr_is_crashed(self): + try: + result = subprocess.check_output(["dumpsys", "activity", "gb.xxy.hr"], encoding='utf8') + print("is_crash = %s" % "ACTIVITY" in result) + return "ACTIVITY" not in result + except (subprocess.CalledProcessError, IndexError) as e: + return False + + def get_remote_version(self): + apk = self.app + ".apk" + try: + url = "https://raw.githubusercontent.com/dragonpilot-community/apps/%s/VERSION" % apk + return subprocess.check_output(["curl", "-H", "'Cache-Control: no-cache'", "-s", url]).decode('utf8').rstrip() + except subprocess.CalledProcessError as e: + pass + return None + + def uninstall_app(self): + try: + local_version = self.get_local_version() + if local_version is not None: + subprocess.check_output(["pm","uninstall", self.app]) + self.is_installed = False + except subprocess.CalledProcessError as e: + pass + + def update_app(self): + put_nonblocking('dp_is_updating', '1') + if self.has_own_apk: + try: + subprocess.check_output(["pm","install","-r",self.own_apk]) + self.is_installed = True + except subprocess.CalledProcessError as e: + self.is_installed = False + else: + apk = self.app + ".apk" + apk_path = "/sdcard/" + apk + try: + os.remove(apk_path) + except (OSError, FileNotFoundError) as e: + pass + + self.uninstall_app() + # if local_version is not None: + # try: + # subprocess.check_output(["pm","uninstall", self.app], stderr=subprocess.STDOUT, shell=True) + # except subprocess.CalledProcessError as e: + # pass + try: + url = "https://raw.githubusercontent.com/dragonpilot-community/apps/%s/%s" % (apk, apk) + subprocess.check_output(["curl","-o", apk_path,"-LJO", url]) + subprocess.check_output(["pm","install","-r",apk_path]) + self.is_installed = True + except subprocess.CalledProcessError as e: + self.is_installed = False + try: + os.remove(apk_path) + except (OSError, FileNotFoundError) as e: + pass + put_nonblocking('dp_is_updating', '0') + + def get_local_version(self): + try: + result = subprocess.check_output(["dumpsys", "package", self.app, "|", "grep", "versionName"], encoding='utf8') + if len(result) > 12: + return re.findall(r"versionName=(.*)", result)[0] + except (subprocess.CalledProcessError, IndexError) as e: + pass + return None + + def init_vars(self, dragonconf): + self.is_enabled = getattr(dragonconf, self.enable_struct) + + if self.is_enabled: + local_version = self.get_local_version() + if local_version is not None: + self.is_installed = True + + if self.has_own_apk and not self.is_installed: + self.update_app() + + elif is_online: + if local_version is None: + self.update_app() + else: + remote_version = self.get_remote_version() if (auto_update and not self.own_apk) else local_version + if remote_version is not None and local_version != remote_version: + self.update_app() + if self.is_installed: + self.set_package_permissions() + else: + self.uninstall_app() + + if self.manual_ctrl_param is not None and getattr(dragonconf, self.manual_ctrl_struct) != self.MANUAL_IDLE: + put_nonblocking(self.manual_ctrl_param, str(self.MANUAL_IDLE)) + self.init = True + + def read_params(self, dragonconf): + if not self.init: + self.init_vars(dragonconf) + + self.last_is_enabled = self.is_enabled + self.is_enabled = False if self.enable_struct is None else getattr(dragonconf, self.enable_struct) + + if self.is_installed: + if self.is_enabled: + # a service app should run automatically and not manual controllable. + if self.app_type in [App.TYPE_SERVICE]: + self.is_auto_runnable = True + self.manual_ctrl_status = self.MANUAL_IDLE + else: + self.manual_ctrl_status = self.MANUAL_IDLE if self.manual_ctrl_param is None else getattr(dragonconf, self.manual_ctrl_struct) + if self.manual_ctrl_status == self.MANUAL_IDLE: + self.is_auto_runnable = False if self.auto_run_struct is None else getattr(dragonconf, self.auto_run_struct) + else: + if self.last_is_enabled: + self.uninstall_app() + self.is_auto_runnable = False + self.manual_ctrl_status = self.MANUAL_IDLE + self.manually_ctrled = False + else: + if not self.last_is_enabled and self.is_enabled: + self.update_app() + + def run(self, force = False): + if self.is_installed and (force or self.is_enabled): + # app is manually ctrl, we record that + if self.manual_ctrl_param is not None and self.manual_ctrl_status == self.MANUAL_ON: + put_nonblocking(self.manual_ctrl_param, '0') + put_nonblocking('dp_last_modified', str(floor(time.time()))) + self.manually_ctrled = True + self.is_running = False + + # only run app if it's not running + if force or not self.is_running: + self.system("pm enable %s" % self.app) + + if self.app_type == self.TYPE_SERVICE: + self.appops_set(self.app, "android:mock_location", "allow") + self.system(self.start_cmd) + self.is_running = True + + def kill(self, force = False): + if self.is_installed and (force or self.is_enabled): + # app is manually ctrl, we record that + if self.manual_ctrl_param is not None and self.manual_ctrl_status == self.MANUAL_OFF: + put_nonblocking(self.manual_ctrl_param, '0') + self.manually_ctrled = True + self.is_running = True + + # only kill app if it's running + if force or self.is_running: + if self.app_type == self.TYPE_SERVICE: + self.appops_set(self.app, "android:mock_location", "deny") + + self.system("pkill %s" % self.app) + self.is_running = False + + def system(self, cmd): + try: + subprocess.check_output(cmd, stderr=subprocess.STDOUT, shell=True) + except subprocess.CalledProcessError as e: + cloudlog.event("running failed", + cmd=e.cmd, + output=e.output[-1024:], + returncode=e.returncode) + +def init_apps(apps): + apps.append(App( + "cn.dragonpilot.gpsservice", + "am startservice cn.dragonpilot.gpsservice/cn.dragonpilot.gpsservice.MainService", + "dp_app_ext_gps", + None, + None, + App.TYPE_SERVICE, + False, + [], + [], + )) + apps.append(App( + "com.mixplorer", + "am start -n com.mixplorer/com.mixplorer.activities.BrowseActivity", + "dp_app_mixplorer", + None, + "dp_app_mixplorer_manual", + App.TYPE_UTIL, + False, + [ + "android.permission.READ_EXTERNAL_STORAGE", + "android.permission.WRITE_EXTERNAL_STORAGE", + ], + [], + )) + apps.append(App( + "com.tomtom.speedcams.android.map", + "am start -n com.tomtom.speedcams.android.map/com.tomtom.speedcams.android.activities.SpeedCamActivity", + "dp_app_tomtom", + "dp_app_tomtom_auto", + "dp_app_tomtom_manual", + App.TYPE_GPS, + False, + [ + "android.permission.ACCESS_FINE_LOCATION", + "android.permission.ACCESS_COARSE_LOCATION", + "android.permission.READ_EXTERNAL_STORAGE", + "android.permission.WRITE_EXTERNAL_STORAGE", + ], + [ + "SYSTEM_ALERT_WINDOW", + ] + )) + apps.append(App( + "tw.com.ainvest.outpack", + "am start -n tw.com.ainvest.outpack/tw.com.ainvest.outpack.ui.MainActivity", + "dp_app_aegis", + "dp_app_aegis_auto", + "dp_app_aegis_manual", + App.TYPE_GPS, + False, + [ + "android.permission.ACCESS_FINE_LOCATION", + "android.permission.READ_EXTERNAL_STORAGE", + "android.permission.WRITE_EXTERNAL_STORAGE", + ], + [ + "SYSTEM_ALERT_WINDOW", + ] + )) + apps.append(App( + "com.autonavi.amapauto", + "am start -n com.autonavi.amapauto/com.autonavi.amapauto.MainMapActivity", + "dp_app_autonavi", + "dp_app_autonavi_auto", + "dp_app_autonavi_manual", + App.TYPE_GPS, + False, + [ + "android.permission.ACCESS_FINE_LOCATION", + "android.permission.ACCESS_COARSE_LOCATION", + "android.permission.READ_EXTERNAL_STORAGE", + "android.permission.WRITE_EXTERNAL_STORAGE", + ], + [ + "SYSTEM_ALERT_WINDOW", + ] + )) + apps.append(App( + "com.waze", + "am start -n com.waze/com.waze.MainActivity", + "dp_app_waze", + None, + "dp_app_waze_manual", + App.TYPE_FULLSCREEN, + False, + [ + "android.permission.ACCESS_FINE_LOCATION", + "android.permission.ACCESS_COARSE_LOCATION", + "android.permission.READ_EXTERNAL_STORAGE", + "android.permission.WRITE_EXTERNAL_STORAGE", + "android.permission.RECORD_AUDIO", + ], + [], + )) + # pm disable gb.xxy.hr && pm enable gb.xxy.hr && am broadcast -a "gb.xxy.hr.WIFI_START" + apps.append(App( + "gb.xxy.hr", + "am start -n gb.xxy.hr/.MainActivity && pm disable gb.xxy.hr && pm enable gb.xxy.hr && am broadcast -a gb.xxy.hr.WIFI_START", + "dp_app_hr", + None, + "dp_app_hr_manual", + App.TYPE_ANDROID_AUTO, + True, + [ + "android.permission.ACCESS_FINE_LOCATION", + "android.permission.ACCESS_COARSE_LOCATION", + "android.permission.READ_EXTERNAL_STORAGE", + "android.permission.WRITE_EXTERNAL_STORAGE", + "android.permission.RECORD_AUDIO", + ], + [], + )) + +def main(): + apps = [] + + last_started = False + sm = messaging.SubMaster(['dragonConf']) + + frame = 0 + start_delay = None + stop_delay = None + allow_auto_run = True + + last_overheat = False + init_done = False + dragon_conf_msg = None + + next_check_process_frame = 0 + + while 1: #has_enabled_apps: + start_sec = sec_since_boot() + if not init_done: + if frame >= 10: + init_apps(apps) + sm.update() + dragon_conf_msg = sm['dragonConf'] + init_done = True + else: + sm.update(1000) + if sm.updated['dragonConf']: + dragon_conf_msg = sm['dragonConf'] + else: + continue + enabled_apps = [] + has_fullscreen_apps = False + has_check_crash = False + for app in apps: + # read params loop + app.read_params(dragon_conf_msg) + if app.last_is_enabled and not app.is_enabled and app.is_running: + app.kill(True) + + if app.is_enabled: + if not has_fullscreen_apps and app.app_type in [App.TYPE_FULLSCREEN, App.TYPE_ANDROID_AUTO]: + has_fullscreen_apps = True + if not has_check_crash and app.check_crash: + has_check_crash = True + + # process manual ctrl apps + if app.manual_ctrl_status != App.MANUAL_IDLE: + app.run(True) if app.manual_ctrl_status == App.MANUAL_ON else app.kill(True) + + enabled_apps.append(app) + + started = dragon_conf_msg.dpThermalStarted + # when car is running + if started: + # we run service apps and kill all util apps + # only run once + if last_started != started: + for app in enabled_apps: + if app.app_type in [App.TYPE_SERVICE]: + app.run() + elif app.app_type == App.TYPE_UTIL: + app.kill() + + stop_delay = None + # apps start 5 secs later + if start_delay is None: + start_delay = frame + 5 + + if not dragon_conf_msg.dpThermalOverheat: + allow_auto_run = True + # when temp reduce from red to yellow, we add start up delay as well + # so apps will not start up immediately + if last_overheat: + start_delay = frame + 60 + else: + allow_auto_run = False + last_overheat = dragon_conf_msg.dpThermalOverheat + + # only run apps that's not manually ctrled + if has_check_crash and frame >= next_check_process_frame: + for app in enabled_apps: + if app.is_running and app.check_crash and app.is_crashed(): + app.kill() + next_check_process_frame = frame + 15 + + for app in enabled_apps: + if not app.manually_ctrled: + if has_fullscreen_apps: + if app.app_type in [App.TYPE_FULLSCREEN, App.TYPE_ANDROID_AUTO]: + app.run() + elif app.app_type in [App.TYPE_GPS, App.TYPE_UTIL]: + app.kill() + else: + if not allow_auto_run: + app.kill() + else: + if frame >= start_delay and app.is_auto_runnable and app.app_type == App.TYPE_GPS: + app.run() + # when car is stopped + else: + start_delay = None + # set delay to 30 seconds + if stop_delay is None: + stop_delay = frame + 30 + + for app in enabled_apps: + if app.is_running and not app.manually_ctrled: + if has_fullscreen_apps or frame >= stop_delay: + app.kill() + + if last_started != started: + for app in enabled_apps: + app.manually_ctrled = False + + last_started = started + frame += 1 + sleep = 1 - (sec_since_boot() - start_sec) + if sleep > 0: + time.sleep(sleep) + +def system(cmd): + try: + cloudlog.info("running %s" % cmd) + subprocess.check_output(cmd, stderr=subprocess.STDOUT, shell=True) + except subprocess.CalledProcessError as e: + cloudlog.event("running failed", + cmd=e.cmd, + output=e.output[-1024:], + returncode=e.returncode) + +if __name__ == "__main__": + main() diff --git a/selfdrive/dragonpilot/dashcam.py b/selfdrive/dragonpilot/dashcam.py new file mode 100644 index 00000000000000..f9915ebb30f3fb --- /dev/null +++ b/selfdrive/dragonpilot/dashcam.py @@ -0,0 +1,69 @@ +#!/usr/bin/env python3.7 +import os +import datetime +from common.realtime import sec_since_boot + +DASHCAM_VIDEOS_PATH = '/sdcard/dashcam/' +DASHCAM_DURATION = 180 # max is 180 +DASHCAM_BIT_RATES = 4000000 # max is 4000000 +DASHCAM_MAX_SIZE_PER_FILE = DASHCAM_BIT_RATES/8*DASHCAM_DURATION # 4Mbps / 8 * 180 = 90MB per 180 seconds +DASHCAM_FREESPACE_LIMIT = 0.15 # we start cleaning up footage when freespace is below 15% +DASHCAM_KEPT = DASHCAM_MAX_SIZE_PER_FILE * 240 # 12 hrs of video = 21GB + +class Dashcam(): + + def __init__(self): + self.dashcam_folder_exists = False + self.dashcam_mkdir_retry = 0 + self.dashcam_next_time = 0 + self.started = False + self.free_space = 1. + pass + + def run(self, started, free_space): + self.started = started + self.free_space = free_space + self.make_folder() + if self.dashcam_folder_exists: + self.record() + self.clean_up() + + def make_folder(self): + if not self.dashcam_folder_exists and self.dashcam_mkdir_retry <= 5: + # create dashcam folder if not exist + try: + if not os.path.exists(DASHCAM_VIDEOS_PATH): + os.makedirs(DASHCAM_VIDEOS_PATH) + else: + self.dashcam_folder_exists = True + except OSError: + self.dashcam_folder_exists = False + self.dashcam_mkdir_retry += 1 + + def record(self): + # start recording + if self.started: + ts = sec_since_boot() + if ts >= self.dashcam_next_time: + now = datetime.datetime.now() + file_name = now.strftime("%Y-%m-%d_%H-%M-%S") + os.system("screenrecord --bit-rate %s --time-limit %s %s%s.mp4 &" % (DASHCAM_BIT_RATES, DASHCAM_DURATION, DASHCAM_VIDEOS_PATH, file_name)) + self.dashcam_next_time = ts + DASHCAM_DURATION - 1 + else: + self.dashcam_next_time = 0 + + def clean_up(self): + # clean up + if (self.free_space < DASHCAM_FREESPACE_LIMIT) or (self.get_used_spaces() > DASHCAM_KEPT): + try: + files = [f for f in sorted(os.listdir(DASHCAM_VIDEOS_PATH)) if os.path.isfile(DASHCAM_VIDEOS_PATH + f)] + os.system("rm -fr %s &" % (DASHCAM_VIDEOS_PATH + files[0])) + except (IndexError, FileNotFoundError, OSError): + pass + + def get_used_spaces(self): + try: + val = sum(os.path.getsize(DASHCAM_VIDEOS_PATH + f) for f in os.listdir(DASHCAM_VIDEOS_PATH) if os.path.isfile(DASHCAM_VIDEOS_PATH + f)) + except (IndexError, FileNotFoundError, OSError): + val = 0 + return val diff --git a/selfdrive/dragonpilot/gpxd.py b/selfdrive/dragonpilot/gpxd.py new file mode 100644 index 00000000000000..0bc1406a185027 --- /dev/null +++ b/selfdrive/dragonpilot/gpxd.py @@ -0,0 +1,164 @@ +#!/usr/bin/env python3.7 +''' +GPS cord converter: https://gist.github.com/jp1017/71bd0976287ce163c11a7cb963b04dd8 +''' +import cereal.messaging as messaging +import os +import time +import datetime +import signal +import threading +import math +import zipfile + +pi = 3.1415926535897932384626 +x_pi = 3.14159265358979324 * 3000.0 / 180.0 +a = 6378245.0 +ee = 0.00669342162296594323 + +GPX_LOG_PATH = '/sdcard/gpx_logs/' + +LOG_DELAY = 0.1 # secs, lower for higher accuracy, 0.1 seems fine +LOG_LENGTH = 60 # mins, higher means it keeps more data in the memory, will take more time to write into a file too. +LOST_SIGNAL_COUNT_LENGTH = 30 # secs, if we lost signal for this long, perform output to data +MIN_MOVE_SPEED_KMH = 5 # km/h, min speed to trigger logging + +# do not change +LOST_SIGNAL_COUNT_MAX = LOST_SIGNAL_COUNT_LENGTH / LOG_DELAY # secs, +LOGS_PER_FILE = LOG_LENGTH * 60 / LOG_DELAY # e.g. 3 * 60 / 0.1 = 1800 points per file +MIN_MOVE_SPEED_MS = MIN_MOVE_SPEED_KMH / 3.6 + +class WaitTimeHelper: + ready_event = threading.Event() + shutdown = False + + def __init__(self): + signal.signal(signal.SIGTERM, self.graceful_shutdown) + signal.signal(signal.SIGINT, self.graceful_shutdown) + signal.signal(signal.SIGHUP, self.graceful_shutdown) + + def graceful_shutdown(self, signum, frame): + self.shutdown = True + self.ready_event.set() + +def main(): + # init + sm = messaging.SubMaster(['gpsLocationExternal']) + log_count = 0 + logs = list() + lost_signal_count = 0 + wait_helper = WaitTimeHelper() + started_time = datetime.datetime.utcnow().isoformat() + # outside_china_checked = False + # outside_china = False + while True: + sm.update() + if sm.updated['gpsLocationExternal']: + gps = sm['gpsLocationExternal'] + + # do not log when no fix or accuracy is too low, add lost_signal_count + if gps.flags % 2 == 0 or gps.accuracy > 5.: + if log_count > 0: + lost_signal_count += 1 + else: + lng = gps.longitude + lat = gps.latitude + # if not outside_china_checked: + # outside_china = out_of_china(lng, lat) + # outside_china_checked = True + # if not outside_china: + # lng, lat = wgs84togcj02(lng, lat) + logs.append([datetime.datetime.utcfromtimestamp(gps.timestamp*0.001).isoformat(), lat, lng, gps.altitude]) + log_count += 1 + lost_signal_count = 0 + ''' + write to log if + 1. reach per file limit + 2. lost signal for a certain time (e.g. under cover car park?) + ''' + if log_count > 0 and (log_count >= LOGS_PER_FILE or lost_signal_count >= LOST_SIGNAL_COUNT_MAX): + # output + to_gpx(logs, started_time) + lost_signal_count = 0 + log_count = 0 + logs.clear() + started_time = datetime.datetime.utcnow().isoformat() + + time.sleep(LOG_DELAY) + if wait_helper.shutdown: + break + # when process end, we store any logs. + if log_count > 0: + to_gpx(logs, started_time) + +''' +check to see if it's in china +''' +def out_of_china(lng, lat): + if lng < 72.004 or lng > 137.8347: + return True + elif lat < 0.8293 or lat > 55.8271: + return True + return False + +def transform_lat(lng, lat): + ret = -100.0 + 2.0 * lng + 3.0 * lat + 0.2 * lat * lat + 0.1 * lng * lat + 0.2 * math.sqrt(abs(lng)) + ret += (20.0 * math.sin(6.0 * lng * pi) + 20.0 * math.sin(2.0 * lng * pi)) * 2.0 / 3.0 + ret += (20.0 * math.sin(lat * pi) + 40.0 * math.sin(lat / 3.0 * pi)) * 2.0 / 3.0 + ret += (160.0 * math.sin(lat / 12.0 * pi) + 320 * math.sin(lat * pi / 30.0)) * 2.0 / 3.0 + return ret + +def transform_lng(lng, lat): + ret = 300.0 + lng + 2.0 * lat + 0.1 * lng * lng + 0.1 * lng * lat + 0.1 * math.sqrt(abs(lng)) + ret += (20.0 * math.sin(6.0 * lng * pi) + 20.0 * math.sin(2.0 * lng * pi)) * 2.0 / 3.0 + ret += (20.0 * math.sin(lng * pi) + 40.0 * math.sin(lng / 3.0 * pi)) * 2.0 / 3.0 + ret += (150.0 * math.sin(lng / 12.0 * pi) + 300.0 * math.sin(lng / 30.0 * pi)) * 2.0 / 3.0 + return ret + +''' +Convert wgs84 to gcj02 ( +''' +def wgs84togcj02(lng, lat): + if out_of_china(lng, lat): + return lng, lat + dlat = transform_lat(lng - 105.0, lat - 35.0) + dlng = transform_lng(lng - 105.0, lat - 35.0) + radlat = lat / 180.0 * pi + magic = math.sin(radlat) + magic = 1 - ee * magic * magic + sqrtmagic = math.sqrt(magic) + dlat = (dlat * 180.0) / ((a * (1 - ee)) / (magic * sqrtmagic) * pi) + dlng = (dlng * 180.0) / (a / sqrtmagic * math.cos(radlat) * pi) + mglat = lat + dlat + mglng = lng + dlng + return mglng, mglat + +''' +write logs to a gpx file and zip it +''' +def to_gpx(logs, timestamp): + if len(logs) > 0: + if not os.path.exists(GPX_LOG_PATH): + os.makedirs(GPX_LOG_PATH) + filename = timestamp.replace(':','-') + str = '' + str += "\n" + str += "\n" + str += "\t\n" + str += "\t\t\n" + for trkpt in logs: + str += "\t\t\t\n" % (trkpt[0], trkpt[1], trkpt[2], trkpt[3]) + str += "\t\t\n" + str += "\t\n" + str += "\n" + try: + zi = zipfile.ZipInfo('%sZ.gpx' % filename, time.localtime()) + zi.compress_type = zipfile.ZIP_DEFLATED + zf = zipfile.ZipFile('%s%sZ.zip' % (GPX_LOG_PATH, filename), mode='w') + zf.writestr(zi, str) + zf.close() + except: + pass + +if __name__ == "__main__": + main() diff --git a/selfdrive/dragonpilot/systemd.py b/selfdrive/dragonpilot/systemd.py new file mode 100644 index 00000000000000..f7c499b5c947d9 --- /dev/null +++ b/selfdrive/dragonpilot/systemd.py @@ -0,0 +1,276 @@ +#!/usr/bin/env python3 +''' +This is a service that broadcast dp config values to openpilot's messaging queues +''' +import cereal.messaging as messaging +import time + +from common.dp_conf import confs, get_struct_name, to_struct_val +from common.params import Params, put_nonblocking +import subprocess +import re +import os +from selfdrive.thermald.power_monitoring import set_battery_charging, get_battery_charging +params = Params() +from common.realtime import sec_since_boot +from common.i18n import get_locale +from common.dp_common import param_get, get_last_modified +from common.dp_time import LAST_MODIFIED_SYSTEMD +from selfdrive.dragonpilot.dashcam import Dashcam + +PARAM_PATH = '/data/params/d/' + +DELAY = 0.5 # 2hz +HERTZ = 1/DELAY + +last_modified_confs = {} + +def confd_thread(): + sm = messaging.SubMaster(['thermal']) + pm = messaging.PubMaster(['dragonConf']) + + last_dp_msg = None + frame = 0 + update_params = False + modified = None + last_modified = None + last_modified_check = None + started = False + free_space = 1 + battery_percent = 0 + overheat = False + last_charging_ctrl = False + last_started = False + dashcam = Dashcam() + + while True: + start_sec = sec_since_boot() + msg = messaging.new_message('dragonConf') + if last_dp_msg is not None: + msg.dragonConf = last_dp_msg + + ''' + =================================================== + load thermald data every 3 seconds + =================================================== + ''' + if frame % (HERTZ * 3) == 0: + started, free_space, battery_percent, overheat = pull_thermald(frame, sm, started, free_space, battery_percent, overheat) + setattr(msg.dragonConf, get_struct_name('dp_thermal_started'), started) + setattr(msg.dragonConf, get_struct_name('dp_thermal_overheat'), overheat) + ''' + =================================================== + hotspot on boot + we do it after 30 secs just in case + =================================================== + ''' + if frame == (HERTZ * 30) and param_get("dp_hotspot_on_boot", "bool", False): + os.system("service call wifi 37 i32 0 i32 1 &") + ''' + =================================================== + check dp_last_modified every second + =================================================== + ''' + if not update_params: + last_modified_check, modified = get_last_modified(LAST_MODIFIED_SYSTEMD, last_modified_check, modified) + if last_modified != modified: + update_params = True + last_modified = modified + ''' + =================================================== + conditionally set update_params to true + =================================================== + ''' + # force updating param when `started` changed + if last_started != started: + update_params = True + last_started = started + + if frame == 0: + update_params = True + ''' + =================================================== + conditionally update dp param base on stock param + =================================================== + ''' + if update_params and params.get("LaneChangeEnabled") == b"1": + params.put("dp_steering_on_signal", "0") + ''' + =================================================== + push param vals to message + =================================================== + ''' + if update_params: + msg = update_conf_all(confs, msg, frame == 0) + update_params = False + ''' + =================================================== + push once + =================================================== + ''' + if frame == 0: + setattr(msg.dragonConf, get_struct_name('dp_locale'), get_locale()) + put_nonblocking('dp_is_updating', '0') + ''' + =================================================== + push ip addr every 10 secs + =================================================== + ''' + if frame % (HERTZ * 10) == 0: + msg = update_ip(msg) + ''' + =================================================== + push is_updating status every 5 secs + =================================================== + ''' + if frame % (HERTZ * 5) == 0: + msg = update_updating(msg) + ''' + =================================================== + update msg based on some custom logic + =================================================== + ''' + msg = update_custom_logic(msg) + ''' + =================================================== + battery ctrl every 30 secs + PowerMonitor in thermald turns back on every mins + so lets turn it off more frequent + =================================================== + ''' + if frame % (HERTZ * 30) == 0: + last_charging_ctrl = process_charging_ctrl(msg, last_charging_ctrl, battery_percent) + ''' + =================================================== + dashcam + =================================================== + ''' + if msg.dragonConf.dpDashcam and frame % HERTZ == 0: + dashcam.run(started, free_space) + ''' + =================================================== + finalise + =================================================== + ''' + last_dp_msg = msg.dragonConf + pm.send('dragonConf', msg) + frame += 1 + sleep = DELAY-(sec_since_boot() - start_sec) + if sleep > 0: + time.sleep(sleep) + +def update_conf(msg, conf, first_run = False): + conf_type = conf.get('conf_type') + + # skip checking since modified date time hasn't been changed. + if (last_modified_confs.get(conf['name'])) is not None and last_modified_confs.get(conf['name']) == os.stat(PARAM_PATH + conf['name']).st_mtime: + return msg + + if 'param' in conf_type and 'struct' in conf_type: + update_this_conf = True + + if not first_run: + update_once = conf.get('update_once') + if update_once is not None and update_once is True: + return msg + if update_this_conf: + update_this_conf = check_dependencies(msg, conf) + + if update_this_conf: + msg = set_message(msg, conf) + if os.path.isfile(PARAM_PATH + conf['name']): + last_modified_confs[conf['name']] = os.stat(PARAM_PATH + conf['name']).st_mtime + return msg + +def update_conf_all(confs, msg, first_run = False): + for conf in confs: + msg = update_conf(msg, conf, first_run) + return msg + +def process_charging_ctrl(msg, last_charging_ctrl, battery_percent): + charging_ctrl = msg.dragonConf.dpChargingCtrl + if last_charging_ctrl != charging_ctrl: + set_battery_charging(True) + if charging_ctrl: + if battery_percent >= msg.dragonConf.dpDischargingAt and get_battery_charging(): + set_battery_charging(False) + elif battery_percent <= msg.dragonConf.dpChargingAt and not get_battery_charging(): + set_battery_charging(True) + return charging_ctrl + + +def pull_thermald(frame, sm, started, free_space, battery_percent, overheat): + sm.update(0) + if sm.updated['thermal']: + started = sm['thermal'].started + free_space = sm['thermal'].freeSpace + battery_percent = sm['thermal'].batteryPercent + overheat = sm['thermal'].thermalStatus >= 2 + return started, free_space, battery_percent, overheat + +def update_custom_logic(msg): + if msg.dragonConf.dpAssistedLcMinMph > msg.dragonConf.dpAutoLcMinMph: + put_nonblocking('dp_auto_lc_min_mph', str(msg.dragonConf.dpAssistedLcMinMph)) + msg.dragonConf.dpAutoLcMinMph = msg.dragonConf.dpAssistedLcMinMph + if msg.dragonConf.dpAtl: + msg.dragonConf.dpAllowGas = True + msg.dragonConf.dpDynamicFollow = 0 + msg.dragonConf.dpAccelProfile = 0 + msg.dragonConf.dpGearCheck = False + if msg.dragonConf.dpAppWaze or msg.dragonConf.dpAppHr: + msg.dragonConf.dpDrivingUi = False + if not msg.dragonConf.dpDriverMonitor: + msg.dragonConf.dpUiFace = False + return msg + +def update_updating(msg): + setattr(msg.dragonConf, get_struct_name('dp_is_updating'), to_struct_val('dp_is_updating', param_get("dp_is_updating", "bool", False))) + return msg + +def update_ip(msg): + val = 'N/A' + try: + result = subprocess.check_output(["ifconfig", "wlan0"], encoding='utf8') + val = re.findall(r"inet addr:((\d+\.){3}\d+)", result)[0][0] + except: + pass + setattr(msg.dragonConf, get_struct_name('dp_ip_addr'), val) + return msg + + +def set_message(msg, conf): + val = params.get(conf['name'], encoding='utf8') + if val is not None: + val = val.rstrip('\x00') + else: + val = conf.get('default') + params.put(conf['name'], str(val)) + struct_val = to_struct_val(conf['name'], val) + orig_val = struct_val + if struct_val is not None: + if conf.get('min') is not None: + struct_val = max(struct_val, conf.get('min')) + if conf.get('max') is not None: + struct_val = min(struct_val, conf.get('max')) + if orig_val != struct_val: + params.put(conf['name'], str(struct_val)) + setattr(msg.dragonConf, get_struct_name(conf['name']), struct_val) + return msg + +def check_dependencies(msg, conf): + passed = True + # if has dependency and the depend param val is not in depend_vals, we dont update that conf val + # this should reduce chance of reading unnecessary params + dependencies = conf.get('depends') + if dependencies is not None: + for dependency in dependencies: + if getattr(msg.dragonConf, get_struct_name(dependency['name'])) not in dependency['vals']: + passed = False + break + return passed + +def main(): + confd_thread() + +if __name__ == "__main__": + main() diff --git a/selfdrive/locationd/paramsd.py b/selfdrive/locationd/paramsd.py index c0afe169740d30..85f6648c253a62 100755 --- a/selfdrive/locationd/paramsd.py +++ b/selfdrive/locationd/paramsd.py @@ -79,7 +79,7 @@ def main(sm=None, pm=None): min_sr, max_sr = 0.5 * CP.steerRatio, 2.0 * CP.steerRatio - params = params_reader.get("LiveParameters") + params = params_reader.get("LiveParameters") if params_reader.get('dp_reset_live_param_on_start') == b'0' else None # Check if car model matches if params is not None: diff --git a/selfdrive/loggerd/deleter.py b/selfdrive/loggerd/deleter.py index 27c40e835d39ee..79070d96eac5ea 100644 --- a/selfdrive/loggerd/deleter.py +++ b/selfdrive/loggerd/deleter.py @@ -5,9 +5,10 @@ from selfdrive.swaglog import cloudlog from selfdrive.loggerd.config import ROOT, get_available_bytes, get_available_percent from selfdrive.loggerd.uploader import listdir_by_creation +from selfdrive.dragonpilot.dashcam import DASHCAM_FREESPACE_LIMIT MIN_BYTES = 5 * 1024 * 1024 * 1024 -MIN_PERCENT = 10 +MIN_PERCENT = 10 + (DASHCAM_FREESPACE_LIMIT * 100) def deleter_thread(exit_event): diff --git a/selfdrive/loggerd/uploader.py b/selfdrive/loggerd/uploader.py index 456712f2bc442f..960fc2ac1d29e3 100644 --- a/selfdrive/loggerd/uploader.py +++ b/selfdrive/loggerd/uploader.py @@ -4,11 +4,14 @@ import json import os import random -import requests +import re +import subprocess import threading import time import traceback +import requests + from cereal import log from common.hardware import HARDWARE from common.api import Api @@ -16,6 +19,8 @@ from selfdrive.loggerd.xattr_cache import getxattr, setxattr from selfdrive.loggerd.config import ROOT from selfdrive.swaglog import cloudlog +from common.dp_time import LAST_MODIFIED_UPLOADER +from common.dp_common import get_last_modified, param_get_if_updated NetworkType = log.ThermalData.NetworkType UPLOAD_ATTR_NAME = 'user.upload' @@ -71,6 +76,16 @@ def clear_locks(root): def is_on_wifi(): return HARDWARE.get_network_type() == NetworkType.wifi +def is_on_hotspot(): + try: + result = subprocess.check_output(["ifconfig", "wlan0"], stderr=subprocess.STDOUT, encoding='utf8') + result = re.findall(r"inet addr:((\d+\.){3}\d+)", result)[0][0] + return (result.startswith('192.168.43.') or # android + result.startswith('172.20.10.') or # ios + result.startswith('10.0.2.')) # toyota entune + except Exception: + return False + class Uploader(): def __init__(self, dongle_id, root): self.dongle_id = dongle_id @@ -215,32 +230,56 @@ def uploader_fn(exit_event): cloudlog.info("uploader_fn") params = Params() - dongle_id = params.get("DongleId").decode('utf8') + dongle_id = params.get("DongleId") if dongle_id is None: - cloudlog.info("uploader missing dongle_id") - raise Exception("uploader can't start without dongle id") + return + # cloudlog.info("uploader missing dongle_id") + # raise Exception("uploader can't start without dongle id") + else: + dongle_id = dongle_id.decode('utf8') uploader = Uploader(dongle_id, ROOT) + # dp + dp_upload_on_mobile = False + dp_last_modified_upload_on_mobile = None + dp_upload_on_hotspot = False + dp_last_modified_upload_on_hotspot = None + + modified = None + last_modified = None + last_modified_check = None + backoff = 0.1 counter = 0 - on_wifi = False + should_upload = False while not exit_event.is_set(): offroad = params.get("IsOffroad") == b'1' allow_raw_upload = (params.get("IsUploadRawEnabled") != b"0") and offroad - if offroad and counter % 12 == 0: + check_network = (counter % 12 == 0 if offroad else True) + if check_network: + on_hotspot = is_on_hotspot() on_wifi = is_on_wifi() - counter += 1 - d = uploader.next_file_to_upload(with_raw=allow_raw_upload and on_wifi and offroad) + # dp - load temp monitor conf + last_modified_check, modified = get_last_modified(LAST_MODIFIED_UPLOADER, last_modified_check, modified) + if last_modified != modified: + dp_upload_on_mobile, dp_last_modified_upload_on_mobile = param_get_if_updated("dp_upload_on_mobile", "bool", dp_upload_on_mobile, dp_last_modified_upload_on_mobile) + dp_upload_on_hotspot, dp_last_modified_upload_on_hotspot = param_get_if_updated("dp_upload_on_hotspot", "bool", dp_upload_on_hotspot, dp_last_modified_upload_on_hotspot) + last_modified = modified + + should_upload = on_wifi and not on_hotspot + + d = uploader.next_file_to_upload(with_raw=allow_raw_upload and should_upload) + counter += 1 if d is None: # Nothing to upload time.sleep(60 if offroad else 5) continue key, fn = d - cloudlog.event("uploader_netcheck", is_on_wifi=on_wifi) + cloudlog.event("uploader_netcheck", is_on_hotspot=on_hotspot, is_on_wifi=on_wifi) cloudlog.info("to upload %r", d) success = uploader.upload(key, fn) if success: @@ -256,4 +295,4 @@ def main(): if __name__ == "__main__": - main() + main() \ No newline at end of file diff --git a/selfdrive/manager.py b/selfdrive/manager.py index 1775c6388b7e32..85e20349931a92 100755 --- a/selfdrive/manager.py +++ b/selfdrive/manager.py @@ -12,6 +12,8 @@ from typing import Dict, List from selfdrive.swaglog import cloudlog, add_logentries_handler +import re +from common.dp_conf import init_params_vals from common.basedir import BASEDIR from common.hardware import HARDWARE, ANDROID, PC @@ -140,9 +142,15 @@ def unblock_stdout(): add_logentries_handler(cloudlog) cloudlog.error("scons build failed\n" + error_s) + try: + result = subprocess.check_output(["ifconfig", "wlan0"], encoding='utf8') + ip = re.findall(r"inet addr:((\d+\.){3}\d+)", result)[0][0] + except: + ip = 'N/A' + # Show TextWindow error_s = "\n \n".join(["\n".join(textwrap.wrap(e, 65)) for e in errors]) - with TextWindow("openpilot failed to build\n \n" + error_s) as t: + with TextWindow(("openpilot failed to build (IP: %s)\n \n" % ip) + error_s) as t: t.wait_for_exit() exit(1) @@ -152,7 +160,7 @@ def unblock_stdout(): import cereal import cereal.messaging as messaging -from common.params import Params +from common.params import Params, put_nonblocking import selfdrive.crash as crash from selfdrive.registration import register from selfdrive.version import version, dirty @@ -191,6 +199,9 @@ def unblock_stdout(): "dmonitoringmodeld": ("selfdrive/modeld", ["./dmonitoringmodeld"]), "modeld": ("selfdrive/modeld", ["./modeld"]), "rtshield": "selfdrive.rtshield", + "systemd": "selfdrive.dragonpilot.systemd", + "appd": "selfdrive.dragonpilot.appd", + "gpxd": "selfdrive.dragonpilot.gpxd", } daemon_processes = { @@ -216,6 +227,8 @@ def get_running(): 'ui', 'uploader', 'deleter', + 'systemd', + 'appd', ] if not PC: @@ -237,6 +250,7 @@ def get_running(): 'proclogd', 'locationd', 'clocksd', + 'gpxd', ] driver_view_processes = [ @@ -413,7 +427,8 @@ def manager_init(should_register=True): if reg_res: dongle_id = reg_res else: - raise Exception("server registration failed") + dongle_id = "c"*16 + # raise Exception("server registration failed") else: dongle_id = "c"*16 @@ -448,14 +463,16 @@ def manager_thread(): cloudlog.info("manager start") cloudlog.info({"environ": os.environ}) - # save boot log - subprocess.call(["./loggerd", "--bootlog"], cwd=os.path.join(BASEDIR, "selfdrive/loggerd")) - params = Params() - # start daemon processes - for p in daemon_processes: - start_daemon_process(p) + # save boot log + if params.get("dp_logger") == b'1': + subprocess.call(["./loggerd", "--bootlog"], cwd=os.path.join(BASEDIR, "selfdrive/loggerd")) + + if params.get("dp_athenad") == b'1': + # start daemon processes + for p in daemon_processes: + start_daemon_process(p) # start persistent processes for p in persistent_processes: @@ -575,15 +592,41 @@ def main(): if params.get("Passive") is None: raise Exception("Passive must be set to continue") + init_params_vals(params) + if ANDROID: update_apks() - manager_init() + manager_init(params.get('dp_reg') == b'1') manager_prepare(spinner) spinner.close() if os.getenv("PREPAREONLY") is not None: return + # dp + del managed_processes['tombstoned'] + steering_monitor = params.get("dp_steering_monitor") == b'1' + if not steering_monitor and params.get("dp_driver_monitor") == b'0': + del managed_processes['loggerd'] + del managed_processes['logmessaged'] + del managed_processes['proclogd'] + del managed_processes['logcatd'] + del managed_processes['dmonitoringd'] + del managed_processes['dmonitoringmodeld'] + elif params.get("dp_logger") == b'0' or \ + params.get("dp_atl") == b'1' or \ + not steering_monitor: + del managed_processes['loggerd'] + del managed_processes['logmessaged'] + del managed_processes['proclogd'] + del managed_processes['logcatd'] + if params.get("dp_uploader") == b'0': + del managed_processes['uploader'] + if params.get("dp_updated") == b'0': + del managed_processes['updated'] + if params.get('dp_gpxd') == b'0': + del managed_processes['gpxd'] + # SystemExit on sigterm signal.signal(signal.SIGTERM, lambda signum, frame: sys.exit(1)) @@ -606,9 +649,15 @@ def main(): add_logentries_handler(cloudlog) cloudlog.exception("Manager failed to start") + try: + result = subprocess.check_output(["ifconfig", "wlan0"], encoding='utf8') + ip = re.findall(r"inet addr:((\d+\.){3}\d+)", result)[0][0] + except: + ip = 'N/A' + # Show last 3 lines of traceback error = traceback.format_exc(-3) - error = "Manager failed to start\n \n" + error + error = ("Manager failed to start (IP: %s)\n \n" % ip) + error with TextWindow(error) as t: t.wait_for_exit() diff --git a/selfdrive/monitoring/dmonitoringd.py b/selfdrive/monitoring/dmonitoringd.py index d8fa4932ca5385..f0e86e45700a24 100755 --- a/selfdrive/monitoring/dmonitoringd.py +++ b/selfdrive/monitoring/dmonitoringd.py @@ -6,13 +6,16 @@ from selfdrive.monitoring.driver_monitor import DriverStatus, MAX_TERMINAL_ALERTS, MAX_TERMINAL_DURATION from selfdrive.locationd.calibrationd import Calibration +from common.realtime import DT_DMON, sec_since_boot +import time + def dmonitoringd_thread(sm=None, pm=None): if pm is None: pm = messaging.PubMaster(['dMonitoringState']) if sm is None: - sm = messaging.SubMaster(['driverState', 'liveCalibration', 'carState', 'controlsState', 'model'], poll=['driverState']) + sm = messaging.SubMaster(['driverState', 'liveCalibration', 'carState', 'controlsState', 'model', 'dragonConf'], poll=['driverState']) driver_status = DriverStatus() driver_status.is_rhd_region = Params().get("IsRHD") == b"1" @@ -26,15 +29,36 @@ def dmonitoringd_thread(sm=None, pm=None): sm['carState'].buttonEvents = [] sm['carState'].steeringPressed = False sm['carState'].gasPressed = False + sm['carState'].brakePressed = False sm['carState'].standstill = True v_cruise_last = 0 driver_engaged = False + # dp + sm['dragonConf'].dpDriverMonitor = True + sm['dragonConf'].dpSteeringMonitor = True + sm['dragonConf'].dpSteeringMonitorTimer = 70 + # 10Hz <- dmonitoringmodeld while True: + start_time = sec_since_boot() sm.update() + # dp + if not sm['dragonConf'].dpDriverMonitor: + driver_status.active_monitoring_mode = False + driver_status.face_detected = False + driver_status.threshold_pre = 15. / sm['dragonConf'].dpSteeringMonitorTimer + driver_status.threshold_prompt = 6. / sm['dragonConf'].dpSteeringMonitorTimer + driver_status.step_change = DT_DMON / sm['dragonConf'].dpSteeringMonitorTimer + if not sm['dragonConf'].dpSteeringMonitor: + driver_status.awareness = 1. + driver_status.awareness_active = 1. + driver_status.awareness_passive = 1. + driver_status.terminal_alert_cnt = 0 + driver_status.terminal_time = 0 + if not sm.updated['driverState']: continue @@ -44,7 +68,8 @@ def dmonitoringd_thread(sm=None, pm=None): driver_engaged = len(sm['carState'].buttonEvents) > 0 or \ v_cruise != v_cruise_last or \ sm['carState'].steeringPressed or \ - sm['carState'].gasPressed + sm['carState'].gasPressed or \ + sm['carState'].brakePressed if driver_engaged: driver_status.update(Events(), True, sm['controlsState'].enabled, sm['carState'].standstill) v_cruise_last = v_cruise @@ -54,7 +79,8 @@ def dmonitoringd_thread(sm=None, pm=None): # Get data from dmonitoringmodeld events = Events() - driver_status.get_pose(sm['driverState'], sm['liveCalibration'].rpyCalib, sm['carState'].vEgo, sm['controlsState'].enabled) + if sm['dragonConf'].dpDriverMonitor: + driver_status.get_pose(sm['driverState'], sm['liveCalibration'].rpyCalib, sm['carState'].vEgo, sm['controlsState'].enabled) # Block engaging after max number of distrations if driver_status.terminal_alert_cnt >= MAX_TERMINAL_ALERTS or driver_status.terminal_time >= MAX_TERMINAL_DURATION: @@ -83,6 +109,9 @@ def dmonitoringd_thread(sm=None, pm=None): "isPreview": offroad, } pm.send('dMonitoringState', dat) + diff = sec_since_boot() - start_time + if not sm['dragonConf'].dpDriverMonitor and diff < 0.1: + time.sleep(0.1-diff) def main(sm=None, pm=None): dmonitoringd_thread(sm, pm) diff --git a/selfdrive/swaglog.py b/selfdrive/swaglog.py index 48447527c68c5a..a755ef112de2ec 100644 --- a/selfdrive/swaglog.py +++ b/selfdrive/swaglog.py @@ -9,7 +9,7 @@ def get_le_handler(): # setup logentries. we forward log messages to it - le_token = "e8549616-0798-4d7e-a2ca-2513ae81fa17" + le_token = ""#"e8549616-0798-4d7e-a2ca-2513ae81fa17" return LogentriesHandler(le_token, use_tls=False, verbose=False) diff --git a/selfdrive/thermald/power_monitoring.py b/selfdrive/thermald/power_monitoring.py index a6f2d4c4e9556e..f775ad5945be07 100644 --- a/selfdrive/thermald/power_monitoring.py +++ b/selfdrive/thermald/power_monitoring.py @@ -9,6 +9,7 @@ from common.hardware import TICI from selfdrive.swaglog import cloudlog +PANDA_OUTPUT_VOLTAGE = 5.28 CAR_VOLTAGE_LOW_PASS_K = 0.091 # LPF gain for 5s tau (dt/tau / (dt/tau + 1)) # A C2 uses about 1W while idling, and 30h seens like a good shutoff for most cars @@ -60,6 +61,9 @@ def _read_param(path, parser, default=0): except Exception: return default +def panda_current_to_actual_current(panda_current): + # From white/grey panda schematic + return (3.3 - (panda_current * 3.3 / 4096)) / 8.25 class PowerMonitoring: def __init__(self): @@ -129,6 +133,11 @@ def calculate(self, health): # If the battery is discharging, we can use this measurement # On C2: this is low by about 10-15%, probably mostly due to UNO draw not being factored in current_power = ((get_battery_voltage() / 1000000) * (get_battery_current() / 1000000)) + elif (health.health.hwType in [log.HealthData.HwType.whitePanda, log.HealthData.HwType.greyPanda]) and (health.health.current > 1): + # If white/grey panda, use the integrated current measurements if the measurement is not 0 + # If the measurement is 0, the current is 400mA or greater, and out of the measurement range of the panda + # This seems to be accurate to about 5% + current_power = (PANDA_OUTPUT_VOLTAGE * panda_current_to_actual_current(health.health.current)) elif (self.next_pulsed_measurement_time is not None) and (self.next_pulsed_measurement_time <= now): # TODO: Figure out why this is off by a factor of 3/4??? FUDGE_FACTOR = 1.33 diff --git a/selfdrive/thermald/thermald.py b/selfdrive/thermald/thermald.py index c36e9cdbe07e3d..939be2fb711557 100755 --- a/selfdrive/thermald/thermald.py +++ b/selfdrive/thermald/thermald.py @@ -45,6 +45,9 @@ LEON = False last_eon_fan_val = None +params = Params() +from common.dp_time import LAST_MODIFIED_THERMALD +from common.dp_common import get_last_modified, param_get_if_updated def get_thermal_config(): # (tz, scale) @@ -124,10 +127,14 @@ def set_eon_fan(val): _TEMP_THRS_H = [50., 65., 80., 10000] # temp thresholds to control fan speed - low hysteresis _TEMP_THRS_L = [42.5, 57.5, 72.5, 10000] -# fan speed options -_FAN_SPEEDS = [0, 16384, 32768, 65535] -# max fan speed only allowed if battery is hot -_BAT_TEMP_THRESHOLD = 45. +if params.get('dp_full_speed_fan', encoding='utf8') == "1": + _FAN_SPEEDS = [65535, 65535, 65535, 65535] + _BAT_TEMP_THRESHOLD = 0. +else: + # fan speed options + _FAN_SPEEDS = [0, 16384, 32768, 65535] + # max fan speed only allowed if battery is hot + _BAT_TEMP_THRESHOLD = 45. def handle_fan_eon(max_cpu_temp, bat_temp, fan_speed, ignition): @@ -151,10 +158,17 @@ def handle_fan_eon(max_cpu_temp, bat_temp, fan_speed, ignition): def handle_fan_uno(max_cpu_temp, bat_temp, fan_speed, ignition): - new_speed = int(interp(max_cpu_temp, [40.0, 80.0], [0, 80])) + dp_uno_fan_mode = params.get('dp_uno_fan_mode') == b'1' + if dp_uno_fan_mode: + new_speed = int(interp(max_cpu_temp, [65.0, 80.0, 90.0], [0, 20, 60])) + else: + new_speed = int(interp(max_cpu_temp, [40.0, 80.0], [0, 80])) if not ignition: - new_speed = min(30, new_speed) + if dp_uno_fan_mode: + new_speed = min(10, new_speed) + else: + new_speed = min(20, new_speed) return new_speed @@ -198,14 +212,35 @@ def thermald_thread(): should_start_prev = False handle_fan = None is_uno = False + has_relay = False - params = Params() pm = PowerMonitoring() no_panda_cnt = 0 thermal_config = get_thermal_config() + # dp + dp_temp_monitor = True + dp_last_modified_temp_monitor = None + dp_last_modified_auto_shutdown = None + dp_last_modified_auto_shutdown_in = None + dp_auto_shutdown = False + dp_auto_shutdown_in = 90 + dp_allow_shutdown = True + dp_allow_shutdown_last = True + modified = None + last_modified = None + last_modified_check = None + while 1: + # dp - load temp monitor conf + last_modified_check, modified = get_last_modified(LAST_MODIFIED_THERMALD, last_modified_check, modified) + if last_modified != modified: + dp_temp_monitor, dp_last_modified_temp_monitor = param_get_if_updated("dp_temp_monitor", "bool", dp_temp_monitor, dp_last_modified_temp_monitor) + dp_auto_shutdown, dp_last_modified_auto_shutdown = param_get_if_updated("dp_auto_shutdown", "bool", dp_auto_shutdown, dp_last_modified_auto_shutdown) + dp_auto_shutdown_in, dp_last_modified_auto_shutdown_in = param_get_if_updated("dp_auto_shutdown_in", "int", dp_auto_shutdown_in, dp_last_modified_auto_shutdown_in) + last_modified = modified + health = messaging.recv_sock(health_sock, wait=True) location = messaging.recv_sock(location_sock) location = location.gpsLocation if location else None @@ -228,6 +263,7 @@ def thermald_thread(): # Setup fan handler on first connect to panda if handle_fan is None and health.health.hwType != log.HealthData.HwType.unknown: is_uno = health.health.hwType == log.HealthData.HwType.uno + has_relay = health.health.hwType in [log.HealthData.HwType.blackPanda, log.HealthData.HwType.uno, log.HealthData.HwType.dos] if (not EON) or is_uno: cloudlog.info("Setting up UNO fan handler") @@ -284,7 +320,7 @@ def thermald_thread(): # since going onroad increases load and can make temps go over 107 # We only do this if there is a relay that prevents the car from faulting is_offroad_for_5_min = (started_ts is None) and ((not started_seen) or (off_ts is None) or (sec_since_boot() - off_ts > 60 * 5)) - if max_cpu_temp > 107. or bat_temp >= 63. or (is_offroad_for_5_min and max_cpu_temp > 70.0): + if max_cpu_temp > 107. or bat_temp >= 63. or (has_relay and is_offroad_for_5_min and max_cpu_temp > 70.0): # onroad not allowed thermal_status = ThermalStatus.danger elif max_comp_temp > 96.0 or bat_temp > 60.: @@ -303,48 +339,50 @@ def thermald_thread(): # all good thermal_status = ThermalStatus.green + if not dp_temp_monitor and thermal_status in [ThermalStatus.yellow, ThermalStatus.red, ThermalStatus.danger]: + thermal_status = ThermalStatus.yellow # **** starting logic **** # Check for last update time and display alerts if needed - now = datetime.datetime.utcnow() - - # show invalid date/time alert - startup_conditions["time_valid"] = (now.year > 2020) or (now.year == 2020 and now.month >= 10) - set_offroad_alert_if_changed("Offroad_InvalidTime", (not startup_conditions["time_valid"])) - - # Show update prompt - try: - last_update = datetime.datetime.fromisoformat(params.get("LastUpdateTime", encoding='utf8')) - except (TypeError, ValueError): - last_update = now - dt = now - last_update - - update_failed_count = params.get("UpdateFailedCount") - update_failed_count = 0 if update_failed_count is None else int(update_failed_count) - last_update_exception = params.get("LastUpdateException", encoding='utf8') - - if update_failed_count > 15 and last_update_exception is not None: - if current_branch in ["release2", "dashcam"]: - extra_text = "Ensure the software is correctly installed" - else: - extra_text = last_update_exception - - set_offroad_alert_if_changed("Offroad_ConnectivityNeeded", False) - set_offroad_alert_if_changed("Offroad_ConnectivityNeededPrompt", False) - set_offroad_alert_if_changed("Offroad_UpdateFailed", True, extra_text=extra_text) - elif dt.days > DAYS_NO_CONNECTIVITY_MAX and update_failed_count > 1: - set_offroad_alert_if_changed("Offroad_UpdateFailed", False) - set_offroad_alert_if_changed("Offroad_ConnectivityNeededPrompt", False) - set_offroad_alert_if_changed("Offroad_ConnectivityNeeded", True) - elif dt.days > DAYS_NO_CONNECTIVITY_PROMPT: - remaining_time = str(max(DAYS_NO_CONNECTIVITY_MAX - dt.days, 0)) - set_offroad_alert_if_changed("Offroad_UpdateFailed", False) - set_offroad_alert_if_changed("Offroad_ConnectivityNeeded", False) - set_offroad_alert_if_changed("Offroad_ConnectivityNeededPrompt", True, extra_text=f"{remaining_time} days.") - else: - set_offroad_alert_if_changed("Offroad_UpdateFailed", False) - set_offroad_alert_if_changed("Offroad_ConnectivityNeeded", False) - set_offroad_alert_if_changed("Offroad_ConnectivityNeededPrompt", False) + # now = datetime.datetime.utcnow() + # + # # show invalid date/time alert + # startup_conditions["time_valid"] = (now.year > 2020) or (now.year == 2020 and now.month >= 10) + # set_offroad_alert_if_changed("Offroad_InvalidTime", (not startup_conditions["time_valid"])) + # + # # Show update prompt + # try: + # last_update = datetime.datetime.fromisoformat(params.get("LastUpdateTime", encoding='utf8')) + # except (TypeError, ValueError): + # last_update = now + # dt = now - last_update + # + # update_failed_count = params.get("UpdateFailedCount") + # update_failed_count = 0 if update_failed_count is None else int(update_failed_count) + # last_update_exception = params.get("LastUpdateException", encoding='utf8') + # + # if update_failed_count > 15 and last_update_exception is not None: + # if current_branch in ["release2", "dashcam"]: + # extra_text = "Ensure the software is correctly installed" + # else: + # extra_text = last_update_exception + # + # set_offroad_alert_if_changed("Offroad_ConnectivityNeeded", False) + # set_offroad_alert_if_changed("Offroad_ConnectivityNeededPrompt", False) + # set_offroad_alert_if_changed("Offroad_UpdateFailed", True, extra_text=extra_text) + # elif dt.days > DAYS_NO_CONNECTIVITY_MAX and update_failed_count > 1: + # set_offroad_alert_if_changed("Offroad_UpdateFailed", False) + # set_offroad_alert_if_changed("Offroad_ConnectivityNeededPrompt", False) + # set_offroad_alert_if_changed("Offroad_ConnectivityNeeded", True) + # elif dt.days > DAYS_NO_CONNECTIVITY_PROMPT: + # remaining_time = str(max(DAYS_NO_CONNECTIVITY_MAX - dt.days, 0)) + # set_offroad_alert_if_changed("Offroad_UpdateFailed", False) + # set_offroad_alert_if_changed("Offroad_ConnectivityNeeded", False) + # set_offroad_alert_if_changed("Offroad_ConnectivityNeededPrompt", True, extra_text=f"{remaining_time} days.") + # else: + # set_offroad_alert_if_changed("Offroad_UpdateFailed", False) + # set_offroad_alert_if_changed("Offroad_ConnectivityNeeded", False) + # set_offroad_alert_if_changed("Offroad_ConnectivityNeededPrompt", False) startup_conditions["not_uninstalling"] = not params.get("DoUninstall") == b"1" startup_conditions["accepted_terms"] = params.get("HasAcceptedTerms") == terms_version @@ -365,8 +403,7 @@ def thermald_thread(): set_offroad_alert_if_changed("Offroad_TemperatureTooHigh", (not startup_conditions["device_temp_good"])) should_start = all(startup_conditions.values()) - startup_conditions["hardware_supported"] = health is not None and health.health.hwType not in [log.HealthData.HwType.whitePanda, - log.HealthData.HwType.greyPanda] + startup_conditions["hardware_supported"] = True set_offroad_alert_if_changed("Offroad_HardwareUnsupported", health is not None and not startup_conditions["hardware_supported"]) if should_start: @@ -402,6 +439,33 @@ def thermald_thread(): time.sleep(10) os.system('LD_LIBRARY_PATH="" svc power shutdown') + # dp + if health is None and msg.thermal.usbOnline: + # happen when boot up without panda connected + dp_allow_shutdown = False + elif health is not None and msg.thermal.usbOnline and health.health.hwType == log.HealthData.HwType.unknown: + # happen when panda was there and gone + dp_allow_shutdown = False + else: + dp_allow_shutdown = True + + # if allow shutdown status change, we reset off_ts + if dp_allow_shutdown != dp_allow_shutdown_last and off_ts is not None: + off_ts = sec_since_boot() + dp_allow_shutdown_last = dp_allow_shutdown + + if dp_allow_shutdown and off_ts is not None and dp_auto_shutdown and sec_since_boot() - off_ts >= dp_auto_shutdown_in * 60: + msg.thermal.chargingDisabled = True + shutdown = False + if health is not None: + if health.health.usbPowerMode in [log.HealthData.UsbPowerMode.client, log.HealthData.UsbPowerMode.none]: + shutdown = True + else: + shutdown = True + if shutdown: + time.sleep(10) + os.system('LD_LIBRARY_PATH="" svc power shutdown') + msg.thermal.chargingError = current_filter.x > 0. and msg.thermal.batteryPercent < 90 # if current is positive, then battery is being discharged msg.thermal.started = started_ts is not None msg.thermal.startedTs = int(1e9*(started_ts or 0)) @@ -415,12 +479,12 @@ def thermald_thread(): startup_conditions_prev = startup_conditions.copy() # report to server once per minute - if (count % int(60. / DT_TRML)) == 0: - cloudlog.event("STATUS_PACKET", - count=count, - health=(health.to_dict() if health else None), - location=(location.to_dict() if location else None), - thermal=msg.to_dict()) + # if (count % int(60. / DT_TRML)) == 0: + # cloudlog.event("STATUS_PACKET", + # count=count, + # health=(health.to_dict() if health else None), + # location=(location.to_dict() if location else None), + # thermal=msg.to_dict()) count += 1 diff --git a/selfdrive/ui/SConscript b/selfdrive/ui/SConscript index 414f862823863c..d3c5eecffed390 100644 --- a/selfdrive/ui/SConscript +++ b/selfdrive/ui/SConscript @@ -43,7 +43,7 @@ if arch in ["x86_64", "Darwin", "larch64"]: -src = ['ui.cc', 'paint.cc', 'sidebar.cc', '#phonelibs/nanovg/nanovg.c'] +src = ['ui.cc', 'paint.cc', 'sidebar.cc', 'paint_dp.cc', '#phonelibs/nanovg/nanovg.c'] libs = [common, 'zmq', 'capnp', 'kj', 'm', cereal, messaging, gpucommon, visionipc] diff --git a/selfdrive/ui/android/spinner/spinner b/selfdrive/ui/android/spinner/spinner index 2acc7e7854aeb0..1a150bf376e3fd 100755 Binary files a/selfdrive/ui/android/spinner/spinner and b/selfdrive/ui/android/spinner/spinner differ diff --git a/selfdrive/ui/android/spinner/spinner.c b/selfdrive/ui/android/spinner/spinner.c index 33ebf7cd38f3d1..70ff7103479c7c 100644 --- a/selfdrive/ui/android/spinner/spinner.c +++ b/selfdrive/ui/android/spinner/spinner.c @@ -118,17 +118,17 @@ int main(int argc, char** argv) { nvgFill(vg); // spin track - nvgSave(vg); - nvgTranslate(vg, spinner_img_xc, spinner_img_yc); - nvgRotate(vg, (3.75*M_PI * cnt/120.0)); - nvgTranslate(vg, -spinner_img_xc, -spinner_img_yc); - NVGpaint spinner_imgPaint = nvgImagePattern(vg, spinner_img_x, spinner_img_y, - spinner_img_s, spinner_img_s, 0, spinner_img, 0.6f); - nvgBeginPath(vg); - nvgFillPaint(vg, spinner_imgPaint); - nvgRect(vg, spinner_img_x, spinner_img_y, spinner_img_s, spinner_img_s); - nvgFill(vg); - nvgRestore(vg); +// nvgSave(vg); +// nvgTranslate(vg, spinner_img_xc, spinner_img_yc); +// nvgRotate(vg, (3.75*M_PI * cnt/120.0)); +// nvgTranslate(vg, -spinner_img_xc, -spinner_img_yc); +// NVGpaint spinner_imgPaint = nvgImagePattern(vg, spinner_img_x, spinner_img_y, +// spinner_img_s, spinner_img_s, 0, spinner_img, 0.6f); +// nvgBeginPath(vg); +// nvgFillPaint(vg, spinner_imgPaint); +// nvgRect(vg, spinner_img_x, spinner_img_y, spinner_img_s, spinner_img_s); +// nvgFill(vg); +// nvgRestore(vg); // comma NVGpaint comma_imgPaint = nvgImagePattern(vg, spinner_img_x, spinner_img_y, diff --git a/selfdrive/ui/android/ui.cc b/selfdrive/ui/android/ui.cc index 08b734a6e01bf4..95b72719697ce4 100644 --- a/selfdrive/ui/android/ui.cc +++ b/selfdrive/ui/android/ui.cc @@ -46,7 +46,10 @@ static void handle_display_state(UIState *s, bool user_input) { // determine desired state bool should_wake = s->awake; - if (user_input || s->ignition || s->started) { + if (s->scene.dpUiScreenOffReversing && s->scene.isReversing) { + should_wake = false; + awake_timeout = 0; + } else if (user_input || (!s->scene.dpUiScreenOffDriving && (s->ignition || s->started))) { should_wake = true; awake_timeout = 30*UI_FREQ; } else if (awake_timeout == 0){ @@ -66,6 +69,44 @@ static void handle_display_state(UIState *s, bool user_input) { } } +static bool handle_dp_btn_touch(UIState *s, int touch_x, int touch_y) { + //dfButton manager // code below thanks to kumar: https://github.com/arne182/openpilot/commit/71d5aac9f8a3f5942e89634b20cbabf3e19e3e78 + if (s->started && s->active_app != cereal::UiLayoutState::App::SETTINGS) { + if (s->scene.dpDynamicFollow > 0 && touch_x >= df_btn_x && touch_x <= (df_btn_x + df_btn_w) && touch_y >= df_btn_y && touch_y <= (df_btn_y + df_btn_h)) { + int val = s->scene.dpDynamicFollow; + val++; + if (val >= 5) { + val = 1; + } + + char str[2] = {0}; + sprintf(str, "%d", val); + Params().write_db_value("dp_dynamic_follow", str, 1); + + char time_str[11]; + snprintf(time_str, 11, "%lu", time(NULL)); + Params().write_db_value("dp_last_modified", time_str, 11); + return true; + } else if (s->scene.dpAccelProfile > 0 && touch_x >= ap_btn_x && touch_x <= (ap_btn_x + ap_btn_w) && touch_y >= ap_btn_y && touch_y <= (ap_btn_y + ap_btn_h)) { + int val = s->scene.dpAccelProfile; + val++; + if (val >= 4) { + val = 1; + } + + char str[2] = {0}; + sprintf(str, "%d", val); + Params().write_db_value("dp_accel_profile", str, 1); + + char time_str[11]; + snprintf(time_str, 11, "%lu", time(NULL)); + Params().write_db_value("dp_last_modified", time_str, 11); + return true; + } + } + return false; +} + static void handle_vision_touch(UIState *s, int touch_x, int touch_y) { if (s->started && (touch_x >= s->scene.viz_rect.x - bdr_s) && (s->active_app != cereal::UiLayoutState::App::SETTINGS)) { @@ -146,6 +187,11 @@ int main(int argc, char* argv[]) { const int MAX_VOLUME = LEON ? 15 : 12; s->sound->setVolume(MIN_VOLUME); + // dp + s->scene.dp_alert_rate = 0; + s->scene.dp_alert_type = 1; + bool show_layer = true; + while (!do_exit) { if (!s->started) { usleep(50 * 1000); @@ -153,31 +199,58 @@ int main(int argc, char* argv[]) { double u1 = millis_since_boot(); ui_update(s); - + // hide layer when waze is running + if (s->scene.dpFullScreenApp) { + if (!show_layer && !s->started && s->status == STATUS_OFFROAD) { + framebuffer_swap_layer(s->fb, 0); + show_layer = true; + } else if (show_layer && s->started) { + framebuffer_swap_layer(s->fb, 0x00001000); + show_layer = false; + } + } + if (s->started && s->scene.dpFullScreenApp) { + // always collapsed sidebar when vision is connect and in waze mode + s->scene.uilayout_sidebarcollapsed = true; + } else { // poll for touch events int touch_x = -1, touch_y = -1; int touched = touch_poll(&touch, &touch_x, &touch_y, 0); if (touched == 1) { + if (!handle_dp_btn_touch(s, touch_x, touch_y)) { handle_sidebar_touch(s, touch_x, touch_y); handle_vision_touch(s, touch_x, touch_y); + } } // Don't waste resources on drawing in case screen is off handle_display_state(s, touched == 1); + } if (!s->awake) { continue; } // up one notch every 5 m/s - s->sound->setVolume(fmin(MAX_VOLUME, MIN_VOLUME + s->scene.controls_state.getVEgo() / 5)); + float min = MIN_VOLUME + s->scene.controls_state.getVEgo() / 5; + if (s->scene.dpUiVolumeBoost != 0) { + min = min * (1 + s->scene.dpUiVolumeBoost * 0.01); + } + s->sound->setVolume(fmin(MAX_VOLUME, min)); // up one notch every 5 m/s // set brightness - float clipped_brightness = fmin(512, (s->light_sensor*brightness_m) + brightness_b); - smooth_brightness = fmin(255, clipped_brightness * 0.01 + smooth_brightness * 0.99); - ui_set_brightness(s, (int)smooth_brightness); - + if (s->scene.dpUiBrightness == 0) { + float clipped_brightness = fmin(512, (s->light_sensor*brightness_m) + brightness_b); + smooth_brightness = fmin(255, clipped_brightness * 0.01 + smooth_brightness * 0.99); + ui_set_brightness(s, (int)smooth_brightness); + } else { + ui_set_brightness(s, (int)(255*s->scene.dpUiBrightness*0.01)); + } update_offroad_layout_state(s, pm); + // skip refresh when running waze + if (s->scene.dpFullScreenApp && s->started) { + continue; + } ui_draw(s); double u2 = millis_since_boot(); if (!s->scene.frontview && (u2-u1 > 66)) { diff --git a/selfdrive/ui/paint.cc b/selfdrive/ui/paint.cc index 72dae8134a5b02..632cc2875fd85b 100644 --- a/selfdrive/ui/paint.cc +++ b/selfdrive/ui/paint.cc @@ -17,6 +17,7 @@ extern "C"{ #include "paint.hpp" #include "sidebar.hpp" +#include "paint_dp.hpp" // TODO: this is also hardcoded in common/transformations/camera.py @@ -226,6 +227,7 @@ static void update_line_data(UIState *s, const cereal::ModelDataV2::XYZTData::Re static void ui_draw_vision_lane_lines(UIState *s) { const UIScene *scene = &s->scene; // paint lanelines + if (scene->dpUiLane) { line_vertices_data *pvd_ll = &s->lane_line_vertices[0]; for (int ll_idx = 0; ll_idx < 4; ll_idx++) { if(s->sm->updated("modelV2")) { @@ -234,7 +236,7 @@ static void ui_draw_vision_lane_lines(UIState *s) { NVGcolor color = nvgRGBAf(1.0, 1.0, 1.0, scene->lane_line_probs[ll_idx]); ui_draw_line(s, (pvd_ll + ll_idx)->v, (pvd_ll + ll_idx)->cnt, &color, nullptr); } - + // paint road edges line_vertices_data *pvd_re = &s->road_edge_vertices[0]; for (int re_idx = 0; re_idx < 2; re_idx++) { @@ -244,12 +246,15 @@ static void ui_draw_vision_lane_lines(UIState *s) { NVGcolor color = nvgRGBAf(1.0, 0.0, 0.0, std::clamp(1.0-scene->road_edge_stds[re_idx], 0.0, 1.0)); ui_draw_line(s, (pvd_re + re_idx)->v, (pvd_re + re_idx)->cnt, &color, nullptr); } - + } + // paint path + if (scene->dpUiPath) { if(s->sm->updated("modelV2")) { update_track_data(s, scene->model.getPosition(), &s->track_vertices); } ui_draw_track(s, &s->track_vertices); + } } // Draw all world space objects. @@ -275,7 +280,7 @@ static void ui_draw_world(UIState *s) { ui_draw_vision_lane_lines(s); // Draw lead indicators if openpilot is handling longitudinal - if (s->longitudinal_control) { + if (s->scene.dpUiLead) { if (scene->lead_data[0].getStatus()) { draw_lead(s, scene->lead_data[0]); } @@ -332,6 +337,7 @@ static void ui_draw_vision_speed(UIState *s) { } const int viz_speed_w = 280; const int viz_speed_x = viz_rect.centerX() - viz_speed_w/2; + if (s->scene.dpUiSpeed) { char speed_str[32]; nvgBeginPath(s->vg); @@ -341,6 +347,32 @@ static void ui_draw_vision_speed(UIState *s) { snprintf(speed_str, sizeof(speed_str), "%d", (int)speed); ui_draw_text(s->vg, viz_rect.centerX(), 240, speed_str, 96*2.5, COLOR_WHITE, s->font_sans_bold); ui_draw_text(s->vg, viz_rect.centerX(), 320, s->is_metric?"km/h":"mph", 36*2.5, COLOR_WHITE_ALPHA(200), s->font_sans_regular); + } + // dp blinker, from kegman + if (s->scene.dpUiBlinker) { + if(s->scene.leftBlinker) { + nvgBeginPath(s->vg); + nvgMoveTo(s->vg, viz_speed_x, viz_rect.y + header_h/4); + nvgLineTo(s->vg, viz_speed_x - viz_speed_w/2, viz_rect.y + header_h/4 + header_h/4); + nvgLineTo(s->vg, viz_speed_x, viz_rect.y + header_h/2 + header_h/4); + nvgClosePath(s->vg); + nvgFillColor(s->vg, nvgRGBA(0,255,0,s->scene.blinker_blinkingrate>=60?190:30)); + nvgFill(s->vg); + } + if(s->scene.rightBlinker) { + nvgBeginPath(s->vg); + nvgMoveTo(s->vg, viz_speed_x+viz_speed_w, viz_rect.y + header_h/4); + nvgLineTo(s->vg, viz_speed_x+viz_speed_w + viz_speed_w/2, viz_rect.y + header_h/4 + header_h/4); + nvgLineTo(s->vg, viz_speed_x+viz_speed_w, viz_rect.y + header_h/2 + header_h/4); + nvgClosePath(s->vg); + nvgFillColor(s->vg, nvgRGBA(0,255,0,s->scene.blinker_blinkingrate>=60?190:30)); + nvgFill(s->vg); + } + if(s->scene.leftBlinker || s->scene.rightBlinker) { + s->scene.blinker_blinkingrate -= 3; + if(s->scene.blinker_blinkingrate<0) s->scene.blinker_blinkingrate = 120; + } + } } static void ui_draw_vision_event(UIState *s) { @@ -424,20 +456,43 @@ static void ui_draw_driver_view(UIState *s) { static void ui_draw_vision_header(UIState *s) { const Rect &viz_rect = s->scene.viz_rect; + if (!s->scene.dpFullScreenApp) { NVGpaint gradient = nvgLinearGradient(s->vg, viz_rect.x, viz_rect.y+(header_h-(header_h/2.5)), viz_rect.x, viz_rect.y+header_h, nvgRGBAf(0,0,0,0.45), nvgRGBAf(0,0,0,0)); - ui_draw_rect(s->vg, viz_rect.x, viz_rect.y, viz_rect.w, header_h, gradient); - + } + if (s->scene.dpUiMaxSpeed) { ui_draw_vision_maxspeed(s); + } + if (s->scene.dpUiSpeed) { ui_draw_vision_speed(s); + } + if (s->scene.dpUiEvent) { ui_draw_vision_event(s); + } } static void ui_draw_vision_footer(UIState *s) { + if (s->scene.dpUiFace) { ui_draw_vision_face(s); + } + if ((int)s->scene.dpDynamicFollow > 0) { + ui_draw_df_button(s); + } + if ((int)s->scene.dpAccelProfile > 0) { + ui_draw_ap_button(s); + } + if (s->scene.dpUiDev) { + ui_draw_bbui(s); + } + if (s->scene.dpUiDevMini) { + ui_draw_blindspots(s, true); + ui_draw_infobar(s); + } else { + ui_draw_blindspots(s, false); + } } void ui_draw_vision_alert(UIState *s, cereal::ControlsState::AlertSize va_size, UIStatus va_color, @@ -446,34 +501,34 @@ void ui_draw_vision_alert(UIState *s, cereal::ControlsState::AlertSize va_size, {cereal::ControlsState::AlertSize::NONE, 0}, {cereal::ControlsState::AlertSize::SMALL, 241}, {cereal::ControlsState::AlertSize::MID, 390}, - {cereal::ControlsState::AlertSize::FULL, s->fb_h}}; + {cereal::ControlsState::AlertSize::FULL, s->fb_h - 150}}; const UIScene *scene = &s->scene; - bool longAlert1 = strlen(va_text1) > 15; + bool longAlert1 = true; NVGcolor color = bg_colors[va_color]; color.a *= s->alert_blinking_alpha; int alr_s = alert_size_map[va_size]; - const int alr_x = scene->viz_rect.x - bdr_s; - const int alr_w = scene->viz_rect.w + (bdr_s*2); - const int alr_h = alr_s+(va_size==cereal::ControlsState::AlertSize::NONE?0:bdr_s); - const int alr_y = s->fb_h-alr_h; + const int alr_x = scene->viz_rect.x - bdr_s + 100; + const int alr_w = scene->viz_rect.w + (bdr_s*2) - 200; + const int alr_h = alr_s+(va_size==cereal::ControlsState::AlertSize::NONE?0:bdr_s) - 100; + const int alr_y = s->fb_h-alr_h - 100; - ui_draw_rect(s->vg, alr_x, alr_y, alr_w, alr_h, color); + ui_draw_rect(s->vg, alr_x, alr_y, alr_w, alr_h, color, 20); NVGpaint gradient = nvgLinearGradient(s->vg, alr_x, alr_y, alr_x, alr_y+alr_h, nvgRGBAf(0.0,0.0,0.0,0.05), nvgRGBAf(0.0,0.0,0.0,0.35)); - ui_draw_rect(s->vg, alr_x, alr_y, alr_w, alr_h, gradient); + ui_draw_rect(s->vg, alr_x, alr_y, alr_w, alr_h, gradient, 20); nvgFillColor(s->vg, COLOR_WHITE); nvgTextAlign(s->vg, NVG_ALIGN_CENTER | NVG_ALIGN_BASELINE); if (va_size == cereal::ControlsState::AlertSize::SMALL) { - ui_draw_text(s->vg, alr_x+alr_w/2, alr_y+alr_h/2+15, va_text1, 40*2.5, COLOR_WHITE, s->font_sans_semibold); + ui_draw_text(s->vg, alr_x+alr_w/2, alr_y+alr_h/2+15, va_text1, 32*2.5, COLOR_WHITE, s->font_sans_semibold); } else if (va_size == cereal::ControlsState::AlertSize::MID) { - ui_draw_text(s->vg, alr_x+alr_w/2, alr_y+alr_h/2-45, va_text1, 48*2.5, COLOR_WHITE, s->font_sans_bold); - ui_draw_text(s->vg, alr_x+alr_w/2, alr_y+alr_h/2+75, va_text2, 36*2.5, COLOR_WHITE, s->font_sans_regular); + ui_draw_text(s->vg, alr_x+alr_w/2, alr_y+alr_h/2-45, va_text1, 40*2.5, COLOR_WHITE, s->font_sans_bold); + ui_draw_text(s->vg, alr_x+alr_w/2, alr_y+alr_h/2+75, va_text2, 28*2.5, COLOR_WHITE, s->font_sans_regular); } else if (va_size == cereal::ControlsState::AlertSize::FULL) { nvgFontSize(s->vg, (longAlert1?72:96)*2.5); nvgFontFaceId(s->vg, s->font_sans_bold); @@ -482,7 +537,7 @@ void ui_draw_vision_alert(UIState *s, cereal::ControlsState::AlertSize va_size, nvgFontSize(s->vg, 48*2.5); nvgFontFaceId(s->vg, s->font_sans_regular); nvgTextAlign(s->vg, NVG_ALIGN_CENTER | NVG_ALIGN_BOTTOM); - nvgTextBox(s->vg, alr_x, alr_h-(longAlert1?300:360), alr_w-60, va_text2, NULL); + nvgTextBox(s->vg, alr_x, alr_h-(longAlert1?150:210), alr_w-60, va_text2, NULL); } } @@ -520,7 +575,11 @@ static void ui_draw_vision(UIState *s) { static void ui_draw_background(UIState *s) { const NVGcolor color = bg_colors[s->status]; + if (s->vision_connected && s->scene.dpFullScreenApp) { + glClearColor(0, 0, 0, 0); + } else { glClearColor(color.r, color.g, color.b, 1.0); + } glClear(GL_STENCIL_BUFFER_BIT | GL_COLOR_BUFFER_BIT); } @@ -539,7 +598,10 @@ void ui_draw(UIState *s) { glViewport(0, 0, s->fb_w, s->fb_h); nvgBeginFrame(s->vg, s->fb_w, s->fb_h, 1.0f); ui_draw_sidebar(s); - if (s->started && s->active_app == cereal::UiLayoutState::App::NONE && + if (s->vision_connected && s->scene.dpFullScreenApp) { + ui_draw_vision(s); + } + else if (s->started && s->active_app == cereal::UiLayoutState::App::NONE && s->status != STATUS_OFFROAD && s->vision_connected) { ui_draw_vision(s); } @@ -629,12 +691,13 @@ void ui_nvg_init(UIState *s) { #endif assert(s->vg); - - s->font_sans_regular = nvgCreateFont(s->vg, "sans-regular", "../assets/fonts/opensans_regular.ttf"); + s->font_courbd = nvgCreateFont(s->vg, "courbd", "../assets/fonts/courbd.ttf"); + assert(s->font_courbd >= 0); + s->font_sans_regular = nvgCreateFont(s->vg, "sans-regular", "../../dragonpilot/cjk-fonts/NotoSansCJKtc-Regular.otf"); assert(s->font_sans_regular >= 0); - s->font_sans_semibold = nvgCreateFont(s->vg, "sans-semibold", "../assets/fonts/opensans_semibold.ttf"); + s->font_sans_semibold = nvgCreateFont(s->vg, "sans-semibold", "../../dragonpilot/cjk-fonts/NotoSansCJKtc-Medium.otf"); assert(s->font_sans_semibold >= 0); - s->font_sans_bold = nvgCreateFont(s->vg, "sans-bold", "../assets/fonts/opensans_bold.ttf"); + s->font_sans_bold = nvgCreateFont(s->vg, "sans-bold", "../../dragonpilot/cjk-fonts/NotoSansCJKtc-Bold.otf"); assert(s->font_sans_bold >= 0); s->img_wheel = nvgCreateImage(s->vg, "../assets/img_chffr_wheel.png", 1); diff --git a/selfdrive/ui/paint_dp.cc b/selfdrive/ui/paint_dp.cc new file mode 100644 index 00000000000000..1a0515699a617e --- /dev/null +++ b/selfdrive/ui/paint_dp.cc @@ -0,0 +1,365 @@ +#include "paint_dp.hpp" +#include + +void ui_draw_df_button(UIState *s) { + nvgBeginPath(s->vg); + nvgRoundedRect(s->vg, df_btn_x, df_btn_y, df_btn_w, df_btn_h, 20); + nvgStrokeColor(s->vg, COLOR_WHITE_ALPHA(80)); + nvgStrokeWidth(s->vg, 6); + nvgStroke(s->vg); + + nvgFontFaceId(s->vg, s->font_sans_regular); + nvgFillColor(s->vg, COLOR_WHITE_ALPHA(200)); + nvgFontSize(s->vg, (s->scene.dpLocale == "zh-TW"? 96 : s->scene.dpLocale == "zh-CN"? 96 : 48)); + nvgTextAlign(s->vg, NVG_ALIGN_CENTER); + + nvgText(s->vg, df_btn_x + df_btn_w / 2, df_btn_y + df_btn_h / 2, + s->scene.dpDynamicFollow == 4? (s->scene.dpLocale == "zh-TW"? "自動" : s->scene.dpLocale == "zh-CN"? "自动" : "AUTO") : + s->scene.dpDynamicFollow == 3? (s->scene.dpLocale == "zh-TW"? "長距" : s->scene.dpLocale == "zh-CN"? "长距" : "LONG") : + s->scene.dpDynamicFollow == 2? (s->scene.dpLocale == "zh-TW"? "正常" : s->scene.dpLocale == "zh-CN"? "正常" : "NORMAL") : + (s->scene.dpLocale == "zh-TW"? "短距" : s->scene.dpLocale == "zh-CN"? "短距" : "SHORT"), + NULL); + + nvgFontFaceId(s->vg, s->font_sans_regular); + nvgFillColor(s->vg, COLOR_WHITE_ALPHA(200)); + nvgFontSize(s->vg, 37.5); + nvgTextAlign(s->vg, NVG_ALIGN_CENTER); + nvgText(s->vg, df_btn_x + df_btn_w / 2, df_btn_y + df_btn_h - 10, + (s->scene.dpLocale == "zh-TW"? "車距" : s->scene.dpLocale == "zh-CN"? "车距" : "FOLLOW"), + NULL); +} + +void ui_draw_ap_button(UIState *s) { + nvgBeginPath(s->vg); + nvgRoundedRect(s->vg, ap_btn_x, ap_btn_y, ap_btn_w, ap_btn_h, 20); + nvgStrokeColor(s->vg, COLOR_WHITE_ALPHA(80)); + nvgStrokeWidth(s->vg, 6); + nvgStroke(s->vg); + + nvgFontFaceId(s->vg, s->font_sans_regular); + nvgFillColor(s->vg, COLOR_WHITE_ALPHA(200)); + nvgFontSize(s->vg, (s->scene.dpLocale == "zh-TW"? 96 : s->scene.dpLocale == "zh-CN"? 96 : 48)); + nvgTextAlign(s->vg, NVG_ALIGN_CENTER); + + nvgText(s->vg, ap_btn_x + ap_btn_w / 2, ap_btn_y + ap_btn_h / 2, + s->scene.dpAccelProfile == 3? (s->scene.dpLocale == "zh-TW"? "運動" : s->scene.dpLocale == "zh-CN"? "运动" : "SPORT") : + s->scene.dpAccelProfile == 2? (s->scene.dpLocale == "zh-TW"? "正常" : s->scene.dpLocale == "zh-CN"? "正常" : "NORMAL") : + (s->scene.dpLocale == "zh-TW"? "節能" : s->scene.dpLocale == "zh-CN"? "节能" : "ECO"), + NULL); + + nvgFontFaceId(s->vg, s->font_sans_regular); + nvgFillColor(s->vg, COLOR_WHITE_ALPHA(200)); + nvgFontSize(s->vg, 37.5); + nvgTextAlign(s->vg, NVG_ALIGN_CENTER); + + nvgText(s->vg, ap_btn_x + ap_btn_w / 2, ap_btn_y + ap_btn_h - 10, + (s->scene.dpLocale == "zh-TW"? "加速" : s->scene.dpLocale == "zh-CN"? "加速" : "ACCEL"), + NULL); +} + +void ui_draw_infobar(UIState *s) { + const int x = s->scene.viz_rect.x; + const int y = s->scene.viz_rect.bottom() - info_bar_h; + const int w = s->scene.viz_rect.w; + const int text_x = w / 2 + x; + const int text_y = y + 55; + + char infobar[100]; + // create time string + char date_time[20]; + time_t rawtime = time(NULL); + struct tm timeinfo; + localtime_r(&rawtime, &timeinfo); + strftime(date_time, sizeof(date_time),"%D %T", &timeinfo); + + // Create temp string + char temp[6]; + snprintf(temp, sizeof(temp), "%02d°C", (int)s->scene.thermal.getAmbient()); + + // create battery percentage string + char battery[5]; + snprintf(battery, sizeof(battery), "%02d%%", s->scene.thermal.getBatteryPercent()); + + if (!s->scene.dpUiDev) { + char rel_steer[9]; + snprintf(rel_steer, sizeof(rel_steer), "%s%05.1f°", s->scene.controls_state.getAngleSteers() < 0? "-" : "+", fabs(s->scene.angleSteers)); + + char des_steer[9]; + if (s->scene.controls_state.getEnabled()) { + snprintf(des_steer, sizeof(des_steer), "%s%05.1f°", s->scene.controls_state.getAngleSteersDes() < 0? "-" : "+", fabs(s->scene.angleSteersDes)); + } else { + snprintf(des_steer, sizeof(des_steer), "%7s", "-"); + } + + char lead_dist[8]; + if (s->scene.lead_data[0].getStatus()) { + snprintf(lead_dist, sizeof(lead_dist), "%06.2fm", s->scene.lead_data[0].getDRel()); + } else { + snprintf(lead_dist, sizeof(lead_dist), "%7s", "-"); + } + + snprintf( + infobar, + sizeof(infobar), + "%s /TMP: %s /BAT: %s /REL: %s /DES: %s /DIS: %s", + date_time, + temp, + battery, + rel_steer, + des_steer, + lead_dist + ); + } else { + snprintf( + infobar, + sizeof(infobar), + "%s /TMP: %s /BAT: %s", + date_time, + temp, + battery + ); + } + + nvgBeginPath(s->vg); + nvgRect(s->vg, x, y, w, info_bar_h); + nvgFillColor(s->vg, (s->scene.brakeLights? COLOR_RED_ALPHA(200) : COLOR_BLACK_ALPHA(s->scene.dpFullScreenApp? 150 : 100))); + nvgFill(s->vg); + + nvgFontSize(s->vg, !s->scene.uilayout_sidebarcollapsed? 35:42); + nvgFontFaceId(s->vg, s->font_courbd); + nvgFillColor(s->vg, COLOR_WHITE_ALPHA(200)); + nvgTextAlign(s->vg, NVG_ALIGN_CENTER); + nvgText(s->vg, text_x, text_y, infobar, NULL); +} + +void ui_draw_blindspots(UIState *s, bool hasInfobar) { + const int width = 100; + const int infobar_h = hasInfobar? info_bar_h : 0; + const int y = s->scene.viz_rect.bottom() - infobar_h - 100; + + if (s->scene.leftBlindspot) { + const int left_x = s->scene.viz_rect.x; + nvgBeginPath(s->vg); + nvgMoveTo(s->vg, left_x, y); + nvgLineTo(s->vg, left_x, y+width); + nvgLineTo(s->vg, left_x+width, y+width); + nvgClosePath(s->vg); + nvgFillColor(s->vg, COLOR_RED_ALPHA(200)); + nvgFill(s->vg); + } + if (s->scene.rightBlindspot) { + const int right_x = s->scene.viz_rect.right(); + nvgBeginPath(s->vg); + nvgMoveTo(s->vg, right_x, y); + nvgLineTo(s->vg, right_x, y+width); + nvgLineTo(s->vg, right_x-100, y+width); + nvgClosePath(s->vg); + nvgFillColor(s->vg, COLOR_RED_ALPHA(200)); + nvgFill(s->vg); + } +} + +//BB START: functions added for the display of various items +int bb_ui_draw_measure(UIState *s, const char* bb_value, const char* bb_uom, const char* bb_label, + int bb_x, int bb_y, int bb_uom_dx, + NVGcolor bb_valueColor, NVGcolor bb_labelColor, NVGcolor bb_uomColor, + int bb_valueFontSize, int bb_labelFontSize, int bb_uomFontSize ) { + + nvgTextAlign(s->vg, NVG_ALIGN_CENTER | NVG_ALIGN_BASELINE); + int dx = 0; + if (strlen(bb_uom) > 0) { + dx = (int)(bb_uomFontSize*2.5/2); + } + //print value + nvgFontFaceId(s->vg, s->font_sans_bold); + nvgFontSize(s->vg, bb_valueFontSize*2.5); + nvgFillColor(s->vg, bb_valueColor); + nvgText(s->vg, bb_x-dx/2, bb_y+ (int)(bb_valueFontSize*2.5)+5, bb_value, NULL); + //print label + nvgFontFaceId(s->vg, s->font_sans_regular); + nvgFontSize(s->vg, bb_labelFontSize*2.5); + nvgFillColor(s->vg, bb_labelColor); + nvgText(s->vg, bb_x, bb_y + (int)(bb_valueFontSize*2.5)+5 + (int)(bb_labelFontSize*2.5)+5, bb_label, NULL); + //print uom + if (strlen(bb_uom) > 0) { + nvgSave(s->vg); + int rx =bb_x + bb_uom_dx + bb_valueFontSize -3; + int ry = bb_y + (int)(bb_valueFontSize*2.5/2)+25; + nvgTranslate(s->vg,rx,ry); + nvgRotate(s->vg, -1.5708); //-90deg in radians + nvgFontFaceId(s->vg, s->font_sans_regular); + nvgFontSize(s->vg, (int)(bb_uomFontSize*2.5)); + nvgFillColor(s->vg, bb_uomColor); + nvgText(s->vg, 0, 0, bb_uom, NULL); + nvgRestore(s->vg); + } + return (int)((bb_valueFontSize + bb_labelFontSize)*2.5) + 5; +} + +void bb_ui_draw_measures_left(UIState *s, int bb_x, int bb_y, int bb_w ) { + int bb_rx = bb_x + (int)(bb_w/2); + int bb_ry = bb_y; + int bb_h = 5; + NVGcolor lab_color = COLOR_WHITE_ALPHA(200); + NVGcolor uom_color = COLOR_WHITE_ALPHA(200); + int value_fontSize=30; + int label_fontSize=15; + int uom_fontSize = 15; + int bb_uom_dx = (int)(bb_w /2 - uom_fontSize*2.5) ; + float d_rel = s->scene.lead_data[0].getDRel(); + float v_rel = s->scene.lead_data[0].getVRel(); + + //add visual radar relative distance + if (true) { + char val_str[16]; + char uom_str[6]; + NVGcolor val_color = COLOR_WHITE_ALPHA(200); + if (s->scene.lead_data[0].getStatus()) { + //show RED if less than 5 meters + //show orange if less than 15 meters + if((int)(d_rel) < 15) { + val_color = nvgRGBA(255, 188, 3, 200); + } + if((int)(d_rel) < 5) { + val_color = nvgRGBA(255, 0, 0, 200); + } + // lead car relative distance is always in meters + snprintf(val_str, sizeof(val_str), "%d", (int)d_rel); + } else { + snprintf(val_str, sizeof(val_str), "-"); + } + snprintf(uom_str, sizeof(uom_str), "m "); + bb_h +=bb_ui_draw_measure(s, val_str, uom_str, + (s->scene.dpLocale == "zh-TW"? "真實車距" : s->scene.dpLocale == "zh-CN"? "真实车距" : "REL DIST"), + bb_rx, bb_ry, bb_uom_dx, + val_color, lab_color, uom_color, + value_fontSize, label_fontSize, uom_fontSize ); + bb_ry = bb_y + bb_h; + } + + //add visual radar relative speed + if (true) { + char val_str[16]; + char uom_str[6]; + NVGcolor val_color = COLOR_WHITE_ALPHA(200); + if (s->scene.lead_data[0].getStatus()) { + //show Orange if negative speed (approaching) + //show Orange if negative speed faster than 5mph (approaching fast) + if((int)(v_rel) < 0) { + val_color = nvgRGBA(255, 188, 3, 200); + } + if((int)(v_rel) < -5) { + val_color = nvgRGBA(255, 0, 0, 200); + } + // lead car relative speed is always in meters + if (s->is_metric) { + snprintf(val_str, sizeof(val_str), "%d", (int)(v_rel * 3.6 + 0.5)); + } else { + snprintf(val_str, sizeof(val_str), "%d", (int)(v_rel * 2.2374144 + 0.5)); + } + } else { + snprintf(val_str, sizeof(val_str), "-"); + } + if (s->is_metric) { + snprintf(uom_str, sizeof(uom_str), "km/h");; + } else { + snprintf(uom_str, sizeof(uom_str), "mph"); + } + bb_h +=bb_ui_draw_measure(s, val_str, uom_str, + (s->scene.dpLocale == "zh-TW"? "相對速度" : s->scene.dpLocale == "zh-CN"? "相对速度" : "REAL SPEED"), + bb_rx, bb_ry, bb_uom_dx, + val_color, lab_color, uom_color, + value_fontSize, label_fontSize, uom_fontSize ); + bb_ry = bb_y + bb_h; + } + + //finally draw the frame + bb_h += 20; + nvgBeginPath(s->vg); + nvgRoundedRect(s->vg, bb_x, bb_y, bb_w, bb_h, 20); + nvgStrokeColor(s->vg, COLOR_WHITE_ALPHA(80)); + nvgStrokeWidth(s->vg, 6); + nvgStroke(s->vg); +} + +void bb_ui_draw_measures_right(UIState *s, int bb_x, int bb_y, int bb_w ) { + int bb_rx = bb_x + (int)(bb_w/2); + int bb_ry = bb_y; + int bb_h = 5; + NVGcolor lab_color = COLOR_WHITE_ALPHA(200); + NVGcolor uom_color = COLOR_WHITE_ALPHA(200); + int value_fontSize=30; + int label_fontSize=15; + int uom_fontSize = 15; + int bb_uom_dx = (int)(bb_w /2 - uom_fontSize*2.5) ; + + //add steering angle + if (true) { + char val_str[16]; + char uom_str[6]; + NVGcolor val_color = COLOR_WHITE_ALPHA(200); + //show Orange if more than 6 degrees + //show red if more than 12 degrees + if(((int)(s->scene.angleSteers) < -6) || ((int)(s->scene.angleSteers) > 6)) { + val_color = nvgRGBA(255, 188, 3, 200); + } + if(((int)(s->scene.angleSteers) < -12) || ((int)(s->scene.angleSteers) > 12)) { + val_color = nvgRGBA(255, 0, 0, 200); + } + // steering is in degrees + snprintf(val_str, sizeof(val_str), "%.1f°",(s->scene.angleSteers)); + + snprintf(uom_str, sizeof(uom_str), ""); + bb_h +=bb_ui_draw_measure(s, val_str, uom_str, + (s->scene.dpLocale == "zh-TW"? "實際轉角" : s->scene.dpLocale == "zh-CN"? "实际转角" : "REAL STEER"), + bb_rx, bb_ry, bb_uom_dx, + val_color, lab_color, uom_color, + value_fontSize, label_fontSize, uom_fontSize ); + bb_ry = bb_y + bb_h; + } + + //add desired steering angle + if (true) { + char val_str[16]; + char uom_str[6]; + NVGcolor val_color = COLOR_WHITE_ALPHA(200); + //show Orange if more than 6 degrees + //show red if more than 12 degrees + if(((int)(s->scene.angleSteersDes) < -6) || ((int)(s->scene.angleSteersDes) > 6)) { + val_color = nvgRGBA(255, 188, 3, 200); + } + if(((int)(s->scene.angleSteersDes) < -12) || ((int)(s->scene.angleSteersDes) > 12)) { + val_color = nvgRGBA(255, 0, 0, 200); + } + // steering is in degrees + snprintf(val_str, sizeof(val_str), "%.1f°",(s->scene.angleSteersDes)); + + snprintf(uom_str, sizeof(uom_str), ""); + bb_h +=bb_ui_draw_measure(s, val_str, uom_str, + (s->scene.dpLocale == "zh-TW"? "預測轉角" : s->scene.dpLocale == "zh-CN"? "预测转角" : "DESIR STEER"), + bb_rx, bb_ry, bb_uom_dx, + val_color, lab_color, uom_color, + value_fontSize, label_fontSize, uom_fontSize ); + bb_ry = bb_y + bb_h; + } + + //finally draw the frame + bb_h += 20; + nvgBeginPath(s->vg); + nvgRoundedRect(s->vg, bb_x, bb_y, bb_w, bb_h, 20); + nvgStrokeColor(s->vg, COLOR_WHITE_ALPHA(80)); + nvgStrokeWidth(s->vg, 6); + nvgStroke(s->vg); +} + +void ui_draw_bbui(UIState *s) { + const int bb_dml_w = 184; + const int bb_dml_x = s->scene.viz_rect.x + (bdr_s*2); + const int bb_dml_y = s->scene.viz_rect.y + (bdr_s*1.5) + 220; + const int bb_dmr_w = 184; + const int bb_dmr_x =s->scene.viz_rect.x + s->scene.viz_rect.w - bb_dmr_w - (bdr_s * 2); + const int bb_dmr_y = s->scene.viz_rect.y + (bdr_s*1.5) + 220; + + bb_ui_draw_measures_right(s, bb_dml_x, bb_dml_y, bb_dml_w); + bb_ui_draw_measures_left(s, bb_dmr_x, bb_dmr_y, bb_dmr_w); +} \ No newline at end of file diff --git a/selfdrive/ui/paint_dp.hpp b/selfdrive/ui/paint_dp.hpp new file mode 100644 index 00000000000000..6dd30760777414 --- /dev/null +++ b/selfdrive/ui/paint_dp.hpp @@ -0,0 +1,8 @@ +#pragma once +#include "ui.hpp" + +void ui_draw_df_button(UIState *s); +void ui_draw_ap_button(UIState *s); +void ui_draw_infobar(UIState *s); +void ui_draw_blindspots(UIState *s, bool hasInfobar); +void ui_draw_bbui(UIState *s); \ No newline at end of file diff --git a/selfdrive/ui/sidebar.cc b/selfdrive/ui/sidebar.cc index 679d347cbad18a..ac0799399f50ca 100644 --- a/selfdrive/ui/sidebar.cc +++ b/selfdrive/ui/sidebar.cc @@ -19,6 +19,26 @@ static void ui_draw_sidebar_settings_button(UIState *s) { static void ui_draw_sidebar_home_button(UIState *s) { const float alpha = s->active_app == cereal::UiLayoutState::App::HOME ? 1.0f : 0.65f;; ui_draw_image(s->vg, home_btn.x, home_btn.y, home_btn.w, home_btn.h, s->img_button_home, alpha); + if (s->scene.dpIsUpdating) { + nvgBeginPath(s->vg); + nvgCircle(s->vg, home_btn.x + home_btn.w/2, home_btn.y + home_btn.h/2, 90); + nvgFillColor(s->vg, nvgRGBA(255, 255, 255, s->scene.dp_alert_rate)); + nvgFill(s->vg); + + nvgFillColor(s->vg, nvgRGBA(0, 0, 0, s->scene.dp_alert_rate)); + nvgFontSize(s->vg, s->scene.dpLocale == "zh-TW"? 60 : s->scene.dpLocale == "zh-CN"? 60 : 46); + nvgFontFaceId(s->vg, s->font_sans_bold); + nvgTextAlign(s->vg, NVG_ALIGN_CENTER | NVG_ALIGN_MIDDLE); + nvgTextBox(s->vg, home_btn.x, home_btn.y + home_btn.h/2, home_btn.w, + s->scene.dpLocale == "zh-TW"? "更新中" : s->scene.dpLocale == "zh-CN"? "更新中" : "UPDATING", + NULL); + + s->scene.dp_alert_rate += 5*s->scene.dp_alert_type; + + if (s->scene.dp_alert_rate <= 0 || s->scene.dp_alert_rate >= 255) { + s->scene.dp_alert_type *= -1; + } + } } static void ui_draw_sidebar_network_strength(UIState *s) { @@ -36,20 +56,44 @@ static void ui_draw_sidebar_network_strength(UIState *s) { ui_draw_image(s->vg, network_img_x, network_img_y, network_img_w, network_img_h, s->img_network[img_idx], 1.0f); } -static void ui_draw_sidebar_battery_icon(UIState *s) { - const int battery_img_h = 36; - const int battery_img_w = 76; - const int battery_img_x = 160; - const int battery_img_y = 255; - - int battery_img = s->scene.thermal.getBatteryStatus() == "Charging" ? s->img_battery_charging : s->img_battery; - - ui_draw_rect(s->vg, battery_img_x + 6, battery_img_y + 5, - ((battery_img_w - 19) * (s->scene.thermal.getBatteryPercent() * 0.01)), battery_img_h - 11, COLOR_WHITE); +static void ui_draw_sidebar_ip_addr(UIState *s) { + const int network_ip_w = 176; + const int network_ip_x = 54; + const int network_ip_y = 255; + nvgFillColor(s->vg, COLOR_WHITE); + nvgFontSize(s->vg, 34); + nvgFontFaceId(s->vg, s->font_sans_regular); + nvgTextAlign(s->vg, NVG_ALIGN_CENTER | NVG_ALIGN_MIDDLE); + nvgTextBox(s->vg, network_ip_x, network_ip_y, network_ip_w, s->scene.dpIpAddr.c_str(), NULL); +} - ui_draw_image(s->vg, battery_img_x, battery_img_y, battery_img_w, battery_img_h, battery_img, 1.0f); +static void ui_draw_sidebar_battery_text(UIState *s) { + const int battery_txt_w = 96; + const int battery_txt_x = 160; + const int battery_txt_y = 305; + char battery_str[7]; + snprintf(battery_str, sizeof(battery_str), "%d%%%s", s->scene.thermal.getBatteryPercent(), s->scene.thermal.getBatteryStatus() == "Charging" ? "+" : "-"); + nvgFillColor(s->vg, COLOR_WHITE); + nvgFontSize(s->vg, 44); + nvgFontFaceId(s->vg, s->font_sans_regular); + nvgTextAlign(s->vg, NVG_ALIGN_CENTER | NVG_ALIGN_MIDDLE); + nvgTextBox(s->vg, battery_txt_x, battery_txt_y, battery_txt_w, battery_str, NULL); } +//static void ui_draw_sidebar_battery_icon(UIState *s) { +// const int battery_img_h = 36; +// const int battery_img_w = 76; +// const int battery_img_x = 160; +// const int battery_img_y = 255; +// +// int battery_img = s->scene.thermal.getBatteryStatus() == "Charging" ? s->img_battery_charging : s->img_battery; +// +// ui_draw_rect(s->vg, battery_img_x + 6, battery_img_y + 5, +// ((battery_img_w - 19) * (s->scene.thermal.getBatteryPercent() * 0.01)), battery_img_h - 11, COLOR_WHITE); +// +// ui_draw_image(s->vg, battery_img_x, battery_img_y, battery_img_w, battery_img_h, battery_img, 1.0f); +//} + static void ui_draw_sidebar_network_type(UIState *s) { static std::map network_type_map = { {cereal::ThermalData::NetworkType::NONE, "--"}, @@ -59,7 +103,7 @@ static void ui_draw_sidebar_network_type(UIState *s) { {cereal::ThermalData::NetworkType::CELL4_G, "4G"}, {cereal::ThermalData::NetworkType::CELL5_G, "5G"}}; const int network_x = 50; - const int network_y = 273; + const int network_y = 303; const int network_w = 100; const char *network_type = network_type_map[s->scene.thermal.getNetworkType()]; nvgFillColor(s->vg, COLOR_WHITE); @@ -101,13 +145,13 @@ static void ui_draw_sidebar_metric(UIState *s, const char* label_str, const char nvgTextBox(s->vg, metric_x + 50, metric_y + 50, metric_w - 60, value_str, NULL); nvgFillColor(s->vg, COLOR_WHITE); - nvgFontSize(s->vg, 48); + nvgFontSize(s->vg, 46); nvgFontFaceId(s->vg, s->font_sans_regular); nvgTextAlign(s->vg, NVG_ALIGN_LEFT | NVG_ALIGN_MIDDLE); nvgTextBox(s->vg, metric_x + 50, metric_y + 50 + 66, metric_w - 60, label_str, NULL); } else { nvgFillColor(s->vg, COLOR_WHITE); - nvgFontSize(s->vg, 48); + nvgFontSize(s->vg, 46); nvgFontFaceId(s->vg, s->font_sans_bold); nvgTextAlign(s->vg, NVG_ALIGN_CENTER | NVG_ALIGN_MIDDLE); nvgTextBox(s->vg, metric_x + 35, metric_y + (strchr(message_str, '\n') ? 40 : 50), metric_w - 50, message_str, NULL); @@ -121,37 +165,41 @@ static void ui_draw_sidebar_temp_metric(UIState *s) { {cereal::ThermalData::ThermalStatus::RED, 2}, {cereal::ThermalData::ThermalStatus::DANGER, 3}}; std::string temp_val = std::to_string((int)s->scene.thermal.getAmbient()) + "°C"; - ui_draw_sidebar_metric(s, "TEMP", temp_val.c_str(), temp_severity_map[s->scene.thermal.getThermalStatus()], 0, NULL); + std::string temp_label = s->scene.dpLocale == "zh-TW"? "溫度" : s->scene.dpLocale == "zh-CN"? "温度" : "TEMP"; + ui_draw_sidebar_metric(s, temp_label.c_str(), temp_val.c_str(), temp_severity_map[s->scene.thermal.getThermalStatus()], 0, NULL); } static void ui_draw_sidebar_panda_metric(UIState *s) { const int panda_y_offset = 32 + 148; int panda_severity = 0; - std::string panda_message = "VEHICLE\nONLINE"; + std::string car = s->scene.dpLocale == "zh-TW"? "車輛" : s->scene.dpLocale == "zh-CN"? "车辆" : "VEHICLE"; + std::string panda_message = car + (s->scene.dpLocale == "zh-TW"? "\n已連線" : s->scene.dpLocale == "zh-CN"? "\n在线" : "\nONLINE"); if (s->scene.hwType == cereal::HealthData::HwType::UNKNOWN) { panda_severity = 2; - panda_message = "NO\nVEHICLE"; + panda_message = car + (s->scene.dpLocale == "zh-TW"? "\n已離線" : s->scene.dpLocale == "zh-CN"? "\n离线" : "\nOFFLINE"); } else if (s->started) { if (s->scene.satelliteCount < 6) { panda_severity = 1; - panda_message = "VEHICLE\nNO GPS"; + panda_message = car + "\nGPS: " + std::to_string(s->scene.satelliteCount); } else { panda_severity = 0; - panda_message = "VEHICLE\nGOOD GPS"; + panda_message = car + "\nGPS: " + std::to_string(s->scene.satelliteCount); } } ui_draw_sidebar_metric(s, NULL, NULL, panda_severity, panda_y_offset, panda_message.c_str()); } static void ui_draw_sidebar_connectivity(UIState *s) { - static std::map> connectivity_map = { - {NET_ERROR, {"CONNECT\nERROR", 2}}, - {NET_CONNECTED, {"CONNECT\nONLINE", 0}}, - {NET_DISCONNECTED, {"CONNECT\nOFFLINE", 1}}, - }; - auto net_params = connectivity_map[s->scene.athenaStatus]; - ui_draw_sidebar_metric(s, NULL, NULL, net_params.second, 180+158, net_params.first); + if (s->scene.dpAthenad) { + static std::map> connectivity_map = { + {NET_ERROR, {"CONNECT\nERROR", 2}}, + {NET_CONNECTED, {"CONNECT\nONLINE", 0}}, + {NET_DISCONNECTED, {"CONNECT\nOFFLINE", 1}}, + }; + auto net_params = connectivity_map[s->scene.athenaStatus]; + ui_draw_sidebar_metric(s, NULL, NULL, net_params.second, 180+158, net_params.first); + } } void ui_draw_sidebar(UIState *s) { @@ -162,7 +210,9 @@ void ui_draw_sidebar(UIState *s) { ui_draw_sidebar_settings_button(s); ui_draw_sidebar_home_button(s); ui_draw_sidebar_network_strength(s); - ui_draw_sidebar_battery_icon(s); +// ui_draw_sidebar_battery_icon(s); + ui_draw_sidebar_ip_addr(s); + ui_draw_sidebar_battery_text(s); ui_draw_sidebar_network_type(s); ui_draw_sidebar_temp_metric(s); ui_draw_sidebar_panda_metric(s); diff --git a/selfdrive/ui/ui.cc b/selfdrive/ui/ui.cc index c9f321b0930162..2fb22f64f11980 100644 --- a/selfdrive/ui/ui.cc +++ b/selfdrive/ui/ui.cc @@ -26,7 +26,8 @@ int write_param_float(float param, const char* param_name, bool persistent_param void ui_init(UIState *s) { s->sm = new SubMaster({"modelV2", "controlsState", "uiLayoutState", "liveCalibration", "radarState", "thermal", - "health", "carParams", "ubloxGnss", "driverState", "dMonitoringState", "sensorEvents"}); + "health", "carParams", "ubloxGnss", "driverState", "dMonitoringState", "sensorEvents", + "dragonConf", "carState"}); s->started = false; s->status = STATUS_OFFROAD; @@ -118,6 +119,7 @@ void update_sockets(UIState *s) { if (s->started && sm.updated("controlsState")) { auto event = sm["controlsState"]; + auto data = event.getControlsState(); scene.controls_state = event.getControlsState(); // TODO: the alert stuff shouldn't be handled here @@ -159,6 +161,9 @@ void update_sockets(UIState *s) { } } } + // dp - steer data + scene.angleSteers = data.getAngleSteers(); + scene.angleSteersDes = data.getAngleSteersDes(); } if (sm.updated("radarState")) { auto data = sm["radarState"].getRadarState(); @@ -236,7 +241,46 @@ void update_sockets(UIState *s) { } } } - + // dp + if (sm.updated("dragonConf")) { + auto data = sm["dragonConf"].getDragonConf(); + scene.dpDashcam = data.getDpDashcam(); + scene.dpFullScreenApp = data.getDpAppWaze() || data.getDpAppHr(); + scene.dpDrivingUi = data.getDpDrivingUi(); + scene.dpUiScreenOffReversing = data.getDpUiScreenOffReversing(); + scene.dpUiScreenOffDriving = data.getDpUiScreenOffDriving(); + scene.dpUiSpeed = data.getDpUiSpeed(); + scene.dpUiEvent = data.getDpUiEvent(); + scene.dpUiMaxSpeed = data.getDpUiMaxSpeed(); + scene.dpUiFace = data.getDpUiFace(); + scene.dpUiLane = data.getDpUiLane(); + scene.dpUiPath = data.getDpUiPath(); + scene.dpUiLead = data.getDpUiLead(); + scene.dpUiDev = data.getDpUiDev(); + scene.dpUiDevMini = data.getDpUiDevMini(); + scene.dpUiBlinker = data.getDpUiBlinker(); + scene.dpUiBrightness = data.getDpUiBrightness(); + scene.dpUiVolumeBoost = data.getDpUiVolumeBoost(); + scene.dpDynamicFollow = data.getDpDynamicFollow(); + scene.dpAccelProfile = data.getDpAccelProfile(); + + scene.dpIpAddr = data.getDpIpAddr(); + scene.dpLocale = data.getDpLocale(); + scene.dpIsUpdating = data.getDpIsUpdating(); + scene.dpAthenad = data.getDpAthenad(); + } + if (sm.updated("carState")) { + auto data = sm["carState"].getCarState(); + if(scene.leftBlinker!=data.getLeftBlinker() || scene.rightBlinker!=data.getRightBlinker()) { + scene.blinker_blinkingrate = 100; + } + scene.leftBlinker = data.getLeftBlinker(); + scene.rightBlinker = data.getRightBlinker(); + scene.brakeLights = data.getBrakeLights(); + scene.isReversing = data.getGearShifter() == cereal::CarState::GearShifter::REVERSE; + scene.leftBlindspot = data.getLeftBlindspot(); + scene.rightBlindspot = data.getRightBlindspot(); + } s->started = scene.thermal.getStarted() || scene.frontview; } @@ -265,10 +309,12 @@ void ui_update(UIState *s) { // Handle controls timeout if (s->started && !s->scene.frontview && ((s->sm)->frame - s->started_frame) > 5*UI_FREQ) { if ((s->sm)->rcv_frame("controlsState") < s->started_frame) { - // car is started, but controlsState hasn't been seen at all - s->scene.alert_text1 = "openpilot Unavailable"; - s->scene.alert_text2 = "Waiting for controls to start"; - s->scene.alert_size = cereal::ControlsState::AlertSize::MID; + if (!s->scene.dpUiScreenOffReversing && !s->scene.dpUiScreenOffDriving) { + // car is started, but controlsState hasn't been seen at all + s->scene.alert_text1 = "openpilot Unavailable"; + s->scene.alert_text2 = "Waiting for controls to start"; + s->scene.alert_size = cereal::ControlsState::AlertSize::MID; + } } else if (((s->sm)->frame - (s->sm)->rcv_frame("controlsState")) > 5*UI_FREQ) { // car is started, but controls is lagging or died if (s->scene.alert_text2 != "Controls Unresponsive") { diff --git a/selfdrive/ui/ui.hpp b/selfdrive/ui/ui.hpp index 023bc866727b05..e790b05b9c2273 100644 --- a/selfdrive/ui/ui.hpp +++ b/selfdrive/ui/ui.hpp @@ -33,6 +33,7 @@ #define COLOR_WHITE_ALPHA(x) nvgRGBA(255, 255, 255, x) #define COLOR_YELLOW nvgRGBA(218, 202, 37, 255) #define COLOR_RED nvgRGBA(201, 34, 49, 255) +#define COLOR_RED_ALPHA(x) nvgRGBA(201, 34, 49, x) #define UI_BUF_COUNT 4 @@ -60,6 +61,18 @@ const int TRACK_POINTS_MAX_CNT = TRAJECTORY_SIZE*4; const int SET_SPEED_NA = 255; +// dp - dynamic follow btn +const int df_btn_h = 180; +const int df_btn_w = 180; +const int df_btn_x = 1650; +const int df_btn_y = 750; +// dp - accel profile btn +const int ap_btn_h = 180; +const int ap_btn_w = 180; +const int ap_btn_x = 1450; +const int ap_btn_y = 750; +const int info_bar_h = 80; + typedef enum NetStatus { NET_CONNECTED, NET_DISCONNECTED, @@ -126,6 +139,48 @@ typedef struct UIScene { float max_distance; float lane_line_probs[4]; float road_edge_stds[2]; + + // dp + bool dpDashcam; + bool dpFullScreenApp; + bool dpDrivingUi; + bool dpUiScreenOffReversing; + bool dpUiScreenOffDriving; + bool dpUiSpeed; + bool dpUiEvent; + bool dpUiMaxSpeed; + bool dpUiFace; + bool dpUiLane; + bool dpUiPath; + bool dpUiLead; + bool dpUiDev; + bool dpUiDevMini; + bool dpUiBlinker; + int dpUiBrightness; + int dpUiVolumeBoost; + std::string dpIpAddr; + // for minimal UI + float angleSteersDes; + float angleSteers; + // for black screen on reversing + bool isReversing; + // for blinker, from kegman + bool leftBlinker; + bool rightBlinker; + bool brakeLights; + int blinker_blinkingrate; + // for blind spot + bool leftBlindspot; + bool rightBlindspot; + + // for updating icon + int dp_alert_rate; + int dp_alert_type; + std::string dpLocale; + bool dpIsUpdating; + bool dpAthenad; + int dpDynamicFollow; + int dpAccelProfile; } UIScene; typedef struct { @@ -152,6 +207,7 @@ typedef struct UIState { NVGcontext *vg; // fonts and images + int font_courbd; int font_sans_regular; int font_sans_semibold; int font_sans_bold; diff --git a/selfdrive/updated.py b/selfdrive/updated.py index bf2427e3a3624b..3e0b083d15af75 100755 --- a/selfdrive/updated.py +++ b/selfdrive/updated.py @@ -112,8 +112,15 @@ def set_params(new_version: bool, failed_count: int, exception: Optional[str]) - params.put("LastUpdateException", exception) if new_version: + branch_name = run(["git", "rev-parse", "--abbrev-ref", "HEAD"], FINALIZED).rstrip() + if branch_name == "testing": + postfix = '' + elif branch_name == "devel-i18n": + postfix = '-DEV' + else: + postfix = '-REL' try: - with open(os.path.join(FINALIZED, "RELEASES.md"), "rb") as f: + with open(os.path.join(FINALIZED, f"CHANGELOGS{postfix}.md"), "rb") as f: r = f.read() r = r[:r.find(b'\n\n')] # Slice latest release notes params.put("ReleaseNotes", r + b"\n") diff --git a/selfdrive/version.py b/selfdrive/version.py index ef975f8940b98e..04e8c333222bdb 100644 --- a/selfdrive/version.py +++ b/selfdrive/version.py @@ -72,7 +72,7 @@ def get_git_remote(default: Optional[str] = None) -> Optional[str]: # Log dirty files if dirty and comma_remote: try: - dirty_files = run_cmd(["git", "diff-index", branch, "--"]) + dirty_files = ""#run_cmd(["git", "diff-index", branch, "--"]) cloudlog.event("dirty comma branch", version=version, dirty=dirty, origin=origin, branch=branch, dirty_files=dirty_files, commit=get_git_commit(), origin_commit=get_git_commit(branch)) except subprocess.CalledProcessError: