class SpheroPwn::Commands::IsPageBlank::Response

The response to a boot main application command.

Attributes

is_blank[R]

@return {Boolean} true if the flash memory page is blank

is_blank?[R]

@return {Boolean} true if the flash memory page is blank

Public Class Methods

new(code_byte, sequence_byte, data_bytes) click to toggle source

@see {SpheroPwn::Response#initialize}

Calls superclass method SpheroPwn::Response::new
# File lib/sphero_pwn/commands/is_page_blank.rb, line 27
def initialize(code_byte, sequence_byte, data_bytes)
  super

  if code == :ok
    @is_blank = data_bytes[0] > 0
  else
    @is_blank = nil
  end
end