2019-09-21 12:33:13 -07:00
|
|
|
/**
|
|
|
|
* @file init_sensorss.cpp
|
|
|
|
*/
|
|
|
|
|
2019-09-21 11:33:38 -07:00
|
|
|
#include "cli_registry.h"
|
|
|
|
#include "init.h"
|
|
|
|
#include "sensor.h"
|
|
|
|
|
2020-02-03 22:54:05 -08:00
|
|
|
void initTps();
|
2019-09-21 11:33:38 -07:00
|
|
|
void initOilPressure();
|
|
|
|
|
|
|
|
void initSensorCli();
|
|
|
|
|
|
|
|
void initSensors() {
|
2020-02-03 22:54:05 -08:00
|
|
|
// TPS
|
|
|
|
initTps();
|
|
|
|
|
2019-09-21 11:33:38 -07:00
|
|
|
// aux sensors
|
|
|
|
initOilPressure();
|
|
|
|
|
|
|
|
// Init CLI functionality for sensors (mocking)
|
|
|
|
initSensorCli();
|
|
|
|
}
|
|
|
|
|
|
|
|
void initSensorCli() {
|
|
|
|
addConsoleActionIF("set_sensor_mock", Sensor::setMockValue);
|
|
|
|
addConsoleAction("reset_sensor_mocks", Sensor::resetAllMocks);
|
|
|
|
}
|