[comp.sys.amiga] using SER: from programs

ain@s.cc.purdue.edu (Patrick White) (02/29/88)

   I have a question using SER: that I'd like some suggestions or solutions to:

   I would like to have a program open a device in shared mode.. right now,
I'm concentrating on getting SER: to work.  Eventually, I'd like to open
a logical device so my programs don't have to be aware of exactly what kind
of hardware they are talking to that does the byte pushing... hence, I am
trying to 'Open' SER:.  I want one program to open the device and only read
from it, and the other to open it and only write to it.
   If I use stdout, and redirect it from CLI to SER: (eg: "send >ser:"), my
program works exactly the way I want it to, in that I can have some other
program open the device and read data from it.  However, if I use AmigaDOS
'Open', or Manx's 'open', the device gets exclusively opened.
   I know I can Opendevice, but then my program has to know about the
device it is opening.. and has to know about all devices it could ever
possibly be asked to open... I'd rather not do it this way.

   What I'm looking for, are some suggestions on how to go about opening
logical devices so they can be shared without using redirection (I want to
have a master program that starts several others up for convenience.. and
two of them talk to the same logical device -- one reading to it, the other
writing to it).


   So, can anyone suggest some ways I can try to do this?

   Many thanks for any and all suggestions/solutions.


-- Pat White
ARPA/UUCP: s.cc.purdue.edu!ain  BITNET: PATWHITE@PURCCVM   PHONE: (317) 743-8421
U.S.  Mail:  320 Brown St. apt. 406,    West Lafayette, IN 47906