Просмотр исходного кода

Lägg till många förändringar i rapporten, eftersom jag skriver den i overleaf..

Jonatan Gezelius 6 лет назад
Родитель
Сommit
7edd13bb78

+ 5 - 2
rapport/conclusion.tex

@@ -1,5 +1,8 @@
-\chapter{Avslutande kommentarer}\label{cha:conclusions}
+\chapter{Conclusion}
+\label{cha:conclusion}
 %
 Sätt av ett kort kapitel sist i rapporten till att avrunda och föreslå rikningar för framtida utveckling av arbetet.
 
-It was suprisingly difficult to find and choose apropriate components for the dummy load. The resistors had to tolerate extreme surges and the relays had to have high insulation voltages between the contacts.
+Besvara frågeställningen
+
+Future work

+ 24 - 0
rapport/discussion.tex

@@ -0,0 +1,24 @@
+\chapter{Discussion}\label{cha:discussion}
+
+\section{Results}
+
+\section{Method}
+
+It was suprisingly difficult to find and choose apropriate components for the dummy load. The resistors had to tolerate extreme surges and the relays had to have high insulation voltages between the contacts.
+
+\subsection{Attenuators}
+\label{discussion_attenuators}
+During the project, the attenuation was considered as the voltage attenuation $att = 20 log_{10}\left( \frac{V_{in}}{V_{out}} \right)  \si{\deci\bel}$. However, lots of information and many tools for RF applications, including the calculator used for the attenuators in this project, assume power attenuation $att = 10 log_{10}\left( \frac{P_{in}}{P_{out}} \right)  \si{\deci\bel}$. The result of these two properties coincides when the input and output impedance, as well as the driving and loading impedance, are all the same.
+
+The fact that these two ways of expressing attenuation could be mixed up was not noticed until very late in the project. Thus the values provided by the online attenuator tool did not give the desired results in the simulator, for the \SI{1000}{\ohm} attenuator. This was at the time manually tweaked until the desired attenuation was acquired, but the out impedance was not considered during the tweaking and ended thereby up being a bit mismatched for the next $\Pi$ link.
+
+There are infinitely many constellations to approximate the nominal value, in this project it was tried to use as few resistors as possible. This process was performed manually, since no suitable software for solving the problem was found. Thus the chosen constellations might not be optimal.
+
+\section{The work in a wider context}
+Ethical aspects
+
+\section{References}
+Source critisism
+
+
+

+ 34 - 18
rapport/introduction.tex

@@ -1,17 +1,26 @@
 \chapter{Introduction}\label{cha:intro}
 
-For a product to be put on the market there are many regulations which the product must follow, e.g. electrical safety, material regulations, electromagnetic compatibility (EMC), radio regulations etc. To test products against these requirements in a unified manner, standards are used. A standard defines how a product should be tested and the accepted result that need to be achieved in order to ensure that the product complies with all the regulations. There are many standards for many different types of regulations and usually a single product must comply with several of these. It is also common that one standard references another standard, or specific parts of another standard, instead of redefining some tests.
+Ta bort
+\squareit{
+For a product to be put on the market there are many regulations which the product must follow, e.g. electrical safety, material regulations, documentation, quality systems, electromagnetic compatibility (EMC), radio regulations etc. To test products against these requirements in a unified manner, standards are used. A standard defines how a product should be tested and the accepted result that need to be achieved in order to ensure that the product complies with the regulations. There are many standards for many different types of regulations and usually a single product must comply with several of these. It is also common that one standard references another standard, or specific parts of another standard, instead of redefining some tests.
 
-The ISO 7637 standard, \emph{Road vehicles -- Electrical disturbances from conduction and coupling}, is an international standard that apply to products in road vehicles with a supply voltage of 12 V or 24 V. The standard states, here put in a very condensed form, that the product shall withstand a sufficient amount of disturbances applied to the power supply. The reason for this is that there can be many voltage surges and much noise in a vehicle's power supply lines. In general, the source of disturbances and noise in a vehicle origins from inductance in other devices connected to the power line, the cables and the vehicles alternator. \cite{iso7637-2}
+% https://europa.eu/youreurope/business/product/product-rules-specifications/index_en.htm besökt 2019-06-19
+}
 
-To test if a product comply with this standard, there is equipment which simulates different events on the power supply. The standard defines the different scenarios, raise and fall times of pulses, repetition times etc. It also defines the functional requirements of the equipment during these tests for what is considered a passed or a failed test. \cite{iso7637-2} 
+The ISO 7637 standard, \emph{Road vehicles -- Electrical disturbances from conduction and coupling}, and ISO 16750, \emph{Road vehicles -- Environmental conditions and testing for electrical and electronic equipment}, are international standards that apply to products in road vehicles with a nominal supply voltage of 12 V or 24 V. The standards states, here put in a very condensed form, that the product shall withstand a sufficient amount of disturbances applied to its power supply. The reason for this is that there can be many voltage surges and much noise in a vehicle's power supply lines. In general, the source of disturbances and noise in a vehicle origins from inductance in other devices connected to the power line, the cables and the vehicles alternator in combination with switching of loads or the supply. \cite{iso7637-2, iso16750-2}
+
+\todo[Mention that the standard also addresses emission, but that the report only focuses on immunity]
+
+To test if a product comply with this standard, there is equipment which simulates different events on the power supply. The standard defines the different scenarios, raise and fall times of test pulses, repetition times etc. It also defines the functional requirements of the equipment during these tests for what is considered a passed or a failed test. \cite{iso7637-2, iso16750-2}
 
 \section{Motivation}
 
-The standard defines all the timing requirements that must be met, and also specifies the load conditions for which the requirements apply \cite{iso7637-2}. From time to time the standards are revised with updated requirements, which might differ from previous versions of the standard. New equipment is guaranteed by its manufacturer to do the tests according to the latest standard, as long as it is regularly sent in for calibration and maintenance. New equipment costs a great amount of money and might not even be affordable by smaller test labs, and can thus inhibit labs from performing the tests.
+The standard defines all the timing requirements that must be met, and also specifies the load conditions for which the requirements apply \cite{iso7637-2}. From time to time the standards are revised, which might alter the requirements form the previous versions of the standard. New equipment is guaranteed by its manufacturer to do the tests according to the latest standard, as long as it is regularly sent in for calibration and maintenance. New equipment costs a great amount of money and might not even be affordable by smaller test labs, and can thus inhibit labs from performing tests for this standard.
 
 An appealing alternative would be the possibility to reuse the test equipment that was used along with the older revision of the standard, as long as it is capable of performing sufficient tests reliable. For this to be of any value the test equipment must be verified in some way to be able to guarantee that the tests are performed according to the new standard.
 
+The old ISO 7637-2:2004 standard got revised to 7637-2:2011 and some parts were 
+
 \section{Aim}
 
 The goal of this work is to investigate the potential of reusing test equipment made for an old standard, with the newer revised version of that standard, and how to assure that the test results are reliable.
@@ -22,17 +31,25 @@ The verification of the system is desired to be automated. This automated verifi
 
 The following questions will be answered in this paper:
 
-\begin{enumerate}
-    \item{How should the test equipment be verified to give a robust result?}
-    \item{How much differences are there in a real implementation compared to a simulated system?}
-    \item{What design considerations must be made when automating the verification system?}
-    \item{------- OLD STUFF FOLLOW, TODO REMOVE STUFF}
-    \item{Can test equipment for ISO 7637-2:2004 of the standard be used for testing compliance with the newer ISO 7637-2:2011 standard?}
-    \item{Is the reused system more cost effective than investing and maintaining a new test system?}
-\end{enumerate}
+\begin{itemize}
+    \item{Can test equipment made for ISO 7637-2:2004, be used for testing compliance against ISO 7637-2:2011, the newer version of the standard?}
+    \item{If it can; What considerations must be made to allow for automating the test and verification process?}
+    \item{If it can't; What causes the failure, and what possible fixes can be made to make the equipment usable for the newer standard?}
+
+    % \item{------- OLD STUFF FOLLOW \todo[Remove the old stuff]}
+    % \item{How should the test equipment be verified to give a robust result?}
+    % \item{How much differences are there in a real implementation compared to a simulated system?}
+    %\item{What is the best way of acquiring a high voltage signal with high frequency components?}
+    %\item{What is the best way to verify the time-domain parameters of the signal?}
+    % \item{------- OLD STUFF FOLLOW \todo[Remove the old stuff]}
+    % 
+    % \item{Is the reused system more cost effective than investing and maintaining a new test system?}
+\end{itemize}
 
-\section{Delimitation}
-This paper only compares the standard ISO 7637-2:2004 to 7637-2:2011. The area of interest here is the specification of the test pulses and how these are verified. Whether a product test is considered as pass or failure, which is also specified in the standard, is not of interest in this paper.
+\section{Delimitations}
+This paper only compares the standard ISO 7637-2:2004 to ISO 7637-2:2011 and ISO~16750-2:2012, because these are the most recent versions of the standards.
+
+This paper only considers Pulse 1, Pulse 2a, Pulse 3a, Pulse 3b and Load dump A. The main reason being that these are the pulses that the available equipment can generate, but also that these pulses share many properties and the method of analysing them will probably be very similar.
 
 This paper only considers the following test equipment for the real implementation that is available for this project:
 
@@ -52,9 +69,8 @@ This paper only considers the following test equipment for the real implementati
     \end{tabularx}
 \end{table}
 
-Though the methods used should be applicable to other similar standards and equipment.
-
-
+%The methods used might be applicable to other similar standards and equipment.
 
 \section{Report structure}
-TODO
+
+\todo[fyll i upplägg när det väl är klart]

+ 13 - 4
rapport/main.tex

@@ -8,7 +8,8 @@
   largesmallcaps,intlimits,widermath,% Good options to KpFonts.
   sharecounter,nobreak,definition=marks,%  See comments in the results chapter of this document for more information on these options!
   numbers, % If you want to cite references by numbers, use this option.
-  noparts% Use option 'noparts' if you do not make use of part divisions.
+  noparts, % Use option 'noparts' if you do not make use of part divisions.
+  table % Make xcolor work?
 ]{rtthesis}
 
 \usepackage{mythesis}
@@ -33,6 +34,12 @@
 \include{acknowledgments}
 
 \tableofcontents
+
+\newpage
+\listoffigures
+\newpage
+\listoftables
+
 \include{notation}
 
 \mainmatter
@@ -40,7 +47,11 @@
 \include{theory}
 \include{methods}
 \include{results}
-\include{conclution}
+\include{discussion}
+\include{conclusion}
+
+%\bibliography{IEEEfull,myrefs}
+\bibliography{myrefs}
 
 \part*{Appendix}
 \appendix
@@ -48,8 +59,6 @@
 \clearemptydoublepage
 \backmatter
 
-\bibliography{IEEEfull,myrefs}
-
 \printindex
 
 \end{document}

+ 42 - 0
rapport/main_partly_quick.tex

@@ -0,0 +1,42 @@
+\documentclass[
+  utf8,%     More capable input encoding than latin-1.
+  % parskip,%  For vertical whitespace between paragraphs.  This comes down to more than just using parskip.sty, so it's better to use this class option.
+  % S5MP % If you intend to really use margin paragraphs (not recommended!).
+%  crop,%     Produce output with crop marks and paper size A4.  Liu-Tryck should like this.  Automatically adds information, including the physical page number, at the top of each page.
+       %     Add option 'noInfo' to suppress the info at the top of each page when using option 'crop'.
+  % Font options: 'kp' (default), 'times', 'lm'.  The KpFonts (loaded using 'kp'), is the most complete font among the provided options.  Among other, it supports slanted small caps.  See rtthesis.cls for more details regarding the font options.
+  largesmallcaps,intlimits,widermath,% Good options to KpFonts.
+  sharecounter,nobreak,definition=marks,%  See comments in the results chapter of this document for more information on these options!
+  numbers, % If you want to cite references by numbers, use this option.
+  noparts, % Use option 'noparts' if you do not make use of part divisions.
+  table % Make xcolor work?
+]{rtthesis}
+
+\usepackage{mythesis}
+
+\usepackage{tabularx}
+\usepackage{float}
+
+\begin{document}
+\selectlanguage{english}
+
+\frontmatter
+
+\tableofcontents
+
+\mainmatter
+
+%\include{introduction}
+\include{theory}
+\include{methods}
+\include{results}
+\include{discussion}
+%\include{conclusion}
+
+\bibliography{myrefs}
+
+\clearemptydoublepage
+\backmatter
+
+
+\end{document}

+ 167 - 0
rapport/methods.tex

@@ -0,0 +1,167 @@
+\chapter{Methods}\label{cha:methods}
+This chapter covers the methodologies used during the project.
+
+\section{Prestudy}
+During the project efforts were made to find relevant research using Linköping University Library's\footnote{\url{https://liu.se/en/library}} and Google Scholar's\footnote{\url{https://scholar.google.se/}} search engines. Among the keywords used in searching were \emph{verification equipment}, \emph{test equipment}, \emph{automatic test}, \emph{automatic verification}, \emph{iso equipment}, \emph{electrical verification}, \emph{curve fitting}, \emph{double exponential function}, \emph{}, \emph{}
+
+\todo[Skriv färdigt nyckelordsdelen här]
+
+Since the equipment intended for this project was untested before the project start, the first step was to hook it up and make some initial measurements to be able to decide the continuation of the project.
+
+If the equipment seem to be mostly in line with the new standard requirements, the project plan was to go along the following path:
+\begin{enumerate}
+    \item Investigate test architectures suitable for automatic testing and verification.
+    \item Design any utilities needed for the test and verification setup.
+    \item Implement the test architecture and any necessary utilities.
+    \item Measure and evaluate the system and the utilities.
+\end{enumerate}
+
+If the equipment proved to deviate to much from the standard requirement, the project should go along the following path:
+\begin{enumerate}
+    \item Investigate possible causes and fixes for the failure.
+    \item Design any utilities needed for the equipment to pass.
+    \item Implement these utilities.
+    \item Measure and evaluate the system with these utilities manually.
+\end{enumerate}
+
+In either case, the following tasks should be considered if there is time:
+\begin{enumerate}
+    \item Investigate possible methods, or algorithms, that can automatically verify the pulse shapes and parameters.
+    \item Implement a number of these methods.
+    \item Evaluate these methods.
+\end{enumerate}
+
+\section{Initial measurement of the performance of the old equipment}
+To decide the forthcoming of the project, the equipment first had to be checked for it's performance and if it is within the limits for use with the newer standard. Because there is no dummy loads available at this point of the project, only open load measurements could be done.
+
+With exception for Pulse 3a and Pulse 3b, all of these pulses were measured with the use of the high voltage differential probe described in \autoref{sec:hv-diff-probe}. The pulses are measured both directly on each generator connected according to \autoref{fig:manual-measurement-hv-diff} and also through the coupling network CNA~200, as depicted in \autoref{fig:manual-measurement-hv-diff-cna}. 
+\todo[figure of connection]
+Pulse 3a and Pulse 3b was measured using the attenuators described in \autoref{sec:hv-attenuators} connected according to \autoref{fig:manual-measurement-hv-att}. Thanks to the 50-ohm attenuator this pulse could be measured in its matched state. The measurement in open state is a compromise, since there was no such attenuator available, and was made into a 1000-ohm attenuator instead.
+
+\section{Test architecture}
+\squareit{Alternatives and choices. Try finding articles on human error maybe. Make plenty of nice figures.}
+The total number of tests needed to verify the testing equipment before each product test is 14, according to \autoref{tab:verification-list}. There are in total three different values for dummy loads, in practice these will be represented by three different high power dummy loads and two high frequency attenuators for pulse 3a and pulse 3b.
+
+The following test architectures were considered, together with the external supervisor at the company. In the end the 3rd alternative was chosen, as explained in \autoref{result-test-architecture}. To design Alternative 3 some utilities needs to be designed, namely:
+\begin{itemize}
+    \item Relay box, the fixture with embedded attenuators that are to be attached to the front of the CNA.
+    \item Match box, the dummy loads with some relays to be able to switch between them.
+\end{itemize}
+
+Additionally there needs to be some sort of measurement fixture for evaluating the verification equipment.
+
+\subsection{Alternative 1 -- Human assisted}
+The test can be performed semi-automatically by means of the existing equipment complemented by some dummy loads and, in the same manner the manual performance tests were executed. A computer could control the equipment and compare the results, by the assist of a human that can make the necessary reconnections between the tests.
+
+The main advantage of this is that it would probably require the least amount of time for development of the automation software. It also doesn't need any extra hardware except from the dummy loads needed to do the verification.
+
+The biggest disadvantage is that it would be very cumbersome to perform and also very prone to human error. If the verification list is studied carefully one can minimise is to five reconnections after the initial connections are made, for example in the following order: No load, \SI{2}{\ohm}, \SI{10}{\ohm}, \SI{50}{\ohm} low frequency, \SI{50}{\ohm} high frequency, \SI{1}{\kilo\ohm} high frequency.
+
+\subsection{Alternative 2 -- Fully automatic rig external attenuators}
+To accurately measure Pulse 3a and Pulse 3b, the probes should be attached as close as possible to the generator because of the high frequency, to avoid influence of the connecting wires. This could be accomplished by the means of a fixture that is attached directly to the generator, which can switch the pulses to the different loads or to the measurement outputs.
+
+The dummy loads for all pulses, but Pulse 3a and Pulse 3b, will need to be put in a separate enclosure because of the power dissipation needed. The proposed architecture is depicted in \autoref{fig:automatic-rig-1}.
+
+The advantage of this method is that the verification can be performed fully automatically, except for the initial connection of the test rig. This also uses the commercially created attenuators that are already available.
+
+The disadvantage to this setup is that the fixture needs to be designed, making the development costs greater. The fixture that attaches to the generator will expose high voltage on its measurement connectors, making it a safety hazard.
+
+\subsection{Alternative 3 -- Fully automatic rig with embedded attenuators}
+To cope with the high voltage exposure, of alternative 1, the high frequency attenuators can be embedded inside the switching fixture, removing the need for high-voltage connectors. \autoref{fig:automatic-rig-2}.
+
+The advantage of this, on top of the advantages of alternative 2, is that there is no longer need for external attenuators and that the connectors will no longer expose high voltage.
+
+The disadvantage of this would be that the embedded attenuators might prove difficult to design. They need to be accurate up to high frequencies, be tolerable to high voltage, dissipate the power necessary and also be electrically safe.
+
+\section{Design of dummy loads}
+Each dummy load must withstand the applied test pulses, and preferably the worst possible test pulse for the specific dummy load even though it might not be intended. The dummy loads must have a tolerance of \SI{1}{\percent} or less and be non-inductive. \cite{iso-7637-2}
+
+The dummy loads consists of one or more resistors. When determining whether the resistors withstands the test pulses, the parameters of interest are power dissipation, maximum voltage and maximum energy applied over time.
+
+\subsection{Components}
+At first the momentary worst case powers and voltages were calculated by hand, to the values seen in \autoref{tab:dummy_load_worst_case}. But to find components that can handle these momentary powers proved very difficult, and it is not necessary since the pulse power is varying over time and the impulse voltage does not stress the components as much as a constant voltage would do.
+
+One manufacturer of thick film resistors, namely Vishay, specifies its overload capability in a graph with energy over time in the datasheet, which was easier to compare against using LTSpice to simulate the energies for the different loads, according to \autoref{graph:dummy_load_energy}. The simulated value was then divided by the value specified in the datasheet to get the minimum number of resistors required to share the load. Some possible combinations of available resistor values were considered to reach the desired load resistance, before the final configuration were decided according to \autoref{fig:final-dummy-loads}.
+
+\todo[ltspice-bild på de tre olika dummy loadsen]
+
+The voltages used in the calculations are specified in \autoref{tab:dummy_load_worst_case}, they are slightly higher than the specified voltages on the equipment to allow for some margins. The worst case voltage must always be tolerated to prevent arching or serious degrading of the components.
+
+\begin{table}[h]
+\begin{adjustbox}{width=\columnwidth,center}
+    \centering
+    \begin{tabular}{|l|r|r|r|r|r|r|} 
+        \hline
+        Dummy load (\si{\ohm}) & Pulse & $R_S$ (\si{\ohm}) & Generator voltage (\si{\volt}) & Peak voltage (\si{\volt}) & Peak power (\si{\watt}) & Mean power (\si{\watt}) \\
+        \hline
+        2   & Pulse 1 & 2 & 650 & 325 & 45 \si{\kilo} & 5 \\
+        10  & Pulse 1 & 2 & 650 & 600 & 5 \si{\kilo} & 5   \\
+        50  & Pulse 1 & 2 & 650 & 600 & 5 \si{\kilo} & 5   \\
+        50  & Pulse 1 & 2 & 650 & 600 & 5 \si{\kilo} & 5   \\
+        \hline
+    \end{tabular}
+\end{adjustbox}
+    \caption{Calculated momentary worst cases for each dummy load.}
+    \label{tab:dummy_load_worst_case}
+\end{table}
+\todo[Rätta till värdena i tabellen!]
+
+\todo[input worst case table here]
+\begin{table}
+\label{tab:dummy_load_worst_case}
+\end{table}
+
+\todo[input graph of energy]
+
+\subsection{PCB}
+Since the dummy loads consists of many discrete resistors, it was decided to design a PCB to connect them. This also gives good mechanical control of the resistors and the possibility to design for good heat dissipation.
+
+Because of the high voltages present on the board it was decided to keep a minimum of 3mm functional isolation creepage distance between all traces on the board, in line with the EN 60664-1 standard \cite{en-60664-1}. The board was perforated to allow for better air flow past the resistors. The mounting holes for the card was placed in a \SI[product-units=single]{105 x 105}{\milli\meter} square, allowing for a \SI{120}{\milli\meter} fan to be mounted on top of the card using mounting hardware.
+
+A two layer board was chosen, and all of the traces were mirrored on both layers to get as much conductive cross sectional area as possible, and thus lowering the resistance and voltage drop in the traces. The PCB was ordered with \SI{60}{\micro\meter} thick copper layer to further extend the cross sectional areas. The width of the traces for the \SI{2}{\ohm} load was chosen as wide as possible, since the pulse currents are the highest for this one. \todo[kolla så detta är sant]
+
+Both the circuit schematic and layout editing of the board were performed in the free EDA tool KiCad. Before ordering the PCB, it was printed in 1:1 scale and attached to a piece of card board. The card board was then populated with the components already at hand to ensure that the footprints are correct and that the placement of the components makes sense and does not collide.
+
+\todo[Fin bild på designprocess av PCB, säkerhetsavstånd etc]
+
+\subsection{Measurement}
+When the dummy loads had been assembled, their resistances were determined using four wire resistance measurement directly at the PCB's connection points, as seen in \autoref{fig:four-wire-measurement}. With this technique, one can neglect the resistance in the cables used for measuring which can have a significant affect when measuring low resistance loads \cite{book:measurment-techniques}.
+
+
+\section{Design of the switching fixture and embedded attenuators}
+The chosen implementation requires a fixture that switches and attenuators, which purpose is to switch the pulse to the desired attenuator or to the dummy load. It must be able to handle the momentary pulse energies and voltages.
+
+\subsection{Attenuators}
+
+The target attenuation was decided to mimic the commercial attenuators, described in \autoref{theory_pat_attenuators}, where the \SI{50}{\ohm} has an attenuation of \SI{54.7}{\deci\bel} and the \SI{1000}{\ohm} has an attenuation of \SI{60.1}{\deci\bel}.
+
+Only Pulse 3a and Pulse 3b were considered when designing these attenuators, since all other test pulses will be coupled to the separate dummy load.
+
+The two attenuators were implemented as $\Pi$-attenuators. The values for the attenuators were retrieved from an online calculator\footnote{\url{https://chemandy.com/calculators/matching-pi-attenuator-calculator.htm}}, and then they were simulated in LTSpice to verify the values.
+
+By dividing the attenuators into two $\Pi$-networks, the series resistance required will get a bit lower compared to realising them in a single $\Pi$-link. This is desirable because the parasitic capacitance, which is dependant of the resistor package and not the resistance, will influence a high value resistor at lower frequencies that it would on a low value resistor, as explained in \autoref{theory_parasitic_properties}.
+
+A resistor with high pulse power and high voltage properties had to be chosen. Vishay's CRCW-HP series fitted this description and were easily available.
+
+When the ideal resistor values had been derived, the maximum power dissipation and maximum voltage for each resistor was retrieved by simulation. Based on this, the minimum number of discrete resistors needed to withstand the pulse power was calculated. In the same way the minimum number of series resistors to withstand the maximum pulse voltage was calculated. These numbers are presented in \autoref{tab:methods_attenuator_constellations}.
+
+With the minimum number of discrete resistors needed for each ideal resistor known, a constellation of available resistor values was constructed to approximate the nominal value with as few resistors as possible.
+
+The \SI{54.7}{\deci\bel} attenuator was divided into two \SI{27.35}{\deci\bel} $\Pi$ attenuator links. When the closest values for the resistors had been chosen, using \SI{56}{\ohm} as shunt resistors and \SI{56}{\ohm} in series, the final attenuation was \SI{53.66}{\deci\bel} for the two links according to the simulation, seen in \autoref{fig:ltspice-att-ideal-54}. The input and output resistance was 
+
+Nice graphs.
+
+The \SI{60.1}{\deci\bel} attenuator was divided into one \SI{27.35}{\deci\bel} $\Pi$ attenuator links \SI{32.75}{\deci\bel}. When the closest values for the resistors had been chosen, using \SI{56}{\ohm} as shunt resistors and \SI{56}{\ohm} in series, the final attenuation was \SI{53.66}{\deci\bel} for the two links according to the simulation, seen in \autoref{fig:ltspice-att-ideal-54}. The input and output resistance was 
+\autoref{discussion_attenuators}
+
+\subsection{Desired vs implemented (simulation)}
+Parasitic effects. (real life, back to simulation) \todo[kanske borde ligga under results?]
+
+\subsection{PCB}
+\todo[Fin bild på designprocess av PVB, säkerhetsavstånd etc]
+
+\subsection{Measurement}
+
+The stuff and things done when measuring the shitload yo. Also measured at the other point. Using oscilloscope bla. Hah.
+
+\section{Analysis}

+ 115 - 1
rapport/myrefs.bib

@@ -1,5 +1,16 @@
 
-@techreport{iso7637-2,
+@techreport{iso-7637-1,
+    author= {ISO} ,
+    type = {Standard},
+    key = {ISO 7637-1:2015},
+    month = oct,
+    year = {2015},
+    title = {{Road vehicles -- Electrical disturbances from conduction and coupling -- Part 1: Definitions and general considerations}},
+    volume = {2015},
+    institution = {ISO/TC 22/SC 32}
+}
+
+@techreport{iso-7637-2,
     author= {ISO} ,
     type = {Standard},
     key = {ISO 7637-2:2011},
@@ -10,6 +21,50 @@
     institution = {ISO/TC 22/SC 32}
 }
 
+@techreport{iso-7637-3,
+    author= {ISO} ,
+    type = {Standard},
+    key = {ISO 7637-3:2016},
+    month = jul,
+    year = {2016},
+    title = {{Road vehicles -- Electrical disturbances from conduction and coupling -- Part 3: Electrical transient transmission by capacitive and inductive coupling via lines other than supply lines}},
+    volume = {2016},
+    institution = {ISO/TC 22/SC 32}
+}
+
+@techreport{iso-7637-5,
+    author= {ISO} ,
+    type = {Standard},
+    key = {ISO 7637-5:2016},
+    month = nov,
+    year = {2016},
+    title = {{Road vehicles -- Electrical disturbances from conduction and coupling -- Part 5: Enhanced definitions and verification methods for harmonization of pulse generators according to ISO 7637}},
+    volume = {2016},
+    institution = {ISO/TC 22/SC 32}
+}
+
+@techreport{iso-16750-2,
+    author= {ISO} ,
+    type = {Standard},
+    key = {ISO 16750-2:2012},
+    month = nov,
+    year = {2012},
+    title = {{Road vehicles -- Environmental conditions and testing for electrical and electronic equipment -- Part 2: Electrical loads}},
+    volume = {2012},
+    institution = {ISO/TC 22/SC 32}
+}
+
+@techreport{en-60664-1,
+    author= {ISO} ,
+    type = {Standard},
+    key = {EN 16664-1:2007},
+    month = nov,
+    year = {2007},
+    title = {{Insulation coordination for equipment within low-voltage systems - Part 1: Principles, requirements and tests}},
+    volume = {2007},
+    institution = {IEC TC 109}
+}
+
 @Book{measAndInst,
   author = {Alan S. Morris},
   title = {Measurement \& Instrumentation Principles},
@@ -27,7 +82,65 @@
   year = {2013},
 }
 
+@Article{comparison_iso_7637_real_world,
+  author =   {Frazier, R.K. and Alles, S.},
+  title =    {Comparison of ISO 7637 Transient Waveforms to Real World Automotive Transient Phenomena},
+  journal =  {2005 International Symposium on Electromagnetic Compatibility, 2005. EMC 2005.},
+  year =     2005,
+  volume =   3,
+  doi = {10.1109/ISEMC.2005.1513662},
+  pages =    {949--954},
+}
+
+@misc{site:iso_about,
+  title="About us",
+  author="ISO",
+  url="https://www.iso.org/about-us.html",
+  year="jun 18, 2019",
+  publisher="ISO",
+  note = "[Visited 2019-06-18]"
+}
+
+@misc{site:iso_developing_standards,
+  title="Developing standards",
+  author="ISO",
+  url="https://www.iso.org/developing-standards.html",
+  year="jun 18, 2019",
+  publisher="ISO",
+  note = "[Visited 2019-06-18]"
+}
+
+@misc{site:iso_who_develops_standards,
+  title="Who develops standards",
+  author="ISO",
+  url="https://www.iso.org/who-develops-standards.html",
+  year="jun 18, 2019",
+  publisher="ISO",
+  note = "[Visited 2019-06-18]"
+}
+
+@techreport{iso_guidance_review,
+    author= {ISO} ,
+    type = {Guidance},
+    key = {ISO 7637-2:2011},
+    month = mar,
+    year = {2019},
+    title = {Guidance on the Systematic Review processing ISO},
+    volume = {2019},
+    note = "Available at \url{https://www.iso.org/files/live/sites/isoorg/files/store/en/PUB100413.pdf}"
+}
+
 %% Exempelreferenser
+@misc{GPIB,
+  title="GPIB Hardware and Software Specifications ",
+  author="National Instruments",
+  url="http://www.ni.com/white-paper/3388/en/",
+  year="apr 30, 2008",
+  publisher="National Instruments",
+  note = "[Besökt 2019-01-30]"
+}
+
+
 @Article{Duck:2005,
   author =   {Duck, Donald},
   title =    {The History of Automatic Control},
@@ -35,6 +148,7 @@
   year =     2005,
   volume =   106,
   number =   3,
+  doi = {10.1137/0201022},
   pages =    {345--401},
 }
 

+ 2 - 1
rapport/notation.tex

@@ -7,8 +7,9 @@
     $\complexes$ & Mängden av komplexa tal \\
   \end{notationtabular}
 
-  \begin{notationtabular}{Förkortningar}{Förkortning}{Betydelse}
+  \begin{notationtabular}{Abbreviations}{Abbreviation}{Description}
     \abbrARMA\index{ARMA@\abbrARMA!abbreviation} & Auto-regressive moving average \\
     \abbrPID\index{PID@\abbrPID!abbreviation} & Proportional, integral, differential (regulator) \\
+    \abbrDUT\index{DUT@\abbrDUT!abbreviation} & Device Under Test \\
   \end{notationtabular}
 \end{notation}

+ 80 - 41
rapport/results.tex

@@ -1,55 +1,94 @@
-\chapter{Resultat}\label{cha:Research}
-%
-Det här är kapitlet där resultaten presenteras.
+\chapter{Results}\label{cha:results}
 
+\section{Prestudy}
+Since not much was known about the project at this time, it was difficult to find relevant papers on the topic of the standards.  Most of the literature was found during the project as new problems was found along the way.
 
-\section{Ditten}\label{sec:research:history}
-%
-Liksom \citep{Duck:2005} har vi kommit fram till att glass smakar bäst på sommaren.
 
-\marginpar{Kommer att tänka på en liten anekdot\ldots}
+\section{Initial measurement of the performance of the old equipment}
 
-\Warning[TODO]{Ta bort den löjliga anekdoten!}
+As can be seen in \autoref{tab:initial-measurements} and \autoref{tab:initial-measurements-cna}, some values exceeded the limits (marked in red).
 
-När vi nu går in på hur glass smakar vid olika tidpunkter under dagen hänvisar vi till \figureref{fig:times}, och speciellt till \figureref{fig:times:early}.  Jämför sedan med \figureref{fig:times2} för att se hur det kan bli när man äter glass vid okontrollerade tidpunkter.
+\todo[flytta till diskussion?]
+Three of these values even exceeds the old standard's limits, thus indicating that the equipment should probably be usable with the new standard after some service or calibration. With this in mind, the course of the project will be targeted towards the design of an automated verification system, as described in \autoref{sec:planning}. With such a verification equipment at hand, the calibration of the generators might be easier to perform as well.
 
-Veselić, Krešimir (Veseli\'{c}, Kre\v{s}imir) skrev en gång en artikel med titeln \emph{Bounds for exponentially stable semigroups}.
 
-\begin{figure}[tbp]
-  \centering
-  \subfloat[Alldeles för tidigt.][\label{fig:times:very-early}Det här är väl tidigt — din glass hinner smälta innan ditt sällskap dyker upp.]{\includegraphics[page=1]{clocks}}
-  \qquad
-  \subfloat[Med marginal.][\label{fig:times:early}Kiosken stänger snart, men inte nu — perfekt!]{\includegraphics[page=2]{clocks}}
-  \\
-  \subfloat[I grevens tid.][\label{fig:times:on-time}Precis i tid — du får in ett finger i luckan just när kiosken ska stänga.  Han som jobbar blir sur, och det blir smolk i bägaren.]{\includegraphics[page=3]{clocks}}
-  \qquad
-  \subfloat[Försent.][\label{fig:times:late}Du är sen — kiosken är stängd.]{\includegraphics[page=4]{clocks}}
-  \caption{\label{fig:times}%
-    Illustration av \emph{subfloats}.  Den så kallade \emph{bounding box}en visas i \protect\subref{fig:times:late}.  Lägg märke till att bounding boxen har satts så att alla bilder har samma storlek, med enhetlig placering av själva innehållet i förhållande till bounding boxen.  Antag att du ska träffa en kompis för att äta glass just när kiosken stänger för dagen vid 08:30.  När dyker du upp?}
-\end{figure}
+\begin{table}[h]
+\begin{adjustbox}{width=\columnwidth,center}
+    %\centering
+    \begin{tabular}{|l|r|r|r|r|r|r|} 
+        \hline
+         & \multicolumn{3}{c|}{Limits} & \multicolumn{3}{c|}{Measured} \\
+        Pulse & $U_S$ (\si{\volt}) & $t_d$ (\si{\second}) & $t_r$ (\si{\second}) & $U_S$ (\si{\volt}) & $t_d$ (\si{\second}) & $t_r$ (\si{\second}) \\ [0.5ex]
+        \hline
+        Pulse 1, 12 V, Open     & $[ -110, -90 ]$   & $[1.6,2.4]$ \si{\milli}   & $[0.5,1]$ \si{\micro}     & $-99.0$   & $2.10$ \si{\milli}    & $540$ \si{\nano} \\
+        Pulse 1, 24 V, Open     & $[ -660, -540 ]$  & $[0.8,1.2]$ \si{\milli}   & $[1.5,3]$ \si{\micro}     & $-630$    & $1.18$ \si{\milli}    & $2.6$ \si{\micro} \\
+        Pulse 2a, Open          & $[ 67.5, 82.5 ]$  & $[40,60]$ \si{\micro}     & $[0.5,1]$ \si{\micro}     & $76.0$    & $51.0$ \si{\micro}    & $750$ \si{\nano} \\
+        Pulse 3a, Open (1k)     & $[ -220, -180 ]$  & $[105,195]$ \si{\nano}    & $[3.5,6.5]$ \si{\nano}    & $-202$    & $163$ \si{\nano}      & $5.2$ \si{\nano} \\
+        Pulse 3a, Match         & $[ -120, -80 ]$   & $[105,195]$ \si{\nano}    & $[3.5,6.5]$ \si{\nano}    & $-104$    & $134$ \si{\nano}      & $5.0$ \si{\nano} \\
+        Pulse 3b, Open (1k)     & $[ 180, 220 ]$    & $[105,195]$ \si{\nano}    & $[3.5,6.5]$ \si{\nano}    & $202$    & \cellcolor{red!60} $208$ \si{\nano}      & $5.1$ \si{\nano} \\
+        Pulse 3b, Match         & $[ 80, 120 ]$     & $[105,195]$ \si{\nano}    & $[3.5,6.5]$ \si{\nano}    & $102$     & $166$ \si{\nano}      & $5.0$ \si{\nano} \\
+        Load dump A, 12 V, Open & $[ 90, 110 ]$     & $[320,480]$ \si{\milli}   & $[5,10]$ \si{\milli}      & $93.4$    & $390$ \si{\milli}     & $5.8$ \si{\milli} \\
+        Load dump A, 24 V, Open & $[ 180, 220 ]$    & $[280,420]$ \si{\milli}   & $[5,10]$ \si{\milli}      & $190$     & $365$ \si{\milli}     & $5.2$ \si{\milli} \\
+        \hline
+    \end{tabular}
+\end{adjustbox}
+    \caption{The initial manual measurements, measured directly at each generator's output.}
+    \label{tab:initial-measurements}
+\end{table}
 
-\begin{figure}[tbp]
-  \centering
-  \subfloat[][\label{fig:times2:very-early}]{\includegraphics[page=5]{clocks}}
-  \qquad
-  \subfloat[][\label{fig:times2:early}]{\includegraphics[page=6]{clocks}}
-  \\
-  \subfloat[][\label{fig:times2:on-time}]{\includegraphics[page=7]{clocks}}
-  \qquad
-  \subfloat[][\label{fig:times2:late}]{\includegraphics[page=8]{clocks}}
-  \caption{\label{fig:times2}%
-    En andra illustration av \emph{subfloats}.  Den här gången har bounding boxen gjorts så liten som möjligt runt själva innehållet.  Resultatet är stökiga placeringar på sidan.  Samma sak kan hända med vanliga fyrkantiga figurer när man har text som spretar ut åt lite olika håll från själva rutan med kurvor i.}
-\end{figure}
+\begin{table}[h]
+\begin{adjustbox}{width=\columnwidth,center}
+    %\centering
+    \begin{tabular}{|l|r|r|r|r|r|r|} 
+        \hline
+         & \multicolumn{3}{c|}{Limits} & \multicolumn{3}{c|}{Measured} \\
+        Pulse & $U_S$ (\si{\volt}) & $t_d$ (\si{\second}) & $t_r$ (\si{\second}) & $U_S$ (\si{\volt}) & $t_d$ (\si{\second}) & $t_r$ (\si{\second}) \\ [0.5ex]
+        \hline
+        Pulse 1, 12 V, Open     & $[ -110, -90 ]$   & $[1.6,2.4]$ \si{\milli}   & $[0.5,1]$ \si{\micro}     & $-99.2$   & $2.00$ \si{\milli}    & \cellcolor{red!60} $450$ \si{\nano} \\
+        Pulse 1, 24 V, Open     & $[ -660, -540 ]$  & $[0.8,1.2]$ \si{\milli}   & $[1.5,3]$ \si{\micro}     & $-632$    & $1.18$ \si{\milli}    & $2.6$ \si{\micro} \\
+        Pulse 2a, Open          & $[ 67.5, 82.5 ]$  & $[40,60]$ \si{\micro}     & $[0.5,1]$ \si{\micro}     & $76.0$    & $50.0$ \si{\micro}    & $770$ \si{\nano} \\
+        Pulse 3a, Open (1k)     & $[ -220, -180 ]$  & $[105,195]$ \si{\nano}    & $[3.5,6.5]$ \si{\nano}    & $-213$    & $163$ \si{\nano}      & $6.2$ \si{\nano} \\
+        Pulse 3a, Match         & $[ -120, -80 ]$   & $[105,195]$ \si{\nano}    & $[3.5,6.5]$ \si{\nano}    & $-93.2$   & $138$ \si{\nano}      & $6.0$ \si{\nano} \\
+        Pulse 3b, Open (1k)     & $[ 180, 220 ]$    & $[105,195]$ \si{\nano}    & $[3.5,6.5]$ \si{\nano}    & \cellcolor{red!60} $222$     & \cellcolor{red!60} $200$ \si{\nano}      & $6.3$ \si{\nano} \\
+        Pulse 3b, Match         & $[ 80, 120 ]$     & $[105,195]$ \si{\nano}    & $[3.5,6.5]$ \si{\nano}    & $94.0$    & $171$ \si{\nano}      & $5.7$ \si{\nano} \\
+        Load dump A, 12 V, Open & $[ 90, 110 ]$     & $[320,480]$ \si{\milli}   & $[5,10]$ \si{\milli}      & $93.2$    & $394$ \si{\milli}     & $5.8$ \si{\milli} \\
+        Load dump A, 24 V, Open & $[ 180, 220 ]$    & $[280,420]$ \si{\milli}   & $[5,10]$ \si{\milli}      & $186$     & $400$ \si{\milli}     & $5.1$ \si{\milli} \\
+        \hline
+    \end{tabular}
+\end{adjustbox}
+    \caption{The initial manual measurements on the equipment, including the CNA~200.}
+    \label{tab:initial-measurements-cna}
+\end{table}
 
-\section{Framtiden}
+\section{Test architecture}
+\label{result-test-architecture}
+The 3rd alternative was chosen because of the convenience of a fully automatic system and because of the electrical safety that alternative 2 would pose.
 
-Sen när glassen är uppäten är det bara till att sätta igång och skriva på exjobbet igen!
+\section{Design of dummy loads}
 
+\todo[flytta till resultat]
+The values measured are, presented in \autoref{tab:four-wire-result}, are well within the \SI{1}{\percent} specified by the standard \cite{iso-7637-2}.
 
-\begin{chapter-appendix}
+\begin{table}[h]
+%\begin{adjustbox}{width=\columnwidth,center}
+    \centering
+    \begin{tabular}{|l|r|r|} 
+        \hline
+        Dummy load (\si{\ohm}) & Measured $R$ (\si{\ohm}) & Tolerance (\si{\percent}) \\
+        \hline
+        2   & $2.004$   & 0.2   \\
+        10  & $9.973$   & 0.27  \\
+        50  & $49.954$  & 0.09  \\
+        \hline
+    \end{tabular}
+%\end{adjustbox}
+    \caption{The measured resistance of the dummy loads.}
+    \label{tab:four-wire-result}
+\end{table}
 
-\section{Ett par långa bevis}
-%
-Det här är en appendix-del av det aktuella kapitlet.
+\section{Design of the switching fixture}
 
-\end{chapter-appendix}
+
+\section{Measurement}
+
+\section{Analysis}

+ 327 - 12
rapport/theory.tex

@@ -1,10 +1,296 @@
 \chapter{Theory}\label{cha:theory}
 
-This chapter contains all the necessary theory.
+This chapter introduces the theory and facts that are related to this project. It describes the necessary parts of the ISO standards, measurement theory and analysis of acquired data.
+
+\section{Previous research}
+No previous research relevant to the reuse of test equipment was found. Though there is research available on smaller specific topics that are covered by this project, such as measurement techniques and curve fitting. Such findings are used in this theory chapter. 
+
+\section{ISO standards}
+The ISO organisation, International Organization for Standardization, was founded in 1947 and has since published more than 22500 International Standards. ISO standards does not only cover the electronic industry, but almost every industry. The purpose of the standards is to ensure safety, reliability and quality of products in a unified way, making international trade easier. The name ISO comes from the Greek word \emph{isos}, which means \emph{equal}.
+\cite{site:iso_about}
+
+The standards are developed and maintained by Technical Committees consisting of, amongst others, experts in the area that the standard  \cite{site:iso_who_develops_standards}. A new standard is only developed when there exists a need for this from the industry or other groups that may require it \cite{site:iso_developing_standards}. Existing standards are automatically scheduled for review five years after its last publication, but can manually be reviewed before that time by the committee \cite{iso_guidance_review}. During the review process, it will be decided if the standard is still valid, need to be updated or if it should be removed \cite{iso_guidance_review}.
+
+
+The naming convention used for ISO standards is of the form \emph{number-part:year}, where the \emph{number} is the identifier to the unique ISO standard, \emph{part} denotes the part of the standard if it is divided into several parts and \emph{year} is the publishing year. For example, the name \emph{ISO~7637-2:2011} refers to part 2 of the ISO~7637 standard published in 2011, whilst \emph{ISO~7637-2:2004} would refer to an earlier version of the exact same document published in 2004.
+
+To get hold of a copy of a standard, one need to buy it from ISO or one of its retailers. \cite{iso-shopping-faqs}
+%https://www.iso.org/shopping-faqs.html besökt 2019-06-19
+
+\section{ISO~7637 and ISO~16750}
+
+\todo[fundera på uppdelningen av stycken och underrubriker här, och allmän formattering]
+\textbf{The ISO~7637 standard}, \emph{Road vehicles — Electrical disturbances from
+conduction and coupling}, concerns the electrical environment in road vehicles. The standard consists of, at the time of writing, four parts.
+
+Part 1, \emph{Definitions and general considerations}, defines some abbreviations and technical terms that are used throughout the standard. It also describes the scope of where the standard is intended to be applied. \cite{iso-7637-1}
+
+Part 2, \emph{Electrical transient conduction along supply lines only}, defines the test procedures related to disturbances that are carried along the supply lines of a product. Both emission, disturbances created by the DUT, and immunity, the DUT's capability to withstand disturbances, are covered. This part defines the test pulses, and the verification of the same, that are of interest to this project. \cite{iso-7637-2}
+
+Part 3, \emph{Electrical transient transmission by capacitive and inductive coupling via lines other than supply lines}, defines immunity tests against disturbances on other interfaces that the power supply. It focuses on test setups and different ways of coupling the signals. \cite{iso-7637-3}
+
+Part 5, \emph{Enhanced definitions and verification methods for harmonization of pulse generators according to ISO~7637}, proposes an alternative verification method of the test pulses defined in ISO~7637-2. The main difference from the method described in ISO~7637-2 is that $U_A$ should not only be 0~V during the verification, but also be set to $U_N$. This will not be considered deeply in this report, since it is only a proposal and makes the verification equipment more difficult. \cite{iso-7637-5}
+
+The ISO~16750, \emph{Road vehicles -- Environmental conditions and testing for electrical and electronic equipment}, concerns different environmental factors that a product might face in a vehicle, such as mechanical shocks, temperature changes and acids. Part 2, \emph{Electrical Loads}, of the standard deals with some electrical aspects that was previously part of the ISO~7637 standard. This is the only part of ISO~16750 that will be considered.
+\cite{iso-16750-1, iso-16750-2}
 
 \section{Test pulses}
 
+All test pulses defined in ISO~7637 and ISO~16750 are supposed to simulate events that can occur in a real vehicle's electrical environment, that products must be able to withstand. The properties of these test pulses are well defined, to allow for unified testing regardless of which test lab that performs the test. In the real world, however, the disturbances might of course differ from the test pulses since a real case environment is not controlled. \cite{iso-7637-2,iso-16750-2, comparison_iso_7637_real_world}
+
+The test pulses of interest defined in ISO~7637 are denoted \emph{Test pulse 1}, \emph{Test pulse 2a}, \emph{Test pulse 3a} and \emph{Test pulse 3b}. The test pulse of interest defined in ISO~16750 is denoted \emph{Load dump Test A}. There are more pulses and tests defined in these standards, but those are not in the scope of this thesis.
+
+The general characteristics in common for all pulses are the surge voltage $U_s$, the rise time $t_r$, the pulse duration $t_d$ and the internal resistance $R_i$. For pulses that are supposed to be applied several times, $t_1$ usually denotes the time between two consecutive pulses.
+
+An important note to make is that the definition of the surge voltage, $U_s$, differs in ISO~7637 and ISO~16750 as seen in \autoref{fig:us_difference}.
+
+\todo[Bild med kurvornas parametrar, båda ISO standardernas definitioner]
+
+\subsection{Test pulse 1}
+This pulse simulates the event of the power supply being disconnected to open, while the DUT is connected to other inductive loads. The other inductive loads will generate a voltage transient of reversed polarity, trying to maintain the current that was previously flowing through it.
+
+In the standard there are two additional timing associated to this pulse, $t_2$ and $t_3$, which are defining the disconnection time for the power supply during the voltage transient. In practice $t_3$ can be very short, specified to less than 100 µs, and the step seen in \autoref{fig:pulse1} might be to short to be clearly distinguishable.
+
+\todo[Två bilder, en på kurvan och en på kretsen som orsakar den. En tabell med parametervärden.]
+
+\subsection{Test pulse 2a}
+This pulse simulates the event of a load, parallel to the DUT, is disconnected. The inductance in the wiring harness will then generate a positive voltage transient trying to maintain the current that was previously flowing through it.
+
+\todo[Två bilder, en på kurvan och en på kretsen som orsakar den. En tabell med parametervärden.]
+
+\subsection{Test pulse 3a and 3b}
+Test pulse 3a and 3b simulates switching activity of devices in the system, causing either negative or positive voltage transients. These transients are very short, compared to the other pulses, and the repetition time is very high frequent. The pulses are sent in bursts, grouping a number of pulses together and separating groups by a fixed time.
+
+These pulses contain high frequency components, up to 100~MHz, and special care must be taken when running tests with them as well as when verifying them.
+
+\todo[Fyra bilder, två på kurvorna, en på burst och en på kretsen som orsakar den? En tabell med parametervärden.]
+
+\subsection{Load dump Test A}
+The Load dump Test A simulates the event of disconnecting a battery that is charged by the vehicles alternator, the current that the alternator is driving will give rise to a long voltage transient.
+
+This pulse has the longest duration, $t_d$, of all the test pulses. It also has the lowest internal resistance. These properties makes it capable of transferring high energies into a low impedance DUT.
+
+Prior to 2011, the Load dump Test A was part of the ISO~7637-2 standard under the name \emph{Test pulse 5a}. The voltages specified for $U_s$ was in the older standard, ISO~7637-2:2004, defined relative to the DC offset voltage $U_A$. In the newer standard ,ISO~16750-2:2012, $U_s$ is defined as the absolute peak voltage including $U_A$.
+
+\todo[Två bilder, en på kurvan och en på kretsen som orsakar den. En tabell med parametervärden.]
+
+\subsection{Test setup}
+During a test, the nominal voltage is first applied between the plus and minus terminal of the DUT's power supply input, then a series of test pulses are applied between the same terminals. The pulses are repeated at specified intervals, $t_1$, as depicted in \autoref{fig:doubleexprep}.
+\todo[Snygg bild på uppkoppling och kopplingsnätverk.].
+
+\subsection{Mathematical description}
+All of the test pulses applied to the vehicle equipment can individually be described mathematically by variations of the double exponential function shown in \autoref{eq:doubleexp} and \autoref{fig:doubleexp}. The properties of interest, the ones which are specified in the standards, are the surge voltage $ U_s $, the rise time $ t_r $, the duration $ t_d $ and the repetition time $ t_1 $. \cite{iso-7637-2}
+
+How $k$, $\alpha$ and $beta$ are related to these properties will be described in more detail in \autoref{sec:double_exponential_function}.
+
+\todo[Tryck ihop bilderna och gör dem lite mindre]
+
+\begin{equation}
+    u(t)=k(e^{\alpha t} - e^{\beta t}) + U_{A}
+    \label{eq:doubleexp}
+\end{equation}
+
+\begin{figure}
+    \includegraphics[width=\textwidth]{doubleexpfunc}
+    \caption{The rise time is defined as the time elapsed from 0.1 to 0.9 times the maximum voltage on the rising edge of the function. The duration is defined as the time from 0.1 times the maximum voltage on the rising edge, back to the same level of the falling edge.}
+    \label{fig:doubleexp}
+\end{figure}
+
+\begin{figure}
+    \includegraphics[width=\textwidth]{doubleexpfuncrep}    
+    \caption{The repetition time is defined as the time between two adjacent rising edges, measured at 0.1 times the maximum pulse voltage.}
+    \label{fig:doubleexprep}
+\end{figure}
+
+\subsection{Verification}
+The test pulses are to be verified before they are applied to the DUT. The voltage levels and the timings are to be measured, with and without a matched load attached $R_L$ = $R_i$. The standard omits the rise time constraint when the load is attached, except for pulse 3a and 3b. \cite{iso-7637-2}
+
+The verification is to be conducted with $U_A$ set to 0. There is, however, a proposal to set $U_A$ to the actual nominal voltage during the verification process, as the behaviour of the pulse generators has proven differ in this case \cite{iso-7637-5}. In this project $U_A = 0$ will be used.
+
+The limits, and tolerances, for the pulses are summarised in \autoref{tab:verification-list}. The matched loads are to be within 1\% of the nominal value. \cite{iso-7637-2}
+
+\begin{table}[h]
+\begin{adjustbox}{width=\columnwidth,center}
+    %\centering
+    \begin{tabular}{|l|r|r|r|r|} 
+        \hline
+         & & \multicolumn{3}{c|}{Limits}\\
+        Pulse & Match resistor (\si{\ohm}) & $U_S$ (\si{\volt}) & $t_d$ (\si{\second}) & $t_r$ (\si{\second}) \\
+        \hline
+        Pulse 1, 12 V, Open         &    & $[ -110, -90 ]$   & $[1.6,2.4]$ \si{\milli}   & $[0.5,1]$ \si{\micro}     \\
+        Pulse 1, 12 V, Matched      & 10 & $[ -110, -90 ]$   & $[1.6,2.4]$ \si{\milli}   & $[0.5,1]$ \si{\micro}     \\
+        Pulse 1, 24 V, Open         &    & $[ -660, -540 ]$  & $[0.8,1.2]$ \si{\milli}   & $[1.5,3]$ \si{\micro}     \\
+        Pulse 1, 24 V, Matched      & 50 & $[ -660, -540 ]$  & $[0.8,1.2]$ \si{\milli}   & $[1.5,3]$ \si{\micro}     \\
+        Pulse 2a, Open              &    & $[ 67.5, 82.5 ]$  & $[40,60]$ \si{\micro}     & $[0.5,1]$ \si{\micro}     \\
+        Pulse 2a, Matched           &  2 & $[ 67.5, 82.5 ]$  & $[40,60]$ \si{\micro}     & $[0.5,1]$ \si{\micro}     \\
+        Pulse 3a, Open (1k)         &    & $[ -220, -180 ]$  & $[105,195]$ \si{\nano}    & $[3.5,6.5]$ \si{\nano}    \\
+        Pulse 3a, Match             & 50 & $[ -120, -80 ]$   & $[105,195]$ \si{\nano}    & $[3.5,6.5]$ \si{\nano}    \\
+        Pulse 3b, Open (1k)         &    & $[ 180, 220 ]$    & $[105,195]$ \si{\nano}    & $[3.5,6.5]$ \si{\nano}    \\
+        Pulse 3b, Match             & 50 & $[ 80, 120 ]$     & $[105,195]$ \si{\nano}    & $[3.5,6.5]$ \si{\nano}    \\
+        Load dump A, 12 V, Open     &    & $[ 90, 110 ]$     & $[320,480]$ \si{\milli}   & $[5,10]$ \si{\milli}      \\
+        Load dump A, 12 V, Matched  &  2 & $[ 90, 110 ]$     & $[320,480]$ \si{\milli}   & $[5,10]$ \si{\milli}      \\
+        Load dump A, 24 V, Open     &    & $[ 180, 220 ]$    & $[280,420]$ \si{\milli}   & $[5,10]$ \si{\milli}      \\
+        Load dump A, 24 V, Matched  &  2 & $[ 180, 220 ]$    & $[280,420]$ \si{\milli}   & $[5,10]$ \si{\milli}      \\
+        \hline
+    \end{tabular}
+\end{adjustbox}
+    \caption{These are all of the verifications that needs to be made before each use of the equipment, along with the limits for each case.}
+    \label{tab:verification-list}
+\end{table}
+
+\section{Differences from ISO 7637:2004 to ISO 7637:2011 and ISO 16750:2012}
+Since the equipment used the project is designed for the older version of the standard, ISO~7637-2:2004 and possibly even ISO~7637-1:1990 together with ISO~7637-2:1990, the differences of importance between these will be presented in this chapter to see what parameters might be a problem for the older equipment to fulfil.
+
+One of the most notable differences is the removal of a test pulse from ISO~7637-2 that was called \emph{Pulse 5a} and \emph{Pulse 5b}, this was instead introduced to the ISO~16750-2 under the name \emph{Load dump A} and \emph{Load dump B}.
+
+\subsection{Definitions}
+Since there are now two different standards, ISO~7637 and ISO~16750, that are describing the pulses some differences in definitions have been introduced.
+
+\todo[Snygga till presentationen av definitionerna]
+
+\bm{$U_S$}
+
+For pulse 1, 2a, 3a and 3b: $U_{TOP} - U_N$
+
+For Load dump A: $U_{TOP}$
+
+
+\bm{$U_A$}
+
+For pulse 1, 2a, 3a and 3b: $13.5 \pm 0.5$ V, $27 \pm 1$ V \cite{iso-7637-}
+
+For Load dump A: $14 \pm 0.2$ V, $28 \pm 0.2$ V \cite{iso-16750-1}
+
+
+\subsection{Tolerances}
+Some of the allowed ranges on the pulses parameters has changed compared to the older version of the standard.
+
+\todo[Gör snygga tabeller]
+
+\textbf{Pulse 1}
+Old, 12V: $U_S -75 -- -100$ V
+Old, 24V: $U_S -450 -- -600$ V
+
+New, 12V: $U_S -75 -- -150$ V
+New, 24V: $U_S -300 -- -600$ V
+
+\textbf{Pulse 2a}
+Old: $U_S 37 -- 50$ V
+
+New: $U_S 37 -- 112$ V
+
+\textbf{Pulse 3a and Pulse 3b}
+Old, 12V: $\lvert U_S \rvert 112 -- 150$ V
+Old, 24V: $\lvert U_S \rvert 150 -- 200$ V
+
+New, 12V: $\lvert U_S \rvert 112 -- 220$ V
+New, 24V: $\lvert U_S \rvert 150 -- 300$ V
+
+Old: $t_r 100 -- 200$ µs
+
+New: $t_r 105 -- 195$ µs
+
+\textbf{Load dump A}
+No change, other that the definitions.
+
+\subsection{Tolerances for verification}
+\textbf{Pulse 1}
+
+Old, 24V, matched: $U_S -300 \pm 30$ V
+
+New, 24V, matched: $U_S -300 \pm 60$ V
+
+\textbf{Pulse 2a}
+
+Old, open: $U_S 50 \pm 5$ V, matched  $U_S 25 \pm 5$ V
+
+New, open: $U_S 75 \pm 7.5$ V, matched  $U_S 35.5 \pm 7.5$ V
+
+\textbf{Pulse 3a and Pulse 3b}
+
+No change.
+
+\textbf{Load dump A}
+No change, but according to print (or thought) error:
+
+Old, 12 V, open: $U_S 100 \pm 10$ V, matched  $U_S 50 \pm 10$ V
+
+New, 12 V, open: $U_S 87 \pm 10$ V, matched  $U_S 37 \pm 10$ V \textbf{NOTE, this can't be true}
+
+Old, 12 V, open: $U_S 200 \pm 20$ V, matched  $U_S 100 \pm 10$ V
+
+New, 12 V, open: $U_S 172 \pm 20$ V, matched  $U_S 72 \pm 20$ V \textbf{NOTE, this can't be true}
+
+\section{Resistors at high frequencies}
+\label{theory_parasitic_properties}
+\url{https://www.edn.com/design/components-and-packaging/4423492/Resistors-aren-t-resistors}
+
+\url{https://www.vishay.com/docs/60107/freqresp.pdf}
+
 \section{Measurement}
+There are several measurement methods needed during the project. To verify the test pulses, voltage has to be measured over time. To verify the dummy loads, resistance has to be measured. To verify the attenuators, the magnitude response has to be measured. This chapter describes the necessary measurement theory required for this project.
+
+\subsection{Resistance}
+The circuit designers companion p.99
+
+
+
+\subsection{High Voltage}
+The highest voltage that can be generated by the pulse generators is 1500~V, which is higher than any of the standards require but will serve as the design goal for the verification equipment. This is a higher voltage than most acquisition devices can measure without the use of external attenuators \cite{source}.
+
+Resistive attenuators.. \todo[fyll på]
+
+\subsection{Bandwidth and rise time}
+The shortest rise time is xxx ns, which can roughly be compared to yyy MHz. \cite{source}
+
+The relationship and requirements, addition of rise time limitations etc
+Combined rise time \cite{source den där boken}.
+
+high speed digital design 83
+
+\subsection{Oscilloscope and probes}
+An oscilloscope measures voltage over time, using voltage probes. 
+
+The oscilloscope has properties bandwidth...
+
+The probe also has properties..
+
+Commercial probes are expensive
+
+\subsection{Measurement errors}
+Put good theory here
+
+\subsection{RF Attenuators}
+Linearity, tolerances, power, combinations of resistors, impedances
+
+\subsection{Tolerances and maximum ratings}
+Resistors, Power, Voltages, surges,
+Relays, isolation, dielectric strength
+
+\section{Analysis}
+The data points from the measurement must be processed and evaluated to determine if the measured pulse is within the specified limits. There are several techniques to accomplish this, which have different advantages.\cite{source}
+
+\subsection{Goodness??}
+\label{sec:goodness}
+\todo[Någonting om vad som anses bra]
+
+\subsection{Curve fitting?}
+\todo[Läs på om ämnet och se ifall det kan vara rimligt]
+
+\subsection{Max/min limits?}
+\todo[Användandet av max/min-fönster]
+
+\subsection{Parameter extraction?}
+\todo[Detta är nog ett påhittat ord, kanske menar jag curve fitting?]
+
+\subsection{Evaluation/simulation/robustness}
+\todo[Jämför och evaluera de två eller tre metoderna med hänseende till vad som står i ``goodness'']
+
+----
+
+\squareit{
+Essentially an embedded high voltage probe.
+
 Bra böcker
 
 High frequency content
@@ -17,7 +303,6 @@ Chapter 15 - Basic Measuring Techniques
 Handbook of Measuring System Design, Peter H Sydenham and Richard Thorn
 
 
-
 \textbf{Artiklar om högspänningsmätning}
 
 High Voltage Measurements Using Slab Coupled 
@@ -42,26 +327,56 @@ Measurement
 Fei Long Jianhuan  Zhang   Chunrong  Xie      Zhiwei  Yuan    
 Mechanical Electrical Engineering Department, Xiamen University, Xiamen, 361005 China
 
+% konstruktion: https://www.venkel.com/media/wysiwyg/technical/docs/technical-papers/the_definitive_guide_to_smt_resistor_selection.pdf
 
-\textbf{Artiklar om }
 
+\textbf{Curve fitting och Double exponential pulse function}
 
+Shape Properties of Pulses Described by Double Exponential Function and Its Modified Forms
 
-----
+On the  Design  and  Generation of the Double  Exponential Function S. C. Dutta  Roy and D. K. Bhargava 
+}
 
+\section{Instrumentation and control}
+The following chapter describes the different instruments that were used, and their control interfaces.
 
+\subsection{GPIB}
+IEEE-488, or GPIB which it is often called, is a parallel bus interface. It is mainly used to interconnect lab instrumentation such as multimeters, signal generators and spectrum analyzers. 
+\todo[fyll på och hitta källor, lägg in bild på interface]
 
+\subsection{Tektronix TDS7104 Oscilloscope}
+The oscilloscope that is available is a Tektronix TDS7104, with specifications as seen in \autoref{tab:tds7104}. It has GPIB interface and TekVISA GPIB, an API for sending GPIB commands over ethernet, available for remote control. 
 
-\section{High Voltage}
+\todo[Lägg in bild på utrustning, och tabell med data]
 
-\section{RF Attenuators}
-Linearity, tolerances, power, combinations of resistors, impedances
+\subsection{EM Test MPG 200 Micropulse generator}
+The MPG~200 is used to generate \emph{Test pulse 1} and \emph{2a}. MPG is an abbreviation for \emph{MicroPulse Generator}. The instrument is designed to generate test pulses according to the older ISO~7637-2:1990 version, but the parameters can be adjusted to comply with the new ISO~7637:1990 standard.
 
-\section{Maximum ratings}
-Resistors, Power, Voltages, surges
+\todo[Lägg in bild på utrustning, och tabell med data]
+
+\subsection{EM Test EFT 200 Burst generator}
+The EFT~200 is used to generate \emph{Test pulse 3a} and \emph{3b}. EFT is an abbreviation for \emph{Electrical Fast Transient}. The instrument is designed to generate test pulses according to the older ISO~7637-2:1990 version, but the parameters can be adjusted to comply with the new ISO~7637:1990 standard.
+
+\todo[Lägg in bild på utrustning, och tabell med data]
+
+\subsection{EM Test LD 200 Load dump}
+The LD~200 is used to generate \emph{Load dump Test A}. LD is an abbreviation for \emph{Load Dump}. The instrument is designed to generate test pulses according to the older ISO~7637-2:1990 version, but the parameters can be adjusted to comply with the new ISO~16750:2012 standard.
+
+\todo[Lägg in bild på utrustning, och tabell med data]
+
+
+\subsection{EM Test CNA 200 Coupling Network}
+The SNA~200 is a coupling network, used to multiplex the pulse generators into one box. It contains several relays to select the appropriate generator output. The SNA~200 has one interface for each pulse generator, but no interface for a computer. It is automatically controlled by the pulse generators.
+
+\todo[Lägg in bild på utrustning, och tabell med data]
+
+\subsection{Rohde \& Schwarz ZVL13}
+The ZVL13 is a vector network analyzer. It is, in this project, used to measure the magnitude and phase response between its two ports.
+
+\todo[Lägg in bild på utrustning, och tabell med data]
+
+\subsection{PAT 50 and PAT 1000}
+\label{theory_pat_attenuators}
 
-Relays, isolation, dielectric strength
 
-\section{GPIB}
-Paralell bla bla.\todo[Lägg till stuff]