'Sync the Harmony device with the web service.'

def sync(self):

    import pyharmony
    _LOGGER.debug('Syncing    hub    with    Harmony    servers')
    pyharmony.ha_sync(self._token, self.host, self._port)
    self._config = pyharmony.ha_get_config(self._token, self.host, self._port)
    _LOGGER.debug('Writing    hub    config    to    file:    %s', self._config_path)
    pyharmony.ha_write_config_file(self._config, self._config_path)
