A smart tablet support control method and system based on MCU

By adopting an MCU-based intelligent tablet bracket control method, the coordination problem between charging management and attitude control was solved, achieving high-precision and stable attitude adjustment, and improving the system's real-time response capability and user experience.

CN121008603BActive Publication Date: 2026-02-10SHANGHAI LINGYUE ELECTRONIC TECH CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511500858.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-10-21
Publication Date
2026-02-10
Estimated Expiration
2045-10-21

AI Technical Summary

Technical Problem

Existing tablet mounts lack an effective coordination mechanism between charging management and attitude control, resulting in inaccurate attitude adjustment during charging, electromagnetic interference affecting sensor measurement accuracy, and insufficient multitasking capabilities, making it difficult to meet the complex needs of modern intelligent applications.

Method used

An MCU-based intelligent flat panel bracket control method is adopted. Through multi-sensor synchronous data packets, hierarchical detection strategy, interference compensation technology, priority task scheduling, and segmented motor control, the charging status and attitude control are coordinated, electromagnetic interference is suppressed, and high precision and stability are ensured.

Benefits of technology

It achieves coordinated operation between the charging process and attitude adjustment, suppresses the influence of electromagnetic interference on the attitude sensor, ensures high precision and stability of gimbal control, and improves the system's real-time response capability and user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121008603B_ABST
    Figure CN121008603B_ABST
Patent Text Reader

Abstract

The application relates to the technical field of intelligent hardware control, and discloses an intelligent flat plate support control method and system based on MCU, wherein the intelligent flat plate support control method based on MCU comprises the following steps: synchronously reading signals of a three-axis accelerometer, a gyroscope, a magnetometer and a charging detection circuit; performing coarse classification through a voltage threshold value and fine identification through a current change rate; dynamically adjusting filter parameters and correcting electromagnetic interference through an interference compensation parameter table; adopting a priority preemption type task scheduling strategy, avoiding task conflicts and resource competition through a time slice rotation and a resource mutual exclusion lock mechanism; adopting a segmented motor control strategy for a task scheduling scheme to obtain a head control position control instruction; dynamically adjusting charging power; and adopting state caching and incremental updating technology to obtain an updated control instruction; through hierarchical charging state detection technology, the system can accurately identify different charging stages, and dynamically adjusts head control parameters according to the charging state.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent hardware control technology, and more specifically, to an intelligent tablet stand control method and system based on an MCU. Background Technology

[0002] With the rapid development of mobile internet technology and the widespread adoption of remote work, tablet computers have become essential terminal devices in modern enterprise meetings, distance education, and digital presentations. In these applications, tablets need to maintain stable operation for extended periods and be able to intelligently adjust their angle and position according to usage needs and environmental changes. This places increasingly higher demands on the intelligence level of tablet stand systems.

[0003] Existing tablet support technologies mainly include mechanical supports, electrically adjustable supports, and simple smart supports. Mechanical supports have a simple structure but lack automatic adjustment capabilities, requiring manual operation by the user and failing to meet the needs of intelligent applications. While electrically adjustable supports possess basic electric adjustment functions, their control methods are simple and lack intelligent sensing and adaptive adjustment capabilities. Existing smart supports, although integrating some sensors and control functions, still have significant shortcomings in areas such as the coordination of charging management and attitude control, the real-time performance of multi-tasking, and the suppression of electromagnetic interference.

[0004] Especially in applications requiring long-term continuous operation, charging management and attitude control of tablet devices are often designed as independent functional modules, lacking an effective coordination mechanism. This results in the inability to perform precise attitude adjustments during charging, or in charging efficiency being affected during attitude adjustments. Simultaneously, electromagnetic interference generated during charging affects the measurement accuracy of attitude sensors, leading to jitter and drift issues in the gimbal control system. Furthermore, existing solutions have numerous limitations in multi-tasking capabilities, system resource management, and user interaction, making it difficult to meet the complex demands of modern intelligent applications. Therefore, there is an urgent need for an intelligent tablet bracket control technology that can effectively integrate charging management and gimbal control functions, possessing high precision, high stability, and strong real-time performance. Summary of the Invention

[0005] This invention provides a smart tablet bracket control method and system based on MCU, which solves the technical problems in related technologies such as lack of linkage between charging status and gimbal attitude control, electromagnetic interference affecting control accuracy, and imperfect system thermal management.

[0006] This invention provides a smart tablet stand control method based on an MCU, comprising:

[0007] The signals from the triaxial accelerometer, gyroscope, magnetometer, and charging detection circuit are read synchronously to obtain a multi-sensor synchronous data packet;

[0008] Based on the voltage and current information in the multi-sensor synchronous data packet, a hierarchical detection strategy is adopted. The charging status detection result is obtained by coarse classification of voltage threshold and fine identification of current change rate.

[0009] Based on the charging status detection results, the filter parameters are dynamically adjusted and electromagnetic interference is corrected through the interference compensation parameter table to obtain attitude angle information;

[0010] A priority-preemptive task scheduling strategy is adopted for attitude angle information and charging status detection results. Task conflicts and resource contention are avoided by time slice round-robin and resource mutex lock mechanism to obtain the task scheduling scheme.

[0011] The task scheduling scheme adopts a segmented motor control strategy, which decomposes large-angle motion into small-angle segments and uses cubic spline interpolation to generate control curves to obtain gimbal position control commands.

[0012] An adaptive power adjustment strategy is adopted for the motor control state during the execution of gimbal position control commands to dynamically adjust the charging power and obtain power allocation parameters.

[0013] The updated control commands are obtained by using state caching and incremental update techniques on multi-sensor synchronization data packets, charging status detection results, attitude angle information, task scheduling schemes, gimbal position control commands, and power allocation parameters.

[0014] In a preferred embodiment, the step of generating the multi-sensor synchronization data packet includes:

[0015] Based on the HC32F005 microcontroller, the TIM1, TIM2, and TIM3 timers are configured to trigger interrupts with the same period. When an interrupt occurs, the signals from the triaxial accelerometer, gyroscope, magnetometer, and charging detection circuit are read sequentially according to a preset sequence. Each sensor is sampled three times continuously and the average value is taken. At the same time, the system clock count value at the sampling time is recorded as a timestamp to obtain a multi-sensor synchronization data packet.

[0016] In a preferred embodiment, the hierarchical detection strategy is specifically implemented as follows:

[0017] Based on the voltage and current information in the multi-sensor synchronization data packet, a voltage threshold judgment method is used for coarse classification. The low voltage threshold is set to 3.2V and the high voltage threshold is set to 4.2V. When the detected voltage is below 3.2V, it is determined to be in a non-charging state. When the voltage is between 3.2V and 4.2V and a charging current is detected, it is determined to be in a charging state. When the voltage reaches 4.2V and the charging current is less than 0.1A, it is determined to be in a charging complete state.

[0018] Calculate the rate of change of charging current during charging, and identify the fast charging, slow charging, and trickle charging stages based on the current magnitude and rate of change to obtain the charging status detection results.

[0019] In a preferred embodiment, the step of generating the attitude angle information includes:

[0020] A state vector containing pitch angle, roll angle and yaw angle is established based on the charging state detection results. The noise covariance matrix is ​​dynamically adjusted according to the charging state. The process noise covariance and observation noise covariance are increased during the fast charging stage, and the noise covariance is decreased during the no-charging and trickle charging stages.

[0021] A two-dimensional compensation parameter table is established based on different charging power levels and sensor types. A fast lookup method of the preset parameter table is used to linearly correct the original sensor data to obtain attitude angle information.

[0022] In a preferred embodiment, the step of generating the task scheduling scheme includes:

[0023] Based on attitude angle information and charging status detection results, a task queue including gimbal control, charging management and temperature monitoring is established. The task priority is set according to the charging status. In fast charging state, the temperature monitoring task is set to the highest priority, and in non-charging state, the gimbal control task is set to the highest priority.

[0024] The time-slice round-robin scheduling algorithm is used to allocate processor time to obtain a task scheduling scheme.

[0025] In a preferred embodiment, the step of generating the gimbal position control command includes: based on the task scheduling scheme, adopting a segmented motor control strategy, decomposing large-angle motion into multiple continuous small-angle motion segments, generating a smooth position-time control curve using cubic spline interpolation within each motion segment, dynamically adjusting the motor acceleration and maximum motion speed parameters according to the current system load state, and achieving closed-loop position control through encoder feedback to obtain the gimbal position control command.

[0026] In a preferred embodiment, the generation of the power allocation parameters includes:

[0027] Based on the motor control status and power consumption information during the execution of gimbal position control commands, an adaptive power adjustment strategy is adopted to monitor three power consumption sources in real time: tablet charging power, gimbal motor drive power, and control circuit power consumption. The total power consumption of the system is obtained by adding the three power consumption sources together.

[0028] A simplified thermodynamic model is used for temperature prediction. The system temperature change rate is calculated based on the current total power consumption, system temperature, ambient temperature, and preset thermal resistance and thermal capacity parameters. When the predicted temperature exceeds the safety threshold, power regulation measures are executed according to preset priority order to obtain power allocation parameters.

[0029] In a preferred embodiment, the step of generating the updated control command includes: based on the power allocation parameters, using state caching and incremental update technology, establishing a core parameter data model that includes multi-sensor synchronization data packets, charging status detection results, attitude angle information, task scheduling scheme, gimbal position control commands and power allocation parameters, setting a parameter change threshold to trigger an update mechanism, and triggering an incremental update of the user interface when any parameter change exceeds the preset threshold to obtain the updated control command.

[0030] In a preferred embodiment, the step of generating the multi-sensor synchronization data packet further includes: using adaptive sampling frequency adjustment technology, the system continuously monitors triaxial accelerometer data, calculates the Euclidean distance of the acceleration vector between two adjacent samples as a motion intensity index, sets a motion intensity threshold, and when the motion intensity of ten consecutive samples is less than the set threshold, it is determined that the plate is in a stationary state, and the system automatically adjusts the sampling frequency from the standard ten milliseconds to once every five milliseconds. When the motion intensity is detected to exceed the threshold and is continuously sampled three times, it is determined to be a rapid motion state, and the system immediately increases the sampling frequency to once every two milliseconds.

[0031] In a preferred embodiment, an MCU-based intelligent tablet stand control system is used to execute the above-described MCU-based intelligent tablet stand control method, comprising:

[0032] The data acquisition module is used to synchronously read signals from the triaxial accelerometer, gyroscope, magnetometer, and charging detection circuit to obtain multi-sensor synchronous data packets;

[0033] The charging status detection module is used to obtain the charging status detection result by adopting a hierarchical detection strategy based on the voltage and current information in the multi-sensor synchronous data packet, through coarse classification of voltage threshold and fine identification of current change rate.

[0034] The attitude calculation module is used to dynamically adjust the filtering parameters based on the charging status detection results and correct electromagnetic interference through the interference compensation parameter table to obtain attitude angle information.

[0035] The task scheduling module is used to apply a priority-based preemptive task scheduling strategy to attitude angle information and charging status detection results. It avoids task conflicts and resource contention through time slice round-robin and resource mutex lock mechanisms to obtain a task scheduling scheme.

[0036] The motor control module is used to adopt a segmented motor control strategy for the task scheduling scheme, decompose large-angle motion into small-angle segments and use cubic spline interpolation to generate control curves to obtain gimbal position control commands.

[0037] The power adjustment module is used to dynamically adjust the charging power by adopting an adaptive power adjustment strategy for the motor control status during the execution of gimbal position control commands, thereby obtaining power allocation parameters.

[0038] The status update module is used to obtain updated control commands by using status caching and incremental update technology for multi-sensor synchronization data packets, charging status detection results, attitude angle information, task scheduling schemes, gimbal position control commands and power allocation parameters.

[0039] The beneficial effects of this invention are as follows: By using a multi-task parallel processing architecture based on the HC32F005 microcontroller, charging management and gimbal control are deeply integrated into a unified control system, which effectively solves the technical problem that the two subsystems are independent and lack coordination in the traditional solution.

[0040] Through graded charging status detection technology, the system can accurately identify different stages of charging and dynamically adjust the gimbal control parameters according to the charging status, achieving coordinated operation between the charging process and attitude adjustment. At the same time, the interference compensation technology effectively suppresses the impact of electromagnetic interference during the charging process on the attitude sensor, ensuring the high precision and stability of gimbal control, and providing a technical foundation for realizing truly intelligent flat panel bracket control.

[0041] A hardware timer interrupt-driven multi-sensor synchronous acquisition strategy ensures the time synchronization and quality reliability of sensor data. A simplified second-order Kalman filter technique is used for multi-sensor data fusion, combined with a preset interference compensation parameter table, effectively improving the accuracy and real-time performance of attitude calculation. A segmented motor control strategy generates smooth motion trajectories through cubic spline interpolation, and combined with PID closed-loop control and feedforward compensation, achieves high-precision position control. A priority task scheduling strategy ensures the system's real-time response capability through reasonable resource allocation and task coordination, improving the user experience and overall system performance. Attached Figure Description

[0042] Figure 1 This is a flowchart of an MCU-based intelligent tablet support control method according to the present invention;

[0043] Figure 2 This is a block diagram of an MCU-based intelligent tablet stand control system according to the present invention;

[0044] Figure 3 It is a bar chart comparing the accuracy of charging status detection;

[0045] Figure 4 It is a line graph showing how the gimbal control accuracy changes with the charging status;

[0046] Figure 5 This is a combined diagram of the system's temperature management effectiveness. Detailed Implementation

[0047] The subject matter described herein will now be discussed with reference to exemplary embodiments. It should be understood that these embodiments are discussed only to enable those skilled in the art to better understand and implement the subject matter described herein, and changes may be made to the function and arrangement of the elements discussed without departing from the scope of this specification. Various processes or components may be omitted, substituted, or added as needed in the examples. Furthermore, some features described in the examples may be combined in other examples.

[0048] At least one embodiment of the present invention discloses a smart tablet holder control method based on an MCU, such as... Figure 1 As shown, it includes:

[0049] Step 1: Synchronously read signals from the triaxial accelerometer, gyroscope, magnetometer, and charging detection circuit to obtain a multi-sensor synchronous data packet;

[0050] Based on the HC32F005 microcontroller's multi-channel timer resources and interrupt management mechanism, a hardware timer interrupt-driven synchronous acquisition strategy is adopted. By configuring timers to trigger interrupt service routines at the same time intervals, the voltage, current, and temperature signals of the three-axis accelerometer, three-axis gyroscope, magnetometer, and charging detection circuit are synchronously read in the interrupt, and a unified data timestamp is established to obtain high-quality multi-sensor synchronous data packets.

[0051] Specifically, the system initializes the TIM1, TIM2, and TIM3 timers of the HC32F005, setting a uniform sampling period of 10 milliseconds. When a timer interrupt is triggered, the system sequentially reads data from each sensor according to a preset acquisition sequence: acceleration and gyroscope data from the MPU6050 six-axis sensor are read via the I2C interface; data from the HMC5883L magnetometer is read via the SPI interface; and analog signals from the charging detection circuit are acquired via the ADC channel. To ensure data quality, the system performs three consecutive samples from each sensor and takes the average, while simultaneously recording the system clock count at each sampling moment as a timestamp.

[0052] Furthermore, adaptive sampling frequency adjustment technology can be adopted, the purpose of which is to dynamically optimize system resource allocation and control accuracy based on the motion state of the flat plate. The specific implementation steps are as follows: The system continuously monitors the data of the three-axis accelerometers and calculates the Euclidean distance of the acceleration vector between two adjacent samplings as a motion intensity index. The specific calculation method of the Euclidean distance is as follows: Let the current three-axis accelerations be ax1, ay1, and az1, and the previous three-axis accelerations be ax0, ay0, and az0. Then the Euclidean distance is equal to the square root of the sum of the squares of the differences in the three axial accelerations. That is, first calculate the square of the difference in the x-axis acceleration, the square of the difference in the y-axis acceleration, and the square of the difference in the z-axis acceleration, then add the three squared values, and finally take the square root of the sum to obtain the motion intensity value. The motion intensity value reflects the change amplitude of the acceleration vector in three-dimensional space; set a motion intensity threshold, when ten consecutive... When the motion intensity of each sampled motion is less than the set threshold, the plate is determined to be stationary. At this time, the system automatically adjusts the sampling frequency from the standard 10 milliseconds to once every 5 milliseconds, effectively saving the microcontroller's computing resources and power consumption. When the motion intensity is detected to exceed the threshold and is continuously sampled three times, it is determined to be a rapid motion state. The system immediately increases the sampling frequency to once every 2 milliseconds to ensure sufficient data density in a high-dynamic environment to improve attitude calculation and control accuracy. To avoid the impact of frequent frequency switching on system stability, a sliding window averaging method is used to smooth the motion intensity. The window length is set to five sampling points. Frequency switching is only performed when the smoothed motion intensity continuously exceeds or falls below the threshold, thereby achieving a smooth adaptive adjustment process.

[0053] During data preprocessing, the system performs digital filtering on voltage and current signals to remove high-frequency noise generated by the switching power supply. A low-pass filter is used with a cutoff frequency of 50Hz; the filtered signal is then used for subsequent charging state analysis. Simultaneously, the system normalizes sensor data. Specifically, for accelerometer data, the maximum measurement range for each axis (typically ±16g) is obtained, and the original measurement value is divided by the maximum measurement range to obtain the normalized result, ensuring the data range is between [-1, 1]. For gyroscope data, based on the sensor's full-scale range (typically ±2000 degrees per second), the original angular velocity value is divided by the full-scale value and then multiplied by 500, normalizing the data range to [-500, 500] degrees per second. For magnetometer data, by measuring the maximum and minimum magnetic field strength values ​​for each axis, a maximum-minimum normalization method is used to map the data to the [-1, 1] range. Specifically, the current measurement value is subtracted from the minimum value, then divided by the difference between the maximum and minimum values, and finally multiplied by 2 and subtracted by 1. Furthermore, the system encodes the charging status indicators, converting the text-based status indicators into numerical codes: 0 for not charging, 1 for fast charging, 2 for slow charging, 3 for trickle charging, and 4 for charging complete. This facilitates subsequent numerical calculations and status determination. This encoding method ensures the comparability and consistency of numerical calculations for different charging states.

[0054] Step 2: Based on the voltage and current information in the multi-sensor synchronous data packet, a hierarchical detection strategy is adopted. Through coarse classification of voltage threshold and fine identification of current change rate, the charging status detection result is obtained.

[0055] Based on the voltage, current, and temperature information from the multi-sensor synchronized data obtained in step 1, a hierarchical detection strategy is adopted for charging status identification. A rapid coarse classification is performed using voltage thresholds, dividing the charging status into three basic categories: not charging, charging in progress, and charging complete. For the charging in progress state, current change rate analysis and power calculation are used for refined identification, distinguishing specific stages such as fast charging, slow charging, and trickle charging. A simplified state transition model is established to obtain the charging status detection results, including accurate charging status identification and state transition probability information.

[0056] In the specific implementation, the first-level coarse classification uses a voltage threshold judgment method. The system presets three voltage thresholds: a low voltage threshold of 3.2V, a normal voltage threshold of 3.7V, and a high voltage threshold of 4.2V. When the detected voltage is below 3.2V, it is determined to be in a non-charging state; when the voltage is between 3.2V and 4.2V and charging current is detected, it is determined to be in a charging state; when the voltage reaches 4.2V and the charging current is less than 0.1A, it is determined to be in a charging complete state.

[0057] The second level of refined identification further analyzes the charging status. The system calculates the rate of change of the charging current:

[0058] The rate of change of current is calculated using a differential method. Specifically, the charging current value measured at the current moment is subtracted from the charging current value recorded at the previous moment, and this current difference is divided by the time interval between the two measurements to obtain the change in current per unit time. Here, the charging current at the current moment refers to the instantaneous current value measured in real time by the current sensor during the current sampling period, the charging current at the previous moment refers to the historical current value recorded and stored by the system in the previous sampling period, and the time interval is a fixed time difference between two consecutive current samples, typically set to ten milliseconds to ensure sufficient time resolution and calculation accuracy.

[0059] When the charging current is greater than 1.5A and the current change rate is less than -0.1A / s, it is identified as the fast charging stage; when the charging current is between 0.5A and 1.5A and the current change rate is between -0.05A / s and 0.05A / s, it is identified as the slow charging stage; when the charging current is less than 0.5A and the current change rate is less than -0.02A / s, it is identified as the trickle charging stage.

[0060] Furthermore, power trend analysis technology can be employed to enhance the accuracy and predictive capability of charging state identification by analyzing the trend of charging power changes. The specific implementation steps are as follows: The system calculates the charging power in real time by multiplying the currently detected charging voltage value by the charging current value to obtain the instantaneous power value; a time series of power data is established, with the system continuously recording the power values ​​for the most recent twenty sampling periods to form a power change curve; the rate of change of the power curve is calculated, and the power change trend is determined by comparing the difference between adjacent power values. A rising phase is marked when three consecutive power values ​​show an increasing trend, and a falling phase is marked when three consecutive power values ​​show a decreasing trend; the acceleration characteristics of power changes are analyzed, and charging state transition points are identified by comparing the changes in the rate of power change. When the rate of power change changes from a positive value to a negative value, it indicates that charging has entered a stable phase; a significant negative abrupt change in the rate of power change indicates that a charging state transition is imminent; based on the power trend analysis results, the state transition is predicted in advance, providing the system with a warning time of three to five seconds, allowing subsequent attitude compensation strategies to adjust parameters in advance and ensuring the continuity of control accuracy during charging state switching.

[0061] Step 3: Dynamically adjust the filter parameters based on the charging status detection results and correct electromagnetic interference through the interference compensation parameter table to obtain attitude angle information;

[0062] Based on the charging status detection results obtained in step 2 and the multi-sensor synchronization data packets obtained in step 1, a simplified second-order Kalman filter technique is used to fuse multi-sensor data. The filter parameters are dynamically adjusted according to the charging status, and the influence of charging electromagnetic interference in the sensor data is quickly corrected through a preset interference compensation parameter table. This reduces computational complexity while ensuring filtering accuracy, resulting in high-precision attitude angle information after interference compensation.

[0063] In its implementation, the system establishes an attitude state prediction model, using the current pitch, roll, and yaw angles as state variables, and combining this with angular velocity information measured by the gyroscope to predict the attitude state at the next moment. The prediction process considers the system's motion characteristics and the influence of external disturbances, calculating the predicted value through a state transition relationship. Specifically, this relationship involves multiplying the current attitude angle by the angular velocity measured by the gyroscope by the time interval and adding the results to obtain the predicted attitude angle for the next moment. Simultaneously, considering the influence of system noise, a random disturbance term based on historical error statistics is added to the prediction result. Simultaneously, the system establishes an observation model, using the measurement data from the accelerometer and magnetometer as observations. The system establishes a connection between sensor measurements and attitude states through observation relationships. Specifically, the observation relationships are implemented as follows: utilizing the projection relationship of gravitational acceleration under different attitudes, the three-axis measurements of the accelerometer are converted into observed values ​​for pitch and roll angles. The specific calculation method is that the pitch angle equals the arcsine of the Y-axis component of acceleration and the magnitude of gravitational acceleration, and the roll angle equals the arcsine of the X-axis component of acceleration and the magnitude of gravitational acceleration. Utilizing the projection relationship of the geomagnetic field under different attitudes, the three-axis measurements of the magnetometer are combined with known pitch and roll angle information to calculate the observed yaw angle. The yaw angle relative to magnetic north is obtained through the arctangent of the magnetometer's horizontal component.

[0064] The filtering process employs a two-step prediction and correction method. In the prediction step, the system predicts the attitude state at the current moment based on the optimal estimate from the previous moment and gyroscope data, while simultaneously calculating the covariance matrix of the prediction error. In the correction step, the system uses observation data from the accelerometer and magnetometer to correct the prediction results, obtaining the optimal attitude estimate by minimizing the variance of the estimation error.

[0065] The key feature of this technology is its dynamic adjustment of filtering parameters based on the charging status. During the fast charging phase, the electromagnetic interference generated by the large charging current is strong. The system automatically increases the covariance parameters of process noise and observation noise, reducing the confidence in sensor measurement data and relying more on the system's predictive model. During the no-charging or trickle charging phases, the electromagnetic interference is weak, and the system reduces the noise covariance parameters, increasing the confidence in sensor data and thus achieving higher filtering accuracy.

[0066] Interference compensation is achieved through a fast lookup of a preset parameter table. The system establishes a two-dimensional compensation parameter table based on different charging power levels (no charging, trickle charging, slow charging, fast charging) and sensor types (accelerometer, gyroscope, magnetometer), with each entry containing the compensation coefficient for the corresponding condition. In actual operation, the system quickly looks up the appropriate compensation coefficient based on the current charging state and sensor type, linearly correcting the original sensor data and effectively eliminating the impact of charging electromagnetic interference on attitude measurement.

[0067] Furthermore, dynamic interference modeling technology can be used, the purpose of which is to achieve more accurate electromagnetic interference compensation by analyzing interference characteristics in real time. The specific implementation steps are as follows: The system continuously monitors the charging current signal, acquires current waveform data through high-speed sampling, and caches the sampled data to establish a sliding data window with a length of 124 sampling points; the cached current data is processed by Fast Fourier Transform to convert the time-domain signal into a frequency-domain signal, and the frequency components and amplitude distribution contained in the current signal are analyzed to identify the main interference frequencies generated by the switching power supply and charging control circuit; a frequency-domain characteristic model of electromagnetic interference is established, the identified interference frequencies are sorted according to their amplitude, the top five frequencies with the largest amplitudes are selected as the main interference sources, and their frequency values ​​and corresponding amplitude information are recorded; an adaptive notch filter is designed, and the center frequency parameter of the filter is dynamically adjusted according to the identified interference frequency to accurately suppress the interference frequency, while the quality factor of the filter is adjusted according to the interference amplitude to ensure that the useful signal is not affected while effectively suppressing the interference; the designed notch filter is applied to the sensor data processing link to filter the raw data of the accelerometer, gyroscope, and magnetometer to eliminate interference components of specific frequencies, so as to obtain high-quality attitude measurement data even in complex electromagnetic interference environments.

[0068] Step 4: A priority-based preemptive task scheduling strategy is adopted for the attitude angle information and charging status detection results. Task conflicts and resource competition are avoided through time slice round-robin and resource mutual exclusion lock mechanism to obtain the task scheduling scheme.

[0069] Based on the attitude angle information and charging status detection results obtained in step 3, a priority-based preemptive task scheduling strategy is adopted. Charging safety management is set as the highest priority task, attitude control is set as a medium priority task, and user interaction and data communication are set as low priority tasks. Task conflicts and resource contention are avoided through time slice rotation and resource mutual exclusion lock mechanisms, resulting in a stable and reliable system operation status and task scheduling scheme.

[0070] The system adopts a three-level priority scheduling mechanism. The highest priority is for emergency safety tasks, including overvoltage, overcurrent, and overtemperature protection, with a response time requirement of less than 1 millisecond; the medium priority is for real-time control tasks, including attitude calculation, motor control, and sensor acquisition, with a response time requirement of less than 10 milliseconds; and the low priority is for background tasks, including data recording, communication processing, and interface updates, with an acceptable response time of less than 100 milliseconds.

[0071] Task scheduling employs a preemptive strategy, allowing high-priority tasks to interrupt the execution of low-priority tasks. To prevent task starvation, the system sets a maximum continuous execution time for each priority level: high-priority tasks can execute for a maximum of 5 milliseconds, medium-priority tasks for a maximum of 20 milliseconds, and low-priority tasks for a maximum of 50 milliseconds. Once the maximum execution time is exceeded, the system forcibly switches tasks.

[0072] Resource management employs mutexes and semaphores. For shared hardware resources (such as ADC, I2C, and SPI interfaces), the system uses mutexes for protection, ensuring that only one task can access them at a time. For software resources (such as data buffers and computation results), the system uses semaphores for synchronization control, avoiding data races and inconsistencies.

[0073] Furthermore, dynamic priority adjustment technology can be adopted, the purpose of which is to optimize task scheduling and system resource utilization through intelligent priority management. The specific implementation steps are as follows: The system maintains execution statistics for each task, including the cumulative number of executions, average execution time, most recent execution time, and dwell time in the waiting queue; a task starvation detection mechanism is established. When the dwell time of a low-priority task in the waiting queue exceeds a preset threshold (e.g., 100 milliseconds), the system marks it as starved and temporarily raises its priority level to ensure that the task can get an execution opportunity within a reasonable time; load balancing control for high-priority tasks is implemented. When a high-priority task is detected to execute more than three times consecutively within a short period of time (e.g., 10 milliseconds), the system appropriately lowers its priority level by one to make room for other tasks and avoids system resources being occupied by a single task for a long time; a system load monitoring mechanism is established to monitor the CPU utilization and execution frequency of each priority task in real time. When the overall system load exceeds 80%, the load balancing strategy is automatically activated to balance the system load by adjusting the task priority distribution; a priority recovery mechanism is set up so that when the starvation status of a task is relieved or the load pressure is alleviated, the system automatically restores the task priority to its original set value, ensuring the temporary nature of the priority adjustment and the stability of the system scheduling strategy.

[0074] Step 5: The task scheduling scheme adopts a segmented motor control strategy, which decomposes large-angle motion into small-angle segments and uses cubic spline interpolation to generate control curves to obtain gimbal position control commands.

[0075] Based on the task scheduling scheme and target attitude command obtained in step 4, a segmented motor control strategy is adopted to decompose the large-angle motion into multiple continuous small-angle motion segments. Within each motion segment, cubic spline interpolation is used to generate a smooth position-time control curve. The acceleration and maximum motion speed parameters of the motor are dynamically adjusted according to the current load state of the system. Closed-loop position control is achieved through encoder feedback to obtain gimbal position control commands, ensuring accurate and smooth gimbal motion control effect.

[0076] The motion trajectory planning employs cubic spline interpolation to achieve smooth control. Specifically, the system calculates the angle difference between the current and target angular positions, and then combines this with preset maximum angular velocity and maximum angular acceleration parameters to calculate the total time required to complete the entire motion. The calculation process considers the time allocation between the acceleration and constant velocity phases to ensure the motion is both fast and smooth.

[0077] The core feature of this method is trajectory segmentation. The system evenly divides the calculated total motion time into multiple small time intervals, typically ten to twenty, each with equal duration. Within each time interval, the system uses a cubic polynomial function to describe the change in position over time. The coefficients of the polynomial are determined by setting boundary conditions and continuity conditions. Specifically, at the start of motion, the position boundary condition is set to the current actual angular position, the velocity boundary condition is set to zero (start from rest), and the acceleration boundary condition is set to the preset maximum starting acceleration. At the end of motion, the position boundary condition is set to the target angular position, the velocity boundary condition is set to zero (smooth stop), and the acceleration boundary condition is set to zero (stop without impact). The continuity condition is implemented as follows: at the boundary of each time interval, the ending position of the previous segment must equal the starting position of the next segment, the ending velocity of the previous segment must equal the starting velocity of the next segment, and the ending acceleration of the previous segment must equal the starting acceleration of the next segment. A system of linear equations is established using these constraints, and the four coefficients of the cubic polynomial for each time interval are solved to ensure continuity of position, velocity, and acceleration between adjacent time intervals, thus generating a smooth overall motion trajectory.

[0078] The motor control employs a proportional-integral-derivative (PID) closed-loop regulation strategy. The system calculates the position error in real time, i.e., the difference between the target position and the actual position, and calculates the proportional, integral, and derivative terms of the error. The proportional term reflects the magnitude of the current error, the integral term reflects the cumulative effect of historical errors, and the derivative term reflects the trend of error changes. The controller weights and sums these three terms according to preset gain coefficients to obtain the final control output signal to drive the motor.

[0079] The system possesses adaptive load adjustment capabilities, dynamically adjusting control parameters based on the current system load status. When a heavy system load is detected, such as when a heavy object is placed on the plate or the motor drive resistance increases, the system automatically increases the proportional gain and integral gain to improve the controller's response speed and steady-state accuracy. When the system load is light, the system increases the derivative gain to improve system stability and effectively suppress overshoot, ensuring optimal control performance under various load conditions.

[0080] Furthermore, feedforward control technology can be used, the purpose of which is to improve the tracking accuracy and response speed of motor control by predicting and compensating for the dynamic characteristics of the system. The specific implementation steps are as follows: The system calculates the desired angular velocity and desired angular acceleration at each moment according to the pre-planned motion trajectory, and establishes time series data of motion parameters; a dynamic characteristic model of the motor system is established, including the main influencing factors such as rotational inertia effect, viscous friction resistance, and Coulomb friction, and the values ​​of each dynamic parameter are obtained through offline calibration; the inertial compensation amount is calculated based on the desired angular acceleration and system rotational inertia, which is used to overcome the inertial resistance when the motor accelerates or decelerates; the viscous friction compensation amount is calculated based on the desired angular velocity and viscous friction coefficient, which is used to overcome the resistance proportional to the speed during motor motion; the static friction compensation amount is calculated based on the direction of the desired angular velocity and the magnitude of the Coulomb friction, with the compensation amount being positive when the desired angular velocity is positive and negative when the desired angular velocity is negative, used to overcome the constant friction resistance opposite to the direction of motion; the inertial compensation amount, viscous friction compensation amount, and static friction compensation amount are added to obtain the total feedforward control amount, and this is added to the output of the feedback controller as the final motor drive signal, thereby realizing active compensation of the system's dynamic characteristics and improving the dynamic performance of the control system.

[0081] Step 6: Adaptive power adjustment strategy is adopted for the motor control state during the execution of gimbal position control commands to dynamically adjust the charging power and obtain power allocation parameters;

[0082] Based on the motor control status and power consumption information obtained in step 5, an adaptive power adjustment strategy is adopted. According to the real-time power consumption of the gimbal motor and the overall temperature change trend of the system, the charging power distribution of the tablet is dynamically adjusted. The cooling fan is started in advance and its speed is adjusted through the temperature prediction model. Power limiting and thermal protection measures are implemented to avoid the system overheating from affecting the control accuracy and equipment safety. The power distribution parameters are obtained to achieve the optimal charging management effect under thermal equilibrium.

[0083] The power regulation algorithm achieves intelligent management based on the principle of energy balance. Specifically, the system monitors three main power consumption sources in real time: tablet charging power, gimbal motor drive power, and control circuit power consumption. The system measures the actual power consumption of each component using current sensors and voltage detection circuits, and then adds the three power consumptions together to obtain the total system power consumption. This total power consumption data serves as a crucial input parameter for the thermal management algorithm, used to predict system temperature change trends.

[0084] Temperature prediction employs a simplified thermodynamic model for real-time calculation. Based on the current total power consumption, system temperature, ambient temperature, and preset thermal resistance and heat capacity parameters, the system calculates the rate of change of system temperature. The thermodynamic model is implemented as follows: the system is treated as a lumped-parameter thermodynamic system. The thermal resistance parameter represents the resistance to heat conduction within the system, with a typical value of 2.5 degrees Celsius per watt obtained through experimental calibration. The heat capacity parameter represents the system's heat storage capacity, with a typical value of 150 joules per degree Celsius calculated based on the material properties and mass of the system's main components. The prediction process considers both heat input from power consumption and heat output through heat dissipation paths. Specifically, heat input equals the current total power consumption multiplied by the time interval; heat output equals the difference between the system temperature and ambient temperature divided by the thermal resistance and then multiplied by the time interval; net heat change equals heat input minus heat output; and temperature change equals net heat change divided by the system heat capacity. The predicted temperature is obtained by adding the temperature change to the current temperature using a numerical integration method, thus predicting the system temperature trend over the next few minutes and providing a forward-looking decision-making basis for thermal protection strategies.

[0085] When the predicted temperature exceeds the safety threshold, the system executes power regulation measures according to a preset priority order. The first priority is to start the cooling fan to quickly reduce the system temperature through forced convection cooling; the second priority is to reduce charging power by reducing charging current to reduce heat generation; the third priority is to limit the motor speed to reduce drive power consumption by reducing motor load. The fan speed control adopts a closed-loop regulation strategy. The system calculates the fan speed command based on the difference between the current temperature and the target temperature, while also considering the historical accumulation and trend of temperature error to achieve precise temperature control.

[0086] Furthermore, an intelligent heat dissipation strategy can be adopted, aiming to achieve optimal energy consumption and thermal balance control through predictive thermal management and environmental adaptive adjustment. The specific implementation steps are as follows: The system establishes a database linking ambient temperature and usage patterns, recording the heat load characteristics corresponding to various usage patterns under different ambient temperatures, including key parameters such as average power consumption, peak power consumption, and temperature rise rate; predictive heat dissipation control is implemented, where the system queries the historical database based on the current ambient temperature and detected usage patterns to predict the heat load change trend within the next ten minutes. When the prediction indicates an approaching high heat load state, the system pre-starts the cooling fan and reduces the charging power by 20%, reserving heat dissipation margin for the upcoming high power consumption phase; an environmental adaptive adjustment strategy is implemented, where the system adjusts its cooling in high-temperature environments (above 25 degrees Celsius) or when a high load is detected. In normal operating modes (such as frequent motor operation), the system automatically lowers the fan start threshold by three degrees Celsius and limits the charging power to within 80% of the rated power. In low-temperature environments (below 20 degrees Celsius) or light-load modes (such as long-term static states), the system raises the fan start threshold by five degrees Celsius and allows the charging power to reach 110% of the rated power, making full use of good heat dissipation conditions to improve charging efficiency. A historical data learning mechanism is established, and the system continuously records the actual thermal management effect under different conditions. Through statistical analysis, the accuracy of the prediction model is optimized, and various threshold parameters are adjusted based on long-term operating data to achieve continuous optimization and personalized adaptation of the heat dissipation strategy.

[0087] Step 7: Apply state caching and incremental update techniques to the multi-sensor synchronization data packets, charging status detection results, attitude angle information, task scheduling scheme, gimbal position control commands, and power allocation parameters to obtain updated control commands;

[0088] Based on multi-sensor synchronous data packets, charging status detection results, attitude angle information, task scheduling schemes, gimbal position control commands, and power allocation parameters, a complete data model containing core parameters such as charging status, attitude angle, system temperature, and motor position is established using status caching and incremental update technologies. A parameter update judgment mechanism is set with thresholds for 0.5-degree attitude angle changes, 2-degree temperature changes, and 1-degree motor position changes. Communication overhead is reduced through JSON format differential encoding and hash mapping table field identifier compression transmission technology. A sliding window history of 1000 data points is maintained for trend analysis and anomaly detection, achieving efficient user interaction response. Real-time system monitoring and historical data recording functions are also provided to obtain updated control commands.

[0089] The status monitoring system maintains historical records of core parameters, including charging status, attitude angle, system temperature, and motor position. The system uses a sliding window to store the most recent 1000 data points for trend analysis and anomaly detection.

[0090] The incremental update mechanism determines whether the display needs to be updated based on parameter change thresholds. The system sets update thresholds for different parameters: update immediately when the charging status changes, update when the attitude angle changes by more than 0.5 degrees, update when the temperature changes by more than 2 degrees, and update when the motor position changes by more than 1 degree.

[0091] The user interface employs a layered display strategy. The main interface displays core status information, including current charging status, tablet posture, and system temperature; the detailed interface displays complete parameter information and historical curves; and the settings interface provides user-defined parameter configuration functions.

[0092] Data transmission employs differential encoding in JSON format. The system only transmits parameters that have changed, reducing the amount of communication data. Specifically, the system maintains a complete copy of the current state. Each update compares the new state with the cached state, and only packages the changed fields into JSON format, sending them to the user terminal via the wireless communication module. The differential encoding process is as follows: A hash mapping table for state fields is established, assigning a unique field identifier to each monitoring parameter (e.g., charging state corresponds to field ID 1, attitude angle to field ID 2). The values ​​of each field in the new state and the cached state are compared one by one. When a difference exceeds a preset threshold, the field ID and the new value are added to the differential data packet. The differential data packet is then serialized according to the JSON standard format, generating structured data containing timestamps, device IDs, and a list of changed fields. The JSON string is compressed using a data compression algorithm to further reduce the amount of transmitted data. The compressed data is sent via the wireless communication module. Upon receiving the data, the receiving end performs reverse decompression and parsing operations to update the local state cache, achieving efficient incremental data synchronization.

[0093] Furthermore, intelligent reminders and early warning functions can be adopted, aiming to enhance user experience and ease of use through proactive services and personalized suggestions. Specific implementation steps are as follows: Establish a user behavior data collection mechanism. The system continuously records user operations, including key behavioral characteristics such as daily usage time periods, angle adjustment frequency, charging timing selection, and interface interaction patterns, establishing a user behavior database covering at least thirty days of historical data; Implement a usage pattern recognition algorithm. The system uses statistical analysis methods to identify users' regular usage patterns, such as preferred angle ranges on weekday mornings, typical postures during meetings, and charging habits during rest periods, establishing a personalized user behavior characteristic model; Establish an intelligent prediction mechanism. Based on the current time, historical usage patterns, and device status, the system predicts the user's potential needs. When the tablet's battery level is detected to be below 20%, and based on… When historical data indicates that a user is about to enter a prolonged usage phase, the system proactively reminds the user to charge and automatically adjusts to the most suitable charging angle. It also implements a fatigue prevention reminder function; when the system detects that a user has maintained the same posture for more than 45 minutes, it proactively suggests that the user adjust the angle based on ergonomic principles, recommending three to five angle options that help relieve neck and eye fatigue. Furthermore, it establishes a personalized service recommendation engine; based on the user's long-term usage data and preferences, the system proactively recommends personalized settings, such as recommending the best viewing angle based on the user's height and sitting habits, and recommending suitable automatic adjustment modes based on the user's work nature, thereby achieving a truly intelligent and personalized service experience.

[0094] An MCU-based intelligent tablet stand control system is provided for executing the aforementioned MCU-based intelligent tablet stand control method, such as... Figure 2 As shown, it includes:

[0095] The data acquisition module is used to synchronously read signals from the triaxial accelerometer, gyroscope, magnetometer, and charging detection circuit to obtain multi-sensor synchronous data packets;

[0096] The charging status detection module is used to obtain the charging status detection result by adopting a hierarchical detection strategy based on the voltage and current information in the multi-sensor synchronous data packet, through coarse classification of voltage threshold and fine identification of current change rate.

[0097] The attitude calculation module is used to dynamically adjust the filtering parameters based on the charging status detection results and correct electromagnetic interference through the interference compensation parameter table to obtain attitude angle information.

[0098] The task scheduling module is used to apply a priority-based preemptive task scheduling strategy to attitude angle information and charging status detection results. It avoids task conflicts and resource contention through time slice round-robin and resource mutex lock mechanisms to obtain a task scheduling scheme.

[0099] The motor control module is used to adopt a segmented motor control strategy for the task scheduling scheme, decompose large-angle motion into small-angle segments and use cubic spline interpolation to generate control curves to obtain gimbal position control commands.

[0100] The power adjustment module is used to dynamically adjust the charging power by adopting an adaptive power adjustment strategy for the motor control status during the execution of gimbal position control commands, thereby obtaining power allocation parameters.

[0101] The status update module is used to obtain updated control commands by using status caching and incremental update technology for multi-sensor synchronization data packets, charging status detection results, attitude angle information, task scheduling schemes, gimbal position control commands and power allocation parameters.

[0102] In one embodiment of the present invention, a specific example is provided:

[0103] A 30-day field test was conducted in a smart conference room in a technology park in City A. During the test, 20 sets of smart tablet stand control systems based on the HC32F005 microcontroller were deployed, covering a 1200-square-meter conference area and involving conference room environments of different sizes. The test environment temperature ranged from 18°C ​​to 28°C, using a test tablet equipped with a 30W fast charger. The following are key data records obtained during system operation:

[0104] Table 1 shows an example of data acquisition by multiple sensors simultaneously:

[0105] Table 1: Example of simultaneous data acquisition by multiple sensors;

[0106] .

[0107] Table 1 shows the multi-sensor synchronous data acquired within a 10-millisecond sampling period, verifying the effectiveness of the hardware timer interrupt-driven synchronous acquisition strategy. Data timestamps are accurate to the millisecond level, ensuring the temporal consistency of the multi-sensor data.

[0108] Table 2 shows an example of how interference compensation parameters were obtained.

[0109] Table 2: Example of data acquisition for interference compensation parameters;

[0110] .

[0111] Table 2 shows the interference compensation parameter data obtained by the system under different charging states, verifying the effectiveness of the hierarchical detection strategy and interference compensation algorithm. By monitoring the electromagnetic interference intensity in real time and applying the corresponding compensation coefficients, the system can improve the accuracy of sensor data under various charging states.

[0112] like Figure 3 The diagram illustrates a comparison of the accuracy of the method of this invention with that of a traditional single voltage detection method in identifying different charging states. The chart clearly shows that the hierarchical detection strategy employed in this invention outperforms the traditional method in identifying all charging states, particularly in state transition identification, where the accuracy improvement is especially significant. Traditional methods are prone to misjudgment at state transition moments, while this invention effectively improves the accuracy of transition identification through current change rate analysis and power trend judgment.

[0113] like Figure 4 The figure shows the variation of gimbal control error and response time with charging state. It can be seen that during the fast charging phase, due to the strongest electromagnetic interference, both control error and response time reach their peak, but the interference compensation algorithm can still keep them within an acceptable range. During trickle charging and the charging completion phase, due to less interference, the control accuracy recovers to its optimal level. This figure verifies the correlation between charging state and gimbal control performance, as well as the effectiveness of the compensation algorithm.

[0114] like Figure 5 The figure shows the system's temperature management performance during 3 hours of continuous operation. The system temperature reached its peak of 52°C after 90 minutes of operation, at which point the cooling fan speed automatically adjusted to 80%, effectively controlling the temperature rise. Through adaptive power adjustment and intelligent heat dissipation strategies, the system temperature remained within a safe range, verifying the effectiveness of the thermal balance management algorithm. The automatic adjustment of fan speed maintained a good responsiveness to temperature changes, achieving efficient thermal management.

[0115] The embodiments of the present invention have been described above. However, the embodiments are not limited to the specific implementation methods described above. The specific implementation methods described above are merely illustrative and not restrictive. Those skilled in the art can make more equivalent embodiments under the guidance of the present embodiments, and all of them are within the protection scope of the present embodiments.

Claims

1. A control method for an intelligent flat panel bracket based on an MCU, characterized in that, include: The signals from the triaxial accelerometer, gyroscope, magnetometer, and charging detection circuit are read synchronously to obtain a multi-sensor synchronous data packet; Based on the voltage and current information in the multi-sensor synchronous data packet, a hierarchical detection strategy is adopted. The charging status detection result is obtained by coarse classification of voltage threshold and fine identification of current change rate. Based on the charging status detection results, the filter parameters are dynamically adjusted and electromagnetic interference is corrected through the interference compensation parameter table to obtain attitude angle information; A priority-preemptive task scheduling strategy is adopted for attitude angle information and charging status detection results. Task conflicts and resource contention are avoided by time slice round-robin and resource mutex lock mechanism to obtain the task scheduling scheme. The task scheduling scheme adopts a segmented motor control strategy, which decomposes large-angle motion into small-angle segments and uses cubic spline interpolation to generate control curves to obtain gimbal position control commands. An adaptive power adjustment strategy is adopted for the motor control state during the execution of gimbal position control commands to dynamically adjust the charging power and obtain power allocation parameters. The updated control commands are obtained by using state caching and incremental update techniques on multi-sensor synchronization data packets, charging status detection results, attitude angle information, task scheduling schemes, gimbal position control commands, and power allocation parameters.

2. The MCU-based intelligent tablet stand control method according to claim 1, characterized in that, The steps for generating the multi-sensor synchronization data packet include: Based on the HC32F005 microcontroller, the TIM1, TIM2, and TIM3 timers are configured to trigger interrupts with the same period. When an interrupt occurs, the signals from the triaxial accelerometer, gyroscope, magnetometer, and charging detection circuit are read sequentially according to a preset sequence. Each sensor is sampled three times continuously and the average value is taken. At the same time, the system clock count value at the sampling time is recorded as a timestamp to obtain a multi-sensor synchronization data packet.

3. The MCU-based intelligent tablet stand control method according to claim 1, characterized in that, The specific implementation of the hierarchical detection strategy is as follows: Based on the voltage and current information in the multi-sensor synchronization data packet, a voltage threshold judgment method is used for coarse classification. The low voltage threshold is set to 3.2V and the high voltage threshold is set to 4.2V. When the detected voltage is below 3.2V, it is determined to be in a non-charging state. When the voltage is between 3.2V and 4.2V and a charging current is detected, it is determined to be in a charging state. When the voltage reaches 4.2V and the charging current is less than 0.1A, it is determined to be in a charging complete state. Calculate the rate of change of charging current during charging, and identify the fast charging, slow charging, and trickle charging stages based on the current magnitude and rate of change to obtain the charging status detection results.

4. The MCU-based intelligent tablet stand control method according to claim 1, characterized in that, The steps for generating the attitude angle information include: A state vector containing pitch angle, roll angle and yaw angle is established based on the charging state detection results. The noise covariance matrix is ​​dynamically adjusted according to the charging state. The process noise covariance and observation noise covariance are increased during the fast charging stage, and the noise covariance is decreased during the no-charging and trickle charging stages. A two-dimensional compensation parameter table is established based on different charging power levels and sensor types. A fast lookup method of the preset parameter table is used to linearly correct the original sensor data to obtain attitude angle information.

5. The MCU-based intelligent tablet stand control method according to claim 1, characterized in that, The steps for generating the task scheduling scheme include: Based on attitude angle information and charging status detection results, a task queue including gimbal control, charging management and temperature monitoring is established. The task priority is set according to the charging status. In fast charging state, the temperature monitoring task is set to the highest priority, and in non-charging state, the gimbal control task is set to the highest priority. The time-slice round-robin scheduling algorithm is used to allocate processor time to obtain a task scheduling scheme.

6. The MCU-based intelligent tablet stand control method according to claim 1, characterized in that, The steps for generating the gimbal position control command include: based on the task scheduling scheme, adopting a segmented motor control strategy, decomposing large-angle motion into multiple continuous small-angle motion segments, generating a smooth position-time control curve using cubic spline interpolation within each motion segment, dynamically adjusting the motor's acceleration and maximum motion speed parameters according to the current system load state, and achieving closed-loop position control through encoder feedback to obtain the gimbal position control command.

7. The MCU-based intelligent tablet stand control method according to claim 1, characterized in that, The generation of the power allocation parameters includes: Based on the motor control status and power consumption information during the execution of gimbal position control commands, an adaptive power adjustment strategy is adopted to monitor three power consumption sources in real time: tablet charging power, gimbal motor drive power, and control circuit power consumption. The total power consumption of the system is obtained by adding the three power consumption sources together. A simplified thermodynamic model is used for temperature prediction. The system temperature change rate is calculated based on the current total power consumption, system temperature, ambient temperature, and preset thermal resistance and thermal capacity parameters. When the predicted temperature exceeds the safety threshold, power regulation measures are executed according to preset priority order to obtain power allocation parameters.

8. The MCU-based intelligent tablet stand control method according to claim 1, characterized in that, The steps for generating the updated control commands include: based on power allocation parameters, using state caching and incremental update techniques, establishing a core parameter data model that includes multi-sensor synchronization data packets, charging status detection results, attitude angle information, task scheduling schemes, gimbal position control commands, and power allocation parameters; setting a parameter change threshold to trigger an update mechanism; and triggering an incremental update of the user interface when any parameter change exceeds a preset threshold to obtain the updated control commands.

9. The MCU-based intelligent tablet stand control method according to claim 1, characterized in that, The multi-sensor synchronization data packet generation step also includes: using adaptive sampling frequency adjustment technology, the system continuously monitors triaxial accelerometer data, calculates the Euclidean distance of the acceleration vector between two adjacent samples as a motion intensity index, sets a motion intensity threshold, and when the motion intensity of ten consecutive samples is less than the set threshold, it is determined that the plate is in a stationary state, and the system automatically adjusts the sampling frequency from the standard ten milliseconds to once every five milliseconds. When the motion intensity is detected to exceed the threshold and is continuously sampled three times, it is determined to be a rapid motion state, and the system immediately increases the sampling frequency to once every two milliseconds.

10. A smart tablet stand control system based on an MCU, characterized in that, A method for executing a MCU-based smart tablet holder control method according to any one of claims 1-9, comprising: The data acquisition module is used to synchronously read signals from the triaxial accelerometer, gyroscope, magnetometer, and charging detection circuit to obtain multi-sensor synchronous data packets; The charging status detection module is used to obtain the charging status detection result by adopting a hierarchical detection strategy based on the voltage and current information in the multi-sensor synchronous data packet, through coarse classification of voltage threshold and fine identification of current change rate. The attitude calculation module is used to dynamically adjust the filtering parameters based on the charging status detection results and correct electromagnetic interference through the interference compensation parameter table to obtain attitude angle information. The task scheduling module is used to apply a priority-based preemptive task scheduling strategy to attitude angle information and charging status detection results. It avoids task conflicts and resource contention through time slice round-robin and resource mutex lock mechanisms to obtain a task scheduling scheme. The motor control module is used to adopt a segmented motor control strategy for the task scheduling scheme, decompose large-angle motion into small-angle segments and use cubic spline interpolation to generate control curves to obtain gimbal position control commands. The power adjustment module is used to dynamically adjust the charging power by adopting an adaptive power adjustment strategy for the motor control status during the execution of gimbal position control commands, thereby obtaining power allocation parameters. The status update module is used to obtain updated control commands by using status caching and incremental update technology for multi-sensor synchronization data packets, charging status detection results, attitude angle information, task scheduling schemes, gimbal position control commands and power allocation parameters.

Citation Information

Patent Citations

  • Inspection robot autonomous charging dynamic control system

    CN120810873A

  • Desk top type charger

    JP2008294793A