mirror of
https://github.com/MoreTore/openpilot.git
synced 2026-08-03 08:41:47 +08:00
78bf4f5867
* Replace ifdefs with hardware abstraction layer (#20801)
* add type to class hadwareXXX
* replace ifdefs with hardware layer
* continue
* continue
* new function get_driver_view_transform
* full path to hw.h
* fix build error setup.cc
* apply review
* fix typo
* fix deprecated error:replace deprecated fromPath with new
* fix build error
* Fixes after ifdef clenaup (#20842)
* inheritance doesnt work with static
* fix debayer
* small cleanup
* Update selfdrive/camerad/cameras/camera_common.cc
* Update selfdrive/ui/qt/offroad/settings.cc
* Update selfdrive/common/modeldata.h
* flip conditions
* fix comment
Co-authored-by: Dean Lee <deanlee3@gmail.com>
old-commit-hash: ab319d4f54
27 lines
602 B
C++
27 lines
602 B
C++
#pragma once
|
|
|
|
#include <cstdlib>
|
|
#include <fstream>
|
|
|
|
|
|
// no-op base hw class
|
|
class HardwareNone {
|
|
public:
|
|
static constexpr float MAX_VOLUME = 0;
|
|
static constexpr float MIN_VOLUME = 0;
|
|
|
|
static std::string get_os_version() { return ""; }
|
|
|
|
static void reboot() {}
|
|
static void poweroff() {}
|
|
static void set_brightness(int percent) {}
|
|
static void set_display_power(bool on) {}
|
|
|
|
static bool get_ssh_enabled() { return false; }
|
|
static void set_ssh_enabled(bool enabled) {}
|
|
|
|
static bool PC() { return false; }
|
|
static bool EON() { return false; }
|
|
static bool TICI() { return false; }
|
|
};
|