This commit is contained in:
2020-07-03 16:06:12 +02:00
parent 7c48ef8931
commit 95089b5faa
14 changed files with 373 additions and 411 deletions

View File

@ -1133,17 +1133,12 @@ int setHighVoltage(int val) {
if (val > HV_SOFT_MAX_VOLTAGE) {
val = HV_SOFT_MAX_VOLTAGE;
}
#ifdef VIRTUAL
if (val >= 0)
highvoltage = val;
return highvoltage;
#endif
// setting hv
if (val >= 0) {
LOG(logINFO, ("Setting High voltage: %d V\n", val));
DAC6571_Set(val);
highvoltage = val;
if (DAC6571_Set(val) == OK)
highvoltage = val;
}
return highvoltage;
}