Commit 4e3e03a4 authored by Matias Guijarro's avatar Matias Guijarro

Merge branch 'ice_traj_python3' into 'master'

icepap: fixed load trajectory for python3

See merge request !1097
parents 60dd72ea 76553127
Pipeline #8526 passed with stages
in 21 minutes and 11 seconds
......@@ -637,8 +637,8 @@ def _vdata_header(data, axis, vdata_type):
PARDATA_HEADER_FORMAT,
0xCAFE, # vdata signature
0, # Version = 0
header_size / 4, # Data offset in dwords
aligned_full_size / 4, # Full vector size in dwords
header_size // 4, # Data offset in dwords
aligned_full_size // 4, # Full vector size in dwords
len(data), # number of values in the vector
dtype, # Data type
0, # no compression
......@@ -646,7 +646,7 @@ def _vdata_header(data, axis, vdata_type):
0,
) # first data value for incremental coding
return numpy.fromstring(
bin_header + data.tostring() + "\0" * (aligned_full_size - full_size),
bin_header + data.tostring() + b"\0" * (aligned_full_size - full_size),
dtype=numpy.int8,
)
......
......@@ -98,7 +98,7 @@ class TrajectoryAxis(Axis):
if name in positions:
axes[axis.name] = axis
positions[axis.name] *= axis.steps_per_unit
if len(positions) > axes:
if len(positions) > len(axes):
raise RuntimeError(
"Axis %s, real axes (%s) are not "
"managed in this controller"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment