fet: continue even if set VCC fails.

This is not a fatal error under all circumstances, for example when
debugging a board with external power applied.
This commit is contained in:
Daniel Beer 2010-07-01 12:25:34 +12:00
parent f96c57cb6e
commit eab488da92
1 changed files with 4 additions and 6 deletions

8
fet.c
View File

@ -870,11 +870,9 @@ device_t fet_open(transport_t transport, int proto_flags, int vcc_mv,
goto fail;
/* set VCC */
if (xfer(dev, C_VCC, NULL, 0, 1, vcc_mv) < 0) {
fprintf(stderr, "fet: set VCC failed\n");
goto fail;
}
if (xfer(dev, C_VCC, NULL, 0, 1, vcc_mv) < 0)
fprintf(stderr, "warning: fet: set VCC failed\n");
else
printf("Set Vcc: %d mV\n", vcc_mv);
/* Identify the chip */