Index: trunk/psModules/src/camera/pmHDUGenerate.c
===================================================================
--- trunk/psModules/src/camera/pmHDUGenerate.c	(revision 15327)
+++ 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
