Smart home switch control system and method based on voice recognition

By adopting ZigBee and WiFi technology, speech recognition module and federated learning security module in smart home systems, combined with Berouti spectrum subtraction algorithm and Wiener filter, the problems of low speech recognition accuracy and weak security protection in a noisy environment of smart home systems are solved, achieving higher speech recognition accuracy and security.

CN120143711APending Publication Date: 2025-06-13深圳市微著智能有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510315151.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-18
Publication Date
2025-06-13

AI Technical Summary

Technical Problem

The existing smart home systems have low voice recognition accuracy and weak security protection in noisy environments, resulting in poor user experience.

Method used

ZigBee and WiFi technology are used to build the home intranet and external network, combining the voice recognition module and the federated learning security module, and improving the speech recognition accuracy through the Berouti spectrum subtraction algorithm and Wiener filter, and encrypting and storing voiceprint features locally to enhance security.

Benefits of technology

It improves the accuracy and security of speech recognition, enhances the intelligence of the system and user experience, and solves the recognition accuracy and security issues in noisy environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120143711A_ABST
    Figure CN120143711A_ABST
Patent Text Reader

Abstract

The invention relates to an intelligent home switch control system and method based on voice recognition. The intelligent home switch control system comprises a home intranet, a home network block and an external network. According to the smart home switch control system and method based on voice recognition, a home intranet is established by adopting a ZigBee technology, data communication between the home intranet and an OneNET cloud platform extranet is realized by utilizing a WiFi technology, and a user can check real-time environment data and remotely control household appliances through a computer and a mobile phone. Meanwhile, under the condition that a mobile phone cannot be used, voice control over household appliances is achieved through the voice recognition technology, the system is made to be more intelligent, meanwhile, the Berroute spectral subtraction line and the Wiener filter are combined, noise is reduced more efficiently, the sound quality is improved, the voice recognition rate is increased, the federal learning safety module is additionally arranged, and the safety of the system is improved. A federal learning framework is adopted, user voiceprint features are locally encrypted and stored, and original data leakage and replay attack stealing are avoided.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of smart home voice interaction, and specifically provides a smart home switch control system and method based on voice recognition. Background Art

[0002] Although the current modern smart home has developed rapidly, voice recognition technology has become increasingly mature in the modern smart home market and has also achieved certain results in practical applications, there are still many core problems that have not been solved. For example, the installation cost of modern smart homes is high, the design standards of control systems are diverse, and the main problems such as recognition accuracy, recognition security, and recognition speed in a noisy environment at home result in an unsatisfactory user experience, and there is still a considerable gap from the ideal intelligent level.

[0003] At the same time, the existing technology has the following defects:

[0004] Insufficient voice recognition accuracy: Traditional solutions rely on single audio signal processing, and the recognition rate is less than 90% in a noisy environment;

[0005] Weak security protection: Voiceprint features are stored in plaintext and are easily stolen by replay attacks. Summary of the Invention

[0006] (1) Technical problems to be solved

[0007] To solve the above technical problems, the present invention provides a smart home switch control system and method based on voice recognition.

[0008] (2) Technical solutions

[0009] Based on this, according to one aspect of the present invention, there is provided a smart home switch control system based on voice recognition, including a home intranet, a home network block, and an external network. The home intranet uses a ZigBee network to receive and transmit various types of home environment data information collected by sensors and control instructions issued by the user terminal; the external network uses a WiFi network to transmit the collected home environment data information and control instructions issued by the user terminal to the cloud platform;

[0010] The described home switch control system includes an environmental data acquisition module, a home device control module, a security alarm module, a voice recognition module, a home gateway module, and a federated learning security module. The environmental data acquisition module consists of ZigBee terminal nodes and various sensors. The various sensors are used to collect various environmental data information in the room, such as temperature and humidity, light intensity, PM2.5 concentration, etc. The collected environmental data information is transmitted by the ZigBee terminal node to the STM32 main controller connected to the ZigBee coordinator. The STM32 main controller analyzes and processes the data according to the data threshold and performs corresponding actions.

[0011] The voice recognition module collects the voice control instructions of the user, converts them into corresponding data information, and locally encrypts and stores the voiceprint features through the federated learning security module, and sends them to the STM32 main controller through the serial port. Finally, the STM32 main controller performs corresponding actions according to the data information, achieving the purpose of human-computer interaction.

[0012] Preferably, the home device control module consists of ZigBee terminal nodes and various execution controllers. The various execution controllers are divided into a relay module, an infrared module, and a motor module, which respectively control socket-type home appliances (such as electric lights, humidifiers, etc.), infrared-type home appliances (such as air conditioners, televisions, etc.), and intelligent curtains.

[0013] Preferably, the security alarm module consists of ZigBee terminal nodes, a smoke sensor, a passive infrared sensor, and an alarm device. For example, when a fire, gas leakage, theft, etc. occur at home, the sensor will detect relevant gas factors and infrared rays. At this time, the alarm device will give an alarm, and at the same time, the alarm information will be uploaded to the cloud platform through the WiFi module, so that corresponding processing can be made in time when the user is not at home.

[0014] Preferably, the home gateway module consists of an STM32 main controller, a ZigBee coordinator, a WiFi module, etc. The indoor environmental data information collected by the ZigBee terminal node is transmitted to the ZigBee coordinator, and the ZigBee coordinator then transmits the data information to the STM32 main controller for processing, and then transmits the data information to the cloud platform through the WiFi module. At the same time, it can also receive the control commands issued by the user terminal through the cloud platform through the WiFi module, realizing two-way data transmission. The user can view the real-time indoor environmental situation through a computer and a mobile phone, and can also remotely control the operation of indoor home appliances.

[0015] Preferably, the voice recognition module uses a CI1103 intelligent voice recognition IC. The voice recognition module internally integrates an A / D, D / A converter, a microphone, and a Wiener filter. The Berouti spectral subtraction algorithm is burned into the voice recognition module.

[0016] Preferably, the specific formula of the Berouti spectral subtraction algorithm is as follows:

[0017]

[0018] Where represents the spectrum of the enhanced speaker voice, represents the speaker voice signal spectrum of the noisy signal, represents the signal spectrum of the noise estimation, and the value of α 0 is 4.5;

[0019] The representation of each segment SNR of the i-th noise signal frame (SNR i ) is as follows:

[0020]

[0021] Where b is the starting point of the i-th noise signal frame and e is the ending point.

[0022] Preferably, the parameter factor θ is defined as follows:

[0023]

[0024] The value of the parameter β is defined as 0.01, and the value of γ is defined as 1.5.

[0025] Preferably, the channels of the ZigBee terminal node and the WiFi network are selected from non-overlapping channels 15, 20, 25, and 26 to reduce or eliminate the co-frequency interference with Wi-Fi, thereby enhancing network security and reducing the bit error rate.

[0026] Preferably, the federated learning security module adopts a federated learning framework to encrypt and store user voiceprint features locally.

[0027] According to another aspect of the present invention, a smart home switch control method based on speech recognition is provided, and the control method is as follows:

[0028] Step S1: After the STM32 main controller is powered on, the system is initialized, and each functional module such as the ZigBee module, the speech recognition module, and the WiFi module is initialized;

[0029] Step S2: After completion, the baud rate of the serial port of the STM32 main controller is set to 115200 bit / s;

[0030] Step S3: When the WiFi module or the voice recognition module receives a control command from the user terminal, the corresponding serial port will perform an interrupt response and judge it. If it is judged to be a device control instruction, the received control instruction will be sent to the STM32 main controller;

[0031] Step S4: The STM32 main controller parses and processes the control instruction, then sends it to the ZigBee coordinator through the serial port, and then the ZigBee coordinator distributes it to the corresponding ZigBee nodes. The actuator module connected to the ZigBee node performs corresponding actions according to the control command.

[0032] (III) Beneficial effects

[0033] Compared with the prior art, the present invention provides a smart home switch control system and method based on voice recognition, having the following beneficial effects:

[0034] The smart home switch control system and method based on voice recognition uses the ZigBee technology to build a home internal network, and uses the WiFi technology to realize the data communication between the home internal network and the OneNET cloud platform external network. Users can view real-time environmental data and remotely control home appliances through a computer and a mobile phone. At the same time, in the case where a mobile phone cannot be used, the voice recognition technology is used to realize the voice control of home appliances, making the system more intelligent. At the same time, the Berouti spectral subtraction method is combined with the Wiener filter to more efficiently reduce noise, thereby improving the sound quality, increasing the voice recognition rate, and adding a federated learning security module. The federated learning framework is used to locally encrypt and store user voiceprint features to avoid the leakage of raw data and the stealing of replay attacks. Description of the drawings

[0035] Figure 1 It is the system block diagram of the present invention;

[0036] Figure 2 It is the algorithm flow chart of the Berouti spectral subtraction method and the Wiener filter of the present invention;

[0037] Figure 3 It is the waveform diagram and spectrogram of the pure voice signal of the present invention;

[0038] Figure 4 It is the waveform diagram and spectrogram of the noisy voice signal of the present invention;

[0039] Figure 5 It is the waveform diagram and spectrogram after enhancement by the spectral subtraction method of the present invention;

[0040] Figure 6 It is the waveform diagram and spectrogram after strengthening by the Wiener filter of the present invention;

[0041] Figure 7 The waveform diagram and spectrogram enhanced by the algorithm of the present invention for the present invention. Specific implementation manners

[0042] The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.

[0043] Embodiment 1

[0044] Please refer to Figure 1 , a smart home switch control system based on speech recognition, including a home intranet, a home network block, and an external network. The home intranet uses a ZigBee network to receive and transmit various types of home environment data information collected by sensors and control instructions issued by the user terminal; the external network uses a WiFi network to transmit the collected home environment data information and control instructions issued by the user terminal to the cloud platform; the home switch control system includes an environmental data acquisition module, a home device control module, a security alarm module, a speech recognition module, a home gateway module, and a federated learning security module. The environmental data acquisition module consists of ZigBee terminal nodes and various sensors. The collected environmental data information is transmitted from the ZigBee terminal nodes to the STM32 main controller connected to the ZigBee coordinator. The STM32 main controller analyzes and processes the data according to the data threshold and performs corresponding actions; the speech recognition module collects the voice control instructions of the user, converts them into corresponding data information, and locally encrypts and stores the voiceprint features through the federated learning security module, and sends them to the STM32 main controller through the serial port. Finally, the STM32 main controller performs corresponding actions according to the data information.

[0045] In some embodiments, the home device control module is composed of a ZigBee terminal node and various execution controllers. The various execution controllers are divided into a relay module, an infrared module, and a motor module, which control socket appliances (such as lights, humidifiers, etc.), infrared appliances (such as air conditioners, TVs, etc.), and smart curtains respectively. The security alarm module is composed of a ZigBee terminal node, a smoke sensor, a passive infrared sensor, and an alarm device. For example, when a fire, gas leakage, theft, etc. occur at home, the sensors will detect relevant gas factors and infrared rays, and at this time the alarm device will give an alarm. At the same time, the alarm information will be uploaded to the cloud platform through the WiFi module so that corresponding processing can be carried out in a timely manner even when the user is not at home. The home gateway module is composed of an STM32 main controller, a ZigBee coordinator, a WiFi module, etc. The indoor environment data information collected by the ZigBee terminal node is transmitted to the ZigBee coordinator, and the ZigBee coordinator then transmits the data information to the STM32 main controller for processing, and then transmits the data information to the cloud platform through the WiFi module. At the same time, control commands sent by the user through the cloud platform can also be received through the WiFi module to achieve two-way data transmission. The user can view the real-time indoor environment through a computer and a mobile phone, and can also remotely control the operation of home devices indoors. The voice recognition module uses a CI1103 intelligent voice recognition IC. The CI1103 is built-in with a self-developed brain neural network processor BNPU, which provides local voice recognition within 300 command words. At the same time, it is built-in with a CPU core and a high-performance low-power AudioCodec unit, integrating peripheral function ports such as high-speed UART, IIC, SPI, PWM, and GPIO. It can directly connect to WIFI using the internal high-speed UART port and provides an offline voice solution. Its basic functions can be controlled using offline voice, and functions and services can also be carried out through the network. The CI1103 system can seamlessly connect local intelligence and cloud intelligence. While realizing cloud applications, it can also overcome problems such as unstable network, delay, network disconnection, etc. that affect the user experience, and the problem that pure cloud interaction cannot guarantee the privacy and security of personal data. The voice recognition module internally integrates an A / D, D / A converter, a microphone, and a Wiener filter. The Berouti spectral subtraction algorithm is burned into the voice recognition module. The specific formula of the Berouti spectral subtraction algorithm is as follows:

[0046]

[0047] Where represents the spectrum of the enhanced speaker's voice, represents the spectrum of the speaker's voice signal with noise, represents the spectrum of the noise estimation signal, and the value of α 0 is 4.5;

[0048] For each segment SNR representation of the frame (SNR i ) of the i-th noise signal, it is as follows:

[0049]

[0050] where b is the starting point and e is the ending point of the i-th noise signal frame, and the parameter factor θ is defined as follows:

[0051]

[0052] The value of the parameter β is defined as 0.01, and the value of γ is defined as 1.5. The specific algorithm flow is as Figure 2 shown. The channels of the ZigBee terminal node and the WiFi network are selected from non - overlapping channels 15, 20, 25, 26 to reduce or mitigate the co - channel interference with Wi - Fi, thereby enhancing network security and reducing the bit error rate. The federated learning security module adopts a federated learning framework to locally encrypt and store user voiceprint features.

[0053] In this application, the STM32 main controller module selects the STM32F103ZET6 chip, whose core is ARM Cortex-M3, with 512KB of FLASH and 64KB of SRAM built-in. It has 16-bit counters, a 12-channel DMA controller, 12-bit A / D and D / A converters, and also has various communication interfaces such as USART, SPI, IIC, CAN bus, USB, and SDIO, which is basically suitable for connecting various communication circuits and peripherals. This chip uses the LQFP144 package. Due to the package restricting its functions, some pins can be multiplexed. This chip has the advantages of low cost, low power consumption, and high performance, and is very suitable for smart home control systems; the ZigBee module uses the CC2530 chip of Texas Instruments (TI) company. It can work under the 2.4GHz and IEEE802.15.4 standard protocols, and can quickly form a network in combination with the ZigBee protocol stack to achieve internal network communication of the smart home system. The temperature and humidity sensor of this system selects DHT11, which is used to monitor the temperature and humidity in the home. It is a temperature and humidity dual-purpose sensor, with an internal structure having an NTC temperature measurement and a resistive humidity sensing element, and has the advantages of high stability, low power consumption, and rapid response. The smoke sensor of this system selects MQ-2, which is used to monitor the concentration of combustible gases such as smoke and gas in the home, so as to warn of fires and gas leaks. The human infrared sensor of this system selects HC-SR501, which is used to monitor illegal intrusion signals. The HC-SR501 sensor is a pyroelectric sensor that can automatically sense human infrared radiation. When someone enters the monitored range it covers, it outputs a high level, otherwise, it outputs a low level. It has the advantages of automatic induction and sensitive reaction. The light intensity sensor of this system selects BH1750, which is used to monitor the light intensity of the windows in the home, so as to control the curtains. The PM2.5 sensor of this system selects GP2Y1010AU0F, which is used to monitor the air quality in the home. The infrared household appliances of this system select infrared modules for control, which are used to control traditional household appliances such as air conditioners with infrared remote control. The socket household appliances of this system select relay modules for control, which are used to control switch devices such as lights. The smart curtains of this system select motor modules for control, which are used to control the opening, stopping, and closing of the curtains. The alarm circuit of this system uses a buzzer for alarm. In daily home life, when the sensor detects a gas factor or an infrared intrusion signal, the buzzer will immediately give an alarm to remind the user to take handling measures. The WiFi module of this system selects the ESP8266 chip. There is a TCP / IP protocol stack inside this chip, and it has 3 working modes (AP mode, STA mode, AP+STA mode), and data transmission can be carried out with the STM32 main controller using the serial port. The normal operation of the system requires a stable power supply. If the system power supply is unstable, the entire system will not be able to work properly.To meet the power supply voltage requirements of each module, two voltages need to be provided: 5V and 3.3V.

[0054] Please refer to Figure 2 , a smart home switch control method based on voice recognition, and the control method is as follows:

[0055] After the STM32 main controller is powered on, the development tool for the STM32 main controller is Keil μVision5, and the system is initialized. Each functional module such as the ZigBee module, voice recognition module, and WiFi module is initialized. The development tool for the ZigBee module is IAR Embedded Workbench. When using IAR Embedded Workbench for program development, the internal ZigBee protocol stack can be directly used for relevant program development, and there are also corresponding API interface functions inside. Just call it to complete the development work of the ZigBee module and realize the reception and transmission of wireless data. The ZigBee coordinator is the core of the ZigBee network and can be regarded as a bridge for data transmission between the STM32 main controller and the ZigBee terminal node. After the ZigBee coordinator is powered on and the system is initialized and completed, the channel is first selected, and then the PAN network is established. At this time, the ZigBee terminal node will periodically receive beacons. When the network receives the network access request of the ZigBee terminal node, the ZigBee terminal node will obtain the corresponding network address and PAN ID, and then wait for the ZigBee terminal nodes in the system to join the network. Only then is the network considered to be truly successfully established. After successful network formation, the network and serial port of the system will be monitored for data. When the control command of the STM32 main controller is sent to the ZigBee coordinator through the serial port, the ZigBee coordinator will process and analyze it, and then send the processed information to the specified ZigBee terminal node. At this time, it is necessary to analyze and discriminate the instructions according to different types of messages, send them respectively according to the type of the message, and then transmit them to the STM32 main controller through the serial port;

[0056] After completion, the baud rates of the serial ports of the STM32 main controller are all set to 115200 bit / s. The sensor terminal node consists of a ZigBee terminal node and various sensors. The sensor terminal node is mainly responsible for collecting home environment data information. The temperature and humidity (DHT11) sensor, the light intensity (BH1750) sensor, and the human infrared (HC-SR501) sensor are sensors of the digital quantity output type. Among them, the transmission methods of the temperature and humidity (DHT11) sensor and the human infrared (HC-SR501) sensor are single-bus, and the transmission method of the light intensity (BH1750) sensor is the IIC bus; the smoke (MQ-2) sensor and the PM2.5 (GP2Y1010AU0F) sensor are sensors of the analog quantity output type. In the normal state, the sensor terminal node is usually in the sleep mode and will only drive the sensors to collect relevant environmental data after being awakened. The actuator terminal node consists of a ZigBee terminal node and various actuators. The actuator terminal node is mainly responsible for executing corresponding control actions according to the control commands sent by the gateway module. Infrared household appliances, socket household appliances, and smart curtains are controlled by an infrared module, a relay module, and a motor module respectively, and the alarm module uses a buzzer to give an alarm. The actuator terminal node is different from the sensor terminal node. The actuator terminal node must be in the normal working mode to ensure that the sent control commands can be executed in time;

[0057] When performing voice recognition, the system needs to be initialized first. After completion, the voice keyword recognition list is loaded. When the voice acquisition device of the voice recognition module acquires the user's voice control command, it will receive and detect the voice signal, and then perform local encryption storage of the voiceprint feature through the federated learning security module. Then it is matched with the commands in the voice keyword recognition list. If the recognition is successfully matched, the voice command is sent to the STM32 main controller through SPI, and then the ZigBee coordinator transmits the data information to the actuator terminal for action control. If there is no matching recognition, it will continue to wait for voice input. The WiFi module is responsible for connecting to the OneNET cloud platform and uploading the home environment data information or sending down the home device control commands of the user side at the same time. The WiFi module is connected to the cloud platform through the TCP protocol. First, the WiFi module needs to be configured through AT commands to realize the data communication between the STM32 main controller and the cloud platform;

[0058] The STM32 main controller parses and processes the control commands, and then sends them to the ZigBee coordinator through the serial port. Then the ZigBee coordinator sends them down to the corresponding ZigBee nodes, and the actuator module connected to the ZigBee node executes the corresponding actions according to the control commands.

[0059] Embodiment 2

[0060] In this application, a voice recognition module is added. A male chorus of one sentence from VoiceBank with a duration of 5 s and a sampling frequency of 8 kHz is used as the pure voice information. The main noises used are Whitenoise, Speechbabble, and Tanknoise from the noise-92 library. Through the windowing and framing process with a Hamming window, the frame length is 24 ms and the maximum frame shift is 9 ms. The pure voice information is successively superimposed and mixed with the three noises. Taking the case of achieving noise reduction by successively passing through the traditional spectral subtraction method, the Wiener filtering method, and the method of this application under the premise that the finally determined signal-to-noise ratios are -10 dB, -5 dB, 0 dB, 5 dB, and 10 dB;

[0061] Taking the speechbabble noise as an example, after being mixed and superimposed with the pure voice information, in the case where the signal-to-noise ratio is approximately zero dB, the time-domain mapping oscillogram and spectrogram of the noisy speech information, the time-domain mapping oscillogram and spectrogram enhanced by the traditional spectral subtraction method, the time-domain mapping oscillogram and spectrogram enhanced by the Wiener filtering method, and the time-domain mapping oscillogram and spectrogram calculated by this application are as Figure 3 、 Figure 4 、 Figure 5 、 Figure 6 、 Figure 7 shown;

[0062] It can be found from the waveform diagram and spectrogram that the voice enhancement improvement method given in this application has an obvious enhancement effect on the noisy voice signal, and the enhancement effect is more obvious, so that the voice recognition efficiency is improved, meeting the requirements of this system.

[0063] Although the embodiments of the present invention have been shown and described, for those of ordinary skill in the art, it can be understood that various changes, modifications, substitutions, and variations can be made to these embodiments without departing from the principles and spirit of the present invention. The scope of the present invention is defined by the appended claims and their equivalents.

Claims

1. A smart home switch control system based on voice recognition, characterized in that: It includes a home intranet, a home network block, and an external network. The home intranet adopts a ZigBee network to receive and transmit home environment data information collected by various sensors and control instructions issued by the user end; the external network adopts a WiFi network to transmit the collected home environment data information and control instructions issued by the user end to the cloud platform; The home switch control system includes an environmental data acquisition module, a home equipment control module, a security alarm module, a voice recognition module, a home gateway module, and a federated learning security module. The environmental data acquisition module is composed of a ZigBee terminal node and various sensors. The collected environmental data information is transmitted by the ZigBee terminal node to the STM32 main controller connected to the ZigBee coordinator, and the STM32 main controller analyzes and processes the data according to the threshold value and executes corresponding actions; The speech recognition module collects the user's voice control instructions, converts them into corresponding data information, and locally encrypts and stores the voiceprint features through the federated learning security module, and sends them to the STM32 main controller through the serial port. Finally, the STM32 main controller executes corresponding actions according to the data information.

2. According to claim 1, a smart home switch control system based on voice recognition is characterized in that: The home appliance control module is composed of a ZigBee terminal node and various execution controllers, and the various execution controllers are divided into a relay module, an infrared module, and a motor module.

3. According to claim 1, a smart home switch control system based on voice recognition is characterized in that: The security alarm module is composed of a ZigBee terminal node, a smoke sensor, a human infrared sensor, and an alarm device. The sensor detects relevant gas factors and infrared rays and uploads the alarm information to the cloud platform through a WiFi module.

4. The smart home switch control system based on voice recognition according to claim 1, characterized in that: The home gateway module is composed of an STM32 main controller, a ZigBee coordinator, a WiFi module, etc. The indoor environment data information collected by the ZigBee terminal node is transmitted to the ZigBee coordinator, and the ZigBee coordinator transmits the data information to the STM32 main controller for processing, and then transmits the data information to the cloud platform through the WiFi module. At the same time, the WiFi module can also be used to receive control commands issued by the user end through the cloud platform to achieve two-way data transmission. Users can view the real-time indoor environment conditions through computers and mobile phones, and can also remotely control the operation of indoor home appliances.

5. The smart home switch control system based on voice recognition according to claim 1, characterized in that: The speech recognition module adopts CI1103 intelligent speech recognition IC, and the speech recognition module integrates A / D, D / A converter, microphone, and Wiener filter. The Berouti spectral subtraction algorithm is burned into the speech recognition module.

6. The smart home switch control system based on voice recognition according to claim 5, characterized in that: The specific formula of the Berouti spectral subtraction algorithm is as follows: in The frequency spectrum representing the enhanced speaker's voice, represents the spectrum of the speaker's speech signal with a noisy signal, represents the signal spectrum of the noise estimate, with the value of α0 being 4.5; The frame of the i-th noise signal (SNR i ) is expressed as follows: Where b is the starting point of the i-th noise signal frame, and e is the ending point.

7. The smart home switch control system based on voice recognition according to claim 6, characterized in that: The parameter factor θ is defined as follows: The value of parameter β is defined as 0.01 and the value of γ is defined as 1.

5.

8. The smart home switch control system based on voice recognition according to claim 1, characterized in that: The channels of the ZigBee terminal node and the WiFi network are selected from non-intersecting channels 15, 20, 25, and 26 to reduce or minimize the co-frequency impact with Wi-Fi, thereby enhancing network security and reducing bit error rate.

9. The smart home switch control system based on voice recognition according to claim 1, characterized in that: The federated learning security module adopts a federated learning framework to locally encrypt and store user voiceprint features.

10. A smart home switch control method based on voice recognition, characterized in that: According to a smart home switch control system based on voice recognition according to claims 1-9, the control method is as follows: Step S1: After the STM32 main controller is powered on, the system is initialized, and each functional module such as the ZigBee module, voice recognition module, and WiFi module is initialized; Step S2: After completion, the baud rate of the serial port of the STM32 main controller is set to 115200 bit / s; Step S3: When the WiFi module or the voice recognition module receives a control command from the user, the corresponding serial port will perform an interrupt response and make a judgment on it. If it is judged to be a device control command, the received control command will be sent to the STM32 main controller; Step S4: The STM32 main controller parses and processes the control instruction, and then sends it to the ZigBee coordinator through the serial port, and then the ZigBee coordinator sends it to the corresponding ZigBee node. The actuator module connected to the ZigBee node performs the corresponding action according to the control command.