On Friday 26 May 2006 21:52, Lauri Pirttiaho wrote: > [...] > I would propose changing the behavior of sanei_usb_read bulk > so that in the case of NAK (resource temporarily unavailable) > the size is returned as 0 and the return value is set > either to SANE_STATUS_GOOD (read OK, just no data > at this moment) or SANE_STATUS_BUSY (device can not > respond right now). Both will work even though probably > the latter one is more in line with the meaning of USB NAK > in this case.
I vote for the latter (SANE_STATUS_BUSY) so that it is possible to distinguish between NAK and zero-length packet. Regards -- Wittawat Yamwong Hannover, Germany