# mod09lec36 Now, we will see other step in our signal conditioning and processing unit So, if you recall our block diagram, if you go back to and visualise our block diagram We will see this ECG amplify amplification same time later ah by the end of the experiment and we have done the filtering part which is nothing, but a pre processing part which are we required; especially like low pass filtering high pass filtering as well as notch filtering Now, next step is what? If we recall our previous ah section we we require in order to find out our BPM, we require to know the QRS peak How many number of QRS peak obtain within a minute gives the measurement of our BPM So, in order to find out the BPM value how do we determine, this is are peak QRS peak and were when we see that peak can be either positive peak are negative peak generally negative peak are called Vales But, we design a circuit no matter what either it may give the positive peak or a negative peak And, since we are interested only in a positive peak ah values if we can pass though an half wave rectifier the negative peaks will be completely removed off So, that is a reason we are we are interested or we have to design a half rectifier, but it is not mandatory to have an half rectifier Even we simply we can go with the positive peak detector and it ritual in circuit and we can implement that too without having half wave rectifier But, if you have a half wave rectifier we do not even have to worry about the negative peaks at all Now, how do you do an half wave rectification? Half way rectification using an op op-amps, if you remember op-amp generally in case of any rectification the first and ah the important ah passive element, the important active element that we take is nothing, but a diodes Diodes plays an major rule, diode plays actuarial even in case of our filtering from AC to DC So, one step is a rectification were half wave ah you know by using diodes we will convert our AC signal into pulsating DC right So, so the problem with ah simple element is impedance matching So, that is the reason if you want to if you want to have some gain as well as some kind of an ah impedance matching rather than having a simple ah you know ah diodes, if you can go with diodes with an operational amplifier it will always have a better advantage Now, if you see here ah you know half wave rectify So, since we required to remove ah negative remove negative signal right as our intention is to find out our positive peak, the negative peak will be rectified using this half wave rectifier Now, how does it work? If you clearly see that right the input is connected to the positive terminal And, forget about the diode right now how does it if this diode is not there, how does is look like? It is nothing, but a half wave rectifier sorry it is nothing, but our voltage follower Now, how do an voltage follower works? What are the input that we give? Output will also be the same so and the gain of the voltage follower is 1 So, whatever the input amplitude the output will all have same amplitude with was not having any change in the shift phase shift The reason is the input is applied to the positive terminal But, now in this case if you clearly observe there is a diode, only one particular amplitude will be allowed and the amplitude below ah and the negative amplitudes cannot be allowed right So, when the diode is in a forward bias condition it allow the input signal When when the diode in reverse bias condition it will not allow it right So, to understand about the circuit what we do that we can understand for example, like say if the input is a positive peak; what was supposed to be the output it should also be positive peak right Now, because of this positive peak the diode will be in the forward bias condition So, that we will get positive peak Now, during a negative peak since it is voltage follower right, we will get a negative and diode will be in a reverse bias condition So, we will not get anything right, but diode will have some cut off; ideally speaking we will not get any negative and similarly another positive peak So, as a result when we pass through the circuit we will get only a positive peaks right Why why do we have to go with the circuit? Because, when we see our ECG signal, ECG signal will also looks like something like this Since, our interest is only this QRS peak right and we do not have to consider the negative and this is nothing, but our unwanted signal So, what we can do is that, we can remove this particular signals which are lower than this value right So that means, the negative ah values can be completely eliminated removed by using this our half wave rectifier . So, to understand that we will do ah you know simulation Now, what we require? We require a diode let me take ah op-amp as well as a let me take op-amp as well as diode then we require a resister So, negative turn terminal should be connected here and ah this is R l; any resistance value is more than enough at this point Even we can go with a 10 k, it should not low the input So, let me take it as 10 k resister Now, to understand the working of the diode working of our half wave rectifier, what we do is that will connect a sinusoidal input free signal Working of the circuit connect a sinusoidal input signal right and the peak to peak value is 2 volts because, this signal is generally used to represent a peak voltage itself Since so, since we require the positive peak and negative peak as an input signal So, that easily to understand whether it is passing only the positive peaks or positive as well as negative peaks So, we can ah take peak to peak as 2 volts, then to visualise both input and output and connecting green; green represent are input signal and other one blue represent our output voltage Now, when we go to grapher and run the circuit right If we observe the green is nothing, but our input blue is nothing, but our output When we see that the green is completely right full way with the peak to peak of ah 2 volts and peak to peak value as 2 volts But whereas, the output if you observe it was only allowing a positive peak to flow whereas, a negative peak is completely removed off So, so even if you considering ECG signal in the same way only the positive positive portion of the ECG signal will be allowed and the negative portion of the ECG signal signal will be removed So, that now it is easy to understand the positive peak from the data, from the signal and we can set a threshold Now, here comes our thinking Why? The reason is when we recall what we had discussed about our ECG signal till this part is ok, but how do we find out this particular voltage is a peak and how do we set a threshold to the system right So, as we know that if we keep a capacitor, capacitor will charge to what value to whatever the output we receive So, from that we can understand that if I use a capacitor, if the voltage is increasing capacitor start slowly right So, it is since if we do not create any discharging path whichever the voltage that we get highest voltage that we get capacitor will be charged to the highest voltage value that is good enough So, it is easy to understand the highest peak in ECG What I mean is that, suppose if I pass the signal to a capacitor So, if I if the complete signal is passing through this since, the maximum voltage is at this particular value right And if I do not create any discharging path the capacitor will always at this particular point , but how do you set a threshold right The idea is that if I can set a threshold, if you recall what we have discussed in our in our first ah ah session of our experiment If we recall, if I can set a threshold and if I can find the peaks how many number of peaks above this particular threshold points that completely gives our the number of peaks in particular duration of time But why why do we have to consider? The reason is when we see the peak this also will be consider as peak, this also consider as a peak right So, if I do not consider the threshold even this things can also be considered as a peak and very hard to understand the BPM correctly and accurately So, that is reason as you already know that the QRS peak is very very long are having a very high amplitude compared to other peak; if you can detect this particular peak our problem is solved So, in order to detect that we are using capacitor which shows you know the complete highest voltage, but how do we create a threshold right And, if I if I can create a threshold if I compare the output signal from the input signal; so, when you do the comparison whichever is the highest that I can decide it right So, if you see the logic to implement it so, this particular capacitor part will charge And, the purpose of this 1 mega and 2 mega is to provide is to provide threshold, but what percentage of threshold we are doing here So, if you observe suppose if I say this is nothing, but voltage divider circuit 1 mega 2 mega, if I say this is V in So, this is what V out, V in is that the charge across our capacitor right The capacitor will be charged to the r voltage value let as consider that V in so, V out is nothing, but V in into 2 mega divided by 3 mega . So, 2 by 3 is how much? 66 percent right 2 by 3 is 66 percent of V in So that means, we are setting a threshold at 66 percent If you want to set at 75 percent or if you want to set at 50 percent, even we can change the resistance value such a way that it will always gives 70 percent or 65 percent whatever the percent that threshold in that we required for Now, why do we are choosing 1 mega and 2 mega resistance? Why not 1 kilo 2 kilo 100 ohms 200 ohms The reason is that the input signal should not see it should not create any loading of our input signal When we choose a resistance value this resistance required some current to operate right So, because of that because of that we cannot it creates an loading on our input signal So, in order to not to have any effect on our input signal, what we do is that if I can take very high input resistance it will not load are the input signal So, rather than going with 1 kilo 100 ohms, if I go with mega ohms the ah you know the loading effect will be good So, that is why we are using 1 mega and 2 mega . So, then whatever we get is nothing, but the signal with her greater than this threshold, this threshold is 66.6 percentage So, it will get a signal like this right, we will see what we do that in a simulation will pass sinusoidal signal And, we will look at this point without this particular, we will see whether the capacitor is passing to the peak value or not Now, we will take even this particular portion this portion to attach to that and will see whether, it is setting a threshold it is passing a only the value greater than particular threshold or not right And, we will also compare with experimental results Now, we will see how to implement ah the circuit using a simulation Once we verify ah in a simulation, we will see in actual way and we will do the experiment on that So, just open multi-sim, if you recall the circuit what we have discussed just recall the circuit So, we need this particular part So, I will take an op-amp I will take op-amp right And I need to have a diode . So, I take a diode then we will take resistors as well as a capacitor, I am taking a resistors one more resistor and capacitor to . So, capacitor is also their then this resistor right So, this two has to be connected together Now, if you remember the purpose of a capacitor is to charge to a peak value So, which are the value that we are ah that ECG signal peak value is there that will be charge inside the capacitor Now, the purpose of this resistors are to provide threshold, now we are setting a threshold using 1 mega resistor or 2 mega resistor So, we calculate we recall it is somewhere around 66 percentage right So, I am taking 1 mega as R 1 resistor and 2 mega as R 2 resistor Now, we have to connected this terminal to one right, so this is the input signal So, in order to circuit what we use is generally go with AC voltage, so let me connect AC voltage here, connecting here and we also need a ground So, I am taking ground connecting here from here to here and even this part to be ground So, what we have do using this circuit? What we have to major? We will see what is a output voltage at this whether, when I change the voltage of the input whether the capacitor output So, in order to understand what I do is that let me remove this part this particular terminal so, that there is no connections here So, we can easily see whether it is following the peak or not Then we will make this connection and at this particular terminal at this particular junction or at this particular node right, we connect another voltage ah output nothing, but our we will connect to a probe and we will see what how the output signal looks like right So, whether it is ah giving that threshold of our requirement or not Now, I will take 2 ropes: one at the input So, which measures the input voltage or whatever the important we are connecting to the op-amp positive terminal And, other one at this particular point right So, the green in represent are input and the blue represent are output of the op-amp Now, to understand the circuit let me go to the grapher and run it See what we can see, the green is completely input right, the blue is output, output is always showing it is 1 right let me stop it So, if it is showing the 1 what were how do we understand it Now, if I zoom completely zoom all and let me zoom only to this particular portion somewhere around 159 millisecond right And, even to 10 millisecond I will zoom right, if you observe the output initially it is keep on increasing, keep on increasing Meaning, it is charging the capacitor starts charging, charging and it charges to value of 1 Why only to 1? Because, the input voltage the peak voltage that we applied is only 1 volt And, since we do not have any discharge in path, since it is a maximum voltage that output is providing it is the capacitor is always at this particular point What if I change my output right, if I change sorry what if I change my input If my input voltage change, if the input voltage is 2 volts slowly again the capacitor charging to the 2 volts value Why do not we see that? So, the whole idea of this circuit is to find out the peak value And the purpose whether it is the purpose is solving or not let me check So, let me run continuously and I am running it continuously Now, this voltage I will change it to 2 1.05 to slowly to 2 value, 2 volts now it is a 2 volt. ah Now, let me change the setting of the grapher to voltage If we observe now, the capacitor stated increase to a to value of input peak value right, isn’t it Now, what if I decrease let me decrease right Now, the capacitor started slowly decreasing because the input voltage now it is very small and the capacitor will also take some time to discharge So, because that entirely depends upon the discharging rate So, that is why it started ah discharging and again continuously maintaining the value of the peak So that means, one part it is clear that whatever the peak voltage that we are getting, the capacitor can the capacitor will charge to that peak value right Now, what is other purpose, we have to see whether it is providing the threshold of our requirement or not So, in order to understand whether it is providing or not what we do, we will connect this R 1 resistor and we will take another output voltage connected this point Now, this particular terminal I am not interested in I do not have to So, what I will do that, let me run and yeah even if it is there no problem for us right So, this indicates our ah the output voltage at this particular point and the violet colour indicates the threshold; that means, the output voltage at the threshold, ah at the junction or note point of both the resistance 1 mega or 2 mega Now, based upon calculation based upon calculation, what is the threshold value So, as we if we recall the potential divider circuit it is nothing, but V in into R 2 by R 1 plus R 2 So, in this case V in is for example, like say V in is 1 volt and R 1 is R 2 is 2 mega R 1 is 1 mega 2 by 3 2 by 3 is 66.6 right So, that that means, if the input voltage is 1 volt the output the threshold point is somewhere around 0.66 millivolt 6 60 666 or 0.66 millivolt right Now so, to understand that let me change the input voltage to 1 volt Now, observe right 664 millivolt; that means, it is it is properly following the required or whatever the thresh point that we said right If the input voltage is changing, even the threshold value will change and how fast it changes everything depends upon the capacitor value that we choose that we have chosen there So, in this case we have chosen 1 micro 1 micro farad capacitor right So, another requirement in order to do the signal conditioning circuit or signal processing circuit of our ECG is completely full filled using this circuit right Now, what is other part? What is the other part? Now, once we ah detect once we understand which are all, but which are all voltages or which are the input signal is greater than this particular threshold, only those output signals has to be passed right Now, we have set this, now what we have to do the input signal should be compared with this particular threshold value And, whenever the input value is greater than the threshold value only that particular value has to be pumped out . So, in order to do that what we have to use, we have to go with a comparator Simple comparator is enough, we do not have to go with smit triggers or anything The reason is we are not setting any two thresholds here, we are using only single threshold If the input values greater than this particular value only that particular signal has to be passed and that has to be detected and that has to be counted So, depends upon how many number of such a pulses are we are getting And, if you use a counter there then we can automatically ah see ah the number of pulses we are getting per second or per minute anything Now, in order to do that we will implement other part of a circuit When we look into our presentation right, this particular part we have seen . And if the input signal is sin wave, if the input signal is sin wave right right then at this particular point the the output will be completely; because of the capacitor because of the capacitor the output is charged to the particular value that is nothing, but the peak value So that means, we could able to see the peak value Now, this particular point we can also create a threshold Now, next part is identifying identifying and generating a triggering pulses, if the input voltage is greater than the particular threshold value So, in order to that what we will be using? We will be using a comparator, we will compare the input signal sorry ah the input signal with this particular threshold right So, how a comparator works? If you recall the working of a comparator and if I observe this ok, ah let us see this is plus or minus this is V 1 and this is V 2 and this is V naught If you recall so, the V naught will be equal to plus V cc, if V 1 is greater than V 2 right And, V naught will be equal to minus V cc if V 1 is less than V 2 Now, in this case if I see V 1 is nothing, but our threshold right So, positive terminal is V 1 and in this case positive we have connected to V 1; that means, the threshold values 666 millivolt and V naught is what sorry and our V 2 is nothing, but the input signal or the ah the positive PQRS wave right only this particular part Now, when we are passing that we will get a peak only when this particular input right input is greater than this value right So, when when when the input signal is greater than 666 millivolt so, say this is say 666 millivolt then we will get a peak value pulse Now, we will see whether we are getting it or not So, what I will do is that we will implement the same circuit So, if you remember so, this particular portion we will implement now right So, here we will apply the inputs actually input signal right This input signal we are apply and here it detects peak and it generates a threshold that we will compare with input signal And, whether we will get pulses only when the input is greater than that or not we will observe that ok So, I will go to multi-sim once again, let me save the circuit Right I will opening a new new file or to this itself we can create extension of it by using another comparator . So, I will go with schematic and I will take one more op-amp right So, let me flip it and the negative terminal when you look into our circuit, if we see the power to the positive terminal we are connecting we are connecting the threshold value And, to the negative terminal we are getting connecting the input signal Now, so just to identify what I will do is that I will take one more resistor, some some rough 1 k value And, other terminal I will be connecting it to the ground or you can connect to ah ok, we will take the same circuit itself, we will take LED So, I will take an LED, connect it here and one more ground let me connect it here . So, colour is red ok, it is cool now when I see let me run it So, since the frequencies very high we can see it continuously glowing . So, make it as frequency sorry ah 1 volt I will say 1 volt ok right then this one let me decrease So, we have to analyse So, 100 hertz is also really higher to understand So, let me make it as 50 even that is too much 30 Go to grapher and here let me change let me increase the time division, just to understand So, what is happening here that we have to understand Now so, we have not connected voltage source here So, let me remove everything right So, I will take one more voltage source connect to this point ok, I will take one more voltage source connect to this point Now, let me go to the split voltage right So, so zoom it so, to understand this How do we understand? ah If I want to understand this, what I have to do is that I have to create a cursor then put voltage is 1 volt So, the cursor is I will take Y axis cursor and I will keep somewhere around, if you observe the cursor value it should be somewhere around 666 millivolt Somewhere around roughly 679 and let me zoom little bit So, that is easy to understand for us, make it as auto or single yes, Now, what to understand? One thing is clear that the C 1 represent our threshold and the green colour represents our input signal What about the blue colour? Blue blue is nothing, but output our output Now, what is happening when our whenever the input signal is greater than that whenever, the input signal is greater than the threshold value what is happening it is going to minus V cc right And, whenever the input signal is lower than that it is going to plus V cc The reason why, because we have used positive input yeah, here if we observe the negative [term/terminal] terminal is connected to here whereas, the positive terminal is connected to threshold Now, when we recall our comparator working one thing we are sure that the e output will be higher only when only when the input signal is greater than this particular value right That is what ah that what we even we have seen in the calculation Now, to quickly understand that why do not we take some values So, take a sine wave I am taking a sine wave so, let us say the values 1 volt So, I am applying a sign o 1 of 1 volt and the threshold values 666 millivolt, now this is positive right So, in order to become plus V cc V naught to be plus V cc, when it will become only if the input is lower than the threshold in this case right Suppose, if the input is 0.5 volts V 1 so, we are taking V 1 as positive V 1 will be higher and this value will be lower, as a result V out will be plus V cc So, that is a reason, but we require in a [FL] way so; that means, if I make this is a positive and this as a negative right Then what happens since, it is 666 and this is the sinusoidal wave ah till ok ah when the . So, this is threshold in order to become V naught as the higher, the input voltage should be greater than the negative value only then it will become higher Now, just to under just to see that let me go to ah schematic; ah just to stop the circuit I will change I will swap the terminals ok This particular terminal should be connected to here and this is here and this particular terminal should be connected here right that is input And, here I am going to measure ah the threshold value and this is ok, now let me run it so, grapher Now, see what is happening? Yes, when we observe C 1, C 1 is at what point C 1 is 679 79 millivolts so, we require 666 Now, when we see the output is becoming higher only when the input is greater than this particular threshold Now, what is other colour behind that value behind the C 1, that is our blue colour that is for the threshold So, here if you remember the schematic we have used one at this point other one is at this point, like blue sky blue and dark blue So, here if you see this is the output and sky blue colour is somewhere here So, that is our threshold right Now, whenever whenever the input is greater than the value, we can also see the LED is keep on blinking it right If I change the input voltage, even thresholds everything will change So, let me make it as 5 and change this to auto right We can see threshold is also changed and even ah right this is the input and this is a threshold and this is the output that we are getting it So that means, that the thresholding part everything is working fine for our application Now, we will see experimentally right we will see experimentally of complete circuit Now, if you see the next part of this, this particular portion . So, we are using a diode right and we are also using a resistor right This the diode and ah the first ah first quadrant portion of the op-amp is using that ah you know ah the half wave rectifier portion So, in order to verify that ah circuit what we do is that now, the input we will connected to the input signal we will connected to the input of operational amplifier that is at the pin number 3 So, what I will do is that I will take the input sinusoidal signal to 3 volts ah to the third pin So, the third pin is somewhere here ok and this is the output ok and which is the output in this case, the output is after the diode So, that is somewhere around when you recall the circuit the output is the cathode terminal of the diode right So, the cathode terminal of the diode is connecting it to the second pin, second pin is are nothing but a inverting terminal of our op-amp Now, now if you see that in this case I will take one more wire or I will take the second CRO probe and I will connect the second CRO probe to that ah the second pin . So, third pin is input so, I am connecting it to the third pin of the input signal and the second pin is the output I am connecting it there right Now so, let me auto set it . So, we can keep it keep it at any frequency there is no problem When we look into ah the oscilloscope so, what I will do is that I will change the little bit down to the same value From the signals it is clear that right only one peak we can see in the output, only one peak we can see in the output and other peak we cannot see that that is because of half wave rectifying So, we are we are removing complete negative ah peak signals of our ah input signal by using a simple diode Why? The reason is that we have to find out only the positive peak, we do not need negativity signal processing in this case So, that is the reason we are going with ah ah the removal of negative signal Now, if I observe so, there is no negative signal whenever, there is a negative signal in input the output is 0 and positive signal it is passing through output is 0 when there is negative again So that means, it is completely removing our negative part negative peak of our signals, negative signals at all So, even if I change the frequencies no matter what frequency that you are at so, it can only [pos/positive] pass positive frequencies not the negative frequencies Sorry positive input signal not the negative input signal right So that means, that particular portion whatever we have seen in the simulation and what we are seeing in our ah experimental, the peaked ah then ah the half wave rectification is completely done Now, what is the next part that we have to see, after passing through the half year rectifier we have to find out the peak So, in order to do the finding out the peak, we if you remember we are using a capacitor Now, in this case if you see here the other part of the operational amplifiers in the board right, when we look into the board right So, this part we are using a capacitor and we are using the resistance of 1 mega and 2 mega right This combination, this particular combination will give us the peak ah the ah you know the peak detection as well as a thresholding So, now what I will do is that so, since we have already connected to this terminal ah and the output of this is connected to the next portion of our circuit; it is nothing, but the peak detection . So, it is already connected using the white colour wire here the output of this and know what I will do is it the output of CRO, we will take the output of CRO So, we will connect this particular point to to the cathode or the sixth terminals in this case so, this is my output right When we see that, when we look into the oscilloscope the input is yellow in colour, input is our yellow and the output is the the ah sky blue in colour right we can clearly see that Now, the output is very ah the output is completely at the peak value of our input signal Now, what if I change the frequency it remains a same, what if I change my amplitude right So now, let me increase a amplitude value So, right now it is the peak value of 1 volt, if you see that the peak value of 1 volt because, we are applying amplitude of 2 volts peak to peak 1 volt on the positive peak and 1 volt in the negative peak So, 2 volts peak to peak value I am increasing the voltage So, I will go to the amplitude I will change it to 3 volts; that means, 1.5 Now, see the capacitor because of 1 microfarad capacitor it is quickly charged and it has gone to the that particular peak value Now, if I slowly increase even then we can see so, it is always, but whereas, when I am decreasing it we can observe that the capacitor is slowly discharging And but whereas, when I am increasing it we can see quick rapid change of going to the peak value So; that means, we can understand that with this circuit we can easily find out the peak value of the input signal right So, the peak detection partition then then the next part is ones the peak detection is then we have to create a threshold Now, if we recall our circuit we are creating the threshold by using two resistance, that is of 1 mega and 2 mega resistor Why we are using such a high resistance value, again the reason is that not to have any loading effect into the system So, what I will do is that now this particular output terminal the blue connection I will connect it to ah you know the junction the resister junction So, when we see that we have connected to output at this point right which is the combination of 1 mega and 2 mega resister So, what we are using it at the node of 1 mega and 2 mega we have connected the output So, here if you can see you have applied input frequency of 100 right, amplitude peak to peak value of 2; that means, peak value of 1 volt Now, when we see the this is this is the yellow represents are input and we can see that the output is in blue colour right, the peak values of 1 volt 1 box and the blue colour if I see it is ah 2 2 points So, somewhere around 400 418 6 millivolts we are getting it The reason why there is a difference in the actual calculated value and and the the experimental value, it may be because of some loading due to the previous stage Or maybe because, of the tolerances that we have that since if we have used ah 1 mega or 2 mega resistances; the tolerances 5 percent tolerances is enough to change the complete the resistance value of that two different other values So, because of that tolerances and because of some previous loading stages it is changing some other it is going to show some other threshold value But as long as as long as even though my input voltage is changing, if that is maintained constantly my problem would be ok Or I can replace some other resistance value and we can see whether it is ah you know ah ah you know whether it is ah having ah the required the threshold or not But when we apply DC input voltage and we do the experimental and we can see the complete ah a like ah theoretically, we can see that 666 millivolts it can be achieved and even in the simulation we have seen Now, what I will do is that I will change the amplitude to somewhere around 4 volts So, if it is a 4 volts it should be so, previously it was 400 now, it should be 800 right Now, if I see previously it was it was in 2.2 level now it has moved to the 4 levels So, closely towards 1 volt so, somewhere around 800 millivolts So, that means when the input is keep on increasing the the threshold value is also increasing; let me change to some other value 6 So, it is 1.2 right So, either may be because of the previous loading or because of ah you know the tolerance is due to the ah resistance value the threshold value expected and and the actual are little different But, by put by putting some part some potentiometer we can even ah know set it to the required threshold value in this case Now what is other stage that we have seen, other stage is we have to pass through the comparator So, we have to connect the negative input to negative input of op-amp to this particular point and the positive input to the input signal So, that when we do in that connection we can see the output ah of an op-amp to plus V cc state right whenever the input is greater than the threshold So, so what we do is that when we look into the board, what we do is that we will connect the positive terminal to input terminal So, positive in this case is 10th terminal so, 1 2 3 4 5 6 7 8 9 and 10 So, this terminal I am connecting it to the input right whereas, other terminal I should connect it to the output ok, I will remove this wire . So, this is our threshold right to this threshold point I am taking one more wire I am connecting it to this point Now, I have to measure the output So, this my output, let me auto set it when I look into oscilloscope right . So, let me keep both the things to the same point So, easy for us to understand and this point to changing the offset value right And the input also I will change to the same ah 2 volts peak to peak So, easy to understand and let me change the input range to 5 volts right so, both are at the same point So, since it is so difficult to understand what I will do is that I will change the input amplitude itself to somewhere around 6 volts a peak to peak so; that means, 3 volts So, here it is clear now, if we remember the threshold the theoretical threshold for ah 3 volts would be 666 millivolt into 3, but practically we are getting 1.2 volts right So, practically we are getting somewhere around to ah 1.2 Now, when we observe that one thing is clear that when I say if I take a cursor, I will take a cursor of a amplitude time, I will just keep somewhere ah somewhere at 1.2 That is what theoretically when we measure, we are getting ah sorry ah the practical when we measure we are getting at that point Now, I place a cursor at that point it is clear that ah so, when we look into that it is clear that when the input So, the cursor yellow one when we looking to the CRO this particular cursor consider it has a threshold for us, whatever we have calculated practically ah practically Now, when the input is greater than the particular threshold, we can see there is a high value High in this case is 15 volts because, the V cc and minus V cc that we are applying is plus 15 and minus 15 It is close to plus 15, it is slightly below plus 15 because of the saturation The output saturation will be lesser than the V cc that you are applying to that And, when the input is lower than that particular value it is again going back to the minus V cc states But, when will look into the board we can see the LED is continuously going glowing We cannot see any flickering of an LED, like on off on off the reason is that frequency When we see the frequency the frequency that we applied is 100 hertz, 100 hertz it is a very hard to understand with our eyes So, what I will do is that I will change the frequency to somewhere around ah human understandable value So, ah somewhere around ah 30 or 20 hertz So, where we can easily visualise it, when I see that right since is the frequency when you look into the oscilloscope So, we can see we have kept somewhere around 30 and an even the oscilloscope so, we can see the input is 30 hertz frequency; oscilloscope we can see the high value And, when you look into the breadboard right so, whenever it is higher the LED is starting glowing So, when we look into the breadboard you can see because, of the smaller frequency right we can see the ah on and off, on and off our LED too Now, if we connect to a digital counter the output of this to a digital counter one thing is clear that we can easily count how many number of pulses we are getting it right And, if we create a some clock cycle for different ah for this particular time period, how many number of ah frequencies that we are getting right that gives us how many BPM beats per minute So, we have seen individual subsystem point of you how whether it is working as per our requirement or not Now, what we have to do we have to take a subject or we have to connect particular person, we will connect the ECG electrodes So, these are the ECG electrodes ah connected to the person So, one at right hand other one at right ah left hand and other one the ground is at right like that we have discuss in the starting of our experiment right And, here we will be connecting to this metal pins we will connect the electrodes and we will see whether we are getting ECG signal or not in a oscilloscope Then what we do is that will pass through amplifier for amplification of an ECG signal, until unless we to the amplification it is very difficult, very hard to detect using our normal DA source because, the amplitude of the actually signal is very poor right So, in order to improve our signal ratio we are passing through the instrumentation amplifier Then will pass through filtering so, that we can easily visualise whether ah the signal has been filtered or not