[Coco] Named pipes in OS-9/68K

Joel Ewy jcewy at swbell.net
Sat Apr 28 12:27:01 EDT 2007

Ok, I've found something about this on page 5-18 of the manual.  I guess
what it means is that unless you're using 'copy' to put the file in the
named pipe the process blocks until the piped file is devoured.  Does
that make sense?  But if that's the case, then I don't see what the
point of named pipes is.  If I can't put:
"djpeg -targa photo.jpg >/pipe/intermediate.tga" and
"tgatoppm /pipe/intermediate.tga >photo.ppm" on two separate command
lines, then how are named pipes different from regular pipes?  I have
situations where a series of NETPBM manipulations is too long for a
single command line.  I'd like to use a named pipe so I don't have to
clean up temporary files on the hard drive or ramdisk.  The
documentation says:

"dir works with /pipe.  This displays all named pipes in existence.  a
dir -e command may be deceiving.[sic]  If any utility other than copy
creates a named pipe, the pipe size equals 90 bytes.  copy expands the
size of the pipe to the size of the file.  This indicates that the first
90 bytes of the output are in the named pipe.  However, if the procs
utility is executed, you will se that a path remains open to /pipe.  If
you were to copy or list the pipe, for example, the pipe would continue
to receive input and pass it to its output path until the input process
is finished.  When the pipe is empty, the named pipe is deleted

So does this mean that I need to do something like:
"djpeg -targa photo.jpg >/pipe/intermediate.tga &" so I can get back to
the shell for the next command?  This really isn't clear to me. 


Joel Ewy wrote:
> Having trouble with named pipes on the MM/1.  Maybe I don't understand
> how they're supposed to work.  If I do something like:
> "djpeg -targa photo.jpg >/pipe/intermediate.tga"
> It appears to hang.  If I go to another virtual terminal and do a:
> "dir -e /pipe"
> I see "intermediate.tga" with a file size of 90.  In fact, any file sent
> to a named pipe never gets beyond 90 bytes, and the program writing the
> file just goes to sleep at that point and stays there.  My MM/1 has 8M
> of RAM.  I've found that the ramdisk needs to be 'iniz'ed before use, so
> I tried "iniz /pipe" but that didn't make any difference.  Anybody have
> any ideas how this is supposed to work?
> --
> Coco mailing list
> Coco at maltedmedia.com
> http://five.pairlist.net/mailman/listinfo/coco

More information about the Coco mailing list