'Login/start a sesion. Called internally on init'

def _login(self, username, password):

    r = self.session.post(self.url, data={'cmd': 'login', 'usr': username, 'pwd': password}, verify=self.verify)
    if ((r.status_code == 200) and (r.json().get('message') == 'Logged    In')):
        return r.json()
    else:
        print(r.text)
        raise AuthError
