comp.lang.ada
 help / color / mirror / Atom feed
From: Simon Clubley <clubley@remove_me.eisner.decus.org-Earth.UFP>
Subject: Re: GNAT.Serial_Communications
Date: Tue, 19 Apr 2011 13:32:34 +0000 (UTC)
Date: 2011-04-19T13:32:34+00:00	[thread overview]
Message-ID: <iok2th$cpe$1@dont-email.me> (raw)
In-Reply-To: be0e8769-2eb5-46ae-9f8c-416764e69e88@j35g2000prb.googlegroups.com

On 2011-04-19, tonyg <tonythegair@gmail.com> wrote:
>
> Just to let you all know ( I'm sure the world was waiting with baited
> breath!) that thanks to the help received, its now all working. I'll
> document what the problem was with some additional stuff to let future
> people know.
>
> It was the flow control setting and it can be fixed by opening another
> terminal window and using the command
>
> stty --file=/dev/ttyUSB0 -crtscts
>
> However - any ada program compiled with the gnat serial communications
> package if run again will reset the port to add flow control so this
> needs it will need to be done again. Which is unfortunate for me and

Interesting. I would not expect that; there may be something resetting
the port (maybe in the GNAT library or the version of the Linux kernel you
are using) without you realising it as I don't recall seeing that while
working with Linux serial ports (which, for the set of applications in
question, I do in C and not Ada).

> anyone with non flow control electronics. I expect this will occur
> everytime the port is opened. Out of interest do all you serial port
> tinkerers out there use flow control?

Yes. It's a hardware based RTS/CTS flow control setup and it's a integral
part of my microcontroller UART library (at least for the hardware UART;
I also created a Tx only software UART for my library and I don't support
flow control on that as it's just used for debugging).

This is for microcontroller to microcontroller communications however.

When I connect the devices to the Linux PC, I use the standard MAX232
setup and since it's been a number of months since I last did this, I
cannot remember if my library supports inverting the RTS/CTS lines
to allow the signals to pass through the MAX232 or if I just disable
the flow control on both sides as I am generally just debugging.

Given that I need to transmit 8 bit data on these ports, I have not
bothered creating a software flow control Xon/Xoff implementation.

Simon.

-- 
Simon Clubley, clubley@remove_me.eisner.decus.org-Earth.UFP
Microsoft: Bringing you 1980s technology to a 21st century world



  parent reply	other threads:[~2011-04-19 13:32 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-11 10:26 GNAT.Serial_Communications tonyg
2011-04-11 11:11 ` GNAT.Serial_Communications Brian Drummond
2011-04-13  7:49   ` GNAT.Serial_Communications tonyg
2011-04-13 14:12     ` GNAT.Serial_Communications Alex Mentis
2011-04-13 21:12       ` GNAT.Serial_Communications tonyg
2011-04-14 13:15         ` GNAT.Serial_Communications Alex Mentis
2011-04-14 17:52         ` GNAT.Serial_Communications Chris Moore
2011-04-15 13:58           ` GNAT.Serial_Communications tonyg
2011-04-15 16:32             ` GNAT.Serial_Communications tonyg
2011-04-15 17:12               ` GNAT.Serial_Communications Simon Clubley
2011-04-15 17:32                 ` GNAT.Serial_Communications tonyg
2011-04-15 18:49                   ` GNAT.Serial_Communications Simon Clubley
2011-04-16  0:07                     ` GNAT.Serial_Communications tonyg
2011-04-16  8:29                       ` GNAT.Serial_Communications Simon Clubley
2011-04-16 10:19                         ` GNAT.Serial_Communications tonyg
2011-04-16 10:33                           ` GNAT.Serial_Communications tonyg
2011-04-16 11:15                             ` GNAT.Serial_Communications Brian Drummond
2011-04-16 12:03                               ` GNAT.Serial_Communications tonyg
2011-04-16 15:12                                 ` GNAT.Serial_Communications Simon Clubley
2011-04-18 20:31                                   ` GNAT.Serial_Communications tonyg
2011-04-18 20:43                                   ` GNAT.Serial_Communications tonyg
2011-04-19 11:46                                     ` GNAT.Serial_Communications tonyg
2011-04-19 12:09                                       ` GNAT.Serial_Communications Ludovic Brenta
2011-04-19 13:53                                         ` GNAT.Serial_Communications tonyg
2011-04-19 19:06                                           ` GNAT.Serial_Communications Ludovic Brenta
2011-04-19 19:57                                         ` GNAT.Serial_Communications Alex Mentis
2011-04-20 11:37                                           ` GNAT.Serial_Communications tonyg
2011-04-20 14:22                                             ` GNAT.Serial_Communications Alex Mentis
2011-04-21  9:00                                               ` GNAT.Serial_Communications tonyg
2011-04-21 13:28                                                 ` GNAT.Serial_Communications Alex Mentis
2011-04-22 13:55                                                 ` GNAT.Serial_Communications Alex Mentis
2011-04-22 15:52                                                   ` GNAT.Serial_Communications Brian Drummond
2011-04-19 13:32                                       ` Simon Clubley [this message]
2011-04-19 16:59                                         ` GNAT.Serial_Communications Simon Clubley
2011-04-20 10:17                                         ` GNAT.Serial_Communications Brian Drummond
2011-04-20 20:46                                         ` GNAT.Serial_Communications Brian Drummond
2011-04-21  4:28                                           ` GNAT.Serial_Communications Simon Wright
2011-04-21  9:12                                             ` GNAT.Serial_Communications tonyg
2011-04-21 10:14                                               ` GNAT.Serial_Communications tonyg
2011-04-22 15:54                                             ` GNAT.Serial_Communications Brian Drummond
2011-04-22 16:14                                               ` GNAT.Serial_Communications Simon Wright
2011-04-21 11:56                                           ` GNAT.Serial_Communications Simon Clubley
2011-04-15 18:01               ` GNAT.Serial_Communications Jeffrey Carter
2011-04-16 10:21                 ` GNAT.Serial_Communications tonyg
2016-12-01 19:58 ` GNAT.Serial_Communications mario.blunk.gplus
2017-03-20 15:20   ` GNAT.Serial_Communications Jacob Sparre Andersen
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox