Index: trunk/archive/dettools/doc/dettools.txt
===================================================================
--- trunk/archive/dettools/doc/dettools.txt	(revision 5870)
+++ trunk/archive/dettools/doc/dettools.txt	(revision 5871)
@@ -30,24 +30,33 @@
 
 dettool -select raw [-state state] [-outmode mode]
- * select the frames to be processed and extract the list of files 
+ * select the unprocessed input infiles
  - output of this program is used by pantasks to schedule the ppImage
  run on each image
 
 dettool -select stack [-state state] [-outmode mode]
- * select the files to be stacked for a given detRun
+ * select the files to be stacked for a given detRun, if exposures are ready
  - output of this program is used by ppMerge to build a master stack
 
-dettool -select residual [-state state]
- * select the frames to be used to generate residuals
+dettool -select rawresid [-state state]
+ * select the residual imfiles to be generated
  - output of this program is used for another ppImage run 
 
-detmerge 
+dettool -update raw
+ * select the raw input exposures, count processed imfiles, update if done
+
+dettool -update resid
+ * select the resid exposures, count processed resid imfiles, update if done
+ - for a given resid exposure, compile the results from the stacks for
+ each chip and renormalize the output files as needed.
+
+dettool -select norm
+ * select the master detrend frames & imfiles to be normalized
+
+dettool -resid
+ * construct the resid exposures and imfiles given 
+
+dettool -assess
  * for a given master detrend frame, compile the results from the
- stacks for each chip and renormalize the output files as needed.
- assemble the resulting master stats as available
-
-detstats
- * for a given master detrend frame, compile the results from the
- residual images and assess the validity of the input images and of
+ residual exposures and assess the validity of the input exposures and of
  the complete stack.  if too many input images are rejected, the
  affect the master detrend frame state.  if input images are rejected
@@ -66,2 +75,39 @@
    after process that determines which happens next.
 
+
+
+States:
+ input detrend exposures:
+  RAW
+  PROCESSED
+
+ input detrend imfiles:
+  RAW
+  PROCESSED
+  
+ master detrend frames
+  RAW
+  NORMALIZED
+  MKRESID
+  SUCCESS
+  FAILURE
+  RETRY
+  (also has NEW/PRIOR flag)
+
+ master detrend imfiles
+  NEW (not yet created)
+  RAW (created, but not normalized)
+  NORMALIZED
+
+ resid exposure
+  RAW
+  PROCESSED
+  ASSESSED
+
+ resid imfiles:
+  RAW
+  PROCESSED
+
+ master detrend run:
+  NEW
+  DONE
