mirror of
https://github.com/infiniteCable2/panda.git
synced 2026-02-18 17:23:52 +08:00
Hyundai: CAMERA_SCC works on both safety modes (#1139)
* Make camera SCC work on both safety modes * update in safety * move to common
This commit is contained in:
@@ -84,8 +84,6 @@ AddrCheckStruct hyundai_legacy_addr_checks[] = {
|
||||
};
|
||||
#define HYUNDAI_LEGACY_ADDR_CHECK_LEN (sizeof(hyundai_legacy_addr_checks) / sizeof(hyundai_legacy_addr_checks[0]))
|
||||
|
||||
const int HYUNDAI_PARAM_CAMERA_SCC = 8;
|
||||
|
||||
bool hyundai_legacy = false;
|
||||
bool hyundai_camera_scc = false;
|
||||
|
||||
|
||||
@@ -96,8 +96,8 @@ addr_checks hyundai_canfd_rx_checks = {hyundai_canfd_addr_checks, HYUNDAI_CANFD_
|
||||
uint16_t hyundai_canfd_crc_lut[256];
|
||||
|
||||
|
||||
const int HYUNDAI_PARAM_CANFD_HDA2 = 8;
|
||||
const int HYUNDAI_PARAM_CANFD_ALT_BUTTONS = 16;
|
||||
const int HYUNDAI_PARAM_CANFD_HDA2 = 16;
|
||||
const int HYUNDAI_PARAM_CANFD_ALT_BUTTONS = 32;
|
||||
bool hyundai_canfd_hda2 = false;
|
||||
bool hyundai_canfd_alt_buttons = false;
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
const int HYUNDAI_PARAM_EV_GAS = 1;
|
||||
const int HYUNDAI_PARAM_HYBRID_GAS = 2;
|
||||
const int HYUNDAI_PARAM_LONGITUDINAL = 4;
|
||||
const int HYUNDAI_PARAM_CAMERA_SCC = 8;
|
||||
|
||||
const uint8_t HYUNDAI_PREV_BUTTON_SAMPLES = 8; // roughly 160 ms
|
||||
const uint32_t HYUNDAI_STANDSTILL_THRSLD = 30; // ~1kph
|
||||
|
||||
@@ -215,8 +215,8 @@ class Panda:
|
||||
FLAG_HYUNDAI_HYBRID_GAS = 2
|
||||
FLAG_HYUNDAI_LONG = 4
|
||||
FLAG_HYUNDAI_CAMERA_SCC = 8
|
||||
FLAG_HYUNDAI_CANFD_HDA2 = 8
|
||||
FLAG_HYUNDAI_CANFD_ALT_BUTTONS = 16
|
||||
FLAG_HYUNDAI_CANFD_HDA2 = 16
|
||||
FLAG_HYUNDAI_CANFD_ALT_BUTTONS = 32
|
||||
|
||||
FLAG_TESLA_POWERTRAIN = 1
|
||||
FLAG_TESLA_LONG_CONTROL = 2
|
||||
|
||||
Reference in New Issue
Block a user