wip
This commit is contained in:
29
README.md
29
README.md
@@ -1,19 +1,32 @@
|
||||
This is oscarpilot. It is a mod of frogpilot.
|
||||
|
||||
Install via: smiskol.com/fork/brianhansonxyz/oscarpilot/master or bit.ly/oscarpilot
|
||||
This is for private use by Brian Hanson. If you come across this you are not intended to use it. Unathorized use of this software
|
||||
is at your own risk.
|
||||
|
||||
- increased driver monitor timeouts to 30 sec warn / 60 second fatal
|
||||
- changed some default settings, notably farmville model default
|
||||
Released under the MIT license. Some parts of the software are released under other licenses as specified.
|
||||
|
||||
Any user of this software shall indemnify and hold harmless Comma.ai, Inc, all developers of openpilot or its forks, and its directors, officers, employees, agents, stockholders, affiliates, subcontractors and customers from and against all allegations, claims, actions, suits, demands, damages, liabilities, obligations, losses, settlements, judgments, costs and expenses (including without limitation attorneys’ fees and costs) which arise out of, relate to or result from any use of this software by user.
|
||||
|
||||
THIS IS ALPHA QUALITY SOFTWARE FOR RESEARCH PURPOSES ONLY. THIS IS NOT A PRODUCT. YOU ARE RESPONSIBLE FOR COMPLYING WITH LOCAL LAWS AND REGULATIONS. NO WARRANTY EXPRESSED OR IMPLIED.
|
||||
|
||||
Changes from frogpilot 2024-01-15:
|
||||
|
||||
- changed some default settings, notably defaults: farmville model, disabled turn intentions
|
||||
- disabled lane change assist
|
||||
- disabled activation / deactivation sounds in custom sound theme
|
||||
- small edits to theme
|
||||
|
||||
This is for private use by Brian Hanson. If you come across this you are not intended to use it. Unathorized use of this software
|
||||
is at your own risk. To the greatest extent possible, by using this software, you agree to free Brian Hanson, frogpilot, and openpilot
|
||||
of any liability by your unauthorized choice to use this software, and you use at your own risk.
|
||||
- increased driver monitor timeouts to 10 sec warn / 60 second terminate.
|
||||
- Justification:
|
||||
- Many people will turn off the moinitor altogether if given the choice. There has to be a good middle ground.
|
||||
- The monitor's primary responsibility should be to detect when the driver has fallen asleep perhaps, which shouldn't
|
||||
ever happen, but if it does will certainly result in the death of the driver and possibly others. This is critical
|
||||
enough that the car should make very lound angry noises after a threshold which only should happen if the driver
|
||||
has flat out stopped paying attention to driving. The shreeking and continuing to drive is preferable to a car
|
||||
stopping in traffic with its hazards off, as a result the car should keep driving for a reasonable amount of time
|
||||
that the driver would be reawoken.
|
||||
|
||||
Goals:
|
||||
- Driving personalities: 3 - no special logic, 2 - match cruise control on speed change, 3 - cruise + 2 mph when < 60, + 7 60-72, 72+ + 8.
|
||||
- Igore auto speed if not on set speed for car speed. Show an icon on display when auto speed.
|
||||
- Conditional experimental mode: override speed on stock ACC, set to experimental mode, revert to last speed when recovered. Last speed updated to car speed limit on change.
|
||||
|
||||

|
||||
|
||||
17
notes
17
notes
@@ -1 +1,18 @@
|
||||
hyundai/interface ENABLE_BUTTONS = (Buttons.RES_ACCEL, Buttons.SET_DECEL, Buttons.CANCEL)
|
||||
|
||||
Goals:
|
||||
1 - get current dash speed via calculate_speed_limit_canfd
|
||||
2 - issue set decel button via LFA button (proof of concept)
|
||||
3 - chirp when speed limit changes
|
||||
4 - Use LFA button to set speed of cruise to desired speed - 0-36 speed limit +3, 36-59 + 5, >= 60 +7
|
||||
5 - On experimental mode engage, adjust cruise speed to experimental model speed
|
||||
Wishlist:
|
||||
- When car reports seeing lanes, turn lane keep over to car, resume when car can't see lanes or turn signal is activated
|
||||
- Get hyundai speed limit reader merged into frogpilot
|
||||
- Get stock experimental mode controller merged into frogpilot
|
||||
OPKR features:
|
||||
- Auto Resume at Stop
|
||||
- Button Spam CC
|
||||
- Accelerated Departure by Cruise Gap: Cruise gap automatically changed to step 1 for faster departure, sets back to orignal gap selection after few second.
|
||||
|
||||
ret.cruiseState.standstill
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 108 KiB After Width: | Height: | Size: 12 KiB |
@@ -176,6 +176,16 @@ class CarController:
|
||||
|
||||
def create_button_messages(self, CC: car.CarControl, CS: car.CarState, use_clu11: bool):
|
||||
can_sends = []
|
||||
|
||||
if CS.custom_speed_down:
|
||||
CS.custom_speed_down = False
|
||||
if self.CP.openpilotLongitudinalControl:
|
||||
CC.cruiseControl.resume = True
|
||||
self.CP.openpilotLongitudinalControl = False
|
||||
else:
|
||||
CC.cruiseControl.cancel = True
|
||||
self.CP.openpilotLongitudinalControl = True
|
||||
|
||||
if use_clu11:
|
||||
if CC.cruiseControl.cancel:
|
||||
can_sends.append(hyundaican.create_clu11(self.packer, self.frame, CS.clu11, Buttons.CANCEL, self.CP.carFingerprint))
|
||||
@@ -208,9 +218,7 @@ class CarController:
|
||||
can_sends.append(hyundaicanfd.create_buttons(self.packer, self.CP, self.CAN, CS.buttons_counter+1, Buttons.RES_ACCEL))
|
||||
self.last_button_frame = self.frame
|
||||
|
||||
if CS.custom_speed_up:
|
||||
can_sends.extend([hyundaican.create_clu11(self.packer, self.frame, CS.clu11, Buttons.RES_ACCEL, self.CP.carFingerprint)] * 25)
|
||||
elif CS.custom_speed_down:
|
||||
|
||||
can_sends.extend([hyundaican.create_clu11(self.packer, self.frame, CS.clu11, Buttons.SET_DECEL, self.CP.carFingerprint)] * 25)
|
||||
|
||||
return can_sends
|
||||
|
||||
@@ -350,6 +350,7 @@ class CarState(CarStateBase):
|
||||
|
||||
return ret
|
||||
|
||||
# BBOT does not work
|
||||
def calculate_speed_limit_canfd(self, CP, cp, cp_cam):
|
||||
try:
|
||||
self._speed_limit_clu = cp.vl["CLUSTER_SPEED_LIMIT"]["SPEED_LIMIT_1"]
|
||||
@@ -456,6 +457,9 @@ class CarState(CarStateBase):
|
||||
("BLINDSPOTS_REAR_CORNERS", 20),
|
||||
]
|
||||
|
||||
# if CP.nav_msg:
|
||||
messages.append(("CLUSTER_SPEED_LIMIT", 10))
|
||||
|
||||
if not (CP.flags & HyundaiFlags.CANFD_CAMERA_SCC.value) and not CP.openpilotLongitudinalControl:
|
||||
messages += [
|
||||
("SCC_CONTROL", 50),
|
||||
@@ -474,7 +478,6 @@ class CarState(CarStateBase):
|
||||
("SCC_CONTROL", 50),
|
||||
]
|
||||
|
||||
# if CP.nav_msg:
|
||||
messages.append(("CLUSTER_SPEED_LIMIT", 10))
|
||||
|
||||
|
||||
return CANParser(DBC[CP.carFingerprint]["pt"], messages, CanBus(CP).CAM)
|
||||
|
||||
@@ -88,7 +88,7 @@ Spinner::Spinner(QWidget *parent) : QWidget(parent) {
|
||||
}
|
||||
QProgressBar::chunk {
|
||||
border-radius: 10px;
|
||||
background-color: rgba(23, 134, 68, 255);
|
||||
background-color: rgba(179, 0, 0, 255);
|
||||
}
|
||||
)");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user