selfdrive.car.honda package

Subpackages

Submodules

selfdrive.car.honda.carcontroller module

class selfdrive.car.honda.carcontroller.CarController(dbc_name, CP, VM)[source]

Bases: CarControllerBase

update(CC, CS, now_nanos)[source]
class selfdrive.car.honda.carcontroller.HUDData(pcm_accel, v_cruise, lead_visible, lanes_visible, fcw, acc_alert, steer_required, lead_distance_bars)

Bases: tuple

acc_alert

Alias for field number 5

fcw

Alias for field number 4

lanes_visible

Alias for field number 3

lead_distance_bars

Alias for field number 7

lead_visible

Alias for field number 2

pcm_accel

Alias for field number 0

steer_required

Alias for field number 6

v_cruise

Alias for field number 1

selfdrive.car.honda.carcontroller.actuator_hysteresis(brake, braking, brake_steady, v_ego, car_fingerprint)[source]
selfdrive.car.honda.carcontroller.brake_pump_hysteresis(apply_brake, apply_brake_last, last_pump_ts, ts)[source]
selfdrive.car.honda.carcontroller.compute_gas_brake(accel, speed, fingerprint)[source]
selfdrive.car.honda.carcontroller.compute_gb_honda_bosch(accel, speed)[source]
selfdrive.car.honda.carcontroller.compute_gb_honda_nidec(accel, speed)[source]
selfdrive.car.honda.carcontroller.process_hud_alert(hud_alert)[source]
selfdrive.car.honda.carcontroller.rate_limit_steer(new_steer, last_steer)[source]

selfdrive.car.honda.carstate module

class selfdrive.car.honda.carstate.CarState(CP)[source]

Bases: CarStateBase

static get_body_can_parser(CP)[source]
static get_cam_can_parser(CP)[source]
get_can_parser(CP)[source]
update(cp, cp_cam, cp_body)[source]
selfdrive.car.honda.carstate.get_can_messages(CP, gearbox_msg)[source]

selfdrive.car.honda.fingerprints module

selfdrive.car.honda.hondacan module

class selfdrive.car.honda.hondacan.CanBus(CP=None, fingerprint=None)[source]

Bases: CanBusBase

property camera: int
property pt: int
property radar: int
selfdrive.car.honda.hondacan.create_acc_commands(packer, CAN, enabled, active, accel, gas, stopping_counter, car_fingerprint)[source]
selfdrive.car.honda.hondacan.create_bosch_supplemental_1(packer, CAN, car_fingerprint)[source]
selfdrive.car.honda.hondacan.create_brake_command(packer, CAN, apply_brake, pump_on, pcm_override, pcm_cancel_cmd, fcw, car_fingerprint, stock_brake)[source]
selfdrive.car.honda.hondacan.create_steering_control(packer, CAN, apply_steer, lkas_active, car_fingerprint, radar_disabled)[source]
selfdrive.car.honda.hondacan.create_ui_commands(packer, CAN, CP, enabled, pcm_speed, hud, is_metric, acc_hud, lkas_hud)[source]
selfdrive.car.honda.hondacan.get_cruise_speed_conversion(car_fingerprint: str, is_metric: bool) float[source]
selfdrive.car.honda.hondacan.get_lkas_cmd_bus(CAN, car_fingerprint, radar_disabled=False)[source]
selfdrive.car.honda.hondacan.spam_buttons_command(packer, CAN, button_val, car_fingerprint)[source]

selfdrive.car.honda.interface module

class selfdrive.car.honda.interface.CarInterface(CP, CarController, CarState)[source]

Bases: CarInterfaceBase

static get_pid_accel_limits(CP, current_speed, cruise_speed)[source]
static init(CP, logcan, sendcan)[source]

selfdrive.car.honda.radar_interface module

class selfdrive.car.honda.radar_interface.RadarInterface(CP)[source]

Bases: RadarInterfaceBase

update(can_strings)[source]

selfdrive.car.honda.values module

class selfdrive.car.honda.values.CAR(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]

Bases: Platforms

ACURA_ILX = 'ACURA_ILX'
ACURA_RDX = 'ACURA_RDX'
ACURA_RDX_3G = 'ACURA_RDX_3G'
HONDA_ACCORD = 'HONDA_ACCORD'
HONDA_CIVIC = 'HONDA_CIVIC'
HONDA_CIVIC_2022 = 'HONDA_CIVIC_2022'
HONDA_CIVIC_BOSCH = 'HONDA_CIVIC_BOSCH'
HONDA_CIVIC_BOSCH_DIESEL = 'HONDA_CIVIC_BOSCH_DIESEL'
HONDA_CRV = 'HONDA_CRV'
HONDA_CRV_5G = 'HONDA_CRV_5G'
HONDA_CRV_EU = 'HONDA_CRV_EU'
HONDA_CRV_HYBRID = 'HONDA_CRV_HYBRID'
HONDA_E = 'HONDA_E'
HONDA_FIT = 'HONDA_FIT'
HONDA_FREED = 'HONDA_FREED'
HONDA_HRV = 'HONDA_HRV'
HONDA_HRV_3G = 'HONDA_HRV_3G'
HONDA_INSIGHT = 'HONDA_INSIGHT'
HONDA_ODYSSEY = 'HONDA_ODYSSEY'
HONDA_ODYSSEY_CHN = 'HONDA_ODYSSEY_CHN'
HONDA_PILOT = 'HONDA_PILOT'
HONDA_RIDGELINE = 'HONDA_RIDGELINE'
config: PlatformConfig
class selfdrive.car.honda.values.CarControllerParams(CP)[source]

Bases: object

BOSCH_ACCEL_MAX = 2.0
BOSCH_ACCEL_MIN = -3.5
BOSCH_GAS_LOOKUP_BP = [-0.2, 2.0]
BOSCH_GAS_LOOKUP_V = [0, 1600]
NIDEC_ACCEL_LOOKUP_BP = [-1.0, 0.0, 0.6]
NIDEC_ACCEL_LOOKUP_V = [-4.8, 0.0, 2.0]
NIDEC_ACCEL_MAX = 1.6
NIDEC_ACCEL_MIN = -4.0
NIDEC_BRAKE_MAX = 256
NIDEC_GAS_MAX = 198
NIDEC_MAX_ACCEL_BP = [0.0, 4.0, 10.0, 20.0]
NIDEC_MAX_ACCEL_V = [0.5, 2.4, 1.4, 0.6]
class selfdrive.car.honda.values.CruiseButtons[source]

Bases: object

CANCEL = 2
DECEL_SET = 3
MAIN = 1
RES_ACCEL = 4
class selfdrive.car.honda.values.CruiseSettings[source]

Bases: object

DISTANCE = 3
LKAS = 1
class selfdrive.car.honda.values.Footnote(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]

Bases: Enum

CIVIC_DIESEL = ('2019 Honda Civic 1.6L Diesel Sedan does not have ALC below 12mph.', Column.FSR_STEERING, False, False)
class selfdrive.car.honda.values.HondaBoschPlatformConfig(car_docs: list[CarDocs], specs: CarSpecs, dbc_dict: dict[str, str], flags: int = 0, platform_str: str | None = None)[source]

Bases: PlatformConfig

init()[source]
class selfdrive.car.honda.values.HondaCarDocs(name: str, package: str = 'Honda Sensing', requirements: str | None = None, video_link: str | None = None, footnotes: list[enum.Enum] = <factory>, min_steer_speed: float | None = None, min_enable_speed: float | None = None, auto_resume: bool | None = None, car_parts: openpilot.selfdrive.car.docs_definitions.CarParts = <factory>)[source]

Bases: CarDocs

init_make(CP: <capnp.lib.capnp._StructModule object at 0x7f3810d53d10>)[source]

CarDocs subclasses can add make-specific logic for harness selection, footnotes, etc.

package: str = 'Honda Sensing'
class selfdrive.car.honda.values.HondaFlags(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]

Bases: IntFlag

BOSCH = 4
BOSCH_ALT_BRAKE = 2
BOSCH_EXT_HUD = 1
BOSCH_RADARLESS = 8
NIDEC = 16
NIDEC_ALT_PCM_ACCEL = 32
NIDEC_ALT_SCM_MESSAGES = 64
class selfdrive.car.honda.values.HondaNidecPlatformConfig(car_docs: list[CarDocs], specs: CarSpecs, dbc_dict: dict[str, str], flags: int = 0, platform_str: str | None = None)[source]

Bases: PlatformConfig

init()[source]

Module contents