Ignore timeouts during initialization.

Some Veo devices never respond to the initialization command, but have
no problem to continue the communication. Therefore a timeout with no
data received is ignored. If there happens to be a real problem, it will
be catched when sending one of the other commands afterwards.
This commit is contained in:
Jef Driesen 2011-01-18 11:53:47 +01:00
parent 8425a22dbc
commit fbe203993c

View File

@ -179,6 +179,8 @@ oceanic_veo250_init (oceanic_veo250_device_t *device)
n = serial_read (device->port, answer, sizeof (answer));
if (n != sizeof (answer)) {
WARNING ("Failed to receive the answer.");
if (n == 0)
return DEVICE_STATUS_SUCCESS;
return EXITCODE (n);
}