diff data-provider.c @ 169:97112b45b838

Get Sr data logger parameters from configuration file. Code reorganization.
author Daniele Nicolodi <daniele.nicolodi@obspm.fr>
date Fri, 14 Feb 2014 16:58:19 +0100
parents be87c8e78266
children ec81395bf08d
line wrap: on
line diff
--- a/data-provider.c	Fri Feb 14 16:58:08 2014 +0100
+++ b/data-provider.c	Fri Feb 14 16:58:19 2014 +0100
@@ -1,22 +1,23 @@
 #include <ansi_c.h>
 #include <userint.h>
 
+#include "logging.h"
+
 /* message buffer */
 #define DATA_PROVIDER_MSGLEN 256
 #define DATA_PROVIDER_MSGNUM 16
 static char messages[DATA_PROVIDER_MSGLEN][DATA_PROVIDER_MSGNUM];
 static unsigned int messageid = 0;
 
-/* logging function defined in main program */
-extern void logmsg(const char *frmt, ...);
 
 /* message callback */
 void CVICALLBACK MessageCB (void *msg)
 {
 	if (msg != NULL)
-		logmsg(msg);
+		logmessage(INFO, msg);
 }
 
+
 void SendMessage(int threadId, const char *frmt, ...)
 {
 	/* message buffer */