From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16553 invoked by alias); 3 Jul 2009 09:38:08 -0000 Received: (qmail 16540 invoked by uid 22791); 3 Jul 2009 09:38:07 -0000 X-SWARE-Spam-Status: No, hits=-2.9 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW X-Spam-Check-By: sourceware.org Received: from lon1-post-2.mail.demon.net (HELO lon1-post-2.mail.demon.net) (195.173.77.149) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 03 Jul 2009 09:37:57 +0000 Received: from calivar.demon.co.uk ([83.104.54.243] helo=xl5.calivar.com) by lon1-post-2.mail.demon.net with esmtp (Exim 4.69) id 1MMfDO-0003aO-cK; Fri, 03 Jul 2009 09:37:54 +0000 Received: from xl5.calivar.com (localhost [127.0.0.1]) by xl5.calivar.com (Postfix) with ESMTP id B575C1386F6; Fri, 3 Jul 2009 10:37:53 +0100 (BST) To: grahamlab Cc: ecos-discuss@ecos.sourceware.org References: <24306125.post@talk.nabble.com> <24307911.post@talk.nabble.com> <24318020.post@talk.nabble.com> From: Nick Garnett Original-Sender: nickg@ecoscentric.com Date: Fri, 03 Jul 2009 09:38:00 -0000 In-Reply-To: <24318020.post@talk.nabble.com> Message-ID: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Mailing-List: contact ecos-discuss-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: ecos-discuss-owner@ecos.sourceware.org Subject: Re: [ECOS] Simple serial comms X-SW-Source: 2009-07/txt/msg00016.txt.bz2 grahamlab writes: > > I have tried flow control but to no avail > there must be a way to receive more than 128 bytes has anybody got any other > suggestions Flow control should entirely solve your problem. Did you enable the same kind of flow control at both ends of the connection? I have run tests that successfully transfer larger quantities of data at higher baud rates for long periods. So I don't believe there is a significant problem with the basic driver code. Some other things to try: - Test against a host with a real RS232 device. USB adaptors can do weird things. It is worth eliminating this as a cause of problems, particularly with regard to flow control. - Try increasing STM32_RXBUFSIZE in the driver source to 128 or more. Also add a diag_printf() to the overflow branch in the ISR to see if it triggers. - Avoid diag_printf() calls while waiting for data. If you are running via GDB these calls can cause interrupts to be disabled while the output is being sent. This may cause the driver to miss characters. - It may be instructive to work out exactly which bytes are lost in each message. This may give a clue as to which FIFO or buffer is filling up. -- Nick Garnett eCos Kernel Architect eCosCentric Limited http://www.eCosCentric.com The eCos experts Barnwell House, Barnwell Drive, Cambridge, UK. Tel: +44 1223 245571 Registered in England and Wales: Reg No: 4422071 -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss