erase method

Future<void> erase(
  1. Duration timeout
)

Erases the image in the inactive slot.

There is no need to call this before uploading an image, it will be overwritten automatically.

Implementation

Future<void> erase(Duration timeout) {
  return execute(
    Message(
      op: Operation.write,
      group: _imgGroup,
      id: _imgCmdErase,
      flags: 0,
      data: CborMap({}),
    ),
    timeout,
  ).unwrap();
}