def _read_counter_scalar_u_32(task_handle, timeout):
value = ctypes.c_uint()
cfunc = lib_importer.windll.DAQmxReadCounterScalarU32
if cfunc.argtypes is None:
with cfunc.arglock:
if cfunc.argtypes is None:
cfunc.argtypes = [
lib_importer.task_handle, ctypes.c_double,
ctypes.POINTER(ctypes.c_uint), ctypes.POINTER(c_bool32)]
error_code = cfunc(
task_handle, timeout, ctypes.byref(value), None)
check_for_error(error_code)
return value.value
评论列表
文章目录