On Mon, Jun 05, 2006 at 06:05:12PM +0400, Sergei Organov wrote:
> Hello,
> 
> I'm using usbserial module to talk to a device supporting 2 bulk
> endpoints (high speed USB 1.1).

Which usb-serial driver are you using?  Or are you just using the
generic driver?

> The input from the device to the host is
> OK. However, when I write a sequence containing CR and/or LF to the
> device, the device sees fake 0x80 just before CR and/or LF, and I see
> this fake 0x80 in the debug output of usbserial/generic modules as
> well. It looks really weird, e.g.:
> 
> Write:     Actual Output:
> 
> a<CR><LF>  a\0x80<CR><LF>
> <CR><LF>   <CR><LF>             ! no 0x80 here !
> a<CR>      a\0x80<CR>
> a<LF>      a\0x80<LF>
> 
> For, say "a<CR><LF>" sequence, the usbserial/generic module actually
> sees two writes, write("a", 1), and write("\0x80\r\n", 3). The number of
> bytes before <CR>/<LF> doesn't really matter unless it is 0, in which
> case fake 0x80 disappears.
> 
> The tty settings are:
> 
> osv:~# stty -F /dev/ttyUSB0 -a
> 
> speed 9600 baud; rows 0; columns 0; line = 0; intr = ^C; quit = ^\;
> erase = ^?; kill = ^U; eof = ^D; eol = <undef>; eol2 = <undef>; start = ^Q;
> stop = ^S; susp = ^Z; rprnt = ^R; werase = ^W; lnext = ^V; flush = ^O;
> min = 0; time = 0; -parenb -parodd cs8 -hupcl -cstopb cread clocal
> -crtscts -ignbrk -brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr
> -icrnl -ixon -ixoff -iuclc -ixany -imaxbel -opost -olcuc -ocrnl onlcr
> -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0 -isig -icanon
> -iexten -echo -echoe -echok -echonl -noflsh -xcase -tostop -echoprt
> -echoctl -echoke

If the generic one, none of these line settings are "real", it's just a
data pipe.  If not, please let us know.

thanks,

greg k-h


_______________________________________________
[email protected]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to