Enum modbus::scoped::RegisterDropFunction
[−]
[src]
pub enum RegisterDropFunction<'a> { Zero, Increment, Decrement, Value(u16), Fun(&'a Fn(u16) -> u16), }
Action to perform when the ScopedRegister
is dropped.
Variants
Zero
Set the register to zero value
Increment
Increment the current register value by 1
Decrement
Decrement the current register value by 1
Value(u16)
Set the register value to the given value.
Fun(&'a Fn(u16) -> u16)
Execute the given function on the current value, setting the register with the result value.