Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!umcp-cs!cvl!umd5!louie From: louie@sayshell.umd.edu (Louis A. Mamakos) Newsgroups: net.micro.amiga Subject: Re: Mechanics of dropping DTR Message-ID: <1332@umd5> Date: Tue, 28-Oct-86 17:06:40 EST Article-I.D.: umd5.1332 Posted: Tue Oct 28 17:06:40 1986 Date-Received: Tue, 28-Oct-86 23:28:05 EST References: <305@pttesac.UUCP> <257@hao.UUCP> Sender: uucp@umd5 Reply-To: louie@sayshell.umd.edu (Louis A. Mamakos) Organization: University of Maryland, College Park Lines: 25 Keywords: serial.device DTR hang-up > However two things remain a mystery to me. The first is that I wonder why > I can't blast the count to zero by repeatedly hitting the "hang up" menu > option in the VT100 program. The second is the matter of the meaning of > "Exclusive Use" of the port. It seems to me that if a program requests > exclusive use of the port, and the count is already up by one, then the > AmigaDOS response had ought to be to return an error for the dev Open call. > I really have no idea what it does do, as I haven't yet had a chance to > look at it. But as I say, I am beginning to wonder... > > Howard Hull > {ucbvax!hplabs | decvax!noao | mcvax!seismo | ihnp4!seismo} !hao!hull You can't zero the use count, because the "hang up" menu item can only close the serial.device, and then reopen it. You should not close the device more than once! If the use count was 2 before, after you close the device, it will drop to 1. If you request exclusive use of the device when you open it, the OpenDevice() will indeed fail if it is already open. Note that in this case, AmigaDOS is not involved at all, since you're using the low level device driver, not the SER: device. If another program is broken, and doesn't clean up after itself, fix it or stop using it. Don't try to kludge other (perfectly good and working) programs to get around it.