 Okay, now let's look at the PI regulator tuning. So we recommend a sequence of the steps for tuning the PI parameters with the current regulator, the observer and observer regulator, speed regulator and other. So let's begin with the current regulator. You can find it in the monitor mode on the first advanced page, and it's depicted in the red shape. So, how to check that the current regulator is set properly? What do we need for checking the current regulator operation? That output is the answer. Then we need the oscilloscope and the current probe. The useful thing is that we fix the rotor by hand or by fixing the load. We apply a unit pulse current signal and observe the curve of the current. So how can we do it? We will come to the monitor and we will set the KP and KI initially to zero on the ID PI regulator. We will set up the startup table like depicted on the bottom of the screen and launch the motor. Then we can see the properly setup current regulator with the oscilloscope on the current probe and on the DAC outputs. There are sharp edges and fast reaction of the current reading. If the current regulator is set improperly, we can see several different phenomena. If it's under-regulated, the current readout will have a significant delay. This is the left picture. The right picture shows when the current regulator is over-regulated and oscillates. So for the first part, increase the KI parameter and in the second, decrease the KP and increase the whole KP slash KI ratio. If we don't fix the rotor, we can still observe the proper setup of the current regulator but we will see the current distorted by shaking of the rotor. The next part for the tuning is our user observer, Lohenberger observer. How it works? It works in the input as a bus voltage applied a voltage vector in PWM and also read back currents. From that, the Lubeck system with some correction parameters C2 and C1 reconstruct the back EMF signal and through that reconstructed signal we can reconstruct speed and angle. The tuning of the observer is as well available in the monitor mode and we can see the setup in the top right corner of this dialog box. There are three very interesting values, the observer C2 parameter which is equivalent to the G2 we spoke about previously and the PLL for the speed reconstruction which is a PI regulator with the KP and KI parameters. So let's check whether the observer is set properly. What we need again the DAC output and the oscilloscope and now we need to set the DAC output channels 1 and 2 to the observer back EMF alpha from the PLL and the second one as a back EMF beta. So if the observer gain C2 is too high this makes the speed reconstruction a little bit noisy because the bandwidth is very high. So it may happen that it never recognizes the motor operation as reliable and we finish with the startup failure or the speed feedback failure. So what we need to do right now we can decrease the original observer gain C2 by successive steps divided by 2, by 4, by 6, by 8 or even more. Additionally we can as well enlarge drive parameters and enlarge the variance threshold in the drive parameters speed and position feedback management dialog box so that the motor locked is still possible to detect but it's less demanding which means for the PLL mode up to 80% for the variance threshold and up to 400% for Cortic. Now to tune observer through the DAC output and now you see a nice picture from the oscilloscope and you see noisy back EMF how we solve this issue we have to change some parameters in this case it's good to reduce C2 parameter and you see that signal it's without the noise. So the solution was to decrease the C2 parameter. Okay there can happen that the speed reconstruction PLL, KP and KI parameters are too high and you can recognize this situation during low speed operation on the measured speed chart. The solution is again similar to reducing the C2 but decrease the KP and KI parameters both of them successfully by the steps divide by 2 by 4, 6 and 8 and test for the highest one which begins to be reliable. Now you see signal from the plot window in the speed and you see that the speed reconstruction is not well, it's shaking around some value. How we solve it? We reduce the KP parameter and you see that the result is better. If we reduce also the KI parameter then we see that there is only a few peaks and reconstruction is smooth. Okay now let's talk about the speed regulator. It's setup is in the middle of this window and it allows you to achieve a given speed, the target speed within a pre-selected duration. When the motor spins and we click exact ramp button this speed will be reached after the setup duration. So let's see how we can check whether the speed regulator is set up well and we can do it directly in the motor control of workbench monitor mode. Initially we will set the speed ramp with a zero duration and a given target speed. When the motor starts it will stabilize at a value and we need to generate a speed step so we will do it by sending this speed command with the exact ramp button. The speed change shall be visible in the plotter. In the red color it's required speed in the yellow color it's measured speed and traction for the required step. This is the setup of the properly set speed regulator. However, if we see artifacts like this with the over and undershoot this means that the regulator is over-regulated. In such case we have to decrease the Ki. Second case is that we have under-regulation. It's not a fast reaction and limiting in the long time and for that we have to increase Ki parameter.