From 3aebe814fbc3059d9c6f6ec188d475d68352be5b Mon Sep 17 00:00:00 2001
From: Ruud Overeem <overeem@astron.nl>
Date: Wed, 29 Nov 2006 22:12:16 +0000
Subject: [PATCH] BugID: 799 PVSS related enhancements.

---
 .../src/DigitalBoardControl/DigitalBoardControl.cc    | 11 ++++++++++-
 .../DigitalBoardControl/DigitalBoardControlDefines.h  |  1 +
 2 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/MAC/APL/StationCU/src/DigitalBoardControl/DigitalBoardControl.cc b/MAC/APL/StationCU/src/DigitalBoardControl/DigitalBoardControl.cc
index 27d50719eee..2c94ad5440f 100644
--- a/MAC/APL/StationCU/src/DigitalBoardControl/DigitalBoardControl.cc
+++ b/MAC/APL/StationCU/src/DigitalBoardControl/DigitalBoardControl.cc
@@ -72,7 +72,8 @@ DigitalBoardControl::DigitalBoardControl(const string&	cntlrName) :
 // for now
 itsClock = globalParameterSet()->getUint32(itsTreePrefix + "sampleClock");
 
-	LOG_INFO_STR("MACProcessScope: " << itsTreePrefix + cntlrName);
+	// TODO
+	LOG_INFO("MACProcessScope: LOFAR.PermSW.iDigBoardCtrl");
 
 	// need port for timers.
 	itsTimerPort = new GCFTimerPort(*this, "TimerPort");
@@ -160,6 +161,14 @@ void DigitalBoardControl::handlePropertySetAnswer(GCFEvent& answer)
 	case F_VCHANGEMSG: {
 		// check which property changed
 		GCFPropValueEvent* pPropAnswer=static_cast<GCFPropValueEvent*>(&answer);
+
+		// don't watch state and error fields.
+		if ((strstr(pPropAnswer->pPropName, PVSSNAME_FSM_STATE) != 0) || 
+			(strstr(pPropAnswer->pPropName, PVSSNAME_FSM_ERROR) != 0) ||
+			(strstr(pPropAnswer->pPropName, PVSSNAME_FSM_LOGMSG) != 0)) {
+			return;
+		}
+
 		if (strstr(pPropAnswer->pPropName, PN_SC_CLOCK) != 0) {
 			itsClock =(static_cast<const GCFPVInteger*>(pPropAnswer->pValue))->getValue();
 			LOG_DEBUG_STR("Received clock change from PVSS, clock is now " << itsClock);
diff --git a/MAC/APL/StationCU/src/DigitalBoardControl/DigitalBoardControlDefines.h b/MAC/APL/StationCU/src/DigitalBoardControl/DigitalBoardControlDefines.h
index ceee8c8f1fd..9e9f1f0e84b 100644
--- a/MAC/APL/StationCU/src/DigitalBoardControl/DigitalBoardControlDefines.h
+++ b/MAC/APL/StationCU/src/DigitalBoardControl/DigitalBoardControlDefines.h
@@ -39,6 +39,7 @@ namespace LOFAR {
 // next lines should be defined somewhere in Common.
 #define PVSSNAME_FSM_STATE			"state"
 #define PVSSNAME_FSM_ERROR			"error"
+#define PVSSNAME_FSM_LOGMSG			"logmsg"
 
 
 }; // StationCU
-- 
GitLab