diff --git a/sensors2osc/sensors2osc/ehealth2osc.py b/sensors2osc/sensors2osc/ehealth2osc.py index 5e05f4d..68a7f7d 100644 --- a/sensors2osc/sensors2osc/ehealth2osc.py +++ b/sensors2osc/sensors2osc/ehealth2osc.py @@ -22,6 +22,7 @@ from __future__ import absolute_import from sensors2osc.common import * +atexit.register(close) def main(): args, osc_sock = init("ehealth2osc") @@ -68,5 +69,4 @@ def main(): if __name__ == '__main__': - atexit.register(close) main() diff --git a/sensors2osc/sensors2osc/ekg2osc.py b/sensors2osc/sensors2osc/ekg2osc.py index 3970a06..0433e99 100644 --- a/sensors2osc/sensors2osc/ekg2osc.py +++ b/sensors2osc/sensors2osc/ekg2osc.py @@ -22,6 +22,7 @@ from __future__ import absolute_import from sensors2osc.common import * +atexit.register(close) def main(): args, osc_sock = init("ekg2osc") @@ -43,5 +44,4 @@ def main(): if __name__ == '__main__': - atexit.register(close) main() diff --git a/sensors2osc/sensors2osc/pulse2osc.py b/sensors2osc/sensors2osc/pulse2osc.py index 3683cce..37be1c2 100644 --- a/sensors2osc/sensors2osc/pulse2osc.py +++ b/sensors2osc/sensors2osc/pulse2osc.py @@ -22,6 +22,8 @@ from __future__ import absolute_import from sensors2osc.common import * +atexit.register(close) + class RingBuffer(object): def __init__(self, length): self.length = length @@ -98,5 +100,4 @@ def main(): if __name__ == '__main__': - atexit.register(close) main() diff --git a/sensors2osc/setup.py b/sensors2osc/setup.py index b42ad6c..f9b4bd8 100644 --- a/sensors2osc/setup.py +++ b/sensors2osc/setup.py @@ -33,6 +33,9 @@ setup( [console_scripts] sensors2osc = sensors2osc.main:main sensorTest = sensors2osc.sensorTest:main + ekg2osc = sensors2osc.ekg2osc:main + pulse2osc = sensors2osc.pulse2osc:main + ehealth2osc = sensors2osc.ehealth2osc:main """, # pypi metadata author = "Stefan Kögl",