application: fix type floating detection

This commit is contained in:
King Kévin 2021-03-25 12:37:39 +01:00
parent 86fd05f52c
commit a4d881df29
1 changed files with 3 additions and 1 deletions

View File

@ -362,12 +362,14 @@ static void command_types(void* argument)
printf("pulled-up (%u kOhm)", (uint32_t)round(pullup));
} else if (pulldown >= 0.9 && pulldown < 100.0 && (pullup <= 0.9 || pullup > 100.0)) {
printf("pulled-down (%u kOhm)", (uint32_t)round(pulldown));
} else if (low && high) {
puts("floating");
} else if (low) {
puts("low");
} else if (high) {
puts("high");
} else {
puts("floating");
puts("unknown");
}
putc('\n');
}