Index: trunk/ippToPsps/test/mkgpc1data.dvo
===================================================================
--- trunk/ippToPsps/test/mkgpc1data.dvo	(revision 39165)
+++ trunk/ippToPsps/test/mkgpc1data.dvo	(revision 40221)
@@ -75,7 +75,11 @@
   $dbuser = dvo
   $dbpass = dvo
-#  $dbuser = czw
-#  $dbpass = czw
-
+
+  $gscfile = `gconfig GSCFILE`
+  if ("$gscfile" == "not found")
+    echo "problem with dvo / ptolemy configuration.  check ~/.ptolemyrc"
+    break
+  end
+   
   exec mkgpc1.sh delete $dbhost $dbname $dbuser $dbpass
   exec mkgpc1.sh create $dbhost $dbname $dbuser $dbpass
@@ -193,4 +197,5 @@
     end
 
+    echo "*****"
     echo addstar -D SKY_DEPTH 4 -D CATDIR $catdir -D CAMERA simtest $cmffile -D CATFORMAT $2 -quick-airmass
     exec addstar -D SKY_DEPTH 4 -D CATDIR $catdir -D CAMERA simtest $cmffile -D CATFORMAT $2 -quick-airmass
@@ -198,12 +203,12 @@
 
   if ($SMALLTEST)
-    echo relphot -D CATDIR $catdir -region 8 12 18 22 -images g,r,i,z,y -nloop 0 -D STAR_TOOFEW 0 -update
-    exec relphot -D CATDIR $catdir -region 8 12 18 22 -images g,r,i,z,y -nloop 0 -D STAR_TOOFEW 0 -update
-
-    echo relastro -v -D CATDIR $catdir -images -update-chips -region 8 12 18 22 -update -apply-offsets
-    exec relastro -v -D CATDIR $catdir -images -update-chips -region 8 12 18 22 -update -apply-offsets
+    echo relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -images g,r,i,z,y -nloop 0 -D STAR_TOOFEW 0 -update
+    exec relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -images g,r,i,z,y -nloop 0 -D STAR_TOOFEW 0 -update
+
+    echo relastro -v -D CATDIR $catdir -D CAMERA simtest -images -update-chips -region 8 12 18 22 -update -apply-offsets
+    exec relastro -v -D CATDIR $catdir -D CAMERA simtest -images -update-chips -region 8 12 18 22 -update -apply-offsets
   else
-    echo relphot -D CATDIR $catdir -region 8 12 18 22 -images g,r,i,z,y -update
-    exec relphot -D CATDIR $catdir -region 8 12 18 22 -images g,r,i,z,y -update
+    echo relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -images g,r,i,z,y -update
+    exec relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -images g,r,i,z,y -update
   end
 
@@ -267,9 +272,9 @@
 
   if ($SMALLTEST)
-    echo relphot -D CATDIR $catdir -region 8 12 18 22 -averages -update
-    exec relphot -D CATDIR $catdir -region 8 12 18 22 -averages -update
+    echo relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -averages -update
+    exec relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -averages -update
   else
-    echo relphot -D CATDIR $catdir -region 8 12 18 22 -images g,r,i,z,y -update
-    exec relphot -D CATDIR $catdir -region 8 12 18 22 -images g,r,i,z,y -update
+    echo relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -images g,r,i,z,y -update
+    exec relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -images g,r,i,z,y -update
   end
 
@@ -352,18 +357,18 @@
     exec mkcmf -forcedgalaxy -photcode SIMTEST.$filter.ForcedWarp $rawfile $cmffile -extroot SkyChip -date 2008/1/1 -time $i\:00:00 -mjd 54466.0 -radec $RA $DEC -type $1 -imageID $stkID -sourceID 1 -tess_id $TESS_ID -skycell $SKYCELL
 
-    echo loadgalphot -D CATDIR $catdir -photcode SIMTEST.$filter.ForcedWarp -image-id $stkID $cmffile 
-    exec loadgalphot -D CATDIR $catdir -photcode SIMTEST.$filter.ForcedWarp -image-id $stkID $cmffile
+    echo loadgalphot -D CATDIR $catdir -D CAMERA simtest -photcode SIMTEST.$filter.ForcedWarp -image-id $stkID $cmffile 
+    exec loadgalphot -D CATDIR $catdir -D CAMERA simtest -photcode SIMTEST.$filter.ForcedWarp -image-id $stkID $cmffile
   end
 
   if ($SMALLTEST)
-    echo relphot -D CATDIR $catdir -region 8 12 18 22 -averages -update
-    exec relphot -D CATDIR $catdir -region 8 12 18 22 -averages -update
+    echo relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -averages -update
+    exec relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -averages -update
   else
-    echo relphot -D CATDIR $catdir -region 8 12 18 22 -images g,r,i,z,y -update
-    exec relphot -D CATDIR $catdir -region 8 12 18 22 -images g,r,i,z,y -update
-  end
-
-  echo dvolens -D CATDIR $catdir -region 8 12 18 22 -update-objects -update
-  exec dvolens -D CATDIR $catdir -region 8 12 18 22 -update-objects -update
+    echo relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -images g,r,i,z,y -update
+    exec relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -images g,r,i,z,y -update
+  end
+
+  echo dvolens -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -update-objects -update
+  exec dvolens -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -update-objects -update
 
   if ($PARALLEL)
@@ -557,9 +562,9 @@
   end
   if ($SMALLTEST)
-    echo relphot -D CATDIR $catdir -region 8 12 18 22 -images g,r,i,z,y -nloop 0 -D STAR_TOOFEW 0 -update -boundary-tree tess.3pi.fits -is-diff-db -statmode WT_MEAN 
-    exec relphot -D CATDIR $catdir -region 8 12 18 22 -images g,r,i,z,y -nloop 0 -D STAR_TOOFEW 0 -update -boundary-tree tess.3pi.fits -is-diff-db -statmode WT_MEAN
+    echo relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -images g,r,i,z,y -nloop 0 -D STAR_TOOFEW 0 -update -boundary-tree tess.3pi.fits -is-diff-db -statmode WT_MEAN 
+    exec relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -images g,r,i,z,y -nloop 0 -D STAR_TOOFEW 0 -update -boundary-tree tess.3pi.fits -is-diff-db -statmode WT_MEAN
   else
-    echo relphot -D CATDIR $catdir -region 8 12 18 22 -images g,r,i,z,y -update
-    exec relphot -D CATDIR $catdir -region 8 12 18 22 -images g,r,i,z,y -update
+    echo relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -images g,r,i,z,y -update
+    exec relphot -D CATDIR $catdir -D CAMERA simtest -region 8 12 18 22 -images g,r,i,z,y -update
   end
 
