modify device control code

modify device control code