cleanup
device loading from xml