# Project: EOGee – Hardware Noise Analysis

Having previously improved the drift performance of EOGlass, I decided to look a little into the sources of noise. It’s pretty clear that there is a lot of noise on the signal.

It’s actually pretty tricky to know exactly what is noise, given that I don’t really know exactly what my eyes were supposed to be doing and, even if I did, the eyes often make micro-saccades that the conscious brain isn’t aware of. If I zoom into a section that looks like I was keeping my eye relatively still, the noise turns out to be about 60 ADC counts peak-to-peak. This is equivalent to approximately 21863nVpkpk, when referred to the input (ie before amplification) (12-bit ADC, 3.3V range, gain of 2211).

I wanted to know how much of this noise was coming from the hardware, and how much was coming from the user. For this I decided to analyse the noise contributions from each stage of the signal chain. Texas Instruments have a good application note on noise analysis.

##### Measurement

To begin with I measured the noise of the signal chain when the inputs were grounded, rather than connected to a human. This is an accurate measurement of the total noise coming purely from hardware.

I shorted both inputs to ground and recorded data for about 10 minutes.

Firstly, we can see there is a reasonable amount of drift. This could be due to the electronics warming up but I would like to look into this further to see if it settles out after a while. For now we can see that the noise is approximately 10 ADC counts peak-to-peak which is equivalent to 3644nVpkpk. If we assume that our peak-to-peak value is equivalent to a +/-3-sigma value, our standard deviation (or RMS noise) is 607nV.

Now we can analyse the circuit to calculate the theoretical noise and make sure it all adds up. This will also help us to understand where the majority of the noise is coming from.

##### 1. Input Resistors

For safety reasons, it is common to insert a high-ish value resistor between the user and the circuit. This is meant to ensure that if there is any kind of voltage spike, the current into the user is limited. In the EOGee circuit we use a 47kΩ resistor on each of the inputs.

These each generate an unavoidable thermal noise, proportional to the square-root of their resistance, the temperature and the bandwidth:

K is the Boltzmann constant, T is the temperature (in Kelvin), B is the bandwidth and R the resistance. In this case we assume room temperature of 293K. For bandwidth we choose a value of 130Hz because of the low-pass filter in the signal chain. However, because this is only a single-pole filter we account for the slow roll-off by including a factor of 1.57 to give us an equivalent bandwidth of 204.1Hz.

In total this gives us an RMS voltage of noise of 394nV for each of these resistors. Because they are uncorrelated voltage noises, the total noise is the square-root of the sum-of-squares (RSS) which gives us a total of 557nV. Because these resistors are directly connected to the input of the circuit, we don’t need to do anything further to get a “referred to input” (RTI) value.

2. Differential Amplification Stage

The next element in the circuit is the AD8220 differential amplifier which applies a gain of 67 to the signal – for this we go to the datasheet to extract the noise value.

The noise is specified in a few places – to start with we can look at the graph of noise vs frequency.

Here we can see that not only does the noise depend on frequency but it also depends on gain. Since our amplifier is operating at a gain of 67 we can not directly look up the noise. However we can note that the curve for gain=100 is basically equal to the curve for gain=1000, and not too much different to the gain=10 line. This implies that at some point the gain starts to become irrelevant. We will therefore assume that we can use the gain=100 line or the gain=1000 line to approximate the gain=67 line.

Given that this is the case, rather than try to read this plot we can look directly in the specifications.

Here we see that the noise from 0.1Hz to 10Hz is given as a total of 0.8μVpkpk at a gain of 1000. Once again assuming peak-to-peak is equivalent to a +/-3-sigma value this gives us an RMS noise of 133nV.

This does not account for the noise between 10Hz and 204Hz (our equivalent bandwidth). For this we can use the input voltage noise (eni) of 14nV/√Hz and multiply it by the square-root our remaining equivalent bandwidth which is √(204-10)=13.9√Hz to give a total of 195nV.

We chose to ignore the current noise as it is so low. 1fA/√Hz through 47kΩ is only 0.047nV/√Hz which is much smaller than the voltage noise.

Because our two noise values operate over two different frequency ranges, we simply add them to get a total noise of 133nV + 195nV = 328nV.

Once again, because the datasheet is providing RTI data, we do not require any more steps to refer this value to the input.

3. Second Amplification Stage

The second stage is an inverting amplifier. This is more complex to analyse because we need to take into account the thermal noise from the resistors as well as the noise from the amplifier.

For this analysis we connect the input to ground and insert voltage sources to represent the noise in the circuit. Inverting amplifier circuit with input shorted to ground and noise sources included

In this case there are three sources of noise: E1, the thermal noise from R1, E2, the thermal noise from R2, and En, the amplifier noise. The next step is to break these down individually. By isolating each of these three noise sources individually we can find how the output voltage depends on each of these noise voltages and arrive at the following equation:

In our circuit the values of R1 and R2 are 100kΩ and 2.2MΩ respectively to give a gain of 22. The thermal noise of the two resistors (E1 and E2) are calculated as described above and are equal to 575nV and 2696nV.

In order to calculate the amplifier noise, En, we use a similar approach to what we used for the AD8220. In this case our amplifier is the LMV358A and we get an RMS noise of 850nV from 0.1Hz to 10Hz and 460nV from 10Hz to 204Hz to give us a total of 1310nV.

Using the above equation we can combine these three values, E1, E2 and En, to get the noise at the output, Vout, which is equal to 32789nV. This may sound very large, but this is the noise observed after the second amplification stage and needs to be referred to the input.

Our first amplifier has a gain of 67 while our second amplifier has a gain of 22. This means we must divide our noise value by these two values to get the RTI noise. This comes out at only 22nV.

4. Final Amplification Stage

The final amplification stage is very similar to the previous stage. It is also an inverting amplifier except in this case R1=10kΩ and R2=15kΩ to give a total gain of 1.5. Because this stage is placed after the 130Hz low-pass filter, the bandwidth is only limited by the bandwidth of the anti-aliasing filter which is 28kHz (I am sampling at 30kHz so I should really reduce this to around 10kHz). Despite the larger bandwidth, and due to the significantly lower gain and lower valued resistors, the total noise in this case is only 5290nV which is reduced to 2.4nV when referred to input.

5. Other sources

There are some other noise sources I’ve not considered. For example, the ADC will have some noise, however from previous experiments I know that it is on the order of 1 ADC count peak-to-peak and therefore is fairly insignificant. I am also ignoring the noise from the mid-rail circuit. This includes a 10kΩ voltage divider and a unity gain buffer. The contribution from this circuit will be less than the final amplification stage because, although it uses the same amplifier, it has lower value resistors at the input and a gain of only 1 rather than 1.5.

Total Noise

We can now add the contribution of all the considered noise sources. Because they are all uncorrelated random noise sources we take the square-root of the sum-of-squares to get a total.

Our final value comes out at 647nV which is very close to our measured value of 607nV. This discrepancy of about 6% could come from a number of places. The biggest source of error was probably the measurement which was taken by eye – a 6% error on top of 10 ADC counts is less than 1 ADC count error. There could also be some error in the assumed bandwidths and gains due to component non-idealities.

This analysis also highlights that the largest noise sources occur at the start of the signal chain. This is because they are subsequently amplified 2211 times before reaching the ADC. Clearly the input resistors make up the majority of the error and removing them would reduce the total noise to 329nV. This would give an expected peak-to-peak noise of 5 ADC counts.

To check this, I shorted out the 47kΩ resistors with 0Ω resistors and remeasured the noise. Once again the signal is somewhat corrupted with drift but we can see that the noise has significantly reduced.