# Deep Learning for Treadmill-Oriented Cardiorespiratory Endurance Testing and Training

Authors: Yanying Zhu
Journal: Advances in Multimedia
 (2022)

---

## Abstract

The aim of this paper was to study deep learning for treadmill-oriented cardiorespiratory endurance testing and training. This paper designs a cardiorespiratory endurance test system for the general public based on ordinary exercise bikes, which can be used to execute training programs and improve cardiorespiratory endurance levels, system design, and implementation. Through the analysis and summary of the design principle, and the design of software and hardware, the heart rate measurement, power measurement, and constant power control are realized, and the human-computer interaction software integrated into the cardiorespiratory endurance test scheme is designed. The results show that the Pearson correlation coefficient verification results of the maximum oxygen uptake VO2max of the two groups are the correlation coefficientr = 0.938, |r > 0.8, indicating that the two groups of data have a high correlation; the significance coefficient p < 0.0S, lpl <0.0S, and the accuracy and validity of the system test are verified by the comparison experiment with the gold standard equipment Monaco MONARK power car.


---

## Body

## 1. Introduction

The rapid development of technological and economic levels greatly changed our way of life: less and less physical activity, nutrient intake is increasing, and people are generally experiencing overnutrition and decreased exercise capacity; the incidence of chronic diseases caused by this continues to increase and seriously endanger the physical and mental health of human beings. In recent years, people gradually realized the seriousness of this problem; under the active advocacy of WHO and health experts, reasonable diet and moderate exercise have become the consensus of health promotion. The so-called moderate exercise means to perform appropriate fitness exercises according to different individual health conditions and exercise capabilities and achieve fitness goals under the premise of ensuring safety [1]. This is based on health status and current athletic ability, and a safe and effective fitness program for a specific fitness goal is an exercise prescription. In recent years, exercise prescription has been a research hotspot in the field of exercise promoting health, and many excellent research results have emerged at home and abroad. Exercise prescription mainly includes exercise form, exercise intensity, exercise time, exercise frequency, and precautions during exercise. Cardiorespiratory fitness (CRF) is an important indicator of human health, and it is one of the core elements of each component of physical health. Cardiopulmonary endurance is positively related to cardiovascular disease, and heart rate is one of the methods to monitor cardiovascular function; it’s a quantitative indicator that the heart can withstand a small load, commonly used meters to monitor cardiovascular physiological indicators [2]. Good cardiorespiratory endurance is beneficial to improve the effects of all aspects of the body and prevent chronic diseases, promote physical health, and the use of oxygen in the human body; this will improve energy metabolism and prolong exercise time. Body composition is also an important element of physical health, this is closely related to the health of the human body, it can be used to evaluate physical health and physical strength, and it can also be used to evaluate the effect of exercise, and it is correlated with the level of cardiorespiratory endurance. It can be seen to improve cardiorespiratory endurance and control body composition, and it has significance for enhancing people’s exercise ability and reducing the incidence of diseases [3].Treadmills transfer running movement indoors, reducing the environmental requirements for running and fitness, and are favored by ordinary people. Although the traditional electric treadmill has defects such as monotonous exercise process, its speed and slope can be set, and the exercise intensity can be controlled, which provides a convenient means for fitness exercise. It has become the most popular indoor fitness equipment, and its market size is still growing year by year. At present, internationally well-known treadmill manufacturers have achieved many excellent research results in the aspects of treadmill-based exercise intensity control, the relationship between exercise intensity and exercise heart rate, and the impact of exercise patterns on fitness effects. The intelligent upgrade of treadmills has laid a good foundation. However, due to the significant individual differences of the population and the difficulty of obtaining the health signs of the subjects on the treadmill, the formulation and execution control of individualized exercise prescriptions based on the treadmill are still issues that practitioners at home and abroad need to study.


## 2. Literature Review

Cardiopulmonary function generally refers to the circulatory system, which promotes blood circulation through lung breathing and heart activity and the ability to deliver oxygen and nutrients to the body, as shown in Figure1. Godzhello, A. G. et al. found that cardiorespiratory endurance represents the body’s ability to continue the physical activity, it reflects the cardiopulmonary function of the human body under a certain exercise intensity, and it is considered to be one of the most important indicators in the healthy physical fitness evaluation index system [4]. Gurry, M. K. and others found that modern medical research proved that if the level of cardiorespiratory endurance is low, the risk of suffering from cardiovascular diseases is significantly increased [5]; Lee, C. B. and others proposed to improve the level of cardiorespiratory endurance; it can not only improve the adaptability of the heart and lungs, strengthen physical fitness, and improve exercise efficiency but it can also reduce the incidence of cardiovascular diseases, metabolic diseases, and other diseases caused by poor lifestyles and improve people’s quality of life [6]. Mikami, Y. et al. found that due to an increase in a static lifestyle and a decrease in physical activity, the cardiorespiratory endurance of people of all ages in China is showing a downward trend [7]. Vitiello, D. and others found that it was mentioned in the “Chinese Student Physical Fitness and Health Survey Report” published as early as 2005, in the 20 years before 2005, that the endurance level of students of all ages and gender groups showed a downward trend, and the decline in the next 10 years is even more pronounced [8]. Woo-Young et al. found that since entering the industrialized society, the form of work requiring physical activity has gradually decreased, and a sedentary lifestyle is the most important factor leading to a decline in cardiorespiratory endurance [9]. Sandberg, C. et al. proposed current research on cardiopulmonary endurance in the field of public health, and its popularity still cannot meet the urgent application needs [1]. Cho, G. J. and others found that, excluding athletes or kinesiology research experts involved in competitive sports, people do not know much about cardiorespiratory endurance, and they do not know much about training methods based on cardiorespiratory endurance; moreover, there is currently no universal, accurate, effective, easy-to-operate, and low-cost cardiopulmonary endurance measurement and training equipment [10]. Therefore, Claire, Maufrai et al. proposed a study of exercise equipment related to cardiopulmonary endurance measurement, evaluation, and training that has broad prospects [11]. Ho, J. P. and others provide a platform for the general public to understand cardiorespiratory endurance on the one hand and, on the other hand, to make up for the lack of cardiorespiratory endurance testing and training equipment suitable for the general public [12]. Jrv, A. et al. considered the feasibility of treadmill formulation and implementation of spirometric endurance exercise prescriptions, including treadmill-based repeatability validation such as pulmonary endurance test and treadmill-based exercise intensity control accuracy validation [13].Figure 1
Flow chart of cardiorespiratory endurance test.


## 3. Methods

### 3.1. Constant Power Fitness Car Constant Power Control Principle

Because the power vehicle needs to ensure the constant power set during the test, that is, the power output of each tester at each test is constant, so as to ensure the accuracy of the test results, the constant power control algorithm of this system adopts the resistance adjustment mode of PID control. By inputting the set target power into the PID controller, the controller compares the difference between the target power and the actual power in real time and makes the user output power constant by adjusting the system resistance.PID control is the so-called proportion (P), integral (I), and differential (D) control, mainly according to the difference between the set target value and the actual value, using the proportion, integral, and differential to calculate the control amount to adjust the system resistance of the accused object system. Proportion regulation is the simplest regulation means of PID. Proportion regulation can rapidly adjust the deviation values of the system. However, the proportional adjustment will lead to steady-state error. Integral regulation differs from proportional regulation in that it is proportional to the integration of systematic deviations. As long as there is a deviation, the regulator then adjusts. Until the deviation output is zero, the regulator does not stop adjusting. Integral regulation does not produce steady-state bias like proportional regulation, Integral adjustment automatically eliminates the steady-state bias, but the integral adjustment does not appear alone. Differential is proportional to differential regulation and system deviation. Differential regulation can predict and adjust before the system change is too large. This system uses proportional regulation with differential regulation.The control expression for the PID controller is(1)ut=Kpet+KPTI∫0tetdt+KpTDdetdt,where Kp is the proportional coefficient, KI is the integral coefficient, KD is the differential coefficient, and TD and TI are the differential and integral time constant, respectively.The transfer function of PID controller can be calculated by using Laplace changes on the left and right sides of formula (1).(2)Gs=UsEs,(3)Gs=KP+KPTIs+KPTDs.Formula (2) and (3) are discretized to obtain the positional PID control algorithm formula.(4)uk=KPek+KI∑j=0kej+KDek−ek−1,where Kp is the proportional coefficient, and the integral coefficient is(5)KI=KPTTI.Differential quotient:(6)KD=KPTDT.According to the above formula, the target power is imported into the PID controller, the PID control monitors the current system power in real time, calculates the system deviatione (k) and the last system deviation e (k−1), and calculates the control amount u (k) according to the u (k). The microcontroller adjusts the PWM duty cycle through u (k) value to adjust the system resistance and realize the constant power output during the test movement.


### 3.2. Principle of Maximum Oxygen Intake Measurement by YMCA Method

The YMCA method is widely used in the indirect measurement of the maximum oxygen intake in lower limb power vehicles. This is one of the most commonly used measurement techniques to calculate V02max. In the YMCA protocol, the first will warm up for at least 3 min with a smaller load charge. After the first level of exercise is completed, to calculate the stable heart rate, the load size of the next level test was also determined according to the calculated steady heart rate size, and so on. The tester shall continuously complete level 3 load test at least and try to ensure that the heart rate of the tester is 110/min–170/min. Finally, the stable heart rate at each level is marked as dots with the corresponding power. Then, we connect the points into a straight line, predict the maximum heart rate using age, extend the straight line to the maximum heart rate, and determine the maximum power of the tester compared with the x-axis projection. Finally, the maximum oxygen intake is predicted according to the maximum load power.P0 represents the first level of warm-up load,HR0 represents the stable heart rate corresponding to the first level of warm-up load, P1 represents the second level of test load, HR1 represents the stable heart rate corresponding to the second level of test load, P2 represents the third level of test load, and HR2 represents the stable heart rate corresponding to the third level of test load. A linear curve function can be obtained from the values of the second level load P1 and the steady heart rate HR1, and the third level load P2 and the steady heart rate HR2.(7)P=P2−P1HR2−HR1∗HR−HR2+P2.Meanwhile, according to Tanaka’s prediction ofHRmax,(8)HRmax=208−0.7∗age.By putting the predicted maximum heart rateHRmax into formula (7), the maximum exercise load Pmax under the maximum heart rate of the tester can be obtained. Meanwhile, the relationship between oxygen uptake (VO2) and power (P) of the lower limb power vehicle can be determined by using the metabolic formula.(9)VO2=7.0+10.8∗powerweight.By inserting the obtained maximum exercise loadPmax into formula (9), the VO2mx of the tester can be predicted, and the cardiopulmonary endurance of the tester can be determined by the VO2mx of the tester.


### 3.3. Cardiorespiratory Endurance Test

In this heart rate measurement, the metal electrode on the handle captures the ECG signal on the palm of the hand. The heart rate acquisition module extracts the R-wave signal in the ECG signal through differential amplification and band-pass filtering and obtains a series of square wave signals after shaping, as shown in Figure2.Figure 2
Block diagram of heart rate acquisition.Each square wave period corresponds to a heartbeat time; after calculating the square wave periodT, get the number of square waves in one minute, that is, the number of heartbeats, thereby converting the measured heart rate [13, 14]. For the calculation of the square wave period, use the timer interrupt of the STM32F103 series single-chip microcomputer to calculate, set the timer to trigger on the pulse edge (rising edge or falling edge), and calculate the interval T between two adjacent triggers. To obtain the square wave signal output by the heart rate acquisition module, use microcontroller timer interrupt capture and calculate the high- and low-level time of the square wave. Through the above analysis of the interference signal waveform, we can know that the high-level duration is relatively stable, and when the heart rate changes, the high-level time change range is also smaller. The low-level time change is greatly affected by interference, floating from tens of milliseconds to hundreds of milliseconds, and it can be seen that low-level signals are the main source of interference signals. At the same time, in the experiment process, through artificially increasing interference, observing the characteristics of the output waveform also verified the above viewpoints [15, 16]. Therefore, first perform signal screening in order to filter out low-level interference; the software uses a method of filtering high and low levels. Retain a square wave signal whose high-level time T is between 100 ms and 300 ms and low-level time T is between 100 ms and 1000 ms; the filter conditions are different due to hardware conditions, and it can be adjusted appropriately according to the actual situation. Use the heart rate calculation formula HR = 6000/(T high level + T low level) for the filtered signal to get the heart rate value; at this time, most of the interference signals have been filtered out, and the heart rate curve is relatively smooth; overall, it reflects the trend of heart rate changes. However, the heart rate fluctuates more, and the adjacent heart rate has large spike interference, so filter processing such as amplitude limiting is still needed. Through the upper limit processing, the value that does not meet the limit condition is directly removed, but at this time, the instability of the ECG signal will cause the update lag. When the interference appears to cause more values to be filtered out, the heart rate value that meets the threshold condition has not been obtained for a long time, and when the subject continues to exercise, the heart rate rises faster. When the heart rate is high, at this time, the same filtering conditions are used; this will cause the acquired heart rate to be filtered out because it does not meet the above limiting conditions. As the exercise continues, the heart rate gradually increases, and the heart rate value cannot be obtained; as a result, the heart rate value cannot be updated continuously [17, 18]. In order to avoid the above situation, the values outside the limit range should also be dealt with, and appropriate predictions should be provided. Replace the filtered value with the predicted heart rate. As a trend, the prediction of heart rate is not a true measurement value, and it needs the heart rate status at the previous time as the basis as shown in Table 1.Table 1
Heart rate prediction methods.
Heart rate at the previous moment<8080 ∼ 120>120Increasing trend+2+4+6Decrease trend−2−4−6For data that meet the limit range, no processing is performed, and for data outside the limit range, use the above prediction method to get the predicted value, enter the calculation as a valid value, and solve the problem of data update lag. The power of the system refers to pedaling an exercise bike, the work done to the outside world overcoming resistance, and it is obtained by multiplying the torque and the rotation speed during pedaling. The torque is approximately equal to the product of the resistance of the reluctance control device and the force arm, which is obtained by measuring the radius of the flywheel. Therefore, power measurement includes speed measurement and pressure measurement, the speed is obtained by the magnetic control switch, and the pressure is measured by the cantilever beam force sensor as shown in formula (10).(10)p=F∗10∗0.1+7∗3.1−1∗n30∗6.8.Overcoming resistance to external work is obtained by formula (10), among them, F is the positive force, n is the speed, the arm length is 0.147 m, and the transmission ratio is 6.8. After the above analysis, the power P of the system is obtained by the speed V and the resistance F of the pedaling through the speed measurement and pressure measurement. The resistance is measured by the arm beam force sensor; measure the force of the magnet in the horizontal direction of the surgical end, and there is an error in this measurement method. When the force motor adjusts the resistance, the position of the magnet needs to be adjusted through the connecting rod with the magnet base. During the adjustment process, there is a component force in the horizontal direction of the connecting rod, which causes the resultant force of the magnet in the horizontal direction to be too small, which causes measurement errors. During the adjustment process, the connecting part of the torque motor and the magnet cannot be easily discarded; this time, we will study the relationship between measured power and actual power and calibrate the measured power [19, 20]. During power calibration, use telescopic parts to connect the magnet and the center bearing of the flywheel, the force of the telescopic part always passes through the center of the circle, and the force direction is the normal direction of the flywheel and does not do work. Based on this calibration idea, using the reluctance device of the torque motor, adjust the resistance to a fixed state and apply a fixed cadence to the system at the same time, take a cadence of 50–70 revolutions for 1 minute, measure the power at this time, and record it as the measured power Po. The cadence factor affects the power consumption in the human body, and the cadence of 50–70 revolutions for 1 minute is the normal pedaling state; therefore, the subject is required to maintain a cadence of 50–70 rpm so as to ensure the consistency of the mechanical efficiency of each test object. Use telescopic parts to fix the magnet, maintain the state of the magnetoresistive device, and remove the connecting rod, and there will be no horizontal force component; at this time, consider that the measured power is the standard power and apply the same cadence, and the measured power at this time is recorded as the actual power P. The purpose of calibration is to find the relationship between the actual power P and the measured power Po; correct the measured power Po in actual use. In order to study the relationship between actual power P and measured power p0, sixteen state points are set by the magnetoresistance adjusting device, measure the corresponding P and p0 when the speed is 50 and 60 rpm, respectively, draw a scatter plot, as shown in Figures 3–5, and draw out the regression equation. The fitted trend line is as follows: at 50 rpm, p=0.7292∗p0+4.021 and goodness of fit R2=0.9974. At 60 rpm, p=0.8124∗p0+2.426 and goodness of fit R2=0.9924. At 50–70 revolutions per minute, p=0.7934∗p0+0.2551 and goodness of fit R2=0.9845. It can be seen that the actual power P and the measured power p0 are approximately linearly distributed, and H has a high degree of fit and can describe the relationship between the actual power P and the measured power p0 as shown in Figures 3–5.Figure 3
The relationship between the time power P and the measured powerp0 at a speed of 50 rpm.Figure 4
The relationship between the time power P and the measured power at 60 rpm.Figure 5
The relationship between the time power P and the measured powerp0 at the speed of 50–70 rpm.After completing the power calibration, the magnetoresistance generator is still used in the actual use process; considering the error caused by the horizontal force component, the accurate power can still be obtained. Accurate power measurement is the prerequisite and basis for cardiopulmonary endurance testing.


## 3.1. Constant Power Fitness Car Constant Power Control Principle

Because the power vehicle needs to ensure the constant power set during the test, that is, the power output of each tester at each test is constant, so as to ensure the accuracy of the test results, the constant power control algorithm of this system adopts the resistance adjustment mode of PID control. By inputting the set target power into the PID controller, the controller compares the difference between the target power and the actual power in real time and makes the user output power constant by adjusting the system resistance.PID control is the so-called proportion (P), integral (I), and differential (D) control, mainly according to the difference between the set target value and the actual value, using the proportion, integral, and differential to calculate the control amount to adjust the system resistance of the accused object system. Proportion regulation is the simplest regulation means of PID. Proportion regulation can rapidly adjust the deviation values of the system. However, the proportional adjustment will lead to steady-state error. Integral regulation differs from proportional regulation in that it is proportional to the integration of systematic deviations. As long as there is a deviation, the regulator then adjusts. Until the deviation output is zero, the regulator does not stop adjusting. Integral regulation does not produce steady-state bias like proportional regulation, Integral adjustment automatically eliminates the steady-state bias, but the integral adjustment does not appear alone. Differential is proportional to differential regulation and system deviation. Differential regulation can predict and adjust before the system change is too large. This system uses proportional regulation with differential regulation.The control expression for the PID controller is(1)ut=Kpet+KPTI∫0tetdt+KpTDdetdt,where Kp is the proportional coefficient, KI is the integral coefficient, KD is the differential coefficient, and TD and TI are the differential and integral time constant, respectively.The transfer function of PID controller can be calculated by using Laplace changes on the left and right sides of formula (1).(2)Gs=UsEs,(3)Gs=KP+KPTIs+KPTDs.Formula (2) and (3) are discretized to obtain the positional PID control algorithm formula.(4)uk=KPek+KI∑j=0kej+KDek−ek−1,where Kp is the proportional coefficient, and the integral coefficient is(5)KI=KPTTI.Differential quotient:(6)KD=KPTDT.According to the above formula, the target power is imported into the PID controller, the PID control monitors the current system power in real time, calculates the system deviatione (k) and the last system deviation e (k−1), and calculates the control amount u (k) according to the u (k). The microcontroller adjusts the PWM duty cycle through u (k) value to adjust the system resistance and realize the constant power output during the test movement.


## 3.2. Principle of Maximum Oxygen Intake Measurement by YMCA Method

The YMCA method is widely used in the indirect measurement of the maximum oxygen intake in lower limb power vehicles. This is one of the most commonly used measurement techniques to calculate V02max. In the YMCA protocol, the first will warm up for at least 3 min with a smaller load charge. After the first level of exercise is completed, to calculate the stable heart rate, the load size of the next level test was also determined according to the calculated steady heart rate size, and so on. The tester shall continuously complete level 3 load test at least and try to ensure that the heart rate of the tester is 110/min–170/min. Finally, the stable heart rate at each level is marked as dots with the corresponding power. Then, we connect the points into a straight line, predict the maximum heart rate using age, extend the straight line to the maximum heart rate, and determine the maximum power of the tester compared with the x-axis projection. Finally, the maximum oxygen intake is predicted according to the maximum load power.P0 represents the first level of warm-up load,HR0 represents the stable heart rate corresponding to the first level of warm-up load, P1 represents the second level of test load, HR1 represents the stable heart rate corresponding to the second level of test load, P2 represents the third level of test load, and HR2 represents the stable heart rate corresponding to the third level of test load. A linear curve function can be obtained from the values of the second level load P1 and the steady heart rate HR1, and the third level load P2 and the steady heart rate HR2.(7)P=P2−P1HR2−HR1∗HR−HR2+P2.Meanwhile, according to Tanaka’s prediction ofHRmax,(8)HRmax=208−0.7∗age.By putting the predicted maximum heart rateHRmax into formula (7), the maximum exercise load Pmax under the maximum heart rate of the tester can be obtained. Meanwhile, the relationship between oxygen uptake (VO2) and power (P) of the lower limb power vehicle can be determined by using the metabolic formula.(9)VO2=7.0+10.8∗powerweight.By inserting the obtained maximum exercise loadPmax into formula (9), the VO2mx of the tester can be predicted, and the cardiopulmonary endurance of the tester can be determined by the VO2mx of the tester.


## 3.3. Cardiorespiratory Endurance Test

In this heart rate measurement, the metal electrode on the handle captures the ECG signal on the palm of the hand. The heart rate acquisition module extracts the R-wave signal in the ECG signal through differential amplification and band-pass filtering and obtains a series of square wave signals after shaping, as shown in Figure2.Figure 2
Block diagram of heart rate acquisition.Each square wave period corresponds to a heartbeat time; after calculating the square wave periodT, get the number of square waves in one minute, that is, the number of heartbeats, thereby converting the measured heart rate [13, 14]. For the calculation of the square wave period, use the timer interrupt of the STM32F103 series single-chip microcomputer to calculate, set the timer to trigger on the pulse edge (rising edge or falling edge), and calculate the interval T between two adjacent triggers. To obtain the square wave signal output by the heart rate acquisition module, use microcontroller timer interrupt capture and calculate the high- and low-level time of the square wave. Through the above analysis of the interference signal waveform, we can know that the high-level duration is relatively stable, and when the heart rate changes, the high-level time change range is also smaller. The low-level time change is greatly affected by interference, floating from tens of milliseconds to hundreds of milliseconds, and it can be seen that low-level signals are the main source of interference signals. At the same time, in the experiment process, through artificially increasing interference, observing the characteristics of the output waveform also verified the above viewpoints [15, 16]. Therefore, first perform signal screening in order to filter out low-level interference; the software uses a method of filtering high and low levels. Retain a square wave signal whose high-level time T is between 100 ms and 300 ms and low-level time T is between 100 ms and 1000 ms; the filter conditions are different due to hardware conditions, and it can be adjusted appropriately according to the actual situation. Use the heart rate calculation formula HR = 6000/(T high level + T low level) for the filtered signal to get the heart rate value; at this time, most of the interference signals have been filtered out, and the heart rate curve is relatively smooth; overall, it reflects the trend of heart rate changes. However, the heart rate fluctuates more, and the adjacent heart rate has large spike interference, so filter processing such as amplitude limiting is still needed. Through the upper limit processing, the value that does not meet the limit condition is directly removed, but at this time, the instability of the ECG signal will cause the update lag. When the interference appears to cause more values to be filtered out, the heart rate value that meets the threshold condition has not been obtained for a long time, and when the subject continues to exercise, the heart rate rises faster. When the heart rate is high, at this time, the same filtering conditions are used; this will cause the acquired heart rate to be filtered out because it does not meet the above limiting conditions. As the exercise continues, the heart rate gradually increases, and the heart rate value cannot be obtained; as a result, the heart rate value cannot be updated continuously [17, 18]. In order to avoid the above situation, the values outside the limit range should also be dealt with, and appropriate predictions should be provided. Replace the filtered value with the predicted heart rate. As a trend, the prediction of heart rate is not a true measurement value, and it needs the heart rate status at the previous time as the basis as shown in Table 1.Table 1
Heart rate prediction methods.
Heart rate at the previous moment<8080 ∼ 120>120Increasing trend+2+4+6Decrease trend−2−4−6For data that meet the limit range, no processing is performed, and for data outside the limit range, use the above prediction method to get the predicted value, enter the calculation as a valid value, and solve the problem of data update lag. The power of the system refers to pedaling an exercise bike, the work done to the outside world overcoming resistance, and it is obtained by multiplying the torque and the rotation speed during pedaling. The torque is approximately equal to the product of the resistance of the reluctance control device and the force arm, which is obtained by measuring the radius of the flywheel. Therefore, power measurement includes speed measurement and pressure measurement, the speed is obtained by the magnetic control switch, and the pressure is measured by the cantilever beam force sensor as shown in formula (10).(10)p=F∗10∗0.1+7∗3.1−1∗n30∗6.8.Overcoming resistance to external work is obtained by formula (10), among them, F is the positive force, n is the speed, the arm length is 0.147 m, and the transmission ratio is 6.8. After the above analysis, the power P of the system is obtained by the speed V and the resistance F of the pedaling through the speed measurement and pressure measurement. The resistance is measured by the arm beam force sensor; measure the force of the magnet in the horizontal direction of the surgical end, and there is an error in this measurement method. When the force motor adjusts the resistance, the position of the magnet needs to be adjusted through the connecting rod with the magnet base. During the adjustment process, there is a component force in the horizontal direction of the connecting rod, which causes the resultant force of the magnet in the horizontal direction to be too small, which causes measurement errors. During the adjustment process, the connecting part of the torque motor and the magnet cannot be easily discarded; this time, we will study the relationship between measured power and actual power and calibrate the measured power [19, 20]. During power calibration, use telescopic parts to connect the magnet and the center bearing of the flywheel, the force of the telescopic part always passes through the center of the circle, and the force direction is the normal direction of the flywheel and does not do work. Based on this calibration idea, using the reluctance device of the torque motor, adjust the resistance to a fixed state and apply a fixed cadence to the system at the same time, take a cadence of 50–70 revolutions for 1 minute, measure the power at this time, and record it as the measured power Po. The cadence factor affects the power consumption in the human body, and the cadence of 50–70 revolutions for 1 minute is the normal pedaling state; therefore, the subject is required to maintain a cadence of 50–70 rpm so as to ensure the consistency of the mechanical efficiency of each test object. Use telescopic parts to fix the magnet, maintain the state of the magnetoresistive device, and remove the connecting rod, and there will be no horizontal force component; at this time, consider that the measured power is the standard power and apply the same cadence, and the measured power at this time is recorded as the actual power P. The purpose of calibration is to find the relationship between the actual power P and the measured power Po; correct the measured power Po in actual use. In order to study the relationship between actual power P and measured power p0, sixteen state points are set by the magnetoresistance adjusting device, measure the corresponding P and p0 when the speed is 50 and 60 rpm, respectively, draw a scatter plot, as shown in Figures 3–5, and draw out the regression equation. The fitted trend line is as follows: at 50 rpm, p=0.7292∗p0+4.021 and goodness of fit R2=0.9974. At 60 rpm, p=0.8124∗p0+2.426 and goodness of fit R2=0.9924. At 50–70 revolutions per minute, p=0.7934∗p0+0.2551 and goodness of fit R2=0.9845. It can be seen that the actual power P and the measured power p0 are approximately linearly distributed, and H has a high degree of fit and can describe the relationship between the actual power P and the measured power p0 as shown in Figures 3–5.Figure 3
The relationship between the time power P and the measured powerp0 at a speed of 50 rpm.Figure 4
The relationship between the time power P and the measured power at 60 rpm.Figure 5
The relationship between the time power P and the measured powerp0 at the speed of 50–70 rpm.After completing the power calibration, the magnetoresistance generator is still used in the actual use process; considering the error caused by the horizontal force component, the accurate power can still be obtained. Accurate power measurement is the prerequisite and basis for cardiopulmonary endurance testing.


## 4. Results and Analysis

During the cardiopulmonary endurance test, it is required to keep the power constant, and the power is affected by pedaling speed. Various reasons make it difficult to maintain a stable pedaling rate when entering the body, and fluctuations are inevitable; the significance of constant power control is that when the cadence changes, the power can be guaranteed to be constant so as to ensure the accuracy of the cardiopulmonary endurance test [21, 22].Constant power control includes resistance regulation and constant power regulation as shown in Figure6. The resistance adjustment module changes the system resistance through PWM pulses, adjusts the power fluctuations caused by cadence, and keeps the output work stable. The constant power adjustment part is mainly the feedback function of power measurement, through real-time calculation and measurement of system power, and compared with the target power, negative feedback regulation is formed [23, 24]. The angle AD value in the reluctance device reflects the rotation range of the torque motor and real-time reaction of the distance between the magnet and the metal flywheel and provides adjustment basis for resistance adjustment. In order to study the relationship between power and angle AD, the regression equation of power and angle is obtained through multiple sets of experiments. Since the power P = F∗V, when the pedaling rate V-timing, the change of resistance F can reflect the change of power P [18, 25]. Under the same cadence, adjust the torque motor and change the resistance of the reluctance device, and the angle potentiometer also outputs the changing AD value with the rotation of the motor; the AD reflects the distance between the magnet and the metal flywheel, so it can represent the change in resistance. Take 50 revolutions for 1 minute, 60 revolutions per minute, and 70 revolutions per minute, respectively; adjust the motor; change the angle potentiometer from 200 to 2000 range; and take out multiple fixed positions from it, measure real-time power, and obtain the following curve as shown in Figure 7.Figure 6
Constant power control.Figure 7
The relationship between power and angle.As seen in Figure7, the power has an exponential relationship with the AD of the angle potentiometer; as the angle AD increases, the power increases faster and faster. This is also consistent with the actual experience; when the magnet is farther away, the adjustment change is smaller, and as the distance decreases, the changes in resistance adjustment are also more obvious [26, 27]. Since the angle potentiometer reflects the range of motor rotation, it also reflects the relative position of the magnet, in order to adjust the power equally, the adjustment area of the potentiometer needs to be divided. The finer the interval division, the higher the adjustment accuracy; divide the angle AD into 32 sections and adjust the power as evenly as possible. This is also the way to achieve constant power adjustment; when the cadence changes, the system will use the real-time AD value, properly adjust the rotation range of the torque motor, and change the size of the positive force. When the cadence increases, the resistance is reduced by PWM adjusting the motor reverse: when the cadence decreases, adjust the motor to increase resistance. Constant power and adhesion adjustment are carried out in real time; after repeated adjustments, the output power is kept stable. Constant power control overcomes the fluctuation of exercise load, makes cardiopulmonary endurance test results more accurate, and it also laid the foundation for the formulation of the exercise intensity of the training plan.The experimental results show that for young people, the treadmill-based exercise prescription for spirometric endurance is scientific and effective in improving stamina endurance, and improving stimulant endurance is also effective in improving resting stamina rate and body composition, indicating that stimulant endurance is improved. It is effective for improvement of body composition and reduction of resting slack rate. It provides a reference for the prescription of lung endurance exercise and also provides data support for the replacement and application of treadmills.


## 5. Conclusion

The author mainly introduces the software and hardware design of the cardiopulmonary endurance test system, and the validity of the system test is verified by experiments [7]. The statistical software SPSS performs data analysis and enters the measured data of two groups of 20 subjects into the statistical software; the results show that the verification result of the Pearson correlation coefficient of the maximum oxygen uptake VO2max of the two groups is the correlation coefficient r = 0.938, |r > 0.8, which indicates that the two sets of data have a high correlation; significance coefficient p < 0.0S, lpl < 0.0S, which shows that the two sets of data are statistically significant, indicating that there is no significant difference between the two sets of data. The heart rate measurement module and the software design of the power measurement module are introduced in turn in modules. Heart rate measurement uses metal handheld electrodes to collect palm heart electrical signals and perform hardware and software filter processing on the collected signal to get the heart rate value. The power measurement part includes speed measurement and pressure measurement, the speed is measured by a magnetic control switch, the resistance is measured by the cantilever beam force sensor, and the relationship between the actual power and the measured power is studied, corrected and calibrated the measured power, and introduced the meaning and realization method of the constant power control of the system. Finally, in order to verify the effectiveness of the system test, a comparative test was done with the MONARK power bicycle, and through the correlation analysis and difference analysis of the maximum oxygen uptake VO2max of the two groups of tests, it shows that the correlation between the two is relatively high and there is no significant difference, which verifies the effectiveness of the system.The research on the cardiorespiratory endurance testing system for cardiorespiratory endurance testing and training has been initially formed, but there are still shortcomings. In the future research, it is still necessary to further improve the cardiorespiratory endurance test and training. In the test method, the test results are more accurate from the optimization of the test principle and the improvement of the measurement accuracy; the formulation of the training program based on this system is more diversified and provides a variety of options for a variety of people. The system can not only help people understand their own cardiorespiratory endurance status but also carry out cardiorespiratory endurance training, which is of great significance for improving cardiorespiratory endurance level and enhancing physical fitness.



---

*Source: 5966488-2022-05-12.xml*