iot-logic/src/utils/platform.py

19 lines
633 B
Python
Raw Normal View History

2021-11-22 20:31:36 +01:00
from config import PLATFORM
2021-11-19 02:18:58 +01:00
2021-11-22 20:31:36 +01:00
if PLATFORM == 'raspberry':
2021-11-19 02:18:58 +01:00
from birbnetes_iot_platform_raspberry import BirbnetesIoTPlatformStatusDriver, BirbnetesIoTPlatformRecordDriver, \
BirbnetesIoTPlatformPlaybackDriver
2021-11-22 20:31:36 +01:00
elif PLATFORM == 'emulator':
2021-11-19 02:18:58 +01:00
from birbnetes_iot_platform_emulator import BirbnetesIoTPlatformStatusDriver, BirbnetesIoTPlatformRecordDriver, \
BirbnetesIoTPlatformPlaybackDriver
else:
2021-11-22 20:31:36 +01:00
raise ModuleNotFoundError(f"Could not load platform driver for {PLATFORM}")
2021-11-19 02:18:58 +01:00
__all__ = [
'BirbnetesIoTPlatformStatusDriver',
'BirbnetesIoTPlatformRecordDriver',
'BirbnetesIoTPlatformPlaybackDriver'
]