mirror of
https://github.com/sunnypilot/sunnypilot.git
synced 2026-02-19 01:53:57 +08:00
* add openpilot prefix to imports * more * more * fix docs * fix linter * bump submodules * fix patched tests * update dynamic imports * debug * Revert "debug" This reverts commit db5e13b9911cc74438bee123bc3430da6c31b24b. * fix pm test
17 lines
375 B
Python
17 lines
375 B
Python
import os
|
|
from typing import cast
|
|
|
|
from openpilot.system.hardware.base import HardwareBase
|
|
from openpilot.system.hardware.tici.hardware import Tici
|
|
from openpilot.system.hardware.pc.hardware import Pc
|
|
|
|
TICI = os.path.isfile('/TICI')
|
|
AGNOS = os.path.isfile('/AGNOS')
|
|
PC = not TICI
|
|
|
|
|
|
if TICI:
|
|
HARDWARE = cast(HardwareBase, Tici())
|
|
else:
|
|
HARDWARE = cast(HardwareBase, Pc())
|