def METHOD_NAME(self, manual, relais, manual_control):
    newmanual = manual
    newmanual_control = manual_control
    try:
        at = str(urllib.request.urlopen("http://" +
                                        str(self._device_pbip)
                                        + "/status",
                                        timeout=3).read().decode("utf-8"))
    except Exception as e1:
        log.warning("Shelly button ch (%d) %s Fehlermeldung: %s "
                    % (self.device_nummer, self._device_pbip, str(e1)))
        return newmanual, newmanual_control
    a = json.loads(at)
    with open(self._basePath+'/ramdisk/smarthome_device_ret' +
              str(self.device_nummer) + '_shelly_bp', 'w') as f:
        f.write(str(a))
    self.oldevent_cnt = self.event_cnt
    self.oldevent = self.event
    self.event_cnt = int(a['inputs'][0]['event_cnt'])
    self.event = str(a['inputs'][0]['event'])
    if (self.oldevent == 'none'):
        return newmanual, newmanual_control
    if ((self.event == self.oldevent) and
       (self.event_cnt == self.oldevent_cnt)):
        return newmanual, newmanual_control
    log.info("Shelly button pressed (%d) %s %s"
             % (self.device_nummer, self._device_pbip, self.event))
    # im automatic modus -> ein mal Drücken wechselen auf manual
    if (manual == 0):
        newmanual = 1
        return newmanual, newmanual_control
    # im manual modus  -> ein mal Drücken wechselen  zwischen on und off
    if (self.event == 'S'):
        if (manual_control == 1):
            newmanual_control = 0
        else:
            newmanual_control = 1
        return newmanual, newmanual_control
    # im manual modus  -> mehrmals drücken wechselen auf automat
    newmanual = 0
    return newmanual, newmanual_control