sas@calmasd.Prime.COM (Shirley Sloper) (08/05/89)
Messages from long ago.... > Someone writes: >>From: "ANIMAL::THOMPSON" <thompson%animal.decnet@cim-vax.honeywell.com> >>Subject: Re: Placing a window on another node. >> But. back to the question at hand. >> [Great info on how to creat a pad on another node via send_alarm or >> crp/crpad] >> >>John Thompson > >Either way (send_alarm, crp/crpad, /bin/write, or /bin/wall), you can't > [blah, blah, blah.....] Hello, Does anyone remember the above discussion? (I'm sorry the references aren't there, this is all I can find.) I had just started reading the group (June?) and I believe the main discussion may have been concerning borrow mode. I'm not interested in borrow mode, what I would like is the "great info on how to create a pad on another node...", that the message refers to. Can someone inform me how to do this? This is the situation I am dealing with: A process on node A starts a process (CPS) on node B. I want the node B process to be able to inform node A that it is finishing, (either from a shell script or C module). Most probably, the originating process on A is no longer running. What I would like to do is create a window back on node A. Thankyou, thankyou, thankyou! -- Shirley A. Sloper sas@calmasd.prime.com ****** Calma ****** ** 9805 Scranton Road ** ** San Diego, CA 92121 **
gaz@apollo.HP.COM (Gary Zaidenweber) (08/09/89)
From article <492@calmasd.Prime.COM>, by sas@calmasd.Prime.COM (Shirley Sloper): > > Messages from long ago.... >> Someone writes: >>>From: "ANIMAL::THOMPSON" <thompson%animal.decnet@cim-vax.honeywell.com> >>>Subject: Re: Placing a window on another node. >>> But. back to the question at hand. >>> [Great info on how to creat a pad on another node via send_alarm or >>> crp/crpad] >>> >>>John Thompson >> >>Either way (send_alarm, crp/crpad, /bin/write, or /bin/wall), you can't >> [blah, blah, blah.....] > > > Hello, > > Does anyone remember the above discussion? (I'm sorry the references > aren't there, this is all I can find.) I had just started reading the > group (June?) and I believe the main discussion may have been concerning > borrow mode. I'm not interested in borrow mode, what I would like is > the "great info on how to create a pad on another node...", that the > message refers to. Can someone inform me how to do this? > > This is the situation I am dealing with: A process on node A starts a > process (CPS) on node B. I want the node B process to be able to > inform node A that it is finishing, (either from a shell script or C > module). Most probably, the originating process on A is no longer > running. What I would like to do is create a window back on node A. > > Thankyou, thankyou, thankyou! > > > -- > Shirley A. Sloper sas@calmasd.prime.com > ****** Calma ****** > ** 9805 Scranton Road ** > ** San Diego, CA 92121 ** The following module sort of emulates the system() call, creating a window to run the shell. It runs under sr10.1+ (and maybe 10.0 I just haven't tried and don't expect to). I run in a sysV environment but I know this works in Aegis and BSD too. I believe that it will not run under sr9.7 without modifications.: #include <apollo/base.h> #include <apollo/pad.h> #include <apollo/pgm.h> #include <apollo/error.h> void psystem(string) char *string; { pad_$window_desc_t window; status_$t st; char *path; ios_$id_t padin,padout,paderr; stream_$id_t strv[3]; short strc = 3; pgm_$mode mode; pgm_$proc phandle; int j; #define NARGC 3 struct arge nargv[NARGC]; pgm_$arg_ptr narg[NARGC]; short nargc = NARGC; name_$pname_t pstring; char *sh = "/bin/sh"; window.top = 0; window.left = 0; window.width = 0; window.height = 0; path = ""; pad_$create_window(path,0,pad_$transcript,(short)1,window,&padout,&st); if( st.all != status_$ok ) { error_$print(st); exit(-1); } else paderr = padout; pad_$create(path,0,pad_$input,padout,pad_$bottom,0,(short)20,&padin,&st); if( st.all != status_$ok ) { error_$print(st); exit(-1); } (VOID)strcpy(pstring,"sh -c "); (VOID)strcat(pstring,string); for(j=0;j<NARGC;j++) narg[j] = (pgm_$arg_ptr) &nargv[j]; strcpy(narg[0]->chars,"sh"); narg[0]->len = (short)strlen(narg[0]->chars); strcpy(narg[1]->chars,"-c"); narg[1]->len = (short)strlen(narg[1]->chars); strcpy(narg[2]->chars,string); narg[2]->len = (short)strlen(narg[2]->chars); nargc = NARGC; strv[ios_$stdin] = padin; strv[ios_$stdout] = padout; strv[ios_$stderr] = paderr; mode = 0; /* run in "default" mode */ pgm_$invoke(sh,(short)strlen(sh),nargc,narg,strc,strv,mode,&phandle,&st); if( st.all != status_$ok ) { error_$print (st); exit(-1); } exit(0); }
sarathy@gpu.utcs.utoronto.ca (Rajiv Sarathy) (08/17/89)
In article <44ed8514.ce45@apollo.HP.COM> gaz@apollo.HP.COM (Gary Zaidenweber) writes: >From article <492@calmasd.Prime.COM>, by sas@calmasd.Prime.COM (Shirley Sloper): >> >> Messages from long ago.... >>> Someone writes: >>>>From: "ANIMAL::THOMPSON" <thompson%animal.decnet@cim-vax.honeywell.com> >>>>Subject: Re: Placing a window on another node. >>>> But. back to the question at hand. >>>> [Great info on how to creat a pad on another node via send_alarm or >>>> crp/crpad] >>>> >>>>John Thompson >>> >>>Either way (send_alarm, crp/crpad, /bin/write, or /bin/wall), you can't >>> [blah, blah, blah.....] >> >> >> Hello, >> >> Does anyone remember the above discussion? (I'm sorry the references >> aren't there, this is all I can find.) I had just started reading the >> group (June?) and I believe the main discussion may have been concerning >> borrow mode. I'm not interested in borrow mode, what I would like is >> the "great info on how to create a pad on another node...", that the >> message refers to. Can someone inform me how to do this? >> >> This is the situation I am dealing with: A process on node A starts a >> process (CPS) on node B. I want the node B process to be able to >> inform node A that it is finishing, (either from a shell script or C >> module). Most probably, the originating process on A is no longer >> running. What I would like to do is create a window back on node A. >> >> Thankyou, thankyou, thankyou! >> >> >> -- >> Shirley A. Sloper sas@calmasd.prime.com >> ****** Calma ****** >> ** 9805 Scranton Road ** >> ** San Diego, CA 92121 ** > >The following module sort of emulates the system() call, creating >a window to run the shell. It runs under sr10.1+ (and maybe 10.0 >I just haven't tried and don't expect to). I run in a sysV environment >but I know this works in Aegis and BSD too. I believe that it will >not run under sr9.7 without modifications.: > >#include <apollo/base.h> >#include <apollo/pad.h> > [long c program] Why can't you just do this: crp "/com/crpad <name_of_file>" -on //<node_name> -me This will place the contents of <name_of_file> in a read-only window on //<node_name> -- _____________________________________________________________________________ | Disclaimer: I'm just an undergrad. All views and opinions are therefore _ | | my own. /\ /\ /-----------------------------------oO(_)| | / \ / \ / NetNorth: sarathy@utorgpu | | Rajiv Partha Sarathy / \/ \/ sarathy@gpu.utcs.utoronto.ca | | --------------------/ {uunet!attcan mnetor att pyramid}!utgpu!sarathy | |_____________________________________________________________________________|
gaz@apollo.HP.COM (Gary Zaidenweber) (08/31/89)
From article <1989Aug17.083649.3654@gpu.utcs.utoronto.ca>, by sarathy@gpu.utcs.utoronto.ca (Rajiv Sarathy): > > Why can't you just do this: > > crp "/com/crpad <name_of_file>" -on //<node_name> -me > > This will place the contents of <name_of_file> in a read-only window > on //<node_name> > > > -- > _____________________________________________________________________________ > | Disclaimer: I'm just an undergrad. All views and opinions are therefore _ | > | my own. /\ /\ /-----------------------------------oO(_)| > | / \ / \ / NetNorth: sarathy@utorgpu | > | Rajiv Partha Sarathy / \/ \/ sarathy@gpu.utcs.utoronto.ca | > | --------------------/ {uunet!attcan mnetor att pyramid}!utgpu!sarathy | > |_____________________________________________________________________________| Of course you can do that if you just wish to show a file. The reason I posted the "long C program" :-) is that sometimes you wish to actually run a program in a window, evoked from another program (which may or may not be running in a window, itself.) I figured I'd supply the useful, general-case module to do that. -- Gary Zaidenweber (508)256-6600 x6081 | You're only young Apollo Computer, a subsidiary of Hewlett Packard | once, but if you UUCP: {umix|decvax|mit-eddie}!apollo!gaz | do it right, ARPA: gaz@apollo.COM; gaz@apollo.HP.COM | once is enough!