Index: /trunk/psModules/src/camera/pmFPAConstruct.c
===================================================================
--- /trunk/psModules/src/camera/pmFPAConstruct.c	(revision 15476)
+++ /trunk/psModules/src/camera/pmFPAConstruct.c	(revision 15477)
@@ -45,5 +45,5 @@
     psMetadata *cellData = psMetadataLookupMetadata(&status, cells, cellName); // The data for the particular cell
     if (!status || !cellData) {
-        psLogMsg(__func__, PS_LOG_WARN, "Unable to find specs for cell %s: ignored\n", cellName);
+        psWarning("Unable to find specs for cell %s: ignored\n", cellName);
     }
 
@@ -304,5 +304,5 @@
         // Put in the cell data
         if (newCell->config) {
-            psLogMsg(__func__, PS_LOG_WARN, "Overwriting cell data in chip\n");
+            psWarning("Overwriting cell data in chip\n");
             psFree(newCell->config); // Make way!
         }
@@ -1304,5 +1304,5 @@
         const char *chipName = componentsItem->name; // Name of the chip
         if (componentsItem->type != PS_DATA_STRING) {
-            psLogMsg(__func__, PS_LOG_WARN, "Element %s in FPA within the camera configuration is not of "
+            psWarning("Element %s in FPA within the camera configuration is not of "
                      "type STR (type=%x) --- ignored.\n", chipName, componentsItem->type);
             continue;
Index: /trunk/psModules/src/camera/pmFPAFlags.c
===================================================================
--- /trunk/psModules/src/camera/pmFPAFlags.c	(revision 15476)
+++ /trunk/psModules/src/camera/pmFPAFlags.c	(revision 15477)
@@ -136,7 +136,7 @@
 
     for (int i = 0; i < fpa->chips->n; i++) {
-	pmChip *chip = fpa->chips->data[i];
-	if (chip == NULL) continue;
-	if (chip->data_exists) return true;
+        pmChip *chip = fpa->chips->data[i];
+        if (chip == NULL) continue;
+        if (chip->data_exists) return true;
     }
     return false;
@@ -170,33 +170,33 @@
 
     if (view->chip == -1) {
-	bool exists = pmFPACheckDataStatus (fpa);
-	return exists;
+        bool exists = pmFPACheckDataStatus (fpa);
+        return exists;
     }
 
     if (view->chip >= fpa->chips->n) {
-	psError(PS_ERR_IO, true, "Requested chip == %d >= fpa->chips->n == %ld", view->chip, fpa->chips->n);
-	return false;
+        psError(PS_ERR_IO, true, "Requested chip == %d >= fpa->chips->n == %ld", view->chip, fpa->chips->n);
+        return false;
     }
     pmChip *chip = fpa->chips->data[view->chip];
 
     if (view->cell == -1) {
-	bool exists = pmChipCheckDataStatus (chip);
-	return exists;
+        bool exists = pmChipCheckDataStatus (chip);
+        return exists;
     }
 
     if (view->cell >= chip->cells->n) {
-	psError(PS_ERR_IO, true, "Requested cell == %d >= chip->cells->n == %ld", view->cell, chip->cells->n);
-	return false;
+        psError(PS_ERR_IO, true, "Requested cell == %d >= chip->cells->n == %ld", view->cell, chip->cells->n);
+        return false;
     }
     pmCell *cell = chip->cells->data[view->cell];
 
     if (view->readout == -1) {
-	bool exists = pmCellCheckDataStatus (cell);
-	return exists;
+        bool exists = pmCellCheckDataStatus (cell);
+        return exists;
     }
 
     if (view->readout >= cell->readouts->n) {
-	psError(PS_ERR_IO, true, "Requested readout == %d >= cell->readouds->n == %ld", view->readout, cell->readouts->n);
-	return false;
+        psError(PS_ERR_IO, true, "Requested readout == %d >= cell->readouds->n == %ld", view->readout, cell->readouts->n);
+        return false;
     }
     pmReadout *readout = cell->readouts->data[view->readout];
@@ -290,9 +290,9 @@
     psArray *chips = fpa->chips;        // Component chips
     if (chips == NULL) {
-        psLogMsg(__func__, PS_LOG_WARN, "WARNING: fpa->chips == NULL\n");
+        psWarning("WARNING: fpa->chips == NULL\n");
         return(0);
     }
     if ((chipNum >= chips->n) || (NULL == (pmChip *) chips->data[chipNum])) {
-        psLogMsg(__func__, PS_LOG_WARN, "WARNING: the specified chip (%d) does not exist.\n", chipNum);
+        psWarning("WARNING: the specified chip (%d) does not exist.\n", chipNum);
         return(0);
     }
Index: /trunk/psModules/src/camera/pmFPAMosaic.c
===================================================================
--- /trunk/psModules/src/camera/pmFPAMosaic.c	(revision 15476)
+++ /trunk/psModules/src/camera/pmFPAMosaic.c	(revision 15477)
@@ -704,6 +704,6 @@
     psArray *readouts = cell->readouts; // The array of readouts
     if (readouts->n > 1) {
-        psLogMsg(__func__, PS_LOG_WARN, "Cell contains more than one readout (%ld) --- only the first will "
-                 "be mosaicked.\n", readouts->n);
+        psWarning("Cell contains more than one readout (%ld) --- only the first will be mosaicked.\n",
+                  readouts->n);
     }
     pmReadout *readout = readouts->data[0]; // The only readout we'll bother with
@@ -754,15 +754,15 @@
     int x0Target = psMetadataLookupS32(&mdok, targetCell->concepts, "CELL.X0");
     if (!mdok) {
-        psLogMsg(__func__, PS_LOG_WARN, "CELL.X0 is not set for the target cell; assuming 0.\n");
+        psWarning("CELL.X0 is not set for the target cell; assuming 0.\n");
         FIX_CONCEPT(targetCell->concepts, "CELL.X0", S32, 0);
     }
     int y0Target = psMetadataLookupS32(&mdok, targetCell->concepts, "CELL.Y0");
     if (!mdok) {
-        psLogMsg(__func__, PS_LOG_WARN, "CELL.Y0 is not set for the target cell; assuming 0.\n");
+        psWarning("CELL.Y0 is not set for the target cell; assuming 0.\n");
         FIX_CONCEPT(targetCell->concepts, "CELL.Y0", S32, 0);
     }
     int xParityTarget = psMetadataLookupS32(&mdok, targetCell->concepts, "CELL.XPARITY");
     if (!mdok || (xParityTarget != -1 && xParityTarget != 1)) {
-        psLogMsg(__func__, PS_LOG_WARN, "CELL.XPARITY is not set for the target cell; assuming 1.\n");
+        psWarning("CELL.XPARITY is not set for the target cell; assuming 1.\n");
         FIX_CONCEPT(targetCell->concepts, "CELL.XPARITY", S32, 1);
         xParityTarget = 1;
@@ -770,5 +770,5 @@
     int yParityTarget = psMetadataLookupS32(&mdok, targetCell->concepts, "CELL.YPARITY");
     if (!mdok || (yParityTarget != -1 && yParityTarget != 1)) {
-        psLogMsg(__func__, PS_LOG_WARN, "CELL.YPARITY is not set for the target cell; assuming 1.\n");
+        psWarning("CELL.YPARITY is not set for the target cell; assuming 1.\n");
         FIX_CONCEPT(targetCell->concepts, "CELL.YPARITY", S32, 1);
         yParityTarget = 1;
@@ -863,25 +863,25 @@
     int x0Target = psMetadataLookupS32(&mdok, targetChip->concepts, "CHIP.X0");
     if (!mdok) {
-        psLogMsg(__func__, PS_LOG_WARN, "CHIP.X0 is not set for the target chip; assuming 0.\n");
+        psWarning("CHIP.X0 is not set for the target chip; assuming 0.\n");
         FIX_CONCEPT(targetChip->concepts, "CHIP.X0", S32, 0);
     }
     int y0Target = psMetadataLookupS32(&mdok, targetChip->concepts, "CHIP.Y0");
     if (!mdok) {
-        psLogMsg(__func__, PS_LOG_WARN, "CHIP.Y0 is not set for the target chip; assuming 0.\n");
+        psWarning("CHIP.Y0 is not set for the target chip; assuming 0.\n");
         FIX_CONCEPT(targetChip->concepts, "CHIP.Y0", S32, 0);
     }
     x0Target += psMetadataLookupS32(&mdok, targetCell->concepts, "CELL.X0");
     if (!mdok) {
-        psLogMsg(__func__, PS_LOG_WARN, "CELL.X0 is not set for the target cell; assuming 0.\n");
+        psWarning("CELL.X0 is not set for the target cell; assuming 0.\n");
         FIX_CONCEPT(targetCell->concepts, "CELL.X0", S32, 0);
     }
     y0Target += psMetadataLookupS32(&mdok, targetCell->concepts, "CELL.Y0");
     if (!mdok) {
-        psLogMsg(__func__, PS_LOG_WARN, "CELL.Y0 is not set for the target cell; assuming 0.\n");
+        psWarning("CELL.Y0 is not set for the target cell; assuming 0.\n");
         FIX_CONCEPT(targetCell->concepts, "CELL.Y0", S32, 0);
     }
     int xParityChipTarget = psMetadataLookupS32(&mdok, targetChip->concepts, "CHIP.XPARITY");
     if (!mdok || (xParityChipTarget != -1 && xParityChipTarget != 1)) {
-        psLogMsg(__func__, PS_LOG_WARN, "CHIP.XPARITY is not set for the target chip; assuming 1.\n");
+        psWarning("CHIP.XPARITY is not set for the target chip; assuming 1.\n");
         FIX_CONCEPT(targetChip->concepts, "CHIP.XPARITY", S32, 1);
         xParityChipTarget = 1;
@@ -889,5 +889,5 @@
     int yParityChipTarget = psMetadataLookupS32(&mdok, targetChip->concepts, "CHIP.YPARITY");
     if (!mdok || (yParityChipTarget != -1 && yParityChipTarget != 1)) {
-        psLogMsg(__func__, PS_LOG_WARN, "CHIP.YPARITY is not set for the target chip; assuming 1.\n");
+        psWarning("CHIP.YPARITY is not set for the target chip; assuming 1.\n");
         FIX_CONCEPT(targetChip->concepts, "CHIP.YPARITY", S32, 1);
         yParityChipTarget = 1;
@@ -895,5 +895,5 @@
     int xParityCellTarget = psMetadataLookupS32(&mdok, targetCell->concepts, "CELL.XPARITY");
     if (!mdok || (xParityCellTarget != -1 && xParityCellTarget != 1)) {
-        psLogMsg(__func__, PS_LOG_WARN, "CELL.XPARITY is not set for the target cell; assuming 1.\n");
+        psWarning("CELL.XPARITY is not set for the target cell; assuming 1.\n");
         FIX_CONCEPT(targetCell->concepts, "CELL.XPARITY", S32, 1);
         xParityCellTarget = 1;
@@ -901,5 +901,5 @@
     int yParityCellTarget = psMetadataLookupS32(&mdok, targetCell->concepts, "CELL.YPARITY");
     if (!mdok || (yParityCellTarget != -1 && yParityCellTarget != 1)) {
-        psLogMsg(__func__, PS_LOG_WARN, "CELL.YPARITY is not set for the target cell; assuming 1.\n");
+        psWarning("CELL.YPARITY is not set for the target cell; assuming 1.\n");
         FIX_CONCEPT(targetCell->concepts, "CELL.YPARITY", S32, 1);
         yParityCellTarget = 1;
@@ -1334,10 +1334,10 @@
     pmHDU *sourceHDU = pmHDUGetHighest(source, firstSourceChip, firstSourceCell); // The HDU for the source
     if (!sourceHDU) {
-        psLogMsg(__func__, PS_LOG_WARN, "Unable to find HDU in source FPA; unable to copy headers.\n");
+        psWarning("Unable to find HDU in source FPA; unable to copy headers.\n");
         return false;
     }
     pmHDU *targetHDU = pmHDUGetHighest(target, targetChip, targetCell); // The HDU for the target
     if (!targetHDU) {
-        psLogMsg(__func__, PS_LOG_WARN, "Unable to find HDU in target FPA; unable to copy headers.\n");
+        psWarning("Unable to find HDU in target FPA; unable to copy headers.\n");
         return false;
     }
Index: /trunk/psModules/src/camera/pmHDU.c
===================================================================
--- /trunk/psModules/src/camera/pmHDU.c	(revision 15476)
+++ /trunk/psModules/src/camera/pmHDU.c	(revision 15477)
@@ -119,5 +119,5 @@
 
     if (*images) {
-        psLogMsg(__func__, PS_LOG_WARN, "HDU %s has already been read --- overwriting.\n", hdu->extname);
+        psWarning("HDU %s has already been read --- overwriting.\n", hdu->extname);
         psFree(*images);                // Blow away anything existing
     }
@@ -167,5 +167,5 @@
 
     if (!images && !hdu->header) {
-        psLogMsg(__func__, PS_LOG_WARN, "Nothing to write for HDU %s\n", hdu->extname);
+        psWarning("Nothing to write for HDU %s\n", hdu->extname);
         return false;
     }
Index: /trunk/psModules/src/camera/pmHDUGenerate.c
===================================================================
--- /trunk/psModules/src/camera/pmHDUGenerate.c	(revision 15476)
+++ /trunk/psModules/src/camera/pmHDUGenerate.c	(revision 15477)
@@ -134,6 +134,5 @@
     psMetadataItem *biassecItem = psMetadataLookup(cell->concepts, "CELL.BIASSEC"); // Bias sections
     if (!biassecItem) {
-        psLogMsg(__func__, PS_LOG_WARN, "CELL.BIASSEC has not been initialised in cell --- "
-                 "ignored.\n");
+        psWarning("CELL.BIASSEC has not been initialised in cell --- ignored.\n");
         return false;
     }
@@ -146,5 +145,5 @@
     if (!mdok || (cellreaddir != 1 && cellreaddir != 2)) {
         // Probably unnecessary, but just in case....
-        psLogMsg(__func__, PS_LOG_WARN, "CELL.READDIR is not set in cell --- ignored.\n");
+        psWarning("CELL.READDIR is not set in cell --- ignored.\n");
         return false;
     }
@@ -152,5 +151,5 @@
         *readdir = cellreaddir;
     } else if (*readdir != cellreaddir) {
-        psLogMsg(__func__, PS_LOG_WARN, "CELL.READDIR does not match read direction for HDU --- ignored.\n");
+        psWarning("CELL.READDIR does not match read direction for HDU --- ignored.\n");
         return false;
     }
@@ -255,6 +254,5 @@
         psMetadataItem *trimsecItem = psMetadataLookup(cell->concepts, "CELL.TRIMSEC"); // Item with trimsec
         if (!trimsecItem || trimsecItem->type != PS_DATA_REGION) {
-            psLogMsg(__func__, PS_LOG_WARN, "CELL.TRIMSEC has not been initialised in cell --- "
-                     "ignored.\n");
+            psWarning("CELL.TRIMSEC has not been initialised in cell --- ignored.\n");
             continue;
         }
@@ -264,5 +262,5 @@
         if (!mdok || (cellreaddir != 1 && cellreaddir != 2)) {
             // Probably unnecessary, but just in case....
-            psLogMsg(__func__, PS_LOG_WARN, "CELL.READDIR is not set in cell --- ignored.\n");
+            psWarning("CELL.READDIR is not set in cell --- ignored.\n");
             continue;
         }
@@ -270,5 +268,5 @@
             readdir = cellreaddir;
         } else if (readdir != cellreaddir) {
-            psLogMsg(__func__, PS_LOG_WARN, "CELL.READDIR for cells within the HDU do not match!\n");
+            psWarning("CELL.READDIR for cells within the HDU do not match!\n");
             cellreaddir = readdir;
         }
@@ -282,10 +280,10 @@
         if (readout->mask &&
                 (readout->mask->numCols != image->numCols || readout->mask->numRows != image->numRows)) {
-            psLogMsg(__func__, PS_LOG_WARN, "Image and mask have different sizes (%dx%d vs %dx%d)!\n",
+            psWarning("Image and mask have different sizes (%dx%d vs %dx%d)!\n",
                      image->numCols, image->numRows, readout->mask->numCols, readout->mask->numRows);
         }
         if (readout->weight &&
                 (readout->weight->numCols != image->numCols || readout->weight->numRows != image->numRows)) {
-            psLogMsg(__func__, PS_LOG_WARN, "Image and weight have different sizes (%dx%d vs %dx%d)!\n",
+            psWarning("Image and weight have different sizes (%dx%d vs %dx%d)!\n",
                      image->numCols, image->numRows, readout->weight->numCols, readout->weight->numRows);
         }
@@ -318,6 +316,6 @@
 
     if (previous != current) {
-        psLogMsg(__func__, PS_LOG_WARN, "Images within the HDU are of different types "
-                 "(%x vs %x) --- promoting\n", previous, current);
+        psWarning("Images within the HDU are of different types (%x vs %x) --- promoting\n",
+                  previous, current);
         return PS_MAX(previous, current);
     }
@@ -336,5 +334,5 @@
     if (source->numCols != region->x1 - region->x0 || source->numRows != region->y1 - region->y0) {
         psString regionString = psRegionToString(*region);
-        psLogMsg(__func__, PS_LOG_WARN, "Image size (%dx%d) does not match region (%s).\n",
+        psWarning("Image size (%dx%d) does not match region (%s).\n",
                  source->numCols, source->numRows, regionString);
         psFree(regionString);
@@ -475,6 +473,6 @@
 
                 if (biassecs->n != readout->bias->n) {
-                    psLogMsg(__func__, PS_LOG_WARN, "Number of bias sections (%ld) and number of biases (%ld)"
-                             " do not match.\n", biassecs->n, readout->bias->n);
+                    psWarning("Number of bias sections (%ld) and number of biases (%ld) do not match.\n",
+                              biassecs->n, readout->bias->n);
                 }
                 psListIterator *biasIter = psListIteratorAlloc(readout->bias, PS_LIST_HEAD, false); // Iteratr
