From owner-freebsd-current@FreeBSD.ORG Mon Dec 8 19:18:10 2008 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EB70B1065670 for ; Mon, 8 Dec 2008 19:18:10 +0000 (UTC) (envelope-from xcllnt@mac.com) Received: from asmtpout019.mac.com (asmtpout019.mac.com [17.148.16.94]) by mx1.freebsd.org (Postfix) with ESMTP id D693F8FC0C for ; Mon, 8 Dec 2008 19:18:10 +0000 (UTC) (envelope-from xcllnt@mac.com) MIME-version: 1.0 Content-transfer-encoding: 7BIT Content-type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Received: from sbansal-mbp.jnpr.net (natint3.juniper.net [66.129.224.36]) by asmtp019.mac.com (Sun Java(tm) System Messaging Server 6.3-7.03 (built Aug 7 2008; 32bit)) with ESMTPSA id <0KBK002WNOA9KJ40@asmtp019.mac.com> for freebsd-current@freebsd.org; Mon, 08 Dec 2008 11:18:10 -0800 (PST) Message-id: From: Marcel Moolenaar To: Mike Tancsa In-reply-to: <200812081906.mB8J6oha042222@lava.sentex.ca> Date: Mon, 08 Dec 2008 11:18:08 -0800 References: <200812081621.mB8GLMxB041498@lava.sentex.ca> <200812081906.mB8J6oha042222@lava.sentex.ca> X-Mailer: Apple Mail (2.929.2) Cc: freebsd-current@freebsd.org Subject: Re: uart vs sio differences ? X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Dec 2008 19:18:11 -0000 On Dec 8, 2008, at 11:06 AM, Mike Tancsa wrote: > At 01:49 PM 12/8/2008, Marcel Moolenaar wrote: > >> On Dec 8, 2008, at 8:21 AM, Mike Tancsa wrote: >> >>> Unfortunately, we only control the FreeBSD side of things and the >>> other end of the serial connection is a windows app we dont >>> control. Everything seems to work ok from our side, but the other >>> side which we dont control seems to be missing some things we are >>> sending it and vice versa. >> >> It looks to me that flow-control is disabled, is that right? >> >> Not only does uart(4) make use of the larger buffer of the >> hardware, it's also more efficient under puc(4) than sio(4) >> is because of the use of the serdev I/F. It's possible that >> the receiver can not keep up when uart(4) is used. A serial >> line analyzer should tell you more... > > Hi, > Yes, flow control is supposed to be disabled. When we hook > up a serial line analyzer, the behaviour is rather odd. We only use > 1200bps, so I dont think its a speed issue. Also, as part of the > protocol, we poll the other side. We send a 3 byte poll, which the > Windows side always sees, and it sends us back a 1 byte answer, > which we see fine. However, when the Windows side has "something to > say", it will send a different 1 byte response (which we get) and > then the data, which is approximately 100 to 200 bytes which we only > get about 30 bytes of. I see, so the FreeBSD box with uart(4) is missing data, not the Windows machine, right? Do you know if you get the first 30 bytes or the last 30 bytes or some mix? -- Marcel Moolenaar xcllnt@mac.com