From c04eb2bc43b1a31b8d961a65f21df85e1a84a7d3 Mon Sep 17 00:00:00 2001
From: Johannes Schumann <johannes.schumann@fau.de>
Date: Sat, 11 Jan 2020 17:48:29 +0100
Subject: [PATCH] Fixed hit time little endian

---
 km3io/daq.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/km3io/daq.py b/km3io/daq.py
index 084e751..e9dba81 100644
--- a/km3io/daq.py
+++ b/km3io/daq.py
@@ -140,11 +140,11 @@ class DAQTimeslices:
             if len(headers) == 0:
                 continue
             superframes = tree[b'vector<KM3NETDAQ::JDAQSuperFrame>']
+            hits_dtype = np.dtype([("pmt", "u1"), ("tdc", "<u4"),
+                                   ("tot", "u1")])
             hits_buffer = superframes[
                 b'vector<KM3NETDAQ::JDAQSuperFrame>.buffer'].lazyarray(
-                    uproot.asjagged(uproot.astable(
-                        uproot.asdtype([("pmt", "u1"), ("tdc", "u4"),
-                                        ("tot", "u1")])),
+                    uproot.asjagged(uproot.astable(uproot.asdtype(hits_dtype)),
                                     skipbytes=6),
                     basketcache=uproot.cache.ThreadSafeArrayCache(
                         TIMESLICE_FRAME_BASKET_CACHE_SIZE))
-- 
GitLab