public function setAlert( $type = 'select' )
    {
        $data = json_encode( array( "alert" => $type ) );
        $this->parent->pest()->put( "lights/" . $this->id . "/state", $data );

        $this->parent->update( $this->id );
    }
public function setAlert( $type = 'select' )
    {
        $data = json_encode( array( "alert" => $type ) );
        $this->parent->pest()->put( "lights/" . $this->id . "/state", $data );

        $this->parent->update( $this->id );
    }
public function setAlert ( $ type = 'select' ) { $ data = json_encode ( array ( "alert" => $ type ) ) ; $ this -> parent -> pest ( ) -> put ( "lights/" . $ this -> id . "/state" , $ data ) ; $ this -> parent -> update ( $ this -> id ) ; }
Sets the alert state. 'select' blinks once, 'lselect' blinks repeatedly, 'none' turns off blinking
Sets the alert state . select blinks once lselect blinks repeatedly none turns off blinking