From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.3 required=5.0 tests=BAYES_00,FREEMAIL_FROM, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,b321573c2e5269d2 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news2.google.com!news.glorb.com!feeder.erje.net!feeder.news-service.com!94.75.214.39.MISMATCH!aioe.org!.POSTED!not-for-mail From: anon@att.net Newsgroups: comp.lang.ada Subject: Re: Asynchronous I/O on a serial device Date: Sun, 12 Jun 2011 21:01:32 +0000 (UTC) Organization: Aioe.org NNTP Server Message-ID: References: Reply-To: anon@anon.org NNTP-Posting-Host: +xKyTa5daN97EsXcOQSCWQ.user.speranza.aioe.org X-Complaints-To: abuse@aioe.org X-Notice: Filtered by postfilter v. 0.8.2 X-Newsreader: IBM NewsReader/2 2.0 Xref: g2news2.google.com comp.lang.ada:20749 Date: 2011-06-12T21:01:32+00:00 List-Id: To connect to the UART device directly you should use to use the Gnat.Sockets.* or AdaSockets packages. Or you could use PolyORB packages which contains a number of serial I/O packages. Like: GNAT.Serial_Communications; Download => Libre.Adacore.com In , Kim Rostgaard Christensen writes: >Hi there > >I am desperately trying to implement a protocol on top of a serial >transport. > >I am running Debian, and for the moment using /dev/ttyACM0 for reading. >This works fine using standard the Text_IO package and In_File. >Only, when I need to write to the device It fails because It is in >In_File mode - Obviously. >Reset on the file handle gives me a USE_ERROR exception, probably due to >it being a special file - please correct me if I am wrong. > >Do I need to implement this more system-near/specific, or is there some >way I can do bi-directional communication like, for instance two file >handles. (I tried Form => "shared=yes", and it also failed). > >It is a usb device that emulates UART, and it seems to be contempt with >just about any Baud setting. > >/Kim