You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
464 B
19 lines
464 B
import os
|
|
from typing import cast
|
|
|
|
from selfdrive.hardware.base import HardwareBase
|
|
from selfdrive.hardware.eon.hardware import Android
|
|
from selfdrive.hardware.tici.hardware import Tici
|
|
from selfdrive.hardware.pc.hardware import Pc
|
|
|
|
EON = os.path.isfile('/EON')
|
|
TICI = os.path.isfile('/TICI')
|
|
PC = not (EON or TICI)
|
|
|
|
|
|
if EON:
|
|
HARDWARE = cast(HardwareBase, Android())
|
|
elif TICI:
|
|
HARDWARE = cast(HardwareBase, Tici())
|
|
else:
|
|
HARDWARE = cast(HardwareBase, Pc())
|
|
|