mainly document changes

This commit is contained in:
2019-02-19 10:18:30 +01:00
parent db8640997a
commit 4c676269fc
9 changed files with 345 additions and 61 deletions

View File

@@ -234,10 +234,14 @@ Motor 1,2: $K_{fff}\approx100$\\
\subsubsection{using advanced Deltatau Servo Loop}
For now only following settings of the servo loop are used:Kp, Kvfb, Ki, Kvff, Kaff, MaxInt.\\
The standard PID servo loop has some additional features, that were not yet used, especially the polynomial filters.
The standard PID servo loop (figure\ref{fig:deltatau_std_ctrl}) has some additional features, that were not yet used, especially the polynomial filters.
\begin{figure}[h!]
\center
\includegraphics[scale=.2]{/home/zamofing_t/Documents/doc-ext/DeltaTau/ServoBlockDiag.png}
\\
\caption{position dependant friction of motor 2}
\label{fig:deltatau_std_ctrl}
\end{figure}
\cite[293]{PMACusr} shows details about the standard servo loop but unfortunately there are errors in documentation and the explanations are not really helpful. Hopefully the implementation is correct.\\
@@ -781,17 +785,43 @@ Motor[1].Ctrl =UserAlgo.ServoCtrlAddr[1]
\FloatBarrier
\subsection{The reality of the state space controller}
The state space controller assumes that the system is observable and controlable. The bode plot shows a flat amplitude at low frequencies, which makes the feeling, that the system is observable and controlable. But in fact the reason of that flat amplitude is friction (section \ref{sec:friction}). The viscode damping is also negligable.\\
This results to the fact that $F=m \cdot \ddot{x}$ consists of really 2 integrators. But an integrator $\frac{1}{s}$ is neighter observable and controlable. Therefore we have to check, how to implement an optimal controller for such a system.\\
The state space controller assumes that the system is observable and controlable. The bode plot shows a flat amplitude at low frequencies, which makes the feeling, that the system is observable and controlable. But in fact the reason of that flat amplitude is friction (section \ref{sec:friction}). The viscode damping is negligable.\\
This results to the fact that the stage consists of really 2 integrators and behaves without friction roughly like $F=m \cdot \ddot{x}$. But an integrator $\frac{1}{s}$ is neighter observable nor controlable. Therefore we have to check, how to implement an optimal controller for such a system.\\
A controller consists in a feed forward and a feed back transfer function.
The overall transfer functions y/u and y/e are: ... Setting H(s)=s results in a overall transfer function of y/u=... and y/e=... .\\
Simulating all this in MATLAB results in unstable system because of the derivate, but with a discrete differentiator it becomes stable again.\\
The optimal loop would be Kaff=(bode value of integrator), Kvff=Kvfb=Kafb=0.
Kp values is the speed to attenuate error values.\\
This is stable as long as Kp=0. With a Kp value, the system starts to osscilate instable. Stability can be achived again with e.g. Kvff=Kvfb=...\\
\begin{tcolorbox}[colback=red!5!white,colframe=red!75!black,colbacktitle=red!50,coltitle=black,title=TODO]
Assume a plant consists of a integrator $\frac{1}{s}$ the overall transfer functions y/u and y/e are: ... Setting H(s)=s results in a overall transfer function of y/u=... and y/e=... .\\
\end{tcolorbox}
Simulating a single integrator plant in MATLAB works. But with 2 integrators the system is unstable because of the two derivate elements. With a discrete differentiator it becomes stable again. In fact a derivate element is a very critical element.\\
\includegraphics[scale=.45]{FF_FB_ctrl.png}
The optimal parameters for a pure feed forward systems are calculated
in equation \ref{eq:calc_Kaff}.
\def\ccdot{\negthinspace\cdot\negthinspace}
\begin{equation}
\begin{aligned}
&DesPosFB=DesVelFF=0,\quad posErrFB=velErrFB=accErrFB=0\\
&\text{Motor 1: 19.8Hz 0dB, Ts=5kHz=.2ms,}\quad
k=(19.8 \ccdot 2 \ccdot \pi)^2\\
&Kaff = 1/(Ts \ccdot Ts \ccdot k) = 1/((19.8 \ccdot 2 \ccdot \pi)^2/5000^2) = 1615.2\\
&\text{Motor 2:11.84Hz 0dB, Ts=5kHz=.2ms,}\quad
k=(11.84 \ccdot 2 \ccdot \pi)^2\\
&Kaff = 1/(Ts \ccdot Ts \ccdot k) = 1/((11.84 \ccdot 2 \ccdot \pi)^2/5000^2) = 4517.28\\
\end{aligned}\label{eq:calc_Kaff}
\end{equation}
To correct errors, posErrFB is increased. But in a discrete system, the regulation becomes instable, because the actPos always lags the desPos for one sample. To avoid instability, a fiter can attenuate this problem.\\
The Standard Delta Tau controller (figure \ref{fig:deltatau_std_ctrl}), shows avery similar feed forward and feedback loop structure with additional filters. So after all the measurements, we can calculate the optimal Kfff and Kaff values.
Kp and Ki values will attenuate the errors. Kvff=Kvfb makes the system stable at hither Kp values, but setting the filter B seems to be more appropriate.\\
% Motor 2:11.84Hz 0dB
% Kaff = 1/((11.84*2*np.pi)**2/5000/5000) = 4517.278506241804
Looking at the Standard Delta Tau controller, one sees, that it has exactly the feed forward and feedback loop. So after all the measurements, we can calculate the optimal Kfff and Kaff values.
Kp and Ki values will attenuate the errors. Kvff=Kvfb makes the system stable at hither Kp values.
% Motor 1: 19.8Hz 0dB
% K=(19.8*2*np.pi)**2