Devices are sorted. Added argument parsing to showsmart.