diff --git a/platypush/backend/sensor/__init__.py b/platypush/backend/sensor/__init__.py index 3a6bb475..8b31ba1a 100644 --- a/platypush/backend/sensor/__init__.py +++ b/platypush/backend/sensor/__init__.py @@ -29,6 +29,7 @@ class SensorBackend(Backend): def run(self): super().run() + self.logger.info('Initialized {} sensor backend'.format(self.__class__.__name__)) while not self.should_stop(): new_data = self.get_measurement() diff --git a/platypush/backend/sensor/serial.py b/platypush/backend/sensor/serial.py index 4c3fbd32..cda03f1a 100644 --- a/platypush/backend/sensor/serial.py +++ b/platypush/backend/sensor/serial.py @@ -1,21 +1,12 @@ -import serial - from platypush.backend.sensor import SensorBackend from platypush.context import get_plugin class SensorSerialBackend(SensorBackend): - def __init__(self, *args, **kwargs): - super().__init__(*args, **kwargs) - def get_measurement(self): plugin = get_plugin('serial') return plugin.get_data().output - def run(self): - self.logger.info('Initialized serial backend') - super().run() - # vim:sw=4:ts=4:et: