Intelligent taste customized popcorn machine control method based on multi-brain region signal interaction

By using a 16-channel EEG acquisition device and a modularly designed popcorn machine, the device enables autonomous operation for people with physical disabilities and provides concentration training for children. It solves the problems of compatibility and limited interaction methods of existing devices, improves the communication stability and hardware integration of the device, and provides multi-dimensional control and efficient feedback.

CN122362962APending Publication Date: 2026-07-10YANSHAN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610214287.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-02-13
Publication Date
2026-07-10

AI Technical Summary

Technical Problem

Existing popcorn machines cannot meet the pure thought control needs of people with physical disabilities. They are difficult to operate and lack adaptability. Children's attention training equipment is not effective. The interaction methods in entertainment venues are limited. The accuracy of EEG signal acquisition is low and the signal processing algorithm is not optimized, resulting in a single control dimension and a single feedback form.

Method used

It employs a 16-channel EEG signal acquisition device, combines WIFI and I2C communication protocols to construct a hierarchical control link, integrates a modular raw material dispensing box and a smart touch screen, and achieves full-link automation of EEG commands and device responses through the SSVEP interaction paradigm, supporting multi-dimensional EEG control and fully automatic raw material dispensing.

Benefits of technology

It enables autonomous operation by people with physical disabilities, provides precise guidance for children's concentration training, enhances the interactivity and fun of entertainment venues, improves the communication stability and hardware integration of the equipment, and ensures the accuracy of signal recognition and the consistency of feedback.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122362962A_ABST
    Figure CN122362962A_ABST
Patent Text Reader

Abstract

This invention discloses a control method for an intelligent flavor-customized popcorn machine based on multi-brain region signal interaction, solving the problems of existing devices' strong reliance on limb operation and poor scene adaptability. The device includes a popcorn machine main body, a 16-channel EEG acquisition device, and an STM32F103RBT6 main controller, etc., constructing a hierarchical control link through WIFI+I2C+SPI. It employs SSVEP frequency-phase joint modulation coding to achieve flavor / ingredient selection based on thought, decoded by the FB-CCA algorithm, achieving a recognition accuracy of ≥95%. Attention level is calculated using prefrontal cortex EEG signals, dynamically matching heating power. An integrated modular ingredient dispensing box enables automatic and precise ingredient dispensing, coupled with a smart touchscreen for status feedback and interaction, and also supports voice backup control. The device requires no limb operation, adapting to scenarios such as independent living for people with disabilities, attention training for children, and entertainment, achieving a fully closed-loop control of "thought-execution-feedback," with stable communication and convenient operation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of interdisciplinary technology of assistive rehabilitation equipment and educational entertainment equipment. Specifically, it is based on 16-lead EEG signal acquisition technology, thought-to-action control link and fully automatic execution components, and integrates a closed-loop control function of "brainwave thought-device response". It can realize the entire process of popcorn making, "raw material input-heat control-flavor selection" through pure thought operation. It primarily serves the independent living needs of people with physical disabilities, while also being suitable for early attention training scenarios for children. It can also be applied to entertainment venues such as theme parks and immersive experience halls, solving the technical pain points of operational barriers for special groups, lack of carriers for children's attention training, and limited interactive entertainment scenarios. Background Technology

[0002] Existing popcorn machines and similar small food preparation equipment have significant technical limitations in terms of adaptability to special populations and functional expansion. For people with physical disabilities or those with limited mobility due to spinal cord injuries, there is a natural barrier to operating equipment that requires manual intervention in their daily lives. Existing popcorn machines generally rely on manually adding ingredients and manually adjusting knobs or touch buttons to control the heat. Even some machines that claim to be "automated" still require physical triggering of start commands, failing to meet the core need of "pure thought control" for people with disabilities. Furthermore, there are no adaptation solutions designed for the perception and interaction habits of people with disabilities, such as the lack of intuitive status feedback interfaces and high control response delays. This makes it difficult for people with disabilities to complete the popcorn making process independently, requiring them to rely on others for assistance, which seriously affects their quality of life.

[0003] On the other hand, in the field of early childhood attention training, existing training methods mostly rely on static tools such as picture books and puzzles or virtual training software on electronic screens. This results in a disconnect between training effectiveness and real-life scenarios. Existing devices do not integrate attention detection with actual operational results, making the training process tedious and lacking in a sense of accomplishment, making it difficult to maintain children's interest in the long term. Furthermore, the lack of optimized algorithms for children's EEG signal characteristics leads to low accuracy in attention detection, hindering precise training guidance. In entertainment venues such as theme parks and immersive experience centers, existing interactive devices mostly rely on touch, voice, or physical movement control, resulting in highly homogenized interaction methods and a lack of technologically advanced and personalized interaction forms like "mind control." At the same time, entertainment scenarios demand high "experience continuity," but existing EEG interactive devices generally suffer from low signal acquisition accuracy, poor control chain integration, and limited feedback methods, failing to meet the "high interactivity, high fun, and high completion" experience requirements of entertainment scenarios.

[0004] Furthermore, existing solutions combining EEG technology with equipment have significant shortcomings in adaptability to specific scenarios. First, the precision of EEG acquisition hardware is insufficient; single-channel or 4-lead devices cannot accurately acquire signals from multiple brain regions, resulting in a single control dimension that can only achieve simple start and stop, failing to support multi-task control such as "flavor selection + heat adjustment." Second, the signal processing algorithms are not optimized for specific populations, such as failing to consider the abnormal fluctuations in EEG signals that may exist in people with disabilities or the low signal-to-noise ratio of EEG signals in children, leading to low recognition accuracy and high false triggering rate. Third, the hardware integration is low; the EEG acquisition module, control unit, and execution components are mostly independent components with loose physical connections, making signal transmission susceptible to interference. Moreover, there is a lack of fully automatic execution mechanisms that match "mind control," making it impossible to translate EEG commands into a complete production process, creating a "command-execution" gap.

[0005] Therefore, there is an urgent need for an intelligent popcorn machine equipped with high-precision multi-channel EEG acquisition, a thought control algorithm optimized for special populations, and fully automated execution components. This would address the operational barriers faced by people with disabilities, the lack of training tools for children's attention spans, and the limited interactive entertainment scenarios, achieving a closed-loop process of "thought control → self-production → feedback," while simultaneously covering three core scenarios: assisted rehabilitation, educational training, and entertainment experiences. Summary of the Invention

[0006] The technical problem to be solved by this invention is to overcome the shortcomings of existing popcorn machines, such as loose hardware structure, reliance on manual feeding of raw materials, weak user participation, and limited functionality that cannot meet personalized taste needs. The invention provides an intelligent popcorn machine with integrated hardware, a clear control link, support for brainwave interaction to customize flavors, and stable communication. It uses a self-developed modular raw material supply system to feed the relevant raw materials and optimizes the SSVEP interaction paradigm to achieve full-link automation of "brainwave command - raw material feeding - heating control".

[0007] To solve the above-mentioned technical problems, the present invention adopts the following technical solution: This invention includes a popcorn machine body, a 16-channel EEG signal acquisition device, a main controller, a human-computer interaction interface smart touch screen, relays, a heating module, and an integrated shell; each component of the system is based on the WIFI communication protocol and connects to I... 2The C-communication protocol constructs a hierarchical control link. The main controller establishes data interaction with the human-machine interface smart touch screen via the SPI communication protocol. The 16-channel EEG acquisition device transmits raw EEG data to the main controller via WIFI communication, using a standardized data frame format of "device identifier-data type-content-checksum" for data transmission. It has a signal loss monitoring function. If the EEG data transmission is interrupted for more than 3 seconds, the device automatically pauses the production process, and the touch screen displays "Signal lost, please check device connection." After the transmission is resumed, user confirmation is required to continue, ensuring stable synchronous communication between multiple devices and avoiding signal interruption or delay. The modular raw material feeding box is integrated inside the popcorn machine body, via I- 2 The C communication protocol establishes a remote control connection with the main controller. After the main controller parses the SSVEP ingredient / flavor selection results, it sends precise ingredient release commands to the dispensing box to achieve stable cross-regional control.

[0008] The popcorn machine has a rectangular structure with a stainless steel popcorn pot inside for holding corn kernels, oil, and flavoring ingredients. A modular ingredient dispensing box is integrated above the popcorn pot. This box is made of 304 stainless steel and features a servo motor-driven feeding mechanism and an infrared sensor-based feeding and obstacle avoidance system. It is temperature resistant to ≥300℃ and has a corrosion resistance rating ≥SUS304, preventing high-temperature deterioration of the ingredients or deformation of the box. A 45° rotating handle is located on the side of the main body for easy pouring of the popcorn. Heat-resistant plastic baffles with 2mm diameter ventilation holes are fixed around the perimeter, providing both heat insulation and splash prevention. The heating module is installed below the popcorn pot, with its power supply circuit connected in series with relay contacts for on / off control.

[0009] The EEG signal acquisition device employs a 16-lead EEG acquisition system and supports WIFI wireless data transmission. The device features a differentiated electrode layout designed to meet functional requirements: the prefrontal cortex electrode group (Fp1, Fp2, F3, F4 channels) is used to acquire EEG signals to analyze focus values; the occipital cortex electrode group (O1, O2, Oz channels) is used to acquire steady-state visual evoked responses (SSVEP) signals for taste selection; and the parietal P3, P4 and temporal T3, T4 channels serve as redundancy backups to prevent signal interference from causing control interruptions. The sensor's active electrodes are comb-shaped and conform to the skin of the corresponding brain region, with the reference electrode located on the left earlobe. Precise EEG signals are obtained by detecting the electrode potential difference. Additionally, the EEG signal acquisition device integrates a real-time electrode impedance monitoring module. When a contact impedance >15kΩ is detected, an impedance abnormality alarm is immediately displayed on the smart touchscreen, and a low-frequency buzzer is triggered until the impedance recovers to ≤10kΩ.

[0010] For the SSVEP ingredient and flavor selection function, the device adopts a frequency-phase joint modulation coding stimulation paradigm, assigning a unique "frequency-phase" combination to five ingredient / flavor categories: corn kernels + cooking oil (6Hz frequency + 0° phase), chocolate (8Hz frequency + 90° phase), cream (10Hz frequency + 180° phase), caramel (12Hz frequency + 270° phase), and strawberry (14Hz frequency + 180° phase). Each selected target on the interface is unique, ensuring signal uniqueness. The offline data acquisition phase follows this paradigm: each trial begins with a 1-second target prompt (a green box appears at the target location). The subject must shift their gaze to the target ingredient / flavor option. After the prompt ends, all options flash synchronously for 2 seconds according to their corresponding "frequency-phase," followed by a 2-second black screen (collecting idle state data). The total duration of a single trial is 6 seconds. Each ingredient / flavor is treated as an independent stimulus target, forming one pixel block. A total of 5 pixel blocks are collected, corresponding to the 5 ingredient / flavor categories.

[0011] The main controller uses an STM32F103RBT6 microcontroller, integrated within a housing. It receives raw data from the EEG signal acquisition device via Wi-Fi communication. On one hand, it analyzes the raw prefrontal cortex signal, using the FastICA algorithm to remove EOG artifacts (separating EOG artifacts from EEG signals and retaining valid EEG components), a 50Hz notch filter (suppressing power frequency interference, attenuation ≥40dB), and a 0.1-30Hz bandpass filter (eliminating EMG and baseline drift interference, transition band width ≤1Hz). Finally, it performs a Fast Fourier Transform. (FFT) extracts the signal power values ​​of the α (8-12Hz), β (12-30Hz), and θ (4-8Hz) bands. The raw focus value is calculated using β / (α+θ), and then mapped to a range of 0-100 using a piecewise linear mapping rule. Specifically, the mapping relationship is: raw value 0-0.3 corresponds to 0-30 points, 0.3-0.6 corresponds to 31-70 points, and 0.6-1.0 corresponds to 71-100 points, which is the final focus value. On the other hand, an asynchronous EEG decoding method is used to process the occipital SSVEP signal, specifically... The process is as follows: ① Data preprocessing: Screening the effective channels O1, O2, and Oz in the occipital region, checking and removing bad conductors, where a signal-to-noise ratio <30dB is considered a bad conductor. Baseline drift and environmental interference are removed by 50Hz notch filtering and 0.1-30Hz bandpass filtering; ② Filter bank processing: Using 8 groups of bandpass filters with different center frequencies (6-15Hz, bandwidth 2Hz, transition band attenuation ≥60dB / dec), the preprocessed signal is sub-filtered to obtain multi-subband SSVEP signals; ③ Target recognition: Based on the filter bank... The canonical correlation analysis (FB-CCA) algorithm calculates the correlation coefficient between each sub-band signal and the corresponding frequency-phase reference sinusoidal signal, and takes the reference signal frequency corresponding to the maximum correlation coefficient as the preliminary identification result; ④ Control state judgment: The non-control state component of the sub-band signal is calculated by Bayesian posterior probability estimation algorithm, combined with the iterative weighting method, the weight is dynamically adjusted based on the sub-band signal-to-noise ratio, the higher the signal-to-noise ratio, the greater the weight, to judge the credibility of the identification result and whether it is in the control state. If the condition is met, the raw material / flavor control command is output, and the identification accuracy is ≥95%.

[0012] The integrated shell of this invention is made of ABS engineering plastic, and the internal components are arranged in layers using a customized aluminum alloy bracket: the bottom layer uses M3 copper pillars to install the STM32F103RBT6 main controller and relay, with a 10mm heat dissipation gap to avoid mutual interference between the heat dissipation of the main controller and the relay; the top layer has a display window adapted to the human-machine interface smart touch screen, with silicone sealing rings at the edges to ensure the touch screen is installed firmly; the sides of the shell have heat dissipation grilles to ensure that the internal component operating temperature is ≤60℃.

[0013] The human-computer interaction interface is a smart touchscreen. The touchscreen establishes data interaction with the main controller microcontroller via the SPI communication protocol, simultaneously realizing two core functions: First, SSVEP stimulation presentation, dividing the interface into 5 independent selection areas, corresponding to corn kernels + cooking oil and 4 flavor ingredients respectively. Each area uses a "dynamic flashing border (modulated according to the corresponding 'frequency-phase', brightness modulation depth ≥80%) + static icon" design to collect SSVEP signals from the user's occipital region; Second, status feedback display, presenting real-time SSVEP recognition results, EEG focus value, production progress, and cooking temperature, helping users adjust their gaze and focus, improving interaction continuity. In addition, the smart touchscreen, as a human-computer interaction interface, also has voice interaction functionality. This function supports the recognition of commands such as 'start making,' 'stop making,' 'pause making,' and 'clear blockage,' with a recognition accuracy of ≥92%. When EEG control fails, voice commands can replace the operation, with a voice command response time ≤500ms.

[0014] The heating module is located below the popcorn pot. The power supply circuit is connected in series with the relay contacts. The main controller controls the relay through the GPIO pin level, thereby sending a level signal command to the popcorn machine to control the relay to engage / disengage. The main controller adjusts the heating module power through PWM technology. The heating power (high level duty cycle) corresponds linearly to the user's concentration level. A concentration level of 30-50 corresponds to a power of 30%-50%, 51-70 corresponds to 51%-70%, and 71-100 corresponds to 71%-100%, thus achieving dynamic matching of heating intensity with the user's concentration level.

[0015] The modular ingredient dispenser is integrated inside the popcorn machine body, directly above the popcorn pot, and coaxially aligned with the pot's inlet. Its overall dimensions are 300mm × 150mm × 100mm. It is made of 304 stainless steel and is divided into five independent storage units, corresponding to corn kernels + cooking oil and four flavor ingredients respectively. Each storage unit has a removable stainless steel top cover for easy replenishment. Each storage unit also has an electromagnetically controlled cover at the bottom, which is opened by a built-in I / O control within the dispenser. 2The slave module uses a PCA9685 chip, supports multi-device cascading, and controls the device after receiving commands from the main controller. The opening duration is preset according to the raw material form to ensure that the single release amount error is ≤±2g. A feeding obstacle removal system consisting of a servo motor-driven feeding mechanism and an infrared sensor is installed at the feeding box outlet. The infrared sensor monitors the feeding channel for blockages in real time. When no raw material falls for 2 consecutive seconds, the servo motor automatically starts alternating forward and reverse rotation (0.5 seconds forward, 0.3 seconds reverse, cycle 3 times). If the blockage is still not cleared, the touch screen displays 'Feeding Blockage, Please Clear' and triggers a buzzer alarm. The cover closure uses a spring reset structure, combined with a Hall position sensor to provide real-time feedback on the switch status, preventing raw material leakage or incomplete feeding. The feeding box and the main controller communicate via I / O. 2 With the I2C communication protocol connected, the main controller acts as an I2C host, sending device addresses, command codes, and data frames to achieve independent control of each storage unit in the delivery box, solving the problem of connection distance limitations, while reducing wiring complexity and signal interference risks.

[0016] The positive effects of this invention are as follows: 1. Significantly improved communication stability and adaptability: Adopting WIFI communication protocol + I 2 The C-communication protocol establishes a hierarchical control link, with the main controller and the EEG device achieving wireless data transmission via WIFI; the main controller and the modular material dispensing box communicate via I- 2 The C protocol connection breaks through distance limitations while reducing wiring complexity. Combined with standardized data frames of "device identifier-data type-content-check bit", it ensures synchronous communication between the main controller, EEG device, touch screen and delivery box. The system response latency is ≤300ms, and the real-time performance and reliability of control commands are greatly improved.

[0017] 2. Dual optimization of SSVEP recognition accuracy and user-friendliness: A "frequency-phase" joint modulation coding paradigm is adopted, assigning unique stimulus parameters to corn kernels, cooking oil, and four flavors to avoid target signal repetition; the offline acquisition paradigm is optimized, combined with the FB-CCA asynchronous decoding algorithm adapted to the computing power of the STM32F103RBT6 microcontroller, ensuring a stable SSVEP recognition accuracy of ≥95%; the intelligent touchscreen simultaneously implements "stimulus presentation + status feedback" functions, dynamically prompting with a green box after successful recognition, while simultaneously displaying attention values ​​and production progress in real time, helping users intuitively perceive the correlation between EEG commands and device responses, reducing the operational difficulty for disabled people, children, and other special users, and improving interactive continuity.

[0018] 3. Significantly Enhanced Hardware Integration and Collaborative Performance: The modular raw material dispensing box, made of 304 stainless steel, is integrated into the main body of the popcorn machine and aligned coaxially with the popcorn pot for precise dispensing. The integrated shell features a layered layout of the STM32F103RBT6 main controller, relays, and touch screen using a custom aluminum alloy bracket. Pre-drainage gaps and a heat dissipation grille ensure that the internal component operating temperature is ≤60℃, preventing high temperatures from affecting the circuitry and raw materials. All hardware components are seamlessly connected via standardized communication protocols, reducing physical interference between independent components and improving the overall anti-interference capability of the device by over 30%. The modular design also ensures portability and ease of maintenance.

[0019] 4. Deep Expansion of Functionality and Scenario Adaptability: Firstly, the dual-dimensional EEG control and fully automatic raw material dispensing form a closed loop. Attention regulation of heating power achieves dynamic matching of heat levels. SSVEP selection of raw materials / flavors triggers automatic dispensing from the dispensing box, completely eliminating dependence on physical operation and accurately adapting to the independent living needs of people with physical disabilities. It also solves operational obstacles in scenarios where children or those using both hands are present. Secondly, the core services of the device serve three major scenarios: assisted rehabilitation (independent operation training for people with disabilities), educational training (concrete cultivation of children's attention), and entertainment experience (theme park mind-interactive projects). It can be quickly adapted to different scenario needs without additional modifications. Thirdly, WIFI communication supports multi-device data interaction. For example, in educational scenarios, teachers can remotely obtain data on changes in children's attention to assist in evaluating training effectiveness and further extend the application value of the device. Attached Figure Description

[0020] The present invention will be further described below with reference to the accompanying drawings and embodiments.

[0021] Figure 1 This is a schematic diagram of the overall structure of the present invention; Figure 2 This is a schematic diagram of the internal structure of the container housing of the present invention; Figure 3 This is a state transition diagram of the control flow of the present invention; Figure 4 This is a graph showing the relationship between the focus and heating power of this invention. Figure 5 This is a schematic diagram of the software system modules of the present invention; Figure 6 This is a schematic diagram illustrating the communication relationships between the components of this invention; Figure 7 This is a schematic diagram showing the positions of each pixel block on the SSVEP stimulation interface of the present invention; Figure 8 This is a schematic diagram showing the channel occupied by the EEG acquisition device of the present invention.

[0022] In the attached diagram: 1. EEG signal acquisition device, 2. Popcorn machine body, 3. Main controller STM32F103RBT6 development board, 4. Human-computer interaction interface smart touch screen, 5. Relay, 6. Stainless steel popcorn pot, 7. Rotating handle, 8. Heat-resistant plastic baffle, 9. Heating module, 10. Modular raw material feeding box, 11. Integrated shell, 12. Popcorn machine relay connection wire. Detailed Implementation

[0023] As attached Figure 1-8 The figure shown is an embodiment of the present invention. like Figure 1 As shown, the overall structure of the intelligent popcorn machine based on EEG attention control of the present invention includes: 1. EEG signal acquisition device, 2. Popcorn machine body, 3. STM32F103RBT6 microcontroller as the main controller, 4. Intelligent touch screen for human-computer interaction, 5. Relay, 6. Stainless steel popcorn pot, 7. Rotating handle, 8. Heat-resistant plastic baffle, 9. Heating module, 10. Modular raw material feeding box, 11. Integrated shell, 12. Popcorn machine relay connection wire. All components form a complete control link through standardized communication protocols and physical connections.

[0024] The EEG signal acquisition device 1 establishes a wireless data connection with the main controller 3 via WIFI communication, transmitting prefrontal lobe focus signals and occipital SSVEP signals in real time. The main controller 3 interacts with the smart touch screen 4 via the SPI communication protocol and establishes a control connection with the modular raw material dispensing box 10 via the I2C communication protocol. The standardized data frame of "device identifier-data type-content-check bit" is used to ensure the accuracy of command transmission. The main controller 3 also outputs high and low levels through GPIO pins, which control the relay 5 to engage / disengage via the popcorn machine relay connection line 12, thereby adjusting the on / off state of the heating module 9. In terms of structural integration, the main controller 3 and relay 5 are integrated into the bottom layer of the integrated shell 11, and the smart touch screen 4 is embedded in the top layer of the integrated shell 11 with an adapter window. The modular raw material dispensing box 10 is a built-in component of the popcorn machine body 2, fixed directly above the stainless steel popcorn pot 6. The rotating handle 7 on the side of the body is linked to the edge of the popcorn pot 6, which can achieve a 45° tilt to pour out the finished product. The heat-resistant plastic baffles 8 around the body are fixed with screws, which also have the functions of heat insulation, anti-splashing and heat dissipation.

[0025] The popcorn machine body 2 is a rectangular structure, with a stainless steel popcorn pot 6 fixed inside for popping corn kernels, oil, and flavoring ingredients. A modular ingredient dispenser is fixed above the popcorn pot, allowing for automatic, mind-controlled dispensing of different ingredients. A rotating handle 7 on the side is linked to the edge of the popcorn pot 6, enabling a 45° tilt to pour out the popcorn. Heat-resistant plastic baffles 8 are fixed around the perimeter with screws, providing both heat insulation and splash prevention. The baffles have evenly spaced 2mm diameter ventilation holes to further enhance heat insulation and dissipation. The heating module 9 is installed below the popcorn pot 6. Its power supply circuit is connected in series with the contacts of a relay 5. The coil of the relay 5 is connected to the GPIO pin of the main controller 3 via DuPont wires. The high and low level signals output by the main controller control the relay's activation / deactivation, thus controlling the heating module's on / off state.

[0026] The control flow state transition of the present invention is as follows: Figure 3 As shown, the system follows a state transition logic of "initialization → SSVEP ingredient / flavor selection → automatic ingredient dispensing → preheating → focus-interactive heating → stop". The system initialization phase lasts for 3 seconds. After the main controller 3 starts, it automatically detects the communication status of the EEG signal acquisition device 1, the smart touch screen 4, and the modular ingredient dispensing box 10. If there is a communication abnormality, the smart touch screen 4 will display a fault code and trigger a buzzer prompt. At the same time, the capacitive level sensor built into the modular ingredient dispensing box 10 will provide real-time feedback on the remaining amount of ingredients in the 5 storage units. When the amount is lower than the threshold, the corresponding ingredient icon will be highlighted in red. In addition, the main controller 3 will also send a calibration command to the dispensing box to control the electromagnetic cover of each storage unit to perform the "open for 1.5 seconds → close" action. The Hall position sensor will confirm the reset status of the cover. After calibration, the touch screen will display "initialization completed, you can start selecting ingredients / flavors" and play a prompt tone "initialization completed" through the speaker.

[0027] During the SSVEP ingredient / flavor selection phase, the user wears the EEG signal acquisition device 1, ensuring that the comb-shaped active electrodes are in close contact with the skin of the prefrontal cortex (Fp1, Fp2, F3, F4 channels) and the occipital region (O1, O2, Oz channels) (contact impedance ≤10kΩ). The user clicks "Start Production" on the smart touchscreen 4, switching the interface to SSVEP stimulation mode and displaying five independently selectable pixel blocks, corresponding to corn kernels + cooking oil (6Hz+0°), chocolate flavor (8Hz+90°), cream flavor (10Hz+180°), caramel flavor (12Hz+270°), and strawberry flavor (14Hz+180°). Each pixel block uses a "dynamic flashing border + static icon" design. After the user focuses on the target pixel block, the system follows a single trial procedure of "1 second target prompt → 2 seconds synchronous flashing → 2 seconds black screen." Data is collected for each ingredient / flavor as an independent block, with 10 trial runs, and transmitted to the main controller 3 via WIFI. The main controller 3 performs preprocessing (50Hz notch filtering, 0.1-30Hz bandpass filtering), filter grouping (8 groups of 6-15Hz bandpass filters), FB-CCA correlation coefficient calculation, and Bayesian posterior probability judgment on the occipital SSVEP signal. If the confidence threshold is ≥0.85 and the proportion of non-control state components is <30%, it is determined to be a valid control state, and the touch screen draws a green flashing box outside the target pixel block as feedback; otherwise, it prompts "Please adjust the gaze state and try again".

[0028] During the automatic raw material dispensing stage, the main controller 3 first sends a command to the "corn kernels + cooking oil" storage unit to control the electromagnetic lid to open for 1.5 seconds (dispensing 80g±5g of corn kernels + 15mL±1mL of cooking oil). After the Hall position sensor detects that the lid has reset, it sends a command to the corresponding flavor storage unit after a delay of 0.5 seconds. The lid opening time is adapted according to the form of the raw material: 1.2 seconds for granules and 1.5 seconds for powder. Each dispensing is 20g±2g. During the dispensing process, the touch screen displays a progress bar in real time. When the dispensing is completed, a message "Preheating is about to begin" is displayed, and the audio module plays the corresponding prompt tone.

[0029] During the preheating and focus-interactive heating phase, focus values ​​are detected after raw materials are added. When focus is ≥30 for 3 consecutive seconds, the system automatically enters a 100-second preheating phase, with heating module 9 operating at 50% power. The touchscreen displays "Preheating (XX seconds remaining)" and the heat indicator turns yellow. After the preheating phase, if focus is <20 for 5 consecutive seconds, the heating power is reduced to 30%, and a message "Please increase focus" is displayed. When focus is >60 for 3 consecutive seconds, the focus-interactive heating phase begins. The main controller 3 extracts the power of the prefrontal cortex α (8-12Hz), β (12-30Hz), and θ (4-8Hz) bands using FFT. The original focus value is calculated using β / (α+θ) and mapped to the 0-100 range using a piecewise linear mapping rule. Specifically, the original value 0-0.3 corresponds to 0-30 points, and 0.3-0.6 corresponds to 31-70 points. The range of 0.6-1.0 corresponds to 71-100 points. Simultaneously, PWM technology ensures a linear correlation between heating power and focus level. When focus is N, the heating module cycles through a period of "heating for N seconds, stopping for (10-N) seconds," with N and focus value having a 1:1 mapping relationship. This allows for dynamic adjustment of N% of the power. N ranges from 0 to 10 seconds. For example, when focus is 0, N=0, and the heating module operates on a cycle of "heating for 0 seconds, stopping for 10 seconds," with 0% power. When focus is 100, N=10, and the heating module operates on a cycle of "heating for 10 seconds, stopping for 0 seconds," with 100% power. When focus is at an intermediate value, such as 50, corresponding to N=5, the heating module operates on a cycle of "heating for 5 seconds, stopping for 5 seconds," with 50% power. This achieves real-time, precise, and dynamic matching of heating power with the user's brainwave focus, preventing the raw materials from burning.

[0030] During the shutdown phase, if the cumulative heating time reaches 8 minutes, the user clicks "End Production," or if the user's focus level is less than 20 for 10 seconds (excluding the 8-minute cumulative heating time), the heating module power will be automatically cut off, the relay will disconnect, and a buzzer will sound. Simultaneously, if the interactive heating phase exceeds 15 minutes without completion, it will automatically stop and display the message "Production timed out, please check ingredients." The user then flips the popcorn pot 6 by turning handle 7 to pour out the finished product, completing the production process.

[0031] The software system modules of this invention are as follows: Figure 5 As shown in the diagram, this software system module is developed using C language to adapt to the STM32F103RBT6 computing power. It adopts a layered modular architecture, with each module interacting with the data buffer through function calls, achieving a response latency of ≤300ms. The driver layer provides the underlying support and includes drivers for WIFI, SPI touchscreen, I2C delivery box, and GPIO relays, encapsulating standardized API functions to simplify calls.

[0032] The data acquisition and analysis module is the core processing layer. The EEG data receiving submodule receives 16 leads of raw data (250Hz sampling rate) via WIFI and stores it in a circular buffer. The signal processing submodule performs filtering on the prefrontal cortex signal, extracts band power using FFT to calculate focus, and performs filtering on the occipital cortex signal, performs filter grouping, and implements SSVEP decoding using the FB-CCA algorithm and Bayesian judgment.

[0033] The control logic module is the decision layer. It adopts a state machine design to define six states: "initialization-selection-dispensing-preheating-heating-stop". It realizes the transition based on data output, user instructions and device status, and calls the driver layer function to control each device to perform the corresponding action.

[0034] The user interface module is the interaction layer. The interface display submodule realizes the switching between multiple interfaces and the display of information. The touch interaction submodule captures user operations and feeds them back to the control logic module to ensure smooth interaction.

[0035] A schematic diagram of the communication relationships between the components of this invention is shown below. Figure 6 As shown in the diagram, which illustrates the communication relationships between various components, the signal transmission paths, communication protocols, and physical connection logic between the core components are clearly presented. A two-tier architecture of "central controller-slave device" is constructed, with the STM32F103RBT6 microcontroller as the communication hub. The slave devices only interact directly with the main controller to avoid interference. The EEG signal acquisition device 1 communicates with the main controller 3 via WIFI. The EEG device sends one frame of data every 50ms in the format of "device identifier-data type-content-checksum". The main controller parses the data through the ESP8266 WIFI module, with a bit error rate of ≤10⁻. 6 The main controller 3 and the smart touch screen 4 communicate via SPI. The main controller acts as the host and sends interface control commands, such as switching the SSVEP interface and updating the focus display. The touch screen responds to user touch commands, such as start / end production, with a response time of ≤100ms. The main controller 3 communicates with the modular raw material feeding box 10 via I2C. The main controller sends feeding commands and reads status information, solving the distance limitation. The main controller 3 is directly connected to the relay 5 via GPIO. The relay contacts are connected in series with the power supply circuit of the heating module 9 to achieve on / off control. In terms of power supply path, the main controller draws power from the Type-C interface and regulates it to 3.3V for peripherals. The touch screen draws power from the main controller via USB. The feeding box has an independent 12V power supply, which is converted to 5V to ensure stable power supply for all components.

[0036] A schematic diagram of the pixel positions of the SSVEP stimulation interface of the present invention is shown below. Figure 7As shown, using a smart touchscreen as the display medium, the interface adopts a "5-pixel block evenly distributed" layout. The top of the interface is the first pixel block (corresponding to the cream flavor, 10Hz frequency + 180° phase), the left side of the interface is the second pixel block (corresponding to the chocolate flavor, 8Hz frequency + 90° phase), the middle is the third pixel block (corresponding to corn kernels + cooking oil, 6Hz frequency + 0° phase), the right side of the interface is the fourth pixel block (corresponding to the caramel flavor, 12Hz frequency + 270° phase), and the bottom of the interface is the fifth pixel block (corresponding to the strawberry flavor, 14Hz frequency + 180° phase). Each pixel block adopts a "dynamic flashing border + static icon" design, with a border width of 10px, a brightness modulation depth of ≥80%, and a flashing signal harmonic distortion rate of ≤5%, ensuring that the SSVEP signal signal-to-noise ratio of the collected occipital electrode is ≥35dB. When the user looks at the target pixel block, the interface first prompts the target with a red border for 1 second, then all pixel blocks flash synchronously for 2 seconds according to the preset "frequency-phase", and finally the screen goes black for 2 seconds to collect idle state data, forming a complete test process. At the same time, after successful recognition, the target pixel block displays a green flashing square to provide feedback on the result, and the audio module plays the corresponding result prompt sound to help the user perceive the interaction status.

[0037] In actual use, the device is first started to complete initialization. The main controller automatically controls the modular ingredient dispensing box integrated into the popcorn machine to precisely dispense 80g±5g of corn kernels and 15mL±1mL of cooking oil into the stainless steel popcorn pot. The user wears a 16-channel EEG signal acquisition device, ensuring the electrodes are in contact with the corresponding brain region. Then, the user activates the "SSVEP Flavor Selection" function via the smart touchscreen, focusing on the pixel block of the target flavor on the interface (focusing time ≥3 seconds). Once a green box appears outside the target pixel block on the touchscreen, indicating successful recognition, the ingredient dispensing box automatically releases 20g±2g of the corresponding flavor ingredient. After ingredient dispensing, the main controller begins to detect the user's EEG focus. When the focus level is ≥30 for 3 seconds, the device enters a 100-second preheating phase. After the preheating phase, if the focus level is <20 for 5 seconds, the heating power is reduced to 30%, and a message "Please increase focus" is displayed. If the focus level is >60 for 3 seconds, the device enters an interactive heating phase, heating according to the aforementioned relationship between focus level and heating power. When the device has been heating for a total of 8 minutes or the user manually clicks "End Production" on the smart touch screen, the heating module will automatically shut off and emit a prompt sound. The user can then flip the popcorn pot using the rotating handle on the side of the popcorn machine to pour the finished product into the container, thus completing the entire production process.

[0038] After each production cycle, the log recording module automatically stores the data as follows: timestamp - user ID - focus curve (power of 8-12Hz α, 12-30Hz β, 4-8Hz θ bands) - equipment status (temperature, impedance, feed amount) - operation instructions. It supports exporting Excel files to a computer via USB connection for analysis of changes in user focus or troubleshooting of equipment malfunctions.

[0039] This implementation method, through the technical approach of "SSVEP recognition + attention regulation + fully automatic raw material dispensing" and combined with a refined modular design, completely eliminates the dependence on physical operation. It is suitable for scenarios such as independent living for people with physical disabilities, attention training for children, and entertainment experiences, providing an innovative intelligent device solution for assisted rehabilitation, education and training, and entertainment experiences.

Claims

1. A control method for an intelligent flavor-customized popcorn machine based on multi-brain region signal interaction, characterized in that... First, a hardware platform is built, which includes a multi-brain region EEG signal acquisition unit, a main control unit, a human-computer interaction unit, a raw material storage and dispensing unit, and a heating control unit: The multi-brain-region EEG signal acquisition unit is used to acquire EEG signals from the user's prefrontal and occipital brain regions. The acquisition unit includes a contact state monitoring module to ensure the effectiveness of signal acquisition. The main control unit establishes a communication connection with the EEG signal acquisition unit to receive and process raw EEG data. The main control unit integrates a signal preprocessing module, a feature extraction module, and a control command generation module. The human-computer interaction unit is communicatively connected to the main control unit and is used to provide a visual stimulation interface and device status display function. The raw material storage and dispensing unit is controlled by the main control unit and includes multiple independent storage chambers and a quantitative dispensing execution mechanism. The heating control unit is electrically connected to the main control unit and is used to adjust the heating power and heating time according to control commands. The signal processing logic of the main control unit includes identifying the user's taste selection intention from the occipital EEG signal through the feature extraction module, extracting attention-related features from the frontal EEG signal and converting them into quantifiable control parameters, thereby driving the raw material feeding unit and the heating control unit to work together. The signal processing logic of the main control unit includes a multi-brain region signal collaborative interlocking mechanism. The flavor selection command of the occipital SSVEP signal is only allowed to take effect when the electrode impedance monitoring module detects a contact impedance ≤10kΩ and the attention value of the prefrontal EEG signal is ≥30 for 3 consecutive seconds. If the attention value is <20 and lasts for 5 seconds, the main control unit automatically pauses the raw material feeding or heating module and triggers the attention enhancement prompt on the smart touch screen until the attention value recovers to ≥30 before the SSVEP selection or heating control function can be reactivated. The multi-brain region EEG signal acquisition unit also integrates a dynamic signal quality assessment submodule, which calculates the signal-to-noise ratio (SNR) of each acquisition channel in real time. When the SNR of a certain channel is less than 30dB, it is automatically marked as a bad channel and the data of that channel is removed. When the main control unit processes the occipital SSVEP signal, it optimizes the recognition results of the filter bank canonical correlation analysis based on the data of the remaining effective channels through the 'sub-band SNR weighted algorithm', whose weight is positively correlated with SNR, to ensure that the recognition accuracy of SSVEP taste selection is ≥95%. If the number of effective channels is less than 3, the recognition accuracy cannot be met, and the main control unit automatically switches to the 'voice interaction backup mode', replacing EEG control with the voice command receiving function of the smart touch screen.

2. The intelligent flavor-customized popcorn machine control method based on multi-brain region signal interaction according to claim 1, characterized in that, The multi-brain region EEG signal acquisition unit is a 16-channel acquisition device, specifically acquiring signals from the prefrontal lobe Fp1, Fp2, F3, F4 channels and the occipital lobe O1, O2, Oz channels, with the parietal lobe P3, P4 and temporal lobe T3, T4 channels as redundant backups; the contact state monitoring module is implemented through an impedance detection circuit, triggering a prompt signal when the contact impedance is >10kΩ, with the reference electrode set on the left earlobe.

3. The intelligent flavor-customized popcorn machine control method based on multi-brain region signal interaction according to claim 2, characterized in that, The human-computer interaction unit is an intelligent touch screen that interacts with the main control unit via the SPI communication protocol; the visual stimulation interface contains multiple dynamic visual stimulation areas corresponding to different raw materials or flavors, and each area is modulated using a unique frequency-phase combination, with modulation parameters meeting the requirements for steady-state visual evoked potential recognition.

4. The intelligent flavor-customized popcorn machine control method based on multi-brain region signal interaction according to claim 3, characterized in that, The raw material storage and dispensing unit is made of food-grade metal in one piece and contains at least 5 independent storage chambers, corresponding to corn kernels, edible oil and at least 3 flavor ingredients respectively; the quantitative dispensing execution mechanism includes an electromagnetically driven opening and closing component and a dispensing amount calibration module, with a single dispensing amount error of ≤±2g, and integrates a blockage detection and removal submodule.

5. The intelligent flavor-customized popcorn machine control method based on multi-brain region signal interaction according to claim 4, characterized in that, The blockage detection and removal submodule includes an infrared sensor and a servo-driven feeding mechanism. When the infrared sensor does not detect a raw material falling signal for 2 consecutive seconds, the servo-driven mechanism performs a preset forward and reverse alternating action to remove the blockage. The action parameters are forward rotation for 0.5 seconds and reverse rotation for 0.3 seconds. If the blockage is still present after 3 cycles, an alarm is triggered.

6. The intelligent flavor-customized popcorn machine control method based on multi-brain region signal interaction according to claim 5, characterized in that, The signal preprocessing module of the main control unit includes an artifact removal algorithm, a power frequency interference filtering unit, and a frequency band filtering unit; the feature extraction module performs the following operations on the prefrontal cortex signal: extracting the power values ​​of the α, β, and θ bands, where α is 8-13Hz, β is 14-30Hz, and θ is 4-7Hz. At this time, the original attention value is calculated by β / (α+θ) and converted into control parameters in the range of 0-100 through piecewise linear mapping.

7. The intelligent flavor-customized popcorn machine control method based on multi-brain region signal interaction according to claim 6, characterized in that, The heating control unit includes a power adjustment module and a timing control module; the power adjustment module adopts PWM technology, and its output power is linearly related to the control parameters generated by the main control unit; the timing control module cyclically executes heating and stopping actions according to a preset cycle, with a single cycle duration of 10 seconds, wherein the heating duration is the control parameter divided by 10 and then rounded to the nearest integer.

8. The intelligent flavor-customizable popcorn machine according to claim 7, characterized in that, It also includes an auxiliary function unit, which includes an audio prompt module, an operation log storage module, and a data export interface; the operation log storage module records EEG characteristic parameters, device status, and operation instructions in time sequence, with a storage capacity of ≥16GB.

9. The intelligent flavor-customized popcorn machine control method based on multi-brain region signal interaction according to claim 8, characterized in that... The main control unit is integrated into an integrated housing made of ABS engineering plastic. Internally, components are arranged in layers using a custom aluminum alloy bracket. The bottom layer uses M3 copper pillars to mount the main control unit and relays, with a 10mm heat dissipation gap. The top layer has a display window adapted to the smart touchscreen, with silicone sealing rings around the window edges. Heat dissipation grilles are located on the sides of the housing to ensure the internal component operating temperature is ≤60℃. The main control unit also integrates a log recording module. This module stores data in real-time to the built-in Flash memory in the format of "timestamp-user ID-EEG attention curve-device status data-operation command". It supports exporting Excel format log files via USB interface, with a storage capacity ≥16GB, capable of covering 1000 complete production process data cycles. The power supply path is as follows: Main control unit... The device draws power from a Type-C interface and is regulated to 3.3V for peripheral use. The smart touchscreen draws power from the main control unit via USB. The modular material feeding box uses an independent 12V power supply and is converted to 5V. The voice interaction function of the smart touchscreen specifically supports the recognition of commands such as "start making", "stop making", "pause making" and "clear blockage", with a recognition accuracy of ≥92% and a voice command response time of ≤500ms. The pixel spacing in its SSVEP stimulation interface is 100px, the brightness modulation depth of the dynamic flashing border is ≥80%, and the harmonic distortion rate of the flashing signal is ≤5%. The heating control unit operates at 50% power for 100 seconds during the preheating stage. After the preheating stage, if the focus level is <20 for 5 seconds, the heating power is reduced to 30% and the smart touchscreen prompts "please increase focus level".

10. A smart popcorn-making control method based on multi-brain region signal interaction according to any one of claims 1-9, characterized in that... Includes the following steps: S1. Equipment Initialization and Signal Validity Detection: When the popcorn machine is started, the main control unit detects the communication status of the EEG signal acquisition device, the modular raw material dispensing box, and the smart touch screen; the electrode impedance monitoring module of the EEG signal acquisition device detects the contact impedance in real time. Only when the contact impedance is ≤10kΩ and the communication of each device is normal, it enters the standby state; otherwise, the smart touch screen alarm prompts. S2. Flavor Selection Based on Multi-Brain Region Signal Coordination: The intelligent touchscreen displays an SSVEP stimulation interface containing five frequency-phase uniquely matched pixel blocks, and the user focuses on the target flavor pixel block. The main control unit first detects the attention value of the prefrontal cortex EEG signal, and only receives the occipital SSVEP signal when the attention value is ≥30 for 3 consecutive seconds. The SSVEP signal is then processed sequentially, including preprocessing, filter group band filtering, FB-CCA algorithm target recognition, and Bayesian posterior probability control state judgment. The preprocessing includes removing bad leads with SNR <30dB, 50Hz notch filtering, and 0.1-30Hz bandpass filtering. The filter group band filtering uses eight groups of 6-15Hz bandpass filters. When the recognition accuracy is ≥95%, a flavor selection instruction is generated. S3. Quantitative Raw Material Dispensing and Status Feedback: Based on the flavor selection command, the main control unit controls the corresponding storage unit electromagnetic cover of the modular raw material dispensing box to open for a preset time via I2C communication. The opening time for the cover of corn kernels and cooking oil is 1.5 seconds, the opening time for the cover of granular flavor raw materials is 1.2 seconds, and the opening time for the cover of powdered flavor raw materials is 1.5 seconds. The single dispensing amount error is ≤±2g. During the dispensing process, the infrared sensor monitors the feeding channel in real time. If no raw material falls for 2 consecutive seconds, the servo motor performs an alternating action of forward rotation for 0.5 seconds and reverse rotation for 0.3 seconds. This action is repeated 3 times. If the blockage is still not resolved, an alarm is triggered. S4. Focus-Adaptive Heating Control: After raw material is added, the main control unit detects the focus value. If the focus value is ≥30 for 3 consecutive seconds, the heating module preheating phase is initiated. During the preheating phase, the heating power is 50% and the running time is 100 seconds. After preheating, the signal power values ​​of the α, β, and θ bands of the prefrontal cortex are extracted using Fast Fourier Transform. The frequency range of the α band is 8-12Hz, the β band is 12-30Hz, and the θ band is 4-8Hz. The original focus value is calculated using β / (α+θ) and mapped to a focus value in the range of 0-100. The heating power is adjusted according to the linear relationship between focus and heating power: 30%-50% heating power for focus 30-50, 51%-70% for focus 51-70, and 71%-100% for focus 71-100. Simultaneously, the relay heats for N seconds and stops for 10-N seconds. The cycle repeats every second, and N is the concentration value divided by 10 and rounded to the nearest integer. S5. Abnormal Protection and Process Termination: During the heating process, if the focus level is <20 for 5 seconds, the main control unit will pause heating and prompt "Please increase focus level" through the smart touch screen; if the cumulative heating time is ≥8 minutes, the user triggers the "End Production" command, or the focus level is <20 for 10 seconds, the main control unit will automatically cut off the power to the heating module, the buzzer will sound a prompt, and the production log for this production will be stored. The log content includes timestamps, focus level curves, and equipment status data.