forked from Mirrors/usk
add CLK detection, apparently was never checked :P
This commit is contained in:
parent
9e2544dbe3
commit
67b9440cd7
1 changed files with 8 additions and 1 deletions
9
main.c
9
main.c
|
|
@ -63,7 +63,9 @@ void self_test()
|
||||||
cmd_ok |= safe_test_voltage(PIN_CMD, 1.8f, 0.2f);
|
cmd_ok |= safe_test_voltage(PIN_CMD, 1.8f, 0.2f);
|
||||||
if (!d0_ok)
|
if (!d0_ok)
|
||||||
d0_ok |= safe_test_voltage(PIN_DAT, 1.8f, 0.2f);
|
d0_ok |= safe_test_voltage(PIN_DAT, 1.8f, 0.2f);
|
||||||
if (rst_ok && cmd_ok && d0_ok)
|
if (!clk_ok)
|
||||||
|
clk_ok |= safe_test_voltage(PIN_CLK, 1.8f, 0.2f);
|
||||||
|
if (rst_ok && cmd_ok && d0_ok && clk_ok)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if(!rst_ok)
|
if(!rst_ok)
|
||||||
|
|
@ -78,6 +80,11 @@ void self_test()
|
||||||
{
|
{
|
||||||
halt_with_error(2, 2);
|
halt_with_error(2, 2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!clk_ok)
|
||||||
|
{
|
||||||
|
halt_with_error(3, 2);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
extern bool was_self_reset;
|
extern bool was_self_reset;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue