1 Introduction

In recent years, with the continuous improvement of quality of life, people pay more attention to physical health and want to have a further understanding of their own physical health. Many scholars did substantive research in the field of healthcare [1, 2, 10,11,12]. Many indexes are used to reflect health conditions, including blood pressure, heart rate and body temperature. These indexes can be measured by a few simple medical devices which ordinary families can easily purchase, and their prices are relatively cheap. Other indexes of health, such as blood glucose, blood oxygen saturation, total cholesterol, and lipids are more important in some cases, but they can be harder to measure. Firstly, people may have to go to the hospital or designated medical laboratories for data collection. Secondly, the prices of these equipment are more expensive. Thirdly, continuous travelling between the family and medical institutions cost energy and financial resources. The above inconveniences prevent people from satisfying their concern about physical health. Fortunately, with the development of various micro-sensors, measurement equipment with smaller size and lower price, and wearable measuring equipment are coming into being. However, current portable instruments may not have the same accuracy as the medical equipment in hospitals. For example, portable blood glucose meters measure the blood glucose concentration of the whole blood, whereas blood glucose meters in hospitals measure glucose concentration of plasma after filtering blood cells. Yet, portable instruments have had guiding significance to common people.

Among these health indexes, the blood glucose concentration is frequently measured. At present, there are many portable blood glucose meters in the market, but they have disadvantages. For instance, data collection requires blood samples and result accuracy relies on fasting blood glucose and postprandial blood glucose. In this case, the result from one-time measurements may be highly random. However, measurements, collected over a period, carried out at the same time every day, would be stable and useful. For the sake of improving people’s adherence, reducing the discomfort of each blood collection, and increasing analyzability of the measurement results, the continuous dynamic blood glucose meter was invented. The various signals that reflect the health of the human body are analog signals, and they are shown on the electronic device, using ADC (Analog-Digital Convertor). Due to volume constraints, a dynamic blood glucose meter cannot work with a large power supply system and large-size chips. This increases the difficulties of measuring the weak signals.

A weak signal has two meanings: 1. the strength of the signal itself is very weak; 2. the strength of the signal itself is not weak but its fluctuation within a short time is very small. The blood glucose level has small fluctuations in seconds, so a high-resolution ADC is required to measure such signal.

The wireless dynamic blood glucose monitoring system is a new type of instrument, which is used to collect weak signals of body fluid current in real time, via implanting a glucose sensor under the skin. The signals are amplified and transformed to the receiver end [3]. Figure 1 shows an ADC unit in the wireless acquisition system.

Fig. 1
figure 1

Wireless acquisition system

Fig. 2
figure 2

Ideally bidirectional saw-tooth

Fig. 3
figure 3

Bidirectional saw-tooth waves with starting point nonlinearity

If a 24-bit ADC (for example AD7787 [8]) is used in the system, it will achieve a high measurement accuracy, but its cost will be high as well. In general, a higher resolution ADC has higher sensitivity to noise even the reference voltage is the same. For the measurement using a lower resolution ADC, the weak signal needs to be amplified and filtered to improve their measurement accuracy. The over-sampling technique allows the low-resolution ADCs to detect weak signals without the use of an amplifier circuit, which can also make high-resolution ADCs break their highest resolution. Over-sampling technology is a common method to improve the resolution of measurement and control system, which has been widely used in various fields [4, 6, 7, 9].

2 Adding saw-tooth shaped function

In this section, we introduce the relationship between ADC and over-sampling technique, and some problems we may encounter when using shaped functions.

2.1 Over-sampling technology

When the quantization step size of the ADC is greater than the signal amplitude after superposing the shaped function, the over-sampling technique will fail. Under such circumstances, the readings of the ADC will not be affected, regardless of the total number of samples. To make ADCs read the numeric normally, the magnitude of the shaped function needs to be greater than one quantization step size of the ADC. In addition, it is also necessary to ensure that the signal amplitude does not exceed the input range of the ADC after the addition of the shaped function. When these two conditions are met, the over-sampling technique can work effectively. In other words, first, the shaped signal is modulated to the weak signal and is sampled, and then mixed signal is demodulated into the original signal by calculating high-precision superposed signal with over-sampling technology. To facilitate demodulation after over-sampling, the linear function like saw-tooth wave is often chosen [5].

2.2 The nonlinearity of the shaped function and its influence

When the closed-loop control with negative feedback is applied to the physical components of the signal generator, the circuit is in an unstable state if the feedback signal and the control signal are not balanced. It needs to take a while to enter the steady state. In this case, the added shaped function exhibits significant nonlinearity at the beginning, and the span of the nonlinear interval is related to the device itself. In general, this nonlinear time does not last long.

Ideally, the amplitude range of the superimposed saw-tooth wave is set to start from zero. However, due to the nonlinear effects of the starting point, this kind of the ADC sampling signal is not reliable, so it should be removed. Otherwise, these non-linear sampling data will affect the subsequent calculation of the ADC resolution.

2.3 Parameter setting

We define the voltage value of the measured weak signal s is V s , the resolution of the ADC is n bits, the reference voltage is VREF and the corresponding analog voltage of a quantization step size is 1LSB.The amplitude of the weak signal is(S + ΔS)LSB, S is a nonnegative integer, 0 ≤ ΔS < 1. The shaped function STW is a periodic bidirectional saw-tooth wave function, the amplitude is C 0 = (N + ΔN)LSB(N ≥ 4, 0 ≤ ΔN < 1), and the period is T. Set the sampling frequency is fs, the saw-tooth wave samples m points on average in each LSB.

2.4 Influence of starting-point nonlinearity on unidirectional saw-tooth shaped function

After the signal s is modulated on the STW, the mixed signal S i is obtained, and then the signal \( \overline{s} \) is obtained by rounding down [5]. When the end of the nonlinear effect of starting point is before the first acquisition of the signal amplitude (x + 1)LSB, the formula given in paper [5] is shown as (M is the number of sampling points of unidirectional saw-tooth waves in one period)

$$ \overline{s}=\frac{1}{\mathrm{M}}{\sum}_{k=1}^M{S}_i=\left[\left(1-\varDelta x\right) mx+\left(x+1\right)m+\left(x+2\right)m+\cdots +\left(\varDelta x+\varDelta x\right)m\left(x+N\right)\right]/\left(N+\varDelta N\right)m $$
(1)

The coefficient (1 − Δx)m in the expansion of Eq.(1) will be affected by the nonlinear effect of the starting point, and sampling frequency of m cannot be calculated or measured. When nonlinear effect of the starting point ends after the first acquisition of the signal amplitude (x + 1)LSB, both coefficients (1 − Δx)m and (x + 1)m will be affected by nonlinear effect of starting point, which will eventually lead to the inaccurate calculation for the formula.

3 Adding bidirectional saw-tooth shaped function

3.1 Ideal Bidirectional Saw-Tooth Waves

For the same function signal generator, in the case of the same parameters, it can be considered that the duration of nonlinear effect is the same at starting points in each period.

Figure 2 Assuming that the saw-tooth wave is ideal and the waveform start points are not distorted. t 1 is the starting time of the forward saw-tooth wave, t 3 is the starting time of the reverse saw-tooth wave, t 2 is the time point for the sampling results of the ADC from S to S + 1, t 4 is the time point for the sampling results of the ADC from S to S-1

Note that ΔABC ∼ ΔDEF, Eq.(2) is derived.

$$ \frac{\mathrm{DF}}{\mathrm{AC}+\mathrm{DF}}=\frac{\mathrm{EF}}{\mathrm{BC}+\mathrm{EF}} $$
(2)

Here, AC represents the sampling time of t 1 to t 2, and DF represents the sampling time of t 3 to t 4. By the definition of LSB, Eq.(3) is derived.

$$ \mathrm{BC}+\mathrm{EF}=1\mathrm{LSB} $$
(3)

Set from t 1 to t 2 a total of P signals, whose amplitude is SLSB, is collected, and from t 3 to t 4, a total of Q signals, whose amplitude is SLSB, is collected. Eq.(4) is derived.

$$ AC=\frac{P}{fs}, DF=\frac{Q}{fs} $$
(4)

Substitute Eq.(2) and Eq.(3) into Eq.(4), the sampled value of the ADC developed to \( EF=\frac{Q}{P+Q}=\frac{Q}{P+Q} \). The resolution is promoted with \( \frac{1}{m} \). The improvement of resolution bit can be estimated by direct oversampling to improve the resolution method, which is shown as (10lgm)/6.02 [5].

3.2 Bidirectional saw-tooth waves sampling method with starting point nonlinearity

Since the nonlinear duration of the starting point is unknown and the amplitude of the forward (or reverse) saw-tooth wave in each period is nonlinear at the beginning time, it is possible to cause inaccurate readings of the ADC superposing the forward (or reverse) saw-tooth wave. As shown in Fig. 3, the impact of starting point nonlinearity continues to the end of the time t 2, the sampling results of t 1 − t 2 will be influenced.

As shown in Fig. 3, the first time to collect the signal amplitude as S + 2 is set to t 3, the last time to collect the signal amplitude as S + 2 is set to t 4. The first time to collect the signal amplitude as S-2 is set to t 7, the last time to collect the signal amplitude as S-2 is set to t 8. To eliminate the influence of the starting point nonlinearity, the forward saw-tooth wave only counts the sampling data during the period t 3 to t 4, and the reverse saw-tooth only counts the data during the period t 7 to t 8.

The stabilized rising edge of forward saw-tooth wave is set to l 1, and the intersection of signal s is set to O. The stabilized falling edge of reverse saw-tooth is set to l 2. By calculating the collected signal’s mid-time-point \( {t}_{O_1} \) between t 3 and t 4, and making a vertical line to s through the point \( {t}_{O_1} \), the foot point is O1, the coordinate is \( \left({t}_{O_1},{\mathrm{y}}_1\right) \). It’s easy to show that y1 = S + 2.5. By calculating the collected signal mid-time-point \( {t}_{O_2} \) between t 7 and t 8, and making a vertical line to s through the point \( {t}_{O_2} \), the foot point is O2, the coordinate is \( \left({t}_{O_2},{\mathrm{y}}_2\right) \). It’s easy to show that y 2 = S − 1.5. Transforming l 2 and O2 to the left by T/2, it gets \( {l}_2^{\prime } \) and \( {\mathrm{O}}_2^{\prime } \), and the coordinate of \( {\mathrm{O}}_2^{\prime } \) is\( \left({t}_{O_2^{\prime }},{\mathrm{y}}_2\right) \). Making a vertical line to s through the point \( {\mathrm{O}}_2^{\prime } \), the foot point is \( {t}_{O_2^{\prime }} \). The ordinate of the intersection O of l 1 and l 2 is the calculated value of s denoted as s . Set \( \left|{t}_{O_2^{\prime }}-{t}_{O_1}\right|=\upvarepsilon \). If ε = 0, then \( \varDelta S=\raisebox{1ex}{$1$}\!\left/ \!\raisebox{-1ex}{$2$}\right.\mathrm{LSB} \). If ε > 0, then Eq.(5) is derived.

$$ \frac{t_{O_1}-{t}_O}{t_{O_2^{\prime }}-{t}_O}=\frac{y_1-{s}^{\prime }}{s^{\prime }-{y}_2} $$
(5)

By the definition of slope, the slope of l 1 can be expressed as

$$ k=\frac{2-\left({s}^{\prime }-S\right)}{t_3-{t}_O}=\frac{3-\left({s}^{\prime }-\mathrm{S}\right)}{t_4-{t}_O} $$
(6)

According to Eq.(5) and Eq.(6), the results of s and t O are derived. Then, the calculated voltage value \( {\mathrm{V}}_s^{\prime } \) of the original signal V s is shown as

$$ {\mathrm{V}}_s^{\prime }=\frac{{\mathrm{V}}_{\mathrm{REF}}}{2^n}\times {s}^{\prime } $$
(7)

4 Experimental results

An 8-bit ADC is used in this experiment with its reference voltage at 2.533v. In consideration of the limitation of performance of wearable equipment, the sample frequency of ADC is set at 10 Hz, the period of bidirectional shaped saw-tooth function is set at 40s, and its amplitude is 0.16v. According to the definition of m, m = 24.95 is calculated. In order to reduce the random noise, the experiment uses down-sampling technology, that is, the average value of each continuous four sampling points is calculated as one sampling point. The experiment collected three sets of voltage data, each set contains three periods, the results are shown in Table 1.

Table 1 Experimental results

5 Discussion

According to the equations (4) and (5), the solution procedure of the amplitude of the signal s has nothing to do with the start time t 1 of the saw-tooth wave, and is independent of the end of the forward and reverse saw-tooth waves. So this procedure avoids the error caused by the ΔN which has been introduced because the saw-tooth wave amplitude is not equal to integer multiple of LSB in the actual case in equation (1).

The error calculated by the readings of the ADC is determined by ΔS. When ΔS is small enough, the error is very small and the second set of data is in this case. Nevertheless, this is just a random situation, not universal. From all the experimental results, our method can effectively improve the measurement accuracy of the ADC and break through its maximum limitation. In order to make the calculated results more stable and reliable, we can figure the average of measuring results of multiple periods.

The error of affecting the accuracy of the signal s in the paper, which has been caused by bidirectional saw-tooth shaped function, is mainly from three aspects. The first is the accuracy of the t 3 and t 4 when signal amplitude of the forward saw-tooth wave is S + 2 in the first time and the last time. The second is the accuracy of the t 7 and t 8 when signal amplitude of the reverse saw-tooth wave is S-2 in the first time and the last time. That is, the higher the sampling frequency is in each LSB of the ADC, the more accurate the measurement time is, and the more accurate the calculated original signal value is. The third is the random noise and the jitter amplitude of the mixed signal.

6 Conclusion

In this paper, an innovative method has been developed, which makes it possible to use a lower-resolution ADC at a lower cost in a wearable device to detect weak signals. Compared to the traditional method of superimposing unidirectional saw-tooth wave, this new method can effectively solve the nonlinear problem of the starting point of the saw-tooth wave and eliminate the error caused by the fact that it is difficult for the amplitude of the saw-tooth wave to precisely control the integer multiple of the LSB. The new method for bidirectional saw-tooth waves only requires one stable linear interval greater than a complete LSB duration. Experiments show that our scheme improves the ADC resolution effectively. Our future work will focus on how to further improve the accuracy of the measurement.