class Tinkerforge::BrickletMotionDetectorV2

Public Instance Methods

blackout() click to toggle source

Switches off all three blue backlight LEDs.

# File lib/tinderfridge/devices/bricklet_motion_detector_v2/bricklet_motion_detector_v2.rb, line 6
def blackout
  set_indicator(0, 0, 0)
  true
end
state() click to toggle source

Returns the device's state.

Calls superclass method
# File lib/tinderfridge/devices/bricklet_motion_detector_v2/bricklet_motion_detector_v2.rb, line 12
def state
  super.merge(
    'motion_detected' => get_motion_detected == 1,
    'sensitivity'     => get_sensitivity,
    'indicator'       => get_indicator,
  )
end