summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--device.c12
-rw-r--r--device.h2
2 files changed, 14 insertions, 0 deletions
diff --git a/device.c b/device.c
index 11f6cc0..4e25c0e 100644
--- a/device.c
+++ b/device.c
@@ -977,4 +977,16 @@ int cMcliDevice::GetAttribute (const char *attr_name, char *val, int maxret)
}
return ret;
}
+
#endif
+
+int cMcliDevice::SignalStrength(void) const
+{
+ return int(m_ten.s.strength/65536.*100.);
+}
+
+int cMcliDevice::SignalQuality(void) const
+{
+ return int(m_ten.s.snr/65536.*100.);
+}
+
diff --git a/device.h b/device.h
index a8cb426..85d642a 100644
--- a/device.h
+++ b/device.h
@@ -160,6 +160,8 @@ class cMcliDevice:public cDevice
return true;
}
#endif
+ virtual int SignalStrength(void) const;
+ virtual int SignalQuality(void) const;
};
#endif // VDR_MCLI_DEVICE_H