simlified update logic for devices, still buggy. threading problem?
added kill command