Index: trunk/psModules/src/detrend/Makefile.am
===================================================================
--- trunk/psModules/src/detrend/Makefile.am	(revision 9433)
+++ trunk/psModules/src/detrend/Makefile.am	(revision 9434)
@@ -27,5 +27,7 @@
 	pmSubtractBias.h \
 	pmDetrendDB.h \
-	pmShutterCorrection.h
+	pmShutterCorrection.h \
+	psPipe.h \
+	psIOBuffer.h
 
 #	pmSubtractSky.c
Index: trunk/psModules/src/detrend/psIOBuffer.h
===================================================================
--- trunk/psModules/src/detrend/psIOBuffer.h	(revision 9434)
+++ trunk/psModules/src/detrend/psIOBuffer.h	(revision 9434)
@@ -0,0 +1,34 @@
+/** @file  psPipe.h
+*
+*  @brief 3-stream pipe 
+*
+*  @ingroup misc
+*
+*  @author EAM, IfA
+*
+*  @version $Revision: 1.1 $ $Name: not supported by cvs2svn $
+*  @date $Date: 2006-10-10 01:01:09 $
+*
+*  Copyright 2004-2005 Institute for Astronomy, University of Hawaii
+*/
+
+#ifndef PS_IO_BUFFER_H
+#define PS_IO_BUFFER_H
+
+typedef struct
+{
+    char *data;
+    int nAlloc;    // current size of allocated buffer
+    int nReset;    // size to set buffer after flush
+    int nBlock;    // number of bytes to try to read at a time
+    int n;    // current size of filled data
+}
+psIOBuffer;
+
+// psIOBuffer functions
+psIOBuffer *psIOBufferAlloc (int nBuffer);
+bool psIOBufferFlush (psIOBuffer *buffer);
+int psIOBufferRead (psIOBuffer *buffer, int fd);
+int psIOBufferReadEmpty (psIOBuffer *buffer, int maxRetries, int fd);
+
+# endif
Index: trunk/psModules/src/detrend/psPipe.h
===================================================================
--- trunk/psModules/src/detrend/psPipe.h	(revision 9434)
+++ trunk/psModules/src/detrend/psPipe.h	(revision 9434)
@@ -0,0 +1,33 @@
+/** @file  psPipe.h
+*
+*  @brief 3-stream pipe 
+*
+*  @ingroup misc
+*
+*  @author EAM, IfA
+*
+*  @version $Revision: 1.1 $ $Name: not supported by cvs2svn $
+*  @date $Date: 2006-10-10 01:01:09 $
+*
+*  Copyright 2004-2005 Institute for Astronomy, University of Hawaii
+*/
+
+#ifndef PS_PIPE_H
+#define PS_PIPE_H
+
+// move these to pslib??
+typedef struct
+{
+    int pid;
+    int stdin;
+    int stdout;
+    int stderr;
+}
+psPipe;
+
+// psPipe functions
+psPipe *psPipeAlloc ();
+psPipe *psPipeOpen (char *command);
+int     psPipeClose (psPipe *pipe);
+
+# endif
Index: trunk/psModules/src/psmodules.h
===================================================================
--- trunk/psModules/src/psmodules.h	(revision 9433)
+++ trunk/psModules/src/psmodules.h	(revision 9434)
@@ -45,4 +45,6 @@
 #include <pmDetrendDB.h>
 #include <pmShutterCorrection.h>
+#include <psPipe.h>
+#include <psIOBuffer.h>
 // #include <pmSubtractSky.h>
 
