Patent ID: 11862158
Assignee: BEIJING XIAOMI PINECONE ELECTRONICS CO., LTD.
Field: Computer technology (Electrical engineering)
Classification: CPC G | IPC G

Claim 12:
13. A non-transitory computer readable storage medium having computer instructions stored thereon, wherein the computer instructions are configured to cause a computer to execute a method for controlling a device, the method comprising:
collecting audio data where the device is located;
determining whether each target frame of the audio data collected is a first type signal;
in response to the target frame of the audio data being the first type signal, determining an acoustic event type represented by the first type signal; and
controlling the device to execute control instructions corresponding to the acoustic event type;
wherein determining the acoustic event type represented by the first type signal in response to the target frame of the audio data being the first type signal, comprises:
in response to the target frame of the audio data being the first type signal, determining whether the target frame of the audio data is the first of the first type signals;
in response to the target frame of the audio data being the first of the first type signals, determining a first preset number of frames of audio data behind the target frame of the audio data in the audio data as target audio data, wherein, the target audio data comprises a second preset number of first type signals;
in response to the target frame of the audio data not being the first of the first type signals, determining the first preset number of frames of the audio data behind historical audio data corresponding to the first of first type signals in the audio data as the target audio data; and
determining the acoustic event type represented by the first type signal according to the target audio data.