public function setLight( $input )
    {
        $data = json_encode( $input );
        $this->parent->pest()->put( "lights/" . $this->id . "/state", $data );

        $this->parent->update( $this->id );
    }