From 4573f9f3e95a0d79c576e3fe0f34023bbf6f0898 Mon Sep 17 00:00:00 2001 From: Marek Siarkowicz Date: Mon, 15 Jun 2015 14:56:52 +0200 Subject: Implement head detection setting. --- parrot_zik/model/version2.py | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'parrot_zik/model') diff --git a/parrot_zik/model/version2.py b/parrot_zik/model/version2.py index 9ef6267..e0bce44 100644 --- a/parrot_zik/model/version2.py +++ b/parrot_zik/model/version2.py @@ -80,6 +80,15 @@ class ParrotZikVersion2(ParrotZikBase): answer = self.resource_manager.get('/api/audio/noise_control/enabled') return self._result_to_bool(answer.audio.noise_control['enabled']) + @property + def head_detection(self): + answer = self.resource_manager.get('/api/system/head_detection/enabled') + return self._result_to_bool(answer.system.head_detection['enabled']) + + @head_detection.setter + def head_detection(self, arg): + self.resource_manager.set('/api/system/head_detection/enabled', arg) + class NoiseControl(object): def __init__(self, type, value): -- cgit v1.2.1