refactored new-device.py
refactored new-device.py again