Patent attributes
A switching method and an electronic device solve the technical problem of an inflexible switching way of an electronic device. The method includes capturing a first sensing parameter by a first sensing unit, and capturing a second sensing parameter by a second sensing unit, when the electronic device is in a first work state; judging whether the first sensing parameter meets a first preset condition and the second sensing parameter meets a second preset condition, or not; generating a first switching instruction for controlling the electronic device to switch from the first work state to a second work state, when the first sensing parameter meets the first preset condition and the second sensing parameter meets the second preset condition; and controlling the electronic device to switch from the first work state to the second work state, according to the first switching instruction.