setValue

Updates the locally stored value of this data.

Return

true if the locally stored value has been set, false if the requested value could not be stored locally.

Parameters

value

New value


fun setValue(value: Int, formatType: IntFormat, @IntRange(from = 0) offset: Int): Boolean

Set the locally stored value of this data.

See .setValue for details.

Return

true if the locally stored value has been set

Parameters

value

New value for this data

formatType

Integer format type used to transform the value parameter

offset

Offset at which the value should be placed


fun setValue(mantissa: Int, exponent: Int, formatType: FloatFormat, @IntRange(from = 0) offset: Int): Boolean

Set the locally stored value of this data.

See .setValue for details.

Return

true if the locally stored value has been set

Parameters

mantissa

Mantissa for this data

exponent

Exponent value for this data

formatType

Float format type used to transform the value parameter

offset

Offset at which the value should be placed


fun setValue(value: Long, formatType: LongFormat, @IntRange(from = 0) offset: Int): Boolean

Set the locally stored value of this data.

See .setValue for details.

Return

true if the locally stored value has been set

Parameters

value

New value for this data. This allows to send .ValueFormat.FORMAT_UINT32_LE.

formatType

Integer format type used to transform the value parameter

offset

Offset at which the value should be placed


fun setValue(value: Float, formatType: FloatFormat, @IntRange(from = 0) offset: Int): Boolean

Set the locally stored value of this data.

See .setValue for details.

Return

true if the locally stored value has been set

Parameters

value

Float value to be written

formatType

Float format type used to transform the value parameter

offset

Offset at which the value should be placed