warnings (#1462)
Co-authored-by: Matthew Kennedy <makenne@microsoft.com>
This commit is contained in:
parent
7433127549
commit
4f334c91d5
|
@ -350,7 +350,7 @@ void EtbController::setOutput(expected<percent_t> outputValue) {
|
|||
}
|
||||
}
|
||||
|
||||
void EtbController::update(efitick_t nowNt) {
|
||||
void EtbController::update(efitick_t) {
|
||||
#if EFI_TUNER_STUDIO
|
||||
// Only debug throttle #0
|
||||
if (m_myIndex == 0) {
|
||||
|
|
|
@ -275,13 +275,13 @@ char * getPinNameByAdcChannel(const char *msg, adc_channel_e hwChannel, char *bu
|
|||
if (hwChannel == EFI_ADC_NONE) {
|
||||
strcpy(buffer, "NONE");
|
||||
} else {
|
||||
strcpy((char*) buffer, portname(getAdcChannelPort(msg, hwChannel)));
|
||||
strcpy(buffer, portname(getAdcChannelPort(msg, hwChannel)));
|
||||
itoa10(&buffer[2], getAdcChannelPin(hwChannel));
|
||||
}
|
||||
#else
|
||||
strcpy(buffer, "NONE");
|
||||
#endif /* HAL_USE_ADC */
|
||||
return (char*) buffer;
|
||||
return buffer;
|
||||
}
|
||||
|
||||
static char pinNameBuffer[16];
|
||||
|
|
|
@ -371,30 +371,6 @@ static void setOperationMode(int value) {
|
|||
doPrintConfiguration();
|
||||
}
|
||||
|
||||
static char pinNameBuffer[16];
|
||||
|
||||
static void printThermistor(const char *msg, ThermistorConf *config, ThermistorMath *tm, bool useLinear) {
|
||||
adc_channel_e adcChannel = config->adcChannel;
|
||||
float voltage = getVoltageDivided("term", adcChannel PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
float r = getResistance(config, voltage);
|
||||
|
||||
float t = getTemperatureC(config, tm, useLinear);
|
||||
|
||||
thermistor_conf_s *tc = &config->config;
|
||||
|
||||
scheduleMsg(&logger, "%s volts=%.2f Celsius=%.2f sensorR=%.2f on channel %d", msg, voltage, t, r, adcChannel);
|
||||
scheduleMsg(&logger, "@%s", getPinNameByAdcChannel(msg, adcChannel, pinNameBuffer));
|
||||
scheduleMsg(&logger, "C=%.2f/R=%.2f C=%.2f/R=%.2f C=%.2f/R=%.2f",
|
||||
tc->tempC_1, tc->resistance_1,
|
||||
tc->tempC_2, tc->resistance_2,
|
||||
tc->tempC_3, tc->resistance_3);
|
||||
|
||||
// %.5f
|
||||
scheduleMsg(&logger, "bias resistor=%.2fK A=%.5f B=%.5f C=%.5f", tc->bias_resistor / 1000,
|
||||
tm->s_h_a, tm->s_h_b, tm->s_h_c);
|
||||
scheduleMsg(&logger, "==============================");
|
||||
}
|
||||
|
||||
static void printTpsSenser(const char *msg, SensorType sensor, int16_t min, int16_t max, adc_channel_e channel) {
|
||||
auto tps = Sensor::get(sensor);
|
||||
auto raw = Sensor::getRaw(sensor);
|
||||
|
@ -402,7 +378,8 @@ static void printTpsSenser(const char *msg, SensorType sensor, int16_t min, int1
|
|||
if (!tps.Valid) {
|
||||
scheduleMsg(&logger, "TPS not valid");
|
||||
}
|
||||
static char pinNameBuffer[16];
|
||||
|
||||
char pinNameBuffer[16];
|
||||
|
||||
scheduleMsg(&logger, "tps min (closed) %d/max (full) %d v=%.2f @%s", min, max,
|
||||
raw, getPinNameByAdcChannel(msg, channel, pinNameBuffer));
|
||||
|
|
|
@ -469,6 +469,11 @@ void initMc33816(Logging *sharedLogger) {
|
|||
mcRestart();
|
||||
}
|
||||
|
||||
static void mcShutdown() {
|
||||
driven.setValue(0); // ensure HV is off
|
||||
resetB.setValue(0); // turn off the chip
|
||||
}
|
||||
|
||||
static void mcRestart() {
|
||||
flag0before = false;
|
||||
flag0after = false;
|
||||
|
@ -566,8 +571,4 @@ static void mcRestart() {
|
|||
}
|
||||
}
|
||||
|
||||
static void mcShutdown() {
|
||||
driven.setValue(0); // ensure HV is off
|
||||
resetB.setValue(0); // turn off the chip
|
||||
}
|
||||
#endif /* EFI_MC33816 */
|
||||
|
|
|
@ -27,5 +27,3 @@ enum {
|
|||
};
|
||||
|
||||
void initMc33816(Logging *logger);
|
||||
static void mcShutdown();
|
||||
|
||||
|
|
Loading…
Reference in New Issue