integrate device info with idiom

clear out some bugs