def state_changed(self, new_state):
print "xmpp state change detected for %s from %i to %i" % (self.doorname, self.state, newstate)
def state_changed(self, new_state):
print "xmpp state change detected for %s from %i to %i" % (self.doorname, self.state, newstate)