(
            scale_name, prescaled_vals, scaled_vals,
            pre_scaled_units=UnitsPreScaled.VOLTS, scaled_units=None)
return scale
Creates a custom scale that maps an list of pre-scaled values to
        an list of corresponding scaled values. NI-DAQmx applies linear
        interpolation to values that fall between the values in the
        table. Read operations clip scaled samples that are outside the
        maximum and minimum scaled values found in the table. Write
        operations generate errors for samples that are outside the
        minimum and maximum scaled values found in the table.

        Args:
            scale_name (str): Specifies the name of the scale to create.
            prescaled_vals (List[float]): Is the list of pre-scaled
                values that map to the values in "scaled_vals".
            scaled_vals (List[float]): Is the list of scaled values that
                map to the values in "prescaled_vals".
            pre_scaled_units (Optional[nidaqmx.constants.UnitsPreScaled]):
                Is the units of the values to scale.
            scaled_units (Optional[str]): Is the units to use for the
                scaled value. You can use an arbitrary string. NI-DAQmx
                uses the units to label a graph or chart.
        Returns:
            nidaqmx.scale.Scale: 
            
            Indicates an object that represents the created custom scale.
Creates a custom scale that maps an list of pre-scaled values to
        an list of corresponding scaled values. NI-DAQmx applies linear
        interpolation to values that fall between the values in the
        table. Read operations clip scaled samples that are outside the
        maximum and minimum scaled values found in the table. Write
        operations generate errors for samples that are outside the
        minimum and maximum scaled values found in the table.
Creates a custom scale that maps an list of pre - scaled values to an list of corresponding scaled values . NI - DAQmx applies linear interpolation to values that fall between the values in the table . Read operations clip scaled samples that are outside the maximum and minimum scaled values found in the table . Write operations generate errors for samples that are outside the minimum and maximum scaled values found in the table .
def create_table_scale(
            scale_name, prescaled_vals, scaled_vals,
            pre_scaled_units=UnitsPreScaled.VOLTS, scaled_units=None):
        """
        Creates a custom scale that maps an list of pre-scaled values to
        an list of corresponding scaled values. NI-DAQmx applies linear
        interpolation to values that fall between the values in the
        table. Read operations clip scaled samples that are outside the
        maximum and minimum scaled values found in the table. Write
        operations generate errors for samples that are outside the
        minimum and maximum scaled values found in the table.

        Args:
            scale_name (str): Specifies the name of the scale to create.
            prescaled_vals (List[float]): Is the list of pre-scaled
                values that map to the values in "scaled_vals".
            scaled_vals (List[float]): Is the list of scaled values that
                map to the values in "prescaled_vals".
            pre_scaled_units (Optional[nidaqmx.constants.UnitsPreScaled]):
                Is the units of the values to scale.
            scaled_units (Optional[str]): Is the units to use for the
                scaled value. You can use an arbitrary string. NI-DAQmx
                uses the units to label a graph or chart.
        Returns:
            nidaqmx.scale.Scale: 
            
            Indicates an object that represents the created custom scale.
        """
        scale = Scale(scale_name)

        if prescaled_vals is None:
            prescaled_vals = []

        if scaled_vals is None:
            scaled_vals = []

        prescaled_vals = numpy.float64(prescaled_vals)
        scaled_vals = numpy.float64(scaled_vals)

        cfunc = lib_importer.windll.DAQmxCreateTableScale
        if cfunc.argtypes is None:
            with cfunc.arglock:
                if cfunc.argtypes is None:
                    cfunc.argtypes = [
                        ctypes_byte_str,
                        wrapped_ndpointer(dtype=numpy.float64,
                                          flags=('C', 'W')),
                        ctypes.c_uint,
                        wrapped_ndpointer(dtype=numpy.float64,
                                          flags=('C', 'W')),
                        ctypes.c_uint, ctypes.c_int, ctypes_byte_str]

        error_code = cfunc(
            scale_name, prescaled_vals, len(prescaled_vals), scaled_vals,
            len(scaled_vals), pre_scaled_units.value, scaled_units)
        check_for_error(error_code)

        return scale
def create_table_scale ( scale_name , prescaled_vals , scaled_vals , pre_scaled_units = UnitsPreScaled . VOLTS , scaled_units = None ) : scale = Scale ( scale_name ) if prescaled_vals is None : prescaled_vals = [ ] if scaled_vals is None : scaled_vals = [ ] prescaled_vals = numpy . float64 ( prescaled_vals ) scaled_vals = numpy . float64 ( scaled_vals ) cfunc = lib_importer . windll . DAQmxCreateTableScale if cfunc . argtypes is None : with cfunc . arglock : if cfunc . argtypes is None : cfunc . argtypes = [ ctypes_byte_str , wrapped_ndpointer ( dtype = numpy . float64 , flags = ( 'C' , 'W' ) ) , ctypes . c_uint , wrapped_ndpointer ( dtype = numpy . float64 , flags = ( 'C' , 'W' ) ) , ctypes . c_uint , ctypes . c_int , ctypes_byte_str ] error_code = cfunc ( scale_name , prescaled_vals , len ( prescaled_vals ) , scaled_vals , len ( scaled_vals ) , pre_scaled_units . value , scaled_units ) check_for_error ( error_code ) return scale