Index: branches/cleanup/ippTools/src/pxchip.c
===================================================================
--- branches/cleanup/ippTools/src/pxchip.c	(revision 17860)
+++ branches/cleanup/ippTools/src/pxchip.c	(revision 17863)
@@ -35,12 +35,6 @@
 
     // check that state is a valid string value
-    if (!(
-            (strncmp(state, "run", 4) == 0)
-            || (strncmp(state, "stop", 5) == 0)
-            || (strncmp(state, "reg", 4) == 0)
-        )
-    ) {
-        psError(PS_ERR_UNKNOWN, false,
-                "invalid chipRun state: %s", state);
+    if (!pxIsValidState(state)) {
+        psError(PS_ERR_UNKNOWN, false, "invalid chipRun state: %s", state);
         return false;
     }
@@ -63,14 +57,9 @@
 
     // check that state is a valid string value
-    if (!(
-            (strncmp(state, "run", 4) == 0)
-            || (strncmp(state, "stop", 5) == 0)
-            || (strncmp(state, "reg", 4) == 0)
-        )
-    ) {
-        psError(PS_ERR_UNKNOWN, false,
-                "invalid chipRun state: %s", state);
+    if (!pxIsValidState(state)) {
+        psError(PS_ERR_UNKNOWN, false, "invalid chipRun state: %s", state);
         return false;
     }
+
 
     psString query = psStringCopy("UPDATE chipRun JOIN rawExp USING(exp_id) SET state = '%s'");
@@ -151,5 +140,5 @@
             0x0, // chip_id
             exp_id,
-            "run",      // state                
+            "new",      // state                
             workdir,
             "dirty",    // workdir_state
@@ -167,2 +156,3 @@
     return psDBLastInsertID(config->dbh);
 }
+
