selfdrive.car.tesla package

Submodules

selfdrive.car.tesla.carcontroller module

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

Bases: CarControllerBase

update(CC, CS, now_nanos)[source]

selfdrive.car.tesla.carstate module

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

Bases: CarStateBase

static get_cam_can_parser(CP)[source]
static get_can_parser(CP)[source]
update(cp, cp_cam)[source]

selfdrive.car.tesla.fingerprints module

selfdrive.car.tesla.interface module

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

Bases: CarInterfaceBase

selfdrive.car.tesla.radar_interface module

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

Bases: RadarInterfaceBase

update(can_strings)[source]

selfdrive.car.tesla.teslacan module

class selfdrive.car.tesla.teslacan.TeslaCAN(packer, pt_packer)[source]

Bases: object

static checksum(msg_id, dat)[source]
create_action_request(msg_stw_actn_req, cancel, bus, counter)[source]
create_longitudinal_commands(acc_state, speed, min_accel, max_accel, cnt)[source]
create_steering_control(angle, enabled, counter)[source]

selfdrive.car.tesla.values module

class selfdrive.car.tesla.values.Button(event_type, can_addr, can_msg, values)

Bases: tuple

can_addr

Alias for field number 1

can_msg

Alias for field number 2

event_type

Alias for field number 0

values

Alias for field number 3

class selfdrive.car.tesla.values.CANBUS[source]

Bases: object

autopilot_chassis = 2
autopilot_powertrain = 6
chassis = 0
powertrain = 4
private = 5
radar = 1
class selfdrive.car.tesla.values.CAR(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]

Bases: Platforms

TESLA_AP1_MODELS = 'TESLA_AP1_MODELS'
TESLA_AP2_MODELS = 'TESLA_AP2_MODELS'
TESLA_MODELS_RAVEN = 'TESLA_MODELS_RAVEN'
config: PlatformConfig
class selfdrive.car.tesla.values.CarControllerParams(CP)[source]

Bases: object

ACCEL_TO_SPEED_MULTIPLIER = 3
ANGLE_RATE_LIMIT_DOWN = ([0.0, 5.0, 15.0], [10.0, 7.0, 0.8])
ANGLE_RATE_LIMIT_UP = ([0.0, 5.0, 15.0], [10.0, 1.6, 0.3])
JERK_LIMIT_MAX = 8
JERK_LIMIT_MIN = -8

Module contents