aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/argaze/TobiiGlassesPro2/TobiiData.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/argaze/TobiiGlassesPro2/TobiiData.py b/src/argaze/TobiiGlassesPro2/TobiiData.py
index 86bdf4c..293f460 100644
--- a/src/argaze/TobiiGlassesPro2/TobiiData.py
+++ b/src/argaze/TobiiGlassesPro2/TobiiData.py
@@ -25,6 +25,12 @@ class PresentationTimeStamp():
value: int
@dataclass
+class VideoTimeStamp():
+ """Define video time stamp data (vts)."""
+
+ value: int
+
+@dataclass
class EventSynch():
"""Define event synch data (evts)."""
@@ -111,6 +117,10 @@ class TobiiJsonDataParser():
return PresentationTimeStamp(json_data['pts'])
+ def parse_vts(self, status, json_data):
+
+ return VideoTimeStamp(json_data['vts'])
+
def parse_event_synch(self, status, json_data):
return EventSynch(json_data['evts'])
@@ -176,6 +186,7 @@ class TobiiJsonDataParser():
parse_map = {
'dir': self.parse_dir_sig,
'pts': self.parse_pts,
+ 'vts': self.parse_vts,
'evts': self.parse_event_synch,
'ets': self.parse_event,
'ac': self.parse_accelerometer,
@@ -350,6 +361,7 @@ class TobiiDataStream(threading.Thread):
ts_data_buffer_dict = {
'DirSig': DataStructures.TimeStampedBuffer(),
'PresentationTimeStamp': DataStructures.TimeStampedBuffer(),
+ 'VideoTimeStamp': DataStructures.TimeStampedBuffer(),
'EventSynch': DataStructures.TimeStampedBuffer(),
'Event': DataStructures.TimeStampedBuffer(),
'Accelerometer': DataStructures.TimeStampedBuffer(),