Skip to content

Commit a273cdd

Browse files
author
Daniel Buscombe
committed
Sat Jan 20 19:04:06 MST 2018
1 parent 7453786 commit a273cdd

File tree

9 files changed

+3734
-3682
lines changed

9 files changed

+3734
-3682
lines changed

PyHum/_pyhum_read.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -296,6 +296,9 @@ def read(humfile, sonpath, cs2cs_args="epsg:26949", c=1450.0, draft=0.3, doplot=
296296
elif model=='helix':
297297
model=1
298298
print("Data is from the HELIX series")
299+
elif model=='mega':
300+
model=2
301+
print("Data is from the MEGA series")
299302
# if cog:
300303
# cog = int(cog)
301304
# if cog==1:

PyHum/pyread.c

Lines changed: 1946 additions & 1930 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

PyHum/pyread.o

16 Bytes
Binary file not shown.

PyHum/pyread.pyx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,8 @@ cdef class pyread:
6161
headbytes=68
6262
elif model=='1': ##helix
6363
headbytes=68
64+
elif model=='2': ##mega
65+
headbytes=68
6466
else: #tested so far 998, 1198
6567
headbytes=67
6668

@@ -239,7 +241,7 @@ cdef class pyread:
239241
head.append(struct.unpack('>h', ''.join(self._fread(fid,2,'c')) )[0]) # gps1
240242
head.append(float(struct.unpack('>h', ''.join(self._fread(fid,2,'c')) )[0])/10) # heading_deg
241243

242-
if model==1199 or model==0 or model==1: #onix, helix
244+
if model==1199 or model==0 or model==2: #onix, helix, mega
243245
spacer = self._fread(fid, 1, 'B')
244246
head.append(struct.unpack('>h', ''.join(self._fread(fid,2,'c')) )[0]) # gps2
245247
head.append(float(struct.unpack('>h', ''.join(self._fread(fid,2,'c')) )[0])/10) # speed_ms

PyHum/pyread.so

0 Bytes
Binary file not shown.

PyHum/pyread_single.c

Lines changed: 1779 additions & 1750 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

PyHum/pyread_single.o

80 Bytes
Binary file not shown.

PyHum/pyread_single.pyx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,8 @@ cdef class pyread:
7676
headbytes=68
7777
elif model=='1': ##helix
7878
headbytes=68
79+
elif model=='2': ##mega
80+
headbytes=68
7981
else: #tested so far 998, 1198, 898
8082
headbytes=67
8183

@@ -244,7 +246,7 @@ cdef class pyread:
244246
head.append(struct.unpack('>h', ''.join(self._fread(fid,2,'c')) )[0]) # gps1
245247
head.append(float(struct.unpack('>h', ''.join(self._fread(fid,2,'c')) )[0])/10) # heading_deg
246248

247-
if model==1199 or model==0: ##'onix'
249+
if model==1199 or model==0 or model==2: #onix, helix, mega
248250
spacer = self._fread(fid, 1, 'B')
249251
head.append(struct.unpack('>h', ''.join(self._fread(fid,2,'c')) )[0]) # gps2
250252
head.append(float(struct.unpack('>h', ''.join(self._fread(fid,2,'c')) )[0])/10) # speed_ms

PyHum/pyread_single.so

0 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)