Compare commits

...

3 Commits

Author SHA1 Message Date
Peter Babič 52b4d40229 add preparation 4 years ago
Peter Babič 6ca59f2221 add system guide 4 years ago
Peter Babič 02ccf10a82 add accompanying paper 4 years ago
  1. 1
      .gitattributes
  2. BIN
      paper/SSIEE-template.doc
  3. BIN
      paper/babic_peter_bc_paper.doc
  4. BIN
      preparation/Communication_PC.avi
  5. BIN
      preparation/Communication_PC_1024.avi
  6. BIN
      preparation/Device.avi
  7. BIN
      preparation/Device_1024.avi
  8. 8
      preparation/INSTRUKCIE.txt
  9. BIN
      preparation/Ovladac inf - keby nieco.zip
  10. BIN
      preparation/Ovladac.exe
  11. BIN
      preparation/Presentation.odp
  12. BIN
      preparation/Presentation.pdf
  13. BIN
      preparation/babic.zip
  14. BIN
      preparation/putty.exe
  15. 26
      system_guide/BOM.csv
  16. 921
      system_guide/analytical.lyx
  17. 124
      system_guide/analytical.tex
  18. 7
      system_guide/appendices.tex
  19. 486
      system_guide/appendixc.lyx
  20. 31
      system_guide/appendixc.tex
  21. 29
      system_guide/bibliography.bib
  22. 11
      system_guide/conclusion.tex
  23. BIN
      system_guide/figures/activity_rfid_uml.jpg
  24. BIN
      system_guide/figures/usecase_rfid_uml.jpg
  25. 35
      system_guide/introduction.tex
  26. 358
      system_guide/mainpart.tex
  27. 802
      system_guide/natbib.sty
  28. 134
      system_guide/nicefrac.sty
  29. 177
      system_guide/nomencl.sty
  30. 12
      system_guide/notes
  31. 157
      system_guide/problemexpres.tex
  32. 1090
      system_guide/tukethesis.cls
  33. 0
      system_guide/tukethesis.lyx
  34. BIN
      system_guide/tukethesis.pdf
  35. 229
      system_guide/tukethesis.tex

1
.gitattributes vendored

@ -2,3 +2,4 @@
*.jpg filter=lfs diff=lfs merge=lfs -text
*.odg filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.doc filter=lfs diff=lfs merge=lfs -text

BIN
paper/SSIEE-template.doc (Stored with Git LFS)

Binary file not shown.

BIN
paper/babic_peter_bc_paper.doc (Stored with Git LFS)

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -0,0 +1,8 @@
1. rozbal vsetky subory do potrebneho priecinka
2. nainstaluj ovladac, exe verim ze bude fungovat, je tam aj inf ale s tym ta nenutim sa bavit, len ak by si velmi chcel
3. skontroluj ci ide spustit putty.exe
4. pozri ci prezentaciu ide citat v open office, ak nepojde tak v PDF
5. pozri ci ide pozerat videa, dal som tam aj s rozmerom _1024 ako odporucali, ale skus najskor tie s normalnou velkostou
6. zapis co slo a co nie
DAKUJEM!!!!

Binary file not shown.

Binary file not shown.

BIN
preparation/Presentation.pdf (Stored with Git LFS)

Binary file not shown.

Binary file not shown.

Binary file not shown.

@ -0,0 +1,26 @@
# RefDes Value Pattern Quantity
1 B1 CR1220 1
2 C1 - C8, C12, C14 0.1uF CAP_0805 10
3 C9 4.7uF CAP_0805 1
4 C10, C11 10uF TC_0805 2
5 C13 10uF CAP_0805 1
6 C15, C16 47pF CAP_0805 2
7 D1 1N4148 CAP_0805 1
8 D2 BAT42 MINIMELF 1
9 J1 – J6 connectors 1
15 LS1 Piezo 1
16 Q1 AP2309GN SOT23 1
17 Q2 BC807 SOT23 1
18 R1, R2, R3, R5, R6, R7 22k RES_0805 6
19 R4, R11, R12, R15, R16 10k RES_0805 5
20 R8 100R RES_0805 1
21 R9 470k RES_0805 1
22 R10 100k RES_0805 1
23 R13, R14 27R RES_0805 2
24 U1 ATmega328 QFP-32/9x9x0.8 1
25 U2 DS1302Z SOIC-8/150mil 1
26 U3 LTC4412ES6 SOT23-6 1
27 U4 FT321X QSOP-20 1
28 U5 LP2985-33 SOT23-5 1
29 Y1 16.0 CSTCE16M0V53-R0 1
30 Y2 0.032768 1
unable to load file from base commit

@ -0,0 +1,921 @@
#LyX file created by tex2lyx 2.0.3
\lyxformat 413
\begin_document
\begin_header
\textclass article
\use_default_options false
\language english
\language_package none
\inputencoding auto
\fontencoding default
\font_roman default
\font_sans default
\font_typewriter default
\font_default_family default
\font_sc false
\font_osf false
\font_sf_scale 100
\font_tt_scale 100
\graphics default
\paperfontsize default
\spacing single
\use_hyperref 0
\papersize default
\use_geometry false
\use_amsmath 1
\use_esint 1
\use_mhchem 0
\use_mathdots 0
\cite_engine basic
\use_bibtopic false
\use_indices false
\paperorientation portrait
\suppress_date false
\use_refstyle 0
\secnumdepth 3
\tocdepth 3
\paragraph_separation indent
\paragraph_indentation default
\quotes_language english
\papercolumns 1
\papersides 1
\paperpagestyle default
\tracking_changes false
\output_changes false
\html_math_output 0
\html_css_as_file 0
\html_be_strict false
\end_header
\begin_body
\begin_layout Section
Analytical considerations
\end_layout
\begin_layout Standard
Text záverečnej práce obsahuje kapitolu, v
\begin_inset space ~
\end_inset
rámci ktorej autor uvedie analýzu riešených problémov. Táto kapitola môže byť v
\begin_inset space ~
\end_inset
prípade potreby delená do viacerých podkapitol. Autor v
\begin_inset space ~
\end_inset
texte záverečnej práce môže zvýrazniť kľúčové slová, pričom sa použije príslušný štýl pre kľúčové slová -- napr. toto je kľúčové slovo. V
\begin_inset space ~
\end_inset
texte môžu byť použité obrázky a
\begin_inset space ~
\end_inset
tabuľky podľa nasledujúcich príkladov:
\end_layout
\begin_layout Standard
\begin_inset Float figure
placement !ht
wide false
sideways false
status open
\begin_layout Standard
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
centering
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
unitlength
\end_layout
\end_inset
=1mm
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
begin{picture}
\end_layout
\end_inset
(30,30)(0,0)
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
put
\end_layout
\end_inset
(0,0)
\begin_inset ERT
status collapsed
\begin_layout Standard
{
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
line
\end_layout
\end_inset
(1,0)
\begin_inset ERT
status collapsed
\begin_layout Standard
{
\end_layout
\end_inset
30
\begin_inset ERT
status collapsed
\begin_layout Standard
}
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
}
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
put
\end_layout
\end_inset
(0,0)
\begin_inset ERT
status collapsed
\begin_layout Standard
{
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
line
\end_layout
\end_inset
(0,1)
\begin_inset ERT
status collapsed
\begin_layout Standard
{
\end_layout
\end_inset
30
\begin_inset ERT
status collapsed
\begin_layout Standard
}
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
}
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
put
\end_layout
\end_inset
(30,0)
\begin_inset ERT
status collapsed
\begin_layout Standard
{
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
line
\end_layout
\end_inset
(0,1)
\begin_inset ERT
status collapsed
\begin_layout Standard
{
\end_layout
\end_inset
30
\begin_inset ERT
status collapsed
\begin_layout Standard
}
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
}
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
put
\end_layout
\end_inset
(0,30)
\begin_inset ERT
status collapsed
\begin_layout Standard
{
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
line
\end_layout
\end_inset
(1,0)
\begin_inset ERT
status collapsed
\begin_layout Standard
{
\end_layout
\end_inset
30
\begin_inset ERT
status collapsed
\begin_layout Standard
}
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
}
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
end{picture}
\end_layout
\end_inset
\begin_inset Caption
\begin_layout Standard
Toto je Å¡tvorec
\end_layout
\end_inset
\end_layout
\begin_layout Standard
\begin_inset CommandInset label
LatexCommand label
name "o:1"
\end_inset
\end_layout
\end_inset
\end_layout
\begin_layout Standard
Obrázok by mal byť podľa možnosti centrovaný. Pri jeho opisovaní v
\begin_inset space ~
\end_inset
texte treba použiť odkazy na obrázok v
\begin_inset space ~
\end_inset
tvare Obrázok
\begin_inset space ~
\end_inset
\begin_inset CommandInset ref
LatexCommand ref
reference "o:1"
\end_inset
.
\end_layout
\begin_layout Standard
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
tabcolsep
\end_layout
\end_inset
=8pt
\begin_inset Float table
placement !ht
wide false
sideways false
status open
\begin_layout Standard
\begin_inset Caption
\begin_layout Standard
Prehľad jednotiek
\end_layout
\end_inset
\end_layout
\begin_layout Standard
\begin_inset CommandInset label
LatexCommand label
name "t:1"
\end_inset
\begin_inset VSpace smallskip
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
centering
\end_layout
\end_inset
\begin_inset Tabular
<lyxtabular version="3" rows="2" columns="2">
<features tabularvalignment="middle" tabularwidth="0pt">
<column alignment="left" valignment="top">
<column alignment="center" valignment="top">
<row>
<cell alignment="left" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
\begin_inset Text
\begin_layout Standard
Názov
\end_layout
\end_inset
</cell>
<cell alignment="center" valignment="top" topline="true" rightline="true" usebox="none">
\begin_inset Text
\begin_layout Standard
(
\begin_inset space \thinspace{}
\end_inset
Jednotka v
\begin_inset space ~
\end_inset
sústave SI)
\end_layout
\end_inset
</cell>
</row>
<row>
<cell alignment="left" valignment="top" topline="true" bottomline="true" leftline="true" rightline="true" usebox="none">
\begin_inset Text
\begin_layout Standard
Napätie
\end_layout
\end_inset
</cell>
<cell alignment="center" valignment="top" topline="true" bottomline="true" rightline="true" usebox="none">
\begin_inset Text
\begin_layout Standard
\begin_inset Formula $\upmu$
\end_inset
V
\end_layout
\end_inset
</cell>
</row>
</lyxtabular>
\end_inset
\end_layout
\end_inset
\end_layout
\begin_layout Standard
\begin_inset CommandInset nomenclature
LatexCommand nomenclature
symbol "$upmu$"
description "mikro, $10^{-6}$"
\end_inset
\begin_inset CommandInset nomenclature
LatexCommand nomenclature
symbol "SI"
description "Syst̀eme International"
\end_inset
\begin_inset CommandInset nomenclature
LatexCommand nomenclature
symbol "V"
description "volt, základná jednotka napätia v sústave SI"
\end_inset
\end_layout
\begin_layout Standard
Tabuľka by mala byť podľa možnosti centrovaná. Pri jej opisovaní v
\begin_inset space ~
\end_inset
texte treba použiť odkazy na tabuľku v
\begin_inset space ~
\end_inset
tvare: pozri Tabuľku
\begin_inset space ~
\end_inset
\begin_inset CommandInset ref
LatexCommand ref
reference "t:1"
\end_inset
. Na číslovanie obrázkov, resp. tabuliek treba použiť triedenie. Za slovom
\shape italic
Obrázok
\family default
\series default
\shape default
nasleduje ako prvé číslo kapitoly alebo časti, v
\begin_inset space ~
\end_inset
ktorej sa obrázok nachádza, potom medzera, pomlčka, medzera a
\begin_inset space ~
\end_inset
poradové číslo ilustrácie v
\begin_inset space ~
\end_inset
danej kapitole alebo časti. Napr.:
\begin_inset space ~
\end_inset
Obrázok
\begin_inset space ~
\end_inset
\begin_inset CommandInset ref
LatexCommand ref
reference "o:1"
\end_inset
iže: prvý obrázok v
\begin_inset space ~
\end_inset
druhej kapitole alebo časti). V
\begin_inset space ~
\end_inset
prípade, ak tabuľka presahuje stranu, je možné použiť balík
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
verb+longtable+
\end_layout
\end_inset
.
\end_layout
\begin_layout Standard
Navrhujeme zaraďovať obrázky v
\begin_inset space ~
\end_inset
elektronickej podobe. Napríklad Obrázok
\begin_inset space ~
\end_inset
\begin_inset CommandInset ref
LatexCommand ref
reference "o:2"
\end_inset
, ktorý opisuje riešenie diferenciálnej rovnice tlmených oscilácií
\begin_inset ERT
status collapsed
\begin_layout Standard
%%
\backslash
def
\backslash
ud{
\backslash
mathrm{d}}
\end_layout
\begin_layout Standard
\end_layout
\end_inset
\begin_inset Formula \begin{equation}\label{r:1}
\frac{\ud^2y}{\ud t^2}+\frac{\ud y}{\ud t}+y =0, \qquad y(0)=1, \quad
y\,'(0)=15,
\end{equation}
\end_inset
bol vytvorený v
\begin_inset space ~
\end_inset
MATLABe a
\begin_inset space ~
\end_inset
príkazom
\family typewriter
print tlmosc.eps -f1 -deps2
\family default
bol uložený vo formáte Encapsulated Postscript. Na prípadné použitie pdfLaTeXu sa obrázok konvertuje do formátu PDF, napr. pomocou programu
\family typewriter
epstopdf
\family default
. Zvyčajne sa číslujú vzťahy, na ktoré sa v
\begin_inset space ~
\end_inset
texte odvolávame. Napríklad: vzťahy (
\begin_inset CommandInset ref
LatexCommand ref
reference "r:1"
\end_inset
) definujú Cauchyho začiatočnú úlohu.
\end_layout
\begin_layout Standard
\begin_inset Float figure
placement ht!
wide false
sideways false
status open
\begin_layout Standard
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
centering
\end_layout
\end_inset
\begin_inset Graphics
filename tlmosc
width 70text%
\end_inset
\begin_inset Caption
\begin_layout Standard
Grafické zobrazenie riešenia rovnice
\begin_inset CommandInset ref
LatexCommand ref
reference "r:1"
\end_inset
\end_layout
\end_inset
\end_layout
\begin_layout Standard
\begin_inset CommandInset label
LatexCommand label
name "o:2"
\end_inset
\end_layout
\end_inset
\end_layout
\begin_layout Subsection
Subsection
\end_layout
\begin_layout Standard
Podkapitoly záverečnej práce majú za úlohu členenie textu záverečnej práce s
\begin_inset space ~
\end_inset
cieľom, čo najväčšej prehľadnosti. Kapitol môže byť viacero a
\begin_inset space ~
\end_inset
v
\begin_inset space ~
\end_inset
ich názvoch sa používa desatinné číslovanie.
\end_layout
\end_body
\end_document

@ -0,0 +1,124 @@
\section{Program requirements}
In present days, there exists multiple libraries for managing almost every action possible by this device. Since the Arduino platform was chosen, the libraries are often normalized to conform some compatibility standards. In most of them, object-oriented programming is embraced, which further simplifies implementation and code reusability.
\subsection{Individual tasks}
The program should handle these tasks:
\begin{itemize}
\item show information on the display
\item receive commands from user interface
\item maintain real time and date
\item obtain tag information from RFID reader module
\item store tag information along with time and date in a memory
\item process communication with PC
\end{itemize}
\newpage
\subsection{Required libraries}
Since the memories, contained within the microcontroller are small enough, that we could easily hit their limits, the used libraries should be small size, more importantly, they should consume as little RAM as possible. Potentially useful libraries:
\begin{itemize}
\item PCD8544 driver for dot-matrix LCD display
\item MicroSD card library with FAT16 library
\item MFRC522 Mifare communication chip
\item commands over serial line library
\item rotary encoder and push-button with interrupt support and aditional software debouncing
\item clock prescaler library
\item DS1302 RTC timekeeping chip library
\end{itemize}
We do not look explicitly for UART, SPI, ADC or EEPROM libraries, since they are natively part of the Arduino framework, and they work well.
%\subsection{User menu entries}
%\begin{itemize}
% \item set time/date
% \item create new meeting file with generic name
% \item delete meeting file
% \item set current meeting file to save into
%\end{itemize}
%
%\subsection{PC communication data set}
%The device should be able to recognize and execute following commands on meeting files given from PC:
%\begin{itemize}
% \item show all
% \item delete
% \item create
% \item rename
% \item download
%\end{itemize}
%
%\newpage
%\section{Hardware dependencies}
%Things that needs to be considered about components/modules, when designing this kind of device are:
%\begin{itemize}
% \item power consumption
% \item cost
% \item availability
%\end{itemize}
%
%%The most crucial thing to consider, when designing this device is probably the power consumption, since it is powered from batteries. Another really important thing is, of course, the cost of components, because cost always drives the design in some ways. The third thing that is ultimately connected with the cost is availability. You have to consider this two factors when designing a product, in case it will get on the market eventually. Yes, we could just splat some pieces together and make it work, but then you will have to redesign the whole thing later to be able to compete on the market. To avoid this, it is easier to design the product with considerations about cost and availability of parts upfront.
%
%\subsection{Viable microcontroller}
%Microcontroller has to synchronize all the device duties, discussed earlier. These task are simple enough to be built around 8-bit microcontroller, which reduces cost and power consumption. Most viable options are:
%\begin{itemize}
% \item AVR ATmega168/ATmega328 has tons of available source codes
% \item AVR ATmega32u2 has built in USB controller
%\end{itemize}
%
%\subsection{Display and user interface}
%Display has to have low power consumption. Apart from that, it should have at least two lines to be able to show enough information.
%
%Touchscreen is option that combines a display and an user interface. If push-buttons are used as a human interface, the display is needed. Viable display types are LCD, oLED and e-ink.
%%\begin{itemize}
%% \item LCD
%% \item oLED
%% \item e-Ink
%%\end{itemize}
%
%
%%The choices are PCD8544 compatible (LCD, Nokia3310), Hitachi HD44780 compatible (LCD, 16x2), e-ink (lowest power consumption but expensive), TFT (expensive, a lot of additional circuitry and software needed but no need for user interface), OLED (not that cheap but less power consumption that LCD).
%
%\subsection{Keeping track of time and date}
%Real-time can be tracked by either a MCU or using external RTC module.
%RTC module has own battery supply, the algorithms for time and date built in and also provides some additional nvRAM for storing data that should not get lost, but microcontroller usually has some EEPROM memory for this purpose, which will be much faster.
%
%\subsection{RFID reader module}
%Reader has to be able to decode Mifare tag information. The most obvious reason is to use MFRC522 Contactless reader IC controller from NXP Semiconductor, because it does all the hard job. It is quite expensive alone, but you can get it from the China already soldered it as a module with driving electronics, and what is more important, an inductor working as an antenna, for the price for the IC alone! Choosing this module solves a lot of problems.
%
%\subsection{Memory for storing lists}
%Lists of information should be stored in some form of electronically programmable non-volatile memory, in basic structured format. Common types are:
%\begin{itemize}
% \item Flash (internal or as a microSD card)
% \item EEPROM
%\end{itemize}
%MicroSD card needs its own special compartment, where it is inserted and makes electrical contact. User should be able to replace the microSD card within the device.
%
%
%\subsection{Communication with PC}
%Communication between the device and the PC has to be fast enough to provide quick way of downloading the lists stored in device memory. This can be accomplished with the use of USB. Using Bluetooth can be another or additional option for this purpose.
%
%\subsection{A power source}
%When considering a power source, a lot of options comes to play. First choice:
%\begin{itemize}
% \item replaceable power source
% \item non-replaceable power source
%\end{itemize}
%Replaceable source could be standard rechargeable or non-rechargeable cell batteries of two 1.5V batteries or one 9V battery. Device will need stand-alone battery compartment for battery maintenance.
%
%For non-replaceable power source, combination of these could be implemented:
%\begin{itemize}
% \item solar panel
% \item Li-Po rechargeable battery
% \item supercapacitor
% \item wireless charging through RFID antenna
%\end{itemize}
%
%
%%Since the device is battery powered, obviously, the battery is needed. Basically, there are two types of batteries: non-replaceable and replaceable. The first option is an easy way - cheap a no additional devices needed. The problem is that batteries needs to be changed and also, the device needs a slot on the box for battery compartment. The second options is to use some rechargeable battery, that will be inside. For small electronics Li-ion or Li-Po battery is probably the best option. This fits greatly, because the device is already going to have an USB connector for data manipulation, so it can be used for charging, too. The disadvantage is added cost and space occupation by charging circuitry devices.
%%
%%There are also some other, rather impractical options. We could use a supercapacitor as a power source. Requires no additional charging circuitry, but the price is still relatively high. I may do some more research on this. Another option is to integrate some mini solar panel, but this again increases the cost greatly and makes practical advantage only on sunlight. Probably the most interesting option is to use the inductor, which is used for RF communication also for battery charging. This cool idea has quite a lot of problems, thou. The module I decided to use does not support this, so it will need custom made (expensive) RF module and it will need some kind of docking charging station. This will however made whole USB capabilities of the device obsolete, so it is maybe not that bad idea.
%%
%%Whichever option will be used is subject for further investigation.
%
%\subsection{Firmware dependencies}
%For the firmware there are again two options: program it from scratch and use some platform. The first option is viable mainly to applications which have limitations such as RAM or Flash memory space, or where timing is crucial. Since these are not the case here, because we are limited mainly with the amount of power stored in battery, a framework/platform can be used to greatly aid in firmware development.

@ -0,0 +1,7 @@
\section*{Appendices}
\addcontentsline{toc}{section}{\numberline{}Appendices}
\thispagestyle{empty}
\begin{description}
\item[Appendix A] CD with electronic form of thesis, schematics source files, firmware source code and all the software needed to open and compile the all the provided source files
\end{description}

@ -0,0 +1,486 @@
#LyX file created by tex2lyx 2.0.3
\lyxformat 413
\begin_document
\begin_header
\textclass article
\use_default_options false
\language english
\language_package none
\inputencoding auto
\fontencoding default
\font_roman default
\font_sans default
\font_typewriter default
\font_default_family default
\font_sc false
\font_osf false
\font_sf_scale 100
\font_tt_scale 100
\graphics default
\paperfontsize default
\spacing single
\use_hyperref 0
\papersize default
\use_geometry false
\use_amsmath 1
\use_esint 1
\use_mhchem 0
\use_mathdots 0
\cite_engine basic
\use_bibtopic false
\use_indices false
\paperorientation portrait
\suppress_date false
\use_refstyle 0
\secnumdepth 3
\tocdepth 3
\paragraph_separation indent
\paragraph_indentation default
\quotes_language english
\papercolumns 1
\papersides 1
\paperpagestyle default
\tracking_changes false
\output_changes false
\html_math_output 0
\html_css_as_file 0
\html_be_strict false
\end_header
\begin_body
\begin_layout Section*
Appendix C
\end_layout
\begin_layout Standard
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
addcontentsline{toc}{section}{
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
numberline{}{A}
\end_layout
\end_inset
ppendix C
\begin_inset ERT
status collapsed
\begin_layout Standard
}
\end_layout
\end_inset
\end_layout
\begin_layout Subsection*
Vytvorenie zoznamu skratiek a symbolov
\end_layout
\begin_layout Standard
Ak sú v
\begin_inset space ~
\end_inset
práci skratky a symboly, vytvára sa
\emph on
Zoznam skratiek a
\begin_inset space ~
\end_inset
symbolov
\emph default
(a
\begin_inset space ~
\end_inset
ich dešifrovanie). V
\begin_inset space ~
\end_inset
prostredí LaTeXu sa takýto zoznam ľahko vytvorí pomocou balíka
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
verb+nomencl+
\end_layout
\end_inset
. Postup je nasledovný:
\end_layout
\begin_layout Enumerate
Do preambuly zapíšeme nasledujúce príkazy
\begin_inset Newline newline
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
verb+
\backslash
usepackage[slovak,noprefix]{nomencl}+
\end_layout
\end_inset
\begin_inset Newline newline
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
verb+
\backslash
makeglossary+
\end_layout
\end_inset
\end_layout
\begin_layout Enumerate
V
\begin_inset space ~
\end_inset
mieste, kde má byť
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
/
\end_layout
\end_inset
vložený zoznam zapíšeme príkaz
\begin_inset Newline newline
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
verb+
\backslash
printglossary+
\end_layout
\end_inset
\end_layout
\begin_layout Enumerate
V miestach, kde sa vyskytujú skratky a symboly ich definíciu zavedieme, napr. ako v
\begin_inset space ~
\end_inset
našom texte, príkazmi
\begin_inset Newline newline
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
verb+
\backslash
nomenclature{$
\backslash
upmu$}{mikro, $10^{-6}$}+
\end_layout
\end_inset
\begin_inset Newline newline
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
verb+
\backslash
nomenclature{V}{volt, základná jednotka napätia v sústave SI}+
\end_layout
\end_inset
\begin_inset Newline newline
\end_inset
a dokument
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
uv
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
{
\end_layout
\end_inset
preLaTeXujeme
\begin_inset ERT
status collapsed
\begin_layout Standard
}
\end_layout
\end_inset
.
\end_layout
\begin_layout Enumerate
Z
\begin_inset space ~
\end_inset
príkazového riadka spustíme program
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
verb+makeindex+
\end_layout
\end_inset
s
\begin_inset space ~
\end_inset
prepínačmi podľa použitého operačného systému, napr.
\begin_inset space ~
\end_inset
v
\begin_inset space ~
\end_inset
OS
\begin_inset space ~
\end_inset
GNU/Linux s
\begin_inset space ~
\end_inset
distribúciou Ubuntu
\begin_inset space ~
\end_inset
\begin_inset Formula $10.04$
\end_inset
a
\begin_inset space ~
\end_inset
verziou
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
verb+texlive 2009-7+
\end_layout
\end_inset
napíšeme:
\begin_inset Newline newline
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
verb*+makeindex tukedip.glo -s nomencl.ist -o tukedip.gls+
\backslash
\backslash
\end_layout
\begin_layout Standard
~v~OS~Win
\backslash
,XP s~verziou
\backslash
verb+TeXLive 2010+
\end_layout
\begin_layout Standard
napíšeme:
\backslash
\backslash
\end_layout
\begin_layout Standard
\backslash
verb*
\end_layout
\end_inset
+makeindex -o tukedip.gls -s nomencl.ist tukedip.glo+
\end_layout
\begin_layout Enumerate
Po opätovnom
\begin_inset ERT
status collapsed
\begin_layout Standard
\backslash
uv
\end_layout
\end_inset
\begin_inset ERT
status collapsed
\begin_layout Standard
{
\end_layout
\end_inset
preLaTeXovaní
\begin_inset ERT
status collapsed
\begin_layout Standard
}
\end_layout
\end_inset
dokumentu sa na požadované miesto vloží
\emph on
Zoznam skratiek a symbolov
\emph default
.
\end_layout
\end_body
\end_document

@ -0,0 +1,31 @@
\section*{Appendix C}
\addcontentsline{toc}{section}{\numberline{}Appendix C}
\subsection*{Vytvorenie zoznamu skratiek a symbolov}
Ak sú v~práci skratky a symboly, vytvára sa \emph{Zoznam skratiek
a~symbolov} (a~ich dešifrovanie). V~prostredí \LaTeX{}u sa takýto
zoznam
ľahko vytvorí pomocou balíka \verb+nomencl+. Postup je nasledovný:
\begin{enumerate}
\item Do preambuly zapíšeme nasledujúce príkazy\\
\verb+\usepackage[slovak,noprefix]{nomencl}+\\ \verb+\makeglossary+
\item V~mieste, kde má byť\/ vložený zoznam zapíšeme príkaz\\
\verb+\printglossary+
\item V miestach, kde sa vyskytujú skratky a symboly ich definíciu
zavedieme, napr. ako v~našom texte, príkazmi\\
\verb+\nomenclature{$\upmu$}{mikro, $10^{-6}$}+\\
\verb+\nomenclature{V}{volt, základná jednotka napätia v sústave SI}+\\
a dokument \uv{pre\LaTeX{}ujeme}.
\item Z~príkazového riadka spustíme program \verb+makeindex+
s~prepínačmi podľa použitého operačného systému, napr.~v~OS~GNU/Linux
s~distribúciou Ubuntu~$10.04$ a~verziou \verb+texlive 2009-7+
napíšeme:\\
\verb*+makeindex tukedip.glo -s nomencl.ist -o tukedip.gls+\\
~v~OS~Win\,XP s~verziou \verb+TeXLive 2010+
napíšeme:\\
\verb*+makeindex -o tukedip.gls -s nomencl.ist tukedip.glo+
\item Po opätovnom \uv{pre\LaTeX{}ovaní} dokumentu sa na
požadované
miesto vloží \emph{Zoznam skratiek a symbolov}.
\end{enumerate}

@ -0,0 +1,29 @@
@book{monk2013programming,
title={Programming Arduino Next Steps: Going Further with Sketches},
author={Monk, S.},
isbn={9780071830256},
lccn={2013033821},
series={McGraw-Hill Electronics},
url={http://books.google.sk/books?id=gRwIAQAAQBAJ},
year={2013},
publisher={McGraw-Hill Education}
}
@book{anderson2013pro,
title={Pro Arduino},
author={Anderson, R. and Cervo, D.},
isbn={9781430239406},
series={Technology in action series},
url={http://books.google.sk/books?id=PNvI6rBrxncC},
year={2013},
publisher={Apress}
}
@misc{arduino:pro_mini,
key = {zzz Arduino Pro Mini, Rev.3 Schematics},
title = {Arduino Pro Mini, Rev.3 Schematics},
howpublished = {\url{http://arduino.cc/en/uploads/Main/Arduino-Pro-Mini-schematic.pdf}},
note = {(Visited on 05/27/2014)}
}

@ -0,0 +1,11 @@
\section{Conclusion}
The main task was to construct a portable hand-held device, capable of reading the RFID tags contained in student's ISIC cards and store them onto the SD card. This task was fully accomplished and the device meets all the requirements. Additional features, like minimal user interface and a Serial connection over the USB with supportive commands were successfully included.
\subsection{Possible future improvements}
The biggest problem is absence of proper switch to turn device off. Present solution relies connectors making touch, when pushed. While it works, it is unintuitive and also unreliable. Also, the implementation of display's backlight would improve readability.
The second main concern are non-rechargeable batteries for main power and for RTC backup. The device could be improved by adding support for handling and charging the LI-PO rechargeable batteries. Used RTC chip has a charging capability, so the RTC backup battery should be changed to supercapacitor.
Also, the RFID reader module itself draws a lot of current, one order of magnitude more, compared to all other electronic. The passive LED diode contained on the module could be desoldered, to reduce the power consumption a bit.
There is also a lot of room to improve the efficiency of the firmware, regarding the power consumption. There was a little effort put in this, since the module itself draws far more current, so it is less important.

Binary file not shown.

Binary file not shown.

@ -0,0 +1,35 @@
\setcounter{page}{1}
\setcounter{equation}{0}
\setcounter{figure}{0}
\setcounter{table}{0}
\section*{Introduction}
The idea is to construct a battery powered device that will be able to read the RFID tag from the ISIC cards students briefly place onto the reader part. The tags will then be stored on the detachable microSD card in structured format, alongside with time and date. The end result of this process is actually a attendance list of students. The device is to be used in the environment, where there are limited possibilities do proper attendance list, i.e. in the gym or when working in terrain.
Basic concept is to design and realize an electronic circuit, which will handle RFID communication with the student's ISIC card.
The project itself basically consists of this main parts:
\begin{itemize}
\item the microcontroller
\item the RFID reader module
\item the power source
\item a display
\item the storage memory for the lists
\item a way to communicate with a PC
\item a real-time tracking module
\item some user interface
\end{itemize}
The two absolutely crucial areas that needs to described in deeper detail this project are microcontrollers and of course the RFID.
\nomenclature{$\upmu$}{micro, $10^{-6}$}
\nomenclature{SI}{Syst\`eme International}
\nomenclature{V}{Volt, basic unit in SI}
\nomenclature{RFID}{Radio Frequency Identification}
\nomenclature{ISIC}{International Student Identity Card}
\nomenclature{LCD}{Liquid-crystal Display}
\nomenclature{USB}{Universal Serial Bus}
\nomenclature{RTC}{Real-time Clock}
\nomenclature{microSD}{Secure Digital memory card}
\nomenclature{MCU}{Microcontroller, sometimes uC or $\upmu$C}

@ -0,0 +1,358 @@
\section{Program description}
The program consists of two main parts: the setup part and the loop part.
The setup part does the things, that needs to be done once which are mostly initializations - clock prescaler, LCD, interrupts, SPI, pins and so on.
The loop part does the same thing all over again. This main cycle check, if there was a command received over a serial line, refreshes the time shown on the display, check if the button was pressed and then checks if some data are available from the RFID reader.
\subsection{UML activity diagram}
\begin{figure}[ht!]
\centering
\includegraphics[width=1\textwidth,angle=0]{activity_rfid_uml.jpg}
\caption{Activity diagram of the program in UML language}\label{uml:act}
\end{figure}
Activity diagram of the internal workings of the device's embedded system is shown in \ref{uml:act}. As we can see from the activity diagram shown above, the device itself (red) is responsible for storing the actual time and date and keeping track of it, checking and reading the file­system on the SD card for files and writing into them, providing the back­end for the device human interface and servicing the communication with RFID capable card working on Mifare protocol.
\subsection*{Actions}
\begin{itemize}
\item Set time and date is done by the interface consisting of LCD display and pushbuttons
\item Load SD card with meeting names is done on any device capable of creating files on the FAT filesystem
\item Choose meeting to record into again, done on the device ­pushbuttons interface
\item Try to read the ID tag is done automatically when the ISIC card is present in the magnetic field of reader
\item Save RFID tag to the SD card is done automatically when the reading of the RFID tag is successful; tag is stored with actual time and date
\end{itemize}
­
\subsection*{Data sources}
\begin{itemize}
\item Meeting names of the text files without extension on the SD card
\item SD card contains the files (meeting names) that contains the meetings data (time, date, RFID tag) on the FAT filesystem
\item RFID tag unique tag read wirelessly from ISIC card
\end{itemize}
\subsection*{Signals}
\begin{itemize}
\item ­SD card error is displayed on the LCD display
\item ­ISIC card error is displayed on the LCD display
\end{itemize}
\subsection{UML use-case diagram}
\begin{figure}[ht!]
\centering
\includegraphics[width=1\textwidth,angle=0]{usecase_rfid_uml.jpg}
\caption{Use-case diagram of the program in UML language}\label{uml:use}
\end{figure}
Unlike th activity diagram, in the Use case diagram, shown in \ref{uml:use}, the responsibilities of device users are depicted. From the diagram, it is clear that three systems are needed for whole concept. The main system (RFID reader) is the system embedded in the device. Two more subsystems are needed: one fro making sense of the data (statistics, analytics) and one for easy manipulation with SD card contents, since the human interface of the main system is very limited.
\subsection*{Meeting orgnizator (red actions)}
Organizator is responsible for preparing the reader by storing empty files, without extension on FAT filesystem formatted SD card on the device, which is capable of doing so. The file names are actually the meeting names. The data are stored in these files. He is also responsible for setting up time and date, after each battery replacement. Before meeting start he chooses the file which data will be saved into. Viewing the data statistics and analytics is subject to further expansion of the system, for now, they are only available in raw format.
\subsection*{Meting visitor (blue actions)}
When the reader is fully prepared by the organizator. meeting visitor's only responsibility is to firmly put his ISIC card on the reader for brief period of time (until beep is sound is played). Data are wirelessly transmitted into the reader and processed there. When this happens, the visitor's presence on the meeting is recorded and stored on the SD card for further analysis.
\newpage
\section{Program compilation}
The program can be compiled with the use of Eclipse IDE, when opened as a project right out of the box. Manual compilation is possible, but is really complicated and should not be used. Versions of compilation tools:
\begin{itemize}
\item \texttt{avrdude-5.11.1}
\item \texttt{avr-libc-1.8.0}
\item \texttt{binutils-avr\_2.20.1-2}
\item \texttt{gcc-avr\_4.7.2-2}
\end{itemize}
%The Contactless Attendance Logger is a device constructed as a result of this work. The requirements for this device was detailed in sections 3 and 4. This section explains, how and why individual components, depicted in those sections were chosen. The fully assembled device, inside a case is shown at \ref{dev:full}, with part labelled at \ref{dev:ilu}.
%
%\begin{figure}[ht!]
%\centering
%\includegraphics[width=.6\textwidth,angle=0]{device_full.png}
%\caption{Full assembled device - Contactless Attendance Logger}\label{dev:full}
%\end{figure}
%
%\subsection{Firmware}
%For the firmware\cite{toulson2012fast} side, the Arduino platform\cite{monk2013programming} will be used. The reason behind this decision is global community support and free software libraries for almost any possible component including most of the components suggested for this device. This will greatly reduce the software development time over plain C programming.
%
%\subsection{Power supplies and battery level}
%Four 1.5V AA type batteries in series will produce slightly more than 6V when fully charged. Together with low drop-out linear regulator LP2985-33\cite{DS:LP2985-33} will provide steady 3.3V over full operable batteries voltage range. This setup will eliminate the need to incorporate a DC converter, which will make the design far simpler.
%
%The device will be operable also without the main power supply, the batteries. Linear Technology LTC4412\cite{DS:LTC4412} chip will take care of switching between battery and USB supply, choosing the USB when provided. Two external diodes will provide further protection. To preserve battery voltage range, the low drop-out Schottky diode BAT42 is used on the batteries side.
%
%The power supply part of the device is able to provide information about which power supply is active at given time, however it is not able to determine the current battery charge level. For this purpose small custom circuitry will be made to handle this task and to protect the MCU from over-voltage, since it cannot measure voltage level of the batteries at their full potential.
%
%\begin{figure}[ht!]
%\centering
%\includegraphics[width=.4\textwidth,angle=0]{device_pcb.png}
%\caption{Disassembled device showing the main board, exposing components}\label{dev:pcb}
%\end{figure}
%
%\subsection{Microcontroller}
%As a brain for the device is chosen the Atmel microcontroller, ATmega328P\cite{DS:ATmega328P}. This MCU is fully compatible with the Arduino platform, so no further modifications are needed. It has 32kB of flash program memory, which gives us a reasonable amount of memory reserve, since estimations shows, that around 20kB of program memory space will be used.
%
%
%\subsection{Communication}
%The FTDI device FT321X\cite{DS:FT231X} will be used for providing communication between microcontroller and the PC over an USB connection. It communicates with a MCU over an UART protocol, which needs precise clock source on both sides. This device has it's own precise clock already integrated. This chip is also cheaper, smaller and more reliable than a lot of other similar solutions on the market.
%
%Since the device will use a fully compliant USB-to-UART bridge, the user will be able to reprogram the microcontroller over the USB without the need of any external device. This will help introducing further firmware updated to the end device. The USB side of the bridge will appear on host computer as Virtual COM Port\cite{axelson2007serial}.
%
%\subsection{Clock source}
%The microcontroller will use small compact 16MHz resonator with integrated run-up capacitors with 0.5\% accuracy. Since the MCU cannot reliably operate clocked to 16MHz at 3.3V, clock prescaler, integrated inside the MCU, with a factor of 2 will be used to drop the clock frequency to 8MHz. This frequency is fully compatible with the Arduino platform, so no further code modifications will be needed. Lower frequency also help to preserve the batteries. The external clock source will reduce the errors over the UART communication.
%
%\subsection{Display}
%User will be able to read the information and menu from the chosen 24x48 dot matrix LCD with PCD8544 controller, known for presence in some popular Nokia mobile phones like 3310 or 5110 models. The reasons for this was really low power consumption, communication in SPI protocol, price and ability to easily display simple images, for example a battery level indication.
%Since the display has its own controller, if there is no actual need for updating the displayed data, microcontroller can go to sleep mode to preserve the battery energy. This is not possible in displays directly controlled by MCU, i.e. multiplexed 7-segment displays.
%
%\subsection{User interface}
%The minimalist design of this device was requiring at least 3 user inputs. For this purpose, re branded rotary encoder from old Sony Ericsson mobile phone is used. Now the device can be controlled with only one finger or thumb.
%The encoder will provide two rotation directions and also acts as a push-button. This will help scrolling the device menu.
%
%Audio feedback for used will be handled by small speaker used commonly in hand-held devices to provide an audible feedback for user, indicating some events, i.e. successful card read operation.
%
%\subsection{Time and date tracking}
%For this task, the Maxim DS1302\cite{DS:DS1302} chip is used. The precise clock source, watch crystal with 32.768kHz, that is fed directly into the chip. The chip is also backed by a small replaceable non-rechargeable 3V battery CR1220. This will make sure that the device will be fully operable without main battery, only with the USB connection active.
%
%\subsection{RFID reader module}
%The suggested RFID reader module from China manufacturers, with NXP's chip MFRC522 will be used for RFID communication. It handles all the Mifare protocol communication and also is able to communicate over SPI protocol. This plays nicely with the LCD display, since it is also communicating over SPI.
%
%\subsection{MicroSD card slot}
%MicroSD card will be pushed into standard MicroSD card slot. No module will be used, since they provide no real advantage and take precious space in hand-held devices. The card also communicates with MCU over the SPI protocol, which needs some surrounding electronics shared with other SPI related components.
%
%\begin{figure}[ht!]
%\centering
%\includegraphics[width=.6\textwidth,angle=0]{device_illustration.jpg}
%\caption{Illustration of the fully assembled device with labelled individual parts}\label{dev:ilu}
%\end{figure}
%
%\newpage
%\section{User interface operation instructions}
%This section is devoted to instructions for proper operation of the device. The manual and all other information provided by the device is available only in English language.
%
%\subsection{MicroSD card preparation and usage}
%The device supports MicroSD cards up to 2 GB of storage space. The card itself has to be formatted with the FAT16 filesystem\cite{solomon2011computer}. Consult your operating system help center for instructions. The device itself cannot do this task alone. Properly prepared card is then inserted with a gentle push into MicroSD slot near the top right corner of the device. This operation is possible only when the device is out of its case, since there is no dedicated hole in the case. Pull the card firmly to take it out of the device. When the card is inserted after the device was powered, or the card is broken or not supported, the CARD INIT ERROR\ref{disp:1} error is displayed.
%\begin{figure}[ht!]
%\centering
%\includegraphics[width=.4\textwidth,angle=0]{display_error_card.jpg}
%\caption{Illustration of the LCD display, when the device is unable to recognize the MicroSD card}\label{disp:1}
%\end{figure}
%When this happens, please ensure that the card is fully inserted inside it's slot, power-down and power-up the device again, or try another card, if the error persists.
%
%
%If the card is supported, but is formatted unproperly, the FAT16 INIT ERROR \ref{disp:2} is displayed.
%\begin{figure}[ht!]
%\centering
%\includegraphics[width=.4\textwidth,angle=0]{display_error_fat16.jpg}
%\caption{Illustration of the LCD display, when the MicroSD card is recognized, but is not formatted with FAT16 file system}\label{disp:2}
%\end{figure}
%Without the working MicroSD card, the device will not be operable.
%
%\subsection{Basic operation}
%The device starts itself as soon, as the power source is present. When inserted into the dedicated plastic case with no USB cable attached, the device is powered from the four contained AA batteries. This fact, along with the current battery level is indicated in the top left corner of the LCD display, in the power source indicator area. With battery mode active, the LCD display looks similar to illustration \ref{disp:3}. Other information displayed on the LCD are current time in the right-top corner and actual storage file. The storage files are explained in advanced operation.
%\begin{figure}[ht!]
%\centering
%\includegraphics[width=.4\textwidth,angle=0]{display_battery.jpg}
%\caption{Illustration of the LCD display, when the device is in battery power supply mode}\label{disp:3}
%\end{figure}
%The indicator has four stages, indicating battery level of circa 100, 75, 50, 25\%. When the batteries re too too low for device to operate, it will not start, nor display anything on the LCD.
%
%For the operation in the USB mode, connect the Mini-B USB connector to he bottom-right corner or the device. Connect the other side to some USB charger or PC. When connected to the PC, device acts as a Virtual COM Port, that is supported by most OS. You should be able to see it in your operating system device manager. Note that on Windows machines, it may take a while for device driver to install itself via Windows Update service. If this is not the case, you can use included CD to install the driver manually.
%
%When the device is plugged into USB power source, it will immediately switch to the USB mode. This mode does not drain the battery and is indicated with a small USB standard icon in the top-left corner of the display, as illustrated on \ref{disp:4}.
%
%\begin{figure}[ht!]
%\centering
%\includegraphics[width=.4\textwidth,angle=0]{display_usb.jpg}
%\caption{Illustration of the LCD display, when the device is in USB power supply mode}\label{disp:4}
%\end{figure}
%
%\subsection{Menu and advanced operation}
%A main menu is accessed by push of the rotary button, which is the only manually operable element. The button is situated in the top-right corner of the device. When in menu, navigation is achieved by a rotation of the rotary button. The current selected menu entry is indicated by the black arrow on the left side of the display. The menu entry is selected by one more push of the button. The main menu itself is simple and contains only 4 entries \ref{disp:5}: Storage, New file, Date/time and an Exit for return to the main screen, when the device is active. This means, that the device records RFID data and responds to Serial commands. Both this concepts will be explained later.
%\begin{figure}[ht!]
%\centering
%\includegraphics[width=.4\textwidth,angle=0]{display_menu.jpg}
%\caption{Illustration of the LCD display, the main menu is active}\label{disp:5}
%\end{figure}
%
%When for some reason, i.e. the MicroSD card is empty or the selected storage file was deleted, the "Please select a storage file" sign \ref{disp:6} will be sown on the display.
%
%The purpose of the storage menu entry is to choose the file, where the data will be stored, the storage file. Navigation in this submenu is identical to the navigation of the of the main menu. When the file is selected, the device returns to the main screen.
%\begin{figure}[ht!]
%\centering
%\includegraphics[width=.4\textwidth,angle=0]{display_error_storage.jpg}
%\caption{Illustration of the LCD display, the storage file is not selected}\label{disp:6}
%\end{figure}
%
%
%If again, the card is empty, the storage submenu will be empty too. This can be solved by accessing the second entry of the main menu - New file. The entry has no visible submenu and will return to the main screen when accessed. However, the empty storage file will be created. The file naming scheme is FILE1, FILE2, FILE3 and so on. The created file will then be shown on the Storage submenu, where can be selected and activated.
%
%The third entry in the main menu is Date/time. When accessed, the current time and date is shown and can be changed. The actual changed value is indicated by continual blinking. The values are accessed by successive pushes of the button and can be changed by rotation of the rotary button. When the button is pushed on the last, year value, the menu is left to the main screen and the changes to date and time are saved.
%
%\subsection{Data recording and Serial commands}
%The device is active when there is no error or sign displayed and is out of menu, on the main screen - illustrated previously on \ref{disp:3} and \ref{disp:4}. The screen contains the sign "Saving to:" and the storage file name beneath the sign. Now, when an RFID active ISIC card is resent in the blue device reader area, the actual date, time and the card's RFID tag is stored on inside the active storage file on the MicroSD card. Success is signalized by a short beep sound. Note that copy of the data that are stored are also sent over the USB cable, through the serial connection.
%
%Serial connection in established by opening a serial terminal application i.e. HyperTerminal, PuTTy or similar one on the PC, to which the device is connected by USB. After choosing the correct port assigned to the device, the baud rate of 38400 is selected. Flow control should be turned off. The other parameters should be left in default state. This includes 8 bit mode, no parity bit and 1 stop bit. The notation for this configuration is 8N1. Consult the application manual for correct settings.
%
%When the serial connection is active, the more advanced commands become available. The commands are typed into the terminal. No special characters are involved. If the command has one or more parameters, they are separated a by space character. When the inserted command is not recognized by the device, the brief help, containing list of possible commands is shown. For easier understanding, the command's arguments are CAPITALIZED. For convention, commands has similar structure as commands used in a Linux/UNIX environment. If the command has one or more arguments, they are all required. Note that file names must be 8 or less characters long. Longer file names may not work. The list of possible commands:
%\begin{itemize}
% \item \texttt{ls} - list all storage files
% \item \texttt{touch FILE} - create a storage file named FILE
% \item \texttt{rm FILE} - remove a storage file named FILE
% \item \texttt{rmall} - remove all storage files
% \item \texttt{mv FILE1 FILE2} - rename storage file FILE1 to FILE2
% \item \texttt{read FILE} - read the contents of the storage file FILE
% \item \texttt{readall} - read the contents of all storage files
% \item \texttt{date D M Y} - set current date to DD:MM:YYYY
% \item \texttt{time H I S} - set current time to HH:II:SS
%\end{itemize}
%
%\subsection{Manual manipulation with MicroSD card contents}
%User is able to manipulate the files directly by inserting the MicroSD card root destination from the device into the dedicated device or a slot in a computer. This way, user is gaining tools provided by the operating system to manipulate the files. Such a functionality is useful in example, when only specific files needs to be deleted, or some special naming convention is used. However, few restrictions still apply, otherwise the device will not work as expected. The maximum of 8 characters long names rule has to be preserved. Another important factor is not to change the .CSV file extension of the existing files and also adding this extension to files created. It is not advised to create any sub-folders on the MicroSD card.
%
%\newpage
%\section{Technical details}
%This section covers some details of the inner workings of the device and also explains some design decisions. All the information contained here are meant to be read by the expert users.
%
%\subsection{Circuit explaination}
%The device circuit is shown on \ref{cir:1}. It was created in the DipTrace electronics CAD software. The voltage regulator U5 is connected according to its datasheet\cite{DS:LP2985-33}. So do the USB-to-UART bridge U4\cite{DS:FT231X}, the bus powered configuration is used. Apart from TX and RX lines, the only connection is the DTR line, which connects over a capacitor to the main microcontroller U1 reset line\cite{arduino:pro_mini}. This allows firmware uploading over the serial port, so no external programmer is needed. Microcontroller gains this capability by running the Optiboot\cite{anderson2013pro} bootloader\cite{susnea2006microcontrollers}. The RTC chip U2\cite{DS:DS1302} is also connected according to it's datasheet. Since the microcontroller does not have the hardware support for the Three line serial interface, communication is implemented purely in software on separate pins.
%
%\begin{figure}
%\centering
%\includegraphics[width=1\textwidth,angle=0]{schematic.pdf}
%\caption{The device's schematic created in DipTrace}\label{cir:1}
%\end{figure}
%
%The PowerPath controller U3\cite{DS:LTC4412} has a special configuration. It's control CTL line is pulled-down by R10 and the GATE pin turns the P-channel MOSFET into On-state, so the current from from battery through Schottky diode D2. This diode is low drop-out, so together with a low drop-out voltage regulator, a minimum battery voltage for device operation can be as low as approximately 3.35V. This diode also stops current, that could flow from the USB bus through MOSFET substrate diode back to the batteries, when their voltage drops below the 5V. This could make batteries explode. The last function of this diode is to protect the whole circuit from situations, when a battery is inserted with wrong polarity.
%
%The U3 CTL line is pulled up by the USB bus. This shuts-down the MOSFET, so even when the battery voltage is higher than 5V, the current flows only from the USB bus through a normal junction diode D1. This diode also protects against wrong polarity, however this is unlikely in the USB bus, due to standardised connectors. It's main purpose is to stop the current flow from the batteries, when higher than 5V, to the USB bus. Also, the CTL line is protected, without the diode, it will be always pulled-up. Lastly, it leaves the U4 without power, when powered from batteries. This helps protects batteries, since there is no for the bridge without the USB connection.
%
%Since the microcontroller provides two pins, that acts only as analog input, without the interrupt capability, we can utilize on of them to sense, which power source is active. This is achieved by connecting the U3 STAT line to ADC7, along with external pull-up resistor to 3.3V, since this analog inputs have no in-built ones. The other one is used for real analog sensing of the battery voltage. This is done by bringing the PC5 high. The transistor Q2 is then fully saturated, so the analog pin ADC6 can sense battery voltage through a voltage divider with the ratio of 1:1. This means that safe maximum battery voltage is 2 x 3.3 - around 6.6V. The capacitor C13 blocks DC current from battery through the transistor's base. After the measurement is done, the PC5 is brought down. This approach makes sure that no microcontroller pin connected to constant voltage higher than 3.3V and also that a battery isn't constantly drained by the voltage divider.
%
%\tabcolsep=8pt
%\begin{table}[!ht]
%\centering
%\caption{Bill of materials used in the circuit}\label{t:bom}
%\begin{tabular}{lllr}
%\hline
%\textbf{RefDes} & \textbf{Value} & \textbf{Pattern} & \textbf{Qty} \\
%B1 & CR1220 & & 1 \\
%C1 - C8, C12, C14 & 0.1uF & CAP\_0805 & 10 \\
%C9 & 4.7uF & CAP\_0805 & 1 \\
%C10, C11 & 10uF & TC\_0805 & 2 \\
%C13 & 10uF & CAP\_0805 & 1 \\
%C15, C16 & 47pF & CAP\_0805 & 2 \\
%D1 & 1N4148 & CAP\_0805 & 1 \\
%D2 & BAT42 & MINIMELF & 1 \\
%J1 – J6 & connectors & & 1 \\
%LS1 & Piezo & & 1 \\
%Q1 & AP2309GN & SOT23 & 1 \\
%Q2 & BC807 & SOT23 & 1 \\
%R1, R2, R3, R5, R6, R7 & 22k & RES\_0805 & 6 \\
%R4, R11, R12, R15, R16 & 10k & RES\_0805 & 5 \\
%R8 & 100R & RES\_0805 & 1 \\
%R9 & 470k & RES\_0805 & 1 \\
%R10 & 100k & RES\_0805 & 1 \\
%R13, R14 & 27R & RES\_0805 & 2 \\
%U1 & ATmega328 & QFP-32/9x9x0.8 & 1 \\
%U2 & DS1302Z & SOIC-8/150mil & 1 \\
%U3 & LTC4412ES6 & SOT23-6 & 1 \\
%U4 & FT321X & QSOP-20 & 1 \\
%U5 & LP2985-33 & SOT23-5 & 1 \\
%Y1 & 16.0 & CSTCE16M0V53-R0 & 1 \\
%Y2 & 0.032768 & & 1
%\end{tabular}
%\end{table}
%
%The only other microcontroller's inputs being the two rotary encoder lines, the button line and the RFID reader module IRQ, which is host interrupt request. All of this inputs needs a I/O pin that is capable of interrupt. Since all normal pins on the microcontroller are capable of pin change interrupt, they could be connected almost anywhere. However, the button and the IRQ are connected to PD2 and PD3, which are the external interrupt pins. Only this two pins can wake-up the MCU from sleep when the card is present or the button is pressed. Sleep helps to reduce the power consumption, thus preserve batteries. Whole action is invisible to the user.
%
%Hardware encoder and button debouncing is done by the C5 - C7 along with MCU internal pull-up resistors activated on selected lines. R8 helps protect the pin driving the speaker, so it will not exceed it's rated 20mA maximum current source. Both the RTC watch crystal and the MCU resonator does not need a drive capacitors. They are built-in corresponding packages.
%
%The last thing is SPI\cite{susnea2006microcontrollers} communication. All lines has an external pull-up resistor. MCU built-in pull-up resistors should not be used for this purpose, since they are not active when the MCU in in reset - they are tri-stated. The communication lines pull-up resistors R1, R5 and R6 protects the slave SPI devices from any possible noise on these lines, when MCU is in the reset. They are also required by some MicroSD cards. The slave-select resistors R2, R3 and R7 are keeping all SPI slaves inactive, unless explicitly driven low by the MCU. This makes external MCU programming through the SPI possible.
%
%
%
%\subsection{Printed circuit board}
%The PCB schematic \ref{pcb:schem} is dual-layer was created in the DipTrace software as well. The main design aim was to have a bottom side of PCB without the components to minimize the device height. It is also a good practice to have one layer of the PCB with as much ground plane, as possible\cite{hara1998emc}. The the PCB design had to be done in the way, that it is possible to create the PCB in amateur, home environment.
%
%The process included application of dry photo-resist, which after exposed to UV light, covered by the actual PCB mask on transparent foil creates a etchant immune paths. For the etchant, the Hydrogen Peroxide with Hydrochlorid Acid was used. The drilling, vias and soldering was done manually.
%
%\begin{figure}
%\centering
%\includegraphics[width=1\textwidth,angle=0]{pcb_schematic.jpg}
%\caption{The device's PCB schematic created in DipTrace}\label{pcb:schem}
%\end{figure}
%
%\subsection{Firmware algorithm}
%There should be a general idea of the device inner operation after the Circuit explanation section was read. The firmware consists of some separate Arduino files and libraries for operating the SPI, LCD, SD, RFID reader, RTC, clock prescaler and the rotary encoder. The strings for a serial communication and bitmaps for a LCD are stored in MCU flash memory, to preserve a precious RAM.
%
%After the MCU is started, prescaler is activated, to make 8Mhz clock from 16MHz resonator for a safe 3.3V operation. Then the pull-ups are activated, the interrupts are initiated and the SPI communication is initialized. After that, LCD and RFID reader are initiated. In the end, the MicroSD card is tested. When everything is ready, the global interrupts are enabled and the program goes into the main loop, which goes over and over.
%
%The main loop handles the received serial commands, refreshes the time,power indicator and storage file information, handles the received RFID data and shows menu, when the button was pressed. The menus and submenus are just endless loops again, that reacts on the button press or rotary encoder activity.
%
%
%
%%
%%Začnime rovnicou
%%
%%\begin{equation}\label{r:2}
%%\frac{\ud^2y}{\ud t^2}+\frac{\ud y}{\ud t}+y =0, \qquad y(0)=1, \quad
%%y\,'(0)=15.
%%\end{equation}
%%
%%Grafický priebeh riešenia tejto rovnice vidíme na Obrázku \ref{o:2}.
%%
%%\begin{figure}[ht!]
%%\centering
%%\includegraphics[width=.6\textwidth,angle=0]{relaxcas.pdf}
%%\caption{Teplotná závislosť\/ spinovo-mriežkového relaxačného
%%času}\label{o:3}
%%\end{figure}
%%
%%%\tabcolsep=3pt % sirka stlpcov
%%%\renewcommand{\arraystretch}{1.2} % riadkovanie
%%\begin{table}[ht!]
%%\centering
%%\caption{Parametre získané z~meraní spinovo-mriežkových relaxačných
%%časov $T_1$}\label{t:2}
%%\medskip
%%\newcolumntype{d}{D{,}{,}{-1}}
%%\begin{tabular}{||c||d|d|d|d|d||}
%%\hhline{|t:==t:==:==:t|}
%%\multicolumn{1}{||c||}{}&\multicolumn{1}{c|}{PP --
%%01}&\multicolumn{1}{c|}{PP -- 05}&\multicolumn{1}{c|}{PP --
%%10}&\multicolumn{1}{c|}{PP -- 16}&\multicolumn{1}{c||}{PP -- 22} \\
%%\hhline{|:==:==:==:|}
%%C $\cdot 10^8$~(s$^{-2}$) & 10,1 & 10,0 & 11,0 & 9,2 & 8 \\
%%\hhline{||-|-|-|-|-|-||}
%%$\tau_0 \cdot 10^{-14}$~(s) & 2,63 & 1,44 & 0,95 & 2,21 & 10,83 \\
%%\hhline{||-|-|-|-|-|-||}
%%$E_{\text a}$~(kJ) & 34,26 & 8,33 & 39,76 & 37,31 & 31,86 \\
%%\hhline{||-|-|-|-|-|-||}
%%$T_{\min}$~(K) & 354 & 367 & 367 & 369 & 367 \\
%%\hhline{||-|-|-|-|-|-||}
%%$T_{1\min}$~(ms) & 141 & 160 & 157 & 175 & 181 \\
%%\hhline{||-|-|-|-|-|-||}
%%$\Delta M_2$~(Gs$^2$) & 5,49 & 5,66 & 5,16 & 5,09 & 5,02 \\
%%\hhline{|b:==b:==:==:b|}
%%\end{tabular}
%%\end{table}
%

@ -0,0 +1,802 @@
%%
%% This is file `natbib.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% natbib.dtx (with options: `package,all')
%% =============================================
%% IMPORTANT NOTICE:
%%
%% This program can be redistributed and/or modified under the terms
%% of the LaTeX Project Public License Distributed from CTAN
%% archives in directory macros/latex/base/lppl.txt; either
%% version 1 of the License, or any later version.
%%
%% This is a generated file.
%% It may not be distributed without the original source file natbib.dtx.
%%
%% Full documentation can be obtained by LaTeXing that original file.
%% Only a few abbreviated comments remain here to describe the usage.
%% =============================================
%% Copyright 1993-1999 Patrick W Daly
%% Max-Planck-Institut f\"ur Aeronomie
%% Max-Planck-Str. 2
%% D-37191 Katlenburg-Lindau
%% Germany
%% E-mail: daly@linmpi.mpg.de
\NeedsTeXFormat{LaTeX2e}[1995/06/01]
\ProvidesPackage{natbib}
[1999/05/28 7.0 (PWD)]
% This package reimplements the LaTeX \cite command to be used for various
% citation styles, both author-year and numerical. It accepts BibTeX
% output intended for many other packages, and therefore acts as a
% general, all-purpose citation-style interface.
%
% With standard numerical .bst files, only numerical citations are
% possible. With an author-year .bst file, both numerical and
% author-year citations are possible.
%
% If author-year citations are selected, \bibitem must have one of the
% following forms:
% \bibitem[Jones et al.(1990)]{key}...
% \bibitem[Jones et al.(1990)Jones, Baker, and Williams]{key}...
% \bibitem[Jones et al., 1990]{key}...
% \bibitem[\protect\citeauthoryear{Jones, Baker, and Williams}{Jones
% et al.}{1990}]{key}...
% \bibitem[\protect\citeauthoryear{Jones et al.}{1990}]{key}...
% \bibitem[\protect\astroncite{Jones et al.}{1990}]{key}...
% \bibitem[\protect\citename{Jones et al., }1990]{key}...
% \harvarditem[Jones et al.]{Jones, Baker, and Williams}{1990}{key}...
%
% This is either to be made up manually, or to be generated by an
% appropriate .bst file with BibTeX.
% Author-year mode || Numerical mode
% Then, \citet{key} ==>> Jones et al. (1990) || Jones et al. [21]
% \citep{key} ==>> (Jones et al., 1990) || [21]
% Multiple citations as normal:
% \citep{key1,key2} ==>> (Jones et al., 1990; Smith, 1989) || [21,24]
% or (Jones et al., 1990, 1991) || [21,24]
% or (Jones et al., 1990a,b) || [21,24]
% \cite{key} is the equivalent of \citet{key} in author-year mode
% and of \citep{key} in numerical mode
% Full author lists may be forced with \citet* or \citep*, e.g.
% \citep*{key} ==>> (Jones, Baker, and Williams, 1990)
% Optional notes as:
% \citep[chap. 2]{key} ==>> (Jones et al., 1990, chap. 2)
% \citep[e.g.,][]{key} ==>> (e.g., Jones et al., 1990)
% \citep[see][pg. 34]{key}==>> (see Jones et al., 1990, pg. 34)
% (Note: in standard LaTeX, only one note is allowed, after the ref.
% Here, one note is like the standard, two make pre- and post-notes.)
% \citealt{key} ==>> Jones et al. 1990
% \citealt*{key} ==>> Jones, Baker, and Williams 1990
% \citealp{key} ==>> Jones et al., 1990
% \citealp*{key} ==>> Jones, Baker, and Williams, 1990
% Additional citation possibilities (both author-year and numerical modes)
% \citeauthor{key} ==>> Jones et al.
% \citeauthor*{key} ==>> Jones, Baker, and Williams
% \citeyear{key} ==>> 1990
% \citeyearpar{key} ==>> (1990)
% \citetext{priv. comm.} ==>> (priv. comm.)
% Note: full author lists depends on whether the bib style supports them;
% if not, the abbreviated list is printed even when full requested.
%
% For names like della Robbia at the start of a sentence, use
% \Citet{dRob98} ==>> Della Robbia (1998)
% \Citep{dRob98} ==>> (Della Robbia, 1998)
% \Citeauthor{dRob98} ==>> Della Robbia
%
%
% Citation aliasing is achieved with
% \defcitealias{key}{text}
% \citetalias{key} ==>> text
% \citepalias{key} ==>> (text)
%
% Defining the citation style of a given bib style:
% Use \bibpunct (in the preamble only) with 6 mandatory arguments:
% 1. opening bracket for citation
% 2. closing bracket
% 3. citation separator (for multiple citations in one \cite)
% 4. the letter n for numerical styles, s for superscripts
% else anything for author-year
% 5. punctuation between authors and date
% 6. punctuation between years (or numbers) when common authors missing
% One optional argument is the character coming before post-notes. It
% appears in square braces before all other arguments. May be left off.
% Example (and default) \bibpunct[, ]{(}{)}{;}{a}{,}{,}
%
% To make this automatic for a given bib style, named newbib, say, make
% a local configuration file, natbib.cfg, with the definition
% \newcommand{\bibstyle@newbib}{\bibpunct...}
% Then the \bibliographystyle{newbib} will cause \bibstyle@newbib to
% be called on THE NEXT LATEX RUN (via the aux file).
%
% Such preprogrammed definitions may be invoked in the text (preamble only)
% by calling \citestyle{newbib}. This is only useful if the style specified
% differs from that in \bibliographystyle.
%
% With \citeindextrue and \citeindexfalse, one can control whether the
% \cite commands make an automatic entry of the citation in the .idx
% indexing file. For this, \makeindex must also be given in the preamble.
%
% LaTeX2e Options: (for selecting punctuation)
% round - round parentheses are used (default)
% square - square brackets are used [option]
% curly - curly braces are used {option}
% angle - angle brackets are used <option>
% colon - multiple citations separated by colon (default)
% comma - separated by comma
% authoryear - selects author-year citations (default)
% numbers- selects numerical citations
% super - numerical citations as superscripts
% sort - sorts multiple citations according to order in ref. list
% sort&compress - like sort, but also compresses numerical citations
% longnamesfirst - makes first citation full author list
% sectionbib - puts bibliography in a \section* instead of \chapter*
% Punctuation so selected dominates over any predefined ones.
% LaTeX2e options are called as, e.g.
% \usepackage[square,comma]{natbib}
% LaTeX the source file natbib.dtx to obtain more details
% or the file natnotes.tex for a brief reference sheet.
%-----------------------------------------------------------
\@ifclassloaded{aguplus}{\PackageError{natbib}
{The aguplus class already includes natbib coding,\MessageBreak
so you should not add it explicitly}
{Type <Return> for now, but then later remove\MessageBreak
the command \protect\usepackage{natbib} from the document}
\endinput}{}
\@ifclassloaded{nlinproc}{\PackageError{natbib}
{The nlinproc class already includes natbib coding,\MessageBreak
so you should not add it explicitly}
{Type <Return> for now, but then later remove\MessageBreak
the command \protect\usepackage{natbib} from the document}
\endinput}{}
\@ifclassloaded{egs}{\PackageError{natbib}
{The egs class already includes natbib coding,\MessageBreak
so you should not add it explicitly}
{Type <Return> for now, but then later remove\MessageBreak
the command \protect\usepackage{natbib} from the document}
\endinput}{}
% Define citation punctuation for some author-year styles
% One may add and delete at this point
% Or put additions into local configuration file natbib.cfg
\newcommand\bibstyle@chicago{\bibpunct{(}{)}{;}{a}{,}{,}}
\newcommand\bibstyle@named{\bibpunct{[}{]}{;}{a}{,}{,}}
\newcommand\bibstyle@agu{\bibpunct{[}{]}{;}{a}{,}{,~}}%Amer. Geophys. Union
\newcommand\bibstyle@egs{\bibpunct{(}{)}{;}{a}{,}{,}}%Eur. Geophys. Soc.
\newcommand\bibstyle@agsm{\bibpunct{(}{)}{,}{a}{}{,}\gdef\harvardand{\&}}
\newcommand\bibstyle@kluwer{\bibpunct{(}{)}{,}{a}{}{,}\gdef\harvardand{\&}}
\newcommand\bibstyle@dcu{\bibpunct{(}{)}{;}{a}{;}{,}\gdef\harvardand{and}}
\newcommand\bibstyle@aa{\bibpunct{(}{)}{;}{a}{}{,}} %Astronomy & Astrophysics
\newcommand\bibstyle@pass{\bibpunct{(}{)}{;}{a}{,}{,}}%Planet. & Space Sci
\newcommand\bibstyle@anngeo{\bibpunct{(}{)}{;}{a}{,}{,}}%Annales Geophysicae
\newcommand\bibstyle@nlinproc{\bibpunct{(}{)}{;}{a}{,}{,}}%Nonlin.Proc.Geophys.
% Define citation punctuation for some numerical styles
\newcommand\bibstyle@cospar{\bibpunct{/}{/}{,}{n}{}{}%
\gdef\NAT@biblabelnum##1{##1.}}
\newcommand\bibstyle@esa{\bibpunct{(Ref.~}{)}{,}{n}{}{}%
\gdef\NAT@biblabelnum##1{##1.\hspace{1em}}}
\newcommand\bibstyle@nature{\bibpunct{}{}{,}{s}{}{\textsuperscript{,}}%
\gdef\NAT@biblabelnum##1{##1.}}
% The standard LaTeX styles
\newcommand\bibstyle@plain{\bibpunct{[}{]}{,}{n}{}{,}}
\let\bibstyle@alpha=\bibstyle@plain
\let\bibstyle@abbrv=\bibstyle@plain
\let\bibstyle@unsrt=\bibstyle@plain
% The author-year modifications of the standard styles
\newcommand\bibstyle@plainnat{\bibpunct{[}{]}{,}{a}{,}{,}}
\let\bibstyle@abbrvnat=\bibstyle@plainnat
\let\bibstyle@unsrtnat=\bibstyle@plainnat
\newif\ifNAT@numbers \NAT@numbersfalse
\newif\ifNAT@super \NAT@superfalse
\DeclareOption{numbers}{\NAT@numberstrue
\ExecuteOptions{square,comma,nobibstyle}}
\DeclareOption{super}{\NAT@supertrue\NAT@numberstrue
\renewcommand\NAT@open{}\renewcommand\NAT@close{}
\ExecuteOptions{nobibstyle}}
\DeclareOption{authoryear}{\NAT@numbersfalse
\ExecuteOptions{round,colon,bibstyle}}
\DeclareOption{round}{%
\renewcommand\NAT@open{(} \renewcommand\NAT@close{)}
\ExecuteOptions{nobibstyle}}
\DeclareOption{square}{%
\renewcommand\NAT@open{[} \renewcommand\NAT@close{]}
\ExecuteOptions{nobibstyle}}
\DeclareOption{angle}{%
\renewcommand\NAT@open{$<$} \renewcommand\NAT@close{$>$}
\ExecuteOptions{nobibstyle}}
\DeclareOption{curly}{%
\renewcommand\NAT@open{\{} \renewcommand\NAT@close{\}}
\ExecuteOptions{nobibstyle}}
\DeclareOption{comma}{\renewcommand\NAT@sep{,}
\ExecuteOptions{nobibstyle}}
\DeclareOption{colon}{\renewcommand\NAT@sep{;}
\ExecuteOptions{nobibstyle}}
\DeclareOption{nobibstyle}{\let\bibstyle=\@gobble}
\DeclareOption{bibstyle}{\let\bibstyle=\@citestyle}
\newif\ifNAT@openbib \NAT@openbibfalse
\DeclareOption{openbib}{\NAT@openbibtrue}
\DeclareOption{sectionbib}{\def\NAT@sectionbib{on}}
\def\NAT@sort{0}
\DeclareOption{sort}{\def\NAT@sort{1}}
\DeclareOption{sort&compress}{\def\NAT@sort{2}}
\@ifpackageloaded{cite}{\PackageWarningNoLine{natbib}
{The `cite' package should not be used\MessageBreak
with natbib. Use option `sort' instead}\ExecuteOptions{sort}}{}
\newif\ifNAT@longnames\NAT@longnamesfalse
\DeclareOption{longnamesfirst}{\NAT@longnamestrue}
\DeclareOption{nonamebreak}{\def\NAT@nmfmt#1{\mbox{\NAT@up#1}}}
\def\NAT@nmfmt#1{{\NAT@up#1}}
\renewcommand\bibstyle[1]{\@ifundefined{bibstyle@#1}{\relax}
{\csname bibstyle@#1\endcsname}}
\AtBeginDocument{\global\let\bibstyle=\@gobble}
\let\@citestyle\bibstyle
\newcommand\citestyle[1]{\@citestyle{#1}\let\bibstyle\@gobble}
\@onlypreamble{\citestyle}\@onlypreamble{\@citestyle}
\newcommand\bibpunct[7][, ]%
{\gdef\NAT@open{#2}\gdef\NAT@close{#3}\gdef
\NAT@sep{#4}\global\NAT@numbersfalse\ifx #5n\global\NAT@numberstrue
\else
\ifx #5s\global\NAT@numberstrue\global\NAT@supertrue
\fi\fi
\gdef\NAT@aysep{#6}\gdef\NAT@yrsep{#7}%
\gdef\NAT@cmt{#1}%
\global\let\bibstyle\@gobble
}
\@onlypreamble{\bibpunct}
\newcommand\NAT@open{(} \newcommand\NAT@close{)}
\newcommand\NAT@sep{;}
\ProcessOptions
\newcommand\NAT@aysep{,} \newcommand\NAT@yrsep{,}
\newcommand\NAT@cmt{, }
\newcommand\NAT@cite%
[3]{\ifNAT@swa\NAT@@open\if*#2*\else#2\ \fi
#1\if*#3*\else\NAT@cmt#3\fi\NAT@@close\else#1\fi\endgroup}
\newcommand\NAT@citenum%
[3]{\ifNAT@swa\NAT@@open\if*#2*\else#2\ \fi
#1\if*#3*\else\NAT@cmt#3\fi\NAT@@close\else#1\fi\endgroup}
\newcommand\NAT@citesuper[3]{\ifNAT@swa
\unskip\hspace{1\p@}\textsuperscript{#1}%
\if*#3*\else\ (#3)\fi\else #1\fi\endgroup}
\providecommand
\textsuperscript[1]{\mbox{$^{\mbox{\scriptsize#1}}$}}
\providecommand\@firstofone[1]{#1}
\newcommand\NAT@citexnum{}
\def\NAT@citexnum[#1][#2]#3{%
\NAT@sort@cites{#3}%
\let\@citea\@empty
\@cite{\def\NAT@num{-1}\let\NAT@last@yr\relax\let\NAT@nm\@empty
\@for\@citeb:=\NAT@cite@list\do
{\edef\@citeb{\expandafter\@firstofone\@citeb}%
\if@filesw\immediate\write\@auxout{\string\citation{\@citeb}}\fi
\@ifundefined{b@\@citeb\@extra@b@citeb}{%
{\reset@font\bfseries?}
\NAT@citeundefined\PackageWarning{natbib}%
{Citation `\@citeb' on page \thepage \space undefined}}%
{\let\NAT@last@num\NAT@num\let\NAT@last@nm\NAT@nm
\NAT@parse{\@citeb}%
\ifNAT@longnames\@ifundefined{bv@\@citeb\@extra@b@citeb}{%
\let\NAT@name=\NAT@all@names
\global\@namedef{bv@\@citeb\@extra@b@citeb}{}}{}%
\fi
\ifNAT@full\let\NAT@nm\NAT@all@names\else
\let\NAT@nm\NAT@name\fi
\ifNAT@swa
\ifnum\NAT@ctype>1\relax\@citea
\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\ifnum\NAT@ctype=2\relax\NAT@test{\NAT@ctype}%
\else\NAT@alias
\fi\hyper@natlinkend\else
\ifnum\NAT@sort>1
\begingroup\catcode`\_=8
\ifcat _\ifnum\z@<0\NAT@num _\else A\fi
\global\let\NAT@nm=\NAT@num \else \gdef\NAT@nm{-2}\fi
\ifcat _\ifnum\z@<0\NAT@last@num _\else A\fi
\global\@tempcnta=\NAT@last@num \global\advance\@tempcnta by\@ne
\else \global\@tempcnta\m@ne\fi
\endgroup
\ifnum\NAT@nm=\@tempcnta
\ifx\NAT@last@yr\relax
\edef\NAT@last@yr{\@citea \mbox{\noexpand\citenumfont\NAT@num}}%
\else
\edef\NAT@last@yr{--\penalty\@m\mbox{\noexpand\citenumfont\NAT@num}}%
\fi
\else
\NAT@last@yr \@citea \mbox{\citenumfont\NAT@num}%
\let\NAT@last@yr\relax
\fi
\else
\@citea \mbox{\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
{\citenumfont\NAT@num}\hyper@natlinkend}%
\fi
\fi
\def\@citea{\NAT@sep\penalty\@m\NAT@space}%
\else
\ifcase\NAT@ctype\relax
\ifx\NAT@last@nm\NAT@nm \NAT@yrsep\penalty\@m\NAT@space\else
\@citea \NAT@test{1}\ \NAT@@open
\if*#1*\else#1\ \fi\fi \NAT@mbox{%
\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
{\citenumfont\NAT@num}\hyper@natlinkend}%
\def\@citea{\NAT@@close\NAT@sep\penalty\@m\ }%
\or\@citea
\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@test{\NAT@ctype}\hyper@natlinkend
\def\@citea{\NAT@sep\penalty\@m\ }%
\or\@citea
\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@test{\NAT@ctype}\hyper@natlinkend
\def\@citea{\NAT@sep\penalty\@m\ }%
\or\@citea
\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@alias\hyper@natlinkend
\def\@citea{\NAT@sep\penalty\@m\ }%
\fi
\fi
}}%
\ifnum\NAT@sort>1\relax\NAT@last@yr\fi
\ifNAT@swa\else\ifnum\NAT@ctype=0\if*#2*\else
\NAT@cmt#2\fi \NAT@@close\fi\fi}{#1}{#2}}
\newcommand\NAT@test[1]{\ifnum#1=1 \ifx\NAT@nm\NAT@noname
{\reset@font\bfseries(author?)}\PackageWarning{natbib}
{Author undefined for citation`\@citeb'
\MessageBreak
on page \thepage}\else \NAT@nm \fi
\else \if\relax\NAT@date\relax
{\reset@font\bfseries(year?)}\PackageWarning{natbib}
{Year undefined for citation`\@citeb'
\MessageBreak
on page \thepage}\else \NAT@date \fi \fi}
\let\citenumfont=\relax
\newcommand\NAT@citex{}
\def\NAT@citex%
[#1][#2]#3{%
\NAT@sort@cites{#3}%
\let\@citea\@empty
\@cite{\let\NAT@nm\@empty\let\NAT@year\@empty
\@for\@citeb:=\NAT@cite@list\do
{\edef\@citeb{\expandafter\@firstofone\@citeb}%
\if@filesw\immediate\write\@auxout{\string\citation{\@citeb}}\fi
\@ifundefined{b@\@citeb\@extra@b@citeb}{\@citea%
{\reset@font\bfseries ?}\NAT@citeundefined
\PackageWarning{natbib}%
{Citation `\@citeb' on page \thepage \space undefined}\def\NAT@date{}}%
{\let\NAT@last@nm=\NAT@nm\let\NAT@last@yr=\NAT@year
\NAT@parse{\@citeb}%
\ifNAT@longnames\@ifundefined{bv@\@citeb\@extra@b@citeb}{%
\let\NAT@name=\NAT@all@names
\global\@namedef{bv@\@citeb\@extra@b@citeb}{}}{}%
\fi
\ifNAT@full\let\NAT@nm\NAT@all@names\else
\let\NAT@nm\NAT@name\fi
\ifNAT@swa\ifcase\NAT@ctype
\if\relax\NAT@date\relax
\@citea\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@nmfmt{\NAT@nm}\NAT@date\hyper@natlinkend
\else
\ifx\NAT@last@nm\NAT@nm\NAT@yrsep
\ifx\NAT@last@yr\NAT@year
\hyper@natlinkstart{\@citeb\@extra@b@citeb}\NAT@exlab
\hyper@natlinkend
\else\unskip\
\hyper@natlinkstart{\@citeb\@extra@b@citeb}\NAT@date
\hyper@natlinkend
\fi
\else\@citea\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@nmfmt{\NAT@nm}%
\hyper@natlinkbreak{\NAT@aysep\ }{\@citeb\@extra@b@citeb}%
\NAT@date\hyper@natlinkend
\fi
\fi
\or\@citea\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@nmfmt{\NAT@nm}\hyper@natlinkend
\or\@citea\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@date\hyper@natlinkend
\or\@citea\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@alias\hyper@natlinkend
\fi \def\@citea{\NAT@sep\ }%
\else\ifcase\NAT@ctype
\if\relax\NAT@date\relax
\@citea\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@nmfmt{\NAT@nm}\hyper@natlinkend
\else
\ifx\NAT@last@nm\NAT@nm\NAT@yrsep
\ifx\NAT@last@yr\NAT@year
\hyper@natlinkstart{\@citeb\@extra@b@citeb}\NAT@exlab
\hyper@natlinkend
\else\unskip\
\hyper@natlinkstart{\@citeb\@extra@b@citeb}\NAT@date
\hyper@natlinkend
\fi
\else\@citea\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@nmfmt{\NAT@nm}%
\hyper@natlinkbreak{\ \NAT@@open\if*#1*\else#1\ \fi}%
{\@citeb\@extra@b@citeb}%
\NAT@date\hyper@natlinkend\fi
\fi
\or\@citea\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@nmfmt{\NAT@nm}\hyper@natlinkend
\or\@citea\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@date\hyper@natlinkend
\or\@citea\hyper@natlinkstart{\@citeb\@extra@b@citeb}%
\NAT@alias\hyper@natlinkend
\fi \if\relax\NAT@date\relax\def\@citea{\NAT@sep\ }%
\else\def\@citea{\NAT@@close\NAT@sep\ }\fi
\fi
}}\ifNAT@swa\else\if*#2*\else\NAT@cmt#2\fi
\if\relax\NAT@date\relax\else\NAT@@close\fi\fi}{#1}{#2}}
\newif\ifNAT@par \NAT@partrue
\newcommand\NAT@@open{\ifNAT@par\NAT@open\fi}
\newcommand\NAT@@close{\ifNAT@par\NAT@close\fi}
\newcommand\NAT@alias{\@ifundefined{al@\@citeb\@extra@b@citeb}{%
{\reset@font\bfseries(alias?)}\PackageWarning{natbib}
{Alias undefined for citation `\@citeb'
\MessageBreak on page \thepage}}{\@nameuse{al@\@citeb\@extra@b@citeb}}}
\let\NAT@up\relax
\newcommand\NAT@Up[1]{{\let\protect\@unexpandable@protect\let~\relax
\expandafter\NAT@deftemp#1}\expandafter\NAT@UP\NAT@temp}
\newcommand\NAT@deftemp[1]{\xdef\NAT@temp{#1}}
\newcommand\NAT@UP[1]{\let\@tempa\NAT@UP\ifcat a#1\MakeUppercase{#1}%
\let\@tempa\relax\else#1\fi\@tempa}
\newcommand\shortcites[1]{%
\@bsphack\@for\@citeb:=#1\do
{\edef\@citeb{\expandafter\@firstofone\@citeb}%
\global\@namedef{bv@\@citeb\@extra@b@citeb}{}}\@esphack}
\newcommand\NAT@biblabel[1]{\hfill}
\newcommand\NAT@biblabelnum[1]{\bibnumfmt{#1}}
\newcommand\bibnumfmt[1]{[#1]}
\def\@tempa#1{[#1]}
\ifx\@tempa\@biblabel\let\@biblabel\@empty\fi
\newcommand\NAT@bibsetnum[1]{\settowidth\labelwidth{\@biblabel{#1}}%
\setlength{\leftmargin}{\labelwidth}\addtolength{\leftmargin}{\labelsep}%
\setlength{\itemsep}{\bibsep}\setlength{\parsep}{\z@}%
\ifNAT@openbib
\addtolength{\leftmargin}{\bibindent}%
\setlength{\itemindent}{-\bibindent}%
\setlength{\listparindent}{\itemindent}%
\setlength{\parsep}{0pt}%
\fi
}
\newlength{\bibhang}
\setlength{\bibhang}{1em}
\newlength{\bibsep}
{\@listi \global\bibsep\itemsep \global\advance\bibsep by\parsep}
\newcommand\NAT@bibsetup%
[1]{\setlength{\leftmargin}{\bibhang}\setlength{\itemindent}{-\leftmargin}%
\setlength{\itemsep}{\bibsep}\setlength{\parsep}{\z@}}
\newcommand\NAT@set@cites{\ifNAT@numbers
\ifNAT@super \let\@cite\NAT@citesuper
\def\NAT@mbox##1{\unskip\nobreak\hspace{1\p@}\textsuperscript{##1}}%
\let\citeyearpar=\citeyear
\let\NAT@space\relax\else
\let\NAT@mbox=\mbox
\let\@cite\NAT@citenum \def\NAT@space{ }\fi
\let\@citex\NAT@citexnum
\ifx\@biblabel\@empty\let\@biblabel\NAT@biblabelnum\fi
\let\@bibsetup\NAT@bibsetnum
\def\natexlab##1{}%
\else
\let\@cite\NAT@cite
\let\@citex\NAT@citex
\let\@biblabel\NAT@biblabel
\let\@bibsetup\NAT@bibsetup
\def\natexlab##1{##1}%
\fi}
\AtBeginDocument{\NAT@set@cites}
\AtBeginDocument{\ifx\SK@def\@undefined\else
\ifx\SK@cite\@empty\else
\SK@def\@citex[#1][#2]#3{\SK@\SK@@ref{#3}\SK@@citex[#1][#2]{#3}}\fi
\ifx\SK@citeauthor\@undefined\def\HAR@checkdef{}\else
\let\citeauthor\SK@citeauthor
\let\citefullauthor\SK@citefullauthor
\let\citeyear\SK@citeyear\fi
\fi}
\AtBeginDocument{\@ifpackageloaded{hyperref}{%
\ifnum\NAT@sort=2\def\NAT@sort{1}\fi}{}}
\newif\ifNAT@full\NAT@fullfalse
\newif\ifNAT@swa
\DeclareRobustCommand\citet
{\begingroup\NAT@swafalse\def\NAT@ctype{0}\NAT@partrue
\@ifstar{\NAT@fulltrue\NAT@citetp}{\NAT@fullfalse\NAT@citetp}}
\newcommand\NAT@citetp{\@ifnextchar[{\NAT@@citetp}{\NAT@@citetp[]}}
\newcommand\NAT@@citetp{}
\def\NAT@@citetp[#1]{\@ifnextchar[{\@citex[#1]}{\@citex[][#1]}}
\DeclareRobustCommand\citep
{\begingroup\NAT@swatrue\def\NAT@ctype{0}\NAT@partrue
\@ifstar{\NAT@fulltrue\NAT@citetp}{\NAT@fullfalse\NAT@citetp}}
\DeclareRobustCommand\cite
{\begingroup\def\NAT@ctype{0}\NAT@partrue\NAT@swatrue
\@ifstar{\NAT@fulltrue\NAT@cites}{\NAT@fullfalse\NAT@cites}}
\newcommand\NAT@cites{\@ifnextchar [{\NAT@@citetp}{%
\ifNAT@numbers\else
\NAT@swafalse
\fi
\NAT@@citetp[]}}
\DeclareRobustCommand\citealt
{\begingroup\NAT@swafalse\def\NAT@ctype{0}\NAT@parfalse
\@ifstar{\NAT@fulltrue\NAT@citetp}{\NAT@fullfalse\NAT@citetp}}
\DeclareRobustCommand\citealp
{\begingroup\NAT@swatrue\def\NAT@ctype{0}\NAT@parfalse
\@ifstar{\NAT@fulltrue\NAT@citetp}{\NAT@fullfalse\NAT@citetp}}
\DeclareRobustCommand\citeauthor
{\begingroup\NAT@swafalse\def\NAT@ctype{1}\NAT@parfalse
\@ifstar{\NAT@fulltrue\NAT@citetp}{\NAT@fullfalse\NAT@citetp}}
\DeclareRobustCommand\Citet
{\begingroup\NAT@swafalse\def\NAT@ctype{0}\NAT@partrue
\let\NAT@up\NAT@Up
\@ifstar{\NAT@fulltrue\NAT@citetp}{\NAT@fullfalse\NAT@citetp}}
\DeclareRobustCommand\Citep
{\begingroup\NAT@swatrue\def\NAT@ctype{0}\NAT@partrue
\let\NAT@up\NAT@Up
\@ifstar{\NAT@fulltrue\NAT@citetp}{\NAT@fullfalse\NAT@citetp}}
\DeclareRobustCommand\Citealt
{\begingroup\NAT@swafalse\def\NAT@ctype{0}\NAT@parfalse
\let\NAT@up\NAT@Up
\@ifstar{\NAT@fulltrue\NAT@citetp}{\NAT@fullfalse\NAT@citetp}}
\DeclareRobustCommand\Citealp
{\begingroup\NAT@swatrue\def\NAT@ctype{0}\NAT@parfalse
\let\NAT@up\NAT@Up
\@ifstar{\NAT@fulltrue\NAT@citetp}{\NAT@fullfalse\NAT@citetp}}
\DeclareRobustCommand\Citeauthor
{\begingroup\NAT@swafalse\def\NAT@ctype{1}\NAT@parfalse
\let\NAT@up\NAT@Up
\@ifstar{\NAT@fulltrue\NAT@citetp}{\NAT@fullfalse\NAT@citetp}}
\DeclareRobustCommand\citeyear
{\begingroup\NAT@swafalse\def\NAT@ctype{2}\NAT@parfalse\NAT@citetp}
\DeclareRobustCommand\citeyearpar
{\begingroup\NAT@swatrue\def\NAT@ctype{2}\NAT@partrue\NAT@citetp}
\newcommand\citetext[1]{\NAT@open#1\NAT@close}
\DeclareRobustCommand\citefullauthor
{\citeauthor*}
\newcommand\defcitealias[2]{%
\@ifundefined{al@#1\@extra@b@citeb}{}
{\PackageWarning{natbib}{Overwriting existing alias for citation #1}}
\@namedef{al@#1\@extra@b@citeb}{#2}}
\DeclareRobustCommand\citetalias{\begingroup
\NAT@swafalse\def\NAT@ctype{3}\NAT@parfalse\NAT@citetp}
\DeclareRobustCommand\citepalias{\begingroup
\NAT@swatrue\def\NAT@ctype{3}\NAT@partrue\NAT@citetp}
\renewcommand\nocite[1]{\@bsphack
\@for\@citeb:=#1\do{%
\edef\@citeb{\expandafter\@firstofone\@citeb}%
\if@filesw\immediate\write\@auxout{\string\citation{\@citeb}}\fi
\if*\@citeb\else
\@ifundefined{b@\@citeb\@extra@b@citeb}{%
\NAT@citeundefined \PackageWarning{natbib}%
{Citation `\@citeb' undefined}}{}\fi}%
\@esphack}
\newcommand\NAT@parse[1]{{%
\let\protect=\@unexpandable@protect\let~\relax
\let\active@prefix=\@gobble
\xdef\NAT@temp{\csname b@#1\@extra@b@citeb\endcsname}}%
\expandafter\NAT@split\NAT@temp
\expandafter\NAT@parse@date\NAT@date??????@@%
\ifciteindex\NAT@index\fi
}
\newcommand\NAT@split[4]{%
\gdef\NAT@num{#1}\gdef\NAT@name{#3}\gdef\NAT@date{#2}%
\gdef\NAT@all@names{#4}%
\ifx\NAT@noname\NAT@all@names \gdef\NAT@all@names{#3}\fi}
\newcommand\NAT@parse@date{}
\def\NAT@parse@date#1#2#3#4#5#6@@{%
\ifnum\the\catcode`#1=11\def\NAT@year{}\def\NAT@exlab{#1}\else
\ifnum\the\catcode`#2=11\def\NAT@year{#1}\def\NAT@exlab{#2}\else
\ifnum\the\catcode`#3=11\def\NAT@year{#1#2}\def\NAT@exlab{#3}\else
\ifnum\the\catcode`#4=11\def\NAT@year{#1#2#3}\def\NAT@exlab{#4}\else
\def\NAT@year{#1#2#3#4}\def\NAT@exlab{{#5}}\fi\fi\fi\fi}
\newcommand\NAT@index{}
\let\NAT@makeindex=\makeindex
\renewcommand\makeindex{\NAT@makeindex
\renewcommand\NAT@index{\@bsphack\begingroup
\def~{\string~}\@wrindex{\NAT@idxtxt}}}
\newcommand\NAT@idxtxt{\NAT@name\ \NAT@open\NAT@date\NAT@close}
\@ifundefined{@indexfile}{}{\let\NAT@makeindex\relax\makeindex}
\newif\ifciteindex \citeindexfalse
\newcommand\citeindextype{default}
\newcommand\NAT@index@alt{{\let\protect=\noexpand\let~\relax
\xdef\NAT@temp{\NAT@idxtxt}}\expandafter\NAT@exp\NAT@temp\@nil}
\newcommand\NAT@exp{}
\def\NAT@exp#1\@nil{\index[\citeindextype]{#1}}
\AtBeginDocument{%
\@ifpackageloaded{index}{\let\NAT@index=\NAT@index@alt}{}}
\newcommand\NAT@ifcmd{\futurelet\NAT@temp\NAT@ifxcmd}
\newcommand\NAT@ifxcmd{\ifx\NAT@temp\relax\else\expandafter\NAT@bare\fi}
\def\NAT@bare#1(#2)#3(@)#4\@nil#5{%
\if @#2
\expandafter\NAT@apalk#1, , \@nil{#5}\else
\stepcounter{NAT@ctr}%
\NAT@wrout{\arabic {NAT@ctr}}{#2}{#1}{#3}{#5}
\fi
}
\newcommand\NAT@wrout[5]{%
\if@filesw
{\let\protect\noexpand\let~\relax
\immediate
\write\@auxout{\string\bibcite{#5}{{#1}{#2}{{#3}}{{#4}}}}}\fi
\ignorespaces}
\def\NAT@noname{{}}
\renewcommand\bibitem{%
\@ifnextchar[{\@lbibitem}{%
\global\NAT@stdbsttrue
\stepcounter{NAT@ctr}\@lbibitem[\arabic{NAT@ctr}]}}
\def\@lbibitem[#1]#2{%
\if\relax\@extra@b@citeb\relax\else
\@ifundefined{br@#2\@extra@b@citeb}{}{%
\@namedef{br@#2}{\@nameuse{br@#2\@extra@b@citeb}}}\fi
\@ifundefined{b@#2\@extra@b@citeb}{\def\NAT@num{}}{\NAT@parse{#2}}%
\item[\hfil\hyper@natanchorstart{#2\@extra@b@citeb}\@biblabel{\NAT@num}%
\hyper@natanchorend]%
\NAT@ifcmd#1(@)(@)\@nil{#2}}
\ifx\SK@lbibitem\@undefined\else
\let\SK@lbibitem\@lbibitem
\def\@lbibitem[#1]#2{%
\SK@lbibitem[#1]{#2}\SK@\SK@@label{#2}\ignorespaces}\fi
\newif\ifNAT@stdbst \NAT@stdbstfalse
\AtEndDocument
{\ifNAT@stdbst\if@filesw\immediate\write\@auxout{\string
\global\string\NAT@numberstrue}\fi\fi
}
\providecommand\bibcite{}
\renewcommand\bibcite[2]{\@ifundefined{b@#1\@extra@binfo}\relax
{\NAT@citemultiple
\PackageWarningNoLine{natbib}{Citation `#1' multiply defined}}%
\global\@namedef{b@#1\@extra@binfo}{#2}}
\AtEndDocument{\NAT@swatrue\let\bibcite\NAT@testdef}
\newcommand\NAT@testdef[2]{%
\def\NAT@temp{#2}\expandafter \ifx \csname b@#1\@extra@binfo\endcsname
\NAT@temp \else \ifNAT@swa \NAT@swafalse
\PackageWarningNoLine{natbib}{Citation(s) may have
changed.\MessageBreak
Rerun to get citations correct}\fi\fi}
\newcommand\NAT@apalk{}
\def\NAT@apalk#1, #2, #3\@nil#4{\if\relax#2\relax
\global\NAT@stdbsttrue
\NAT@wrout{#1}{}{}{}{#4}\else
\stepcounter{NAT@ctr}%
\NAT@wrout{\arabic {NAT@ctr}}{#2}{#1}{}{#4}\fi}
\newcommand\citeauthoryear{}
\def\citeauthoryear#1#2#3(@)(@)\@nil#4{\stepcounter{NAT@ctr}\if\relax#3\relax
\NAT@wrout{\arabic {NAT@ctr}}{#2}{#1}{}{#4}\else
\NAT@wrout{\arabic {NAT@ctr}}{#3}{#2}{#1}{#4}\fi}
\newcommand\citestarts{\NAT@open}
\newcommand\citeends{\NAT@close}
\newcommand\betweenauthors{and}
\newcommand\astroncite{}
\def\astroncite#1#2(@)(@)\@nil#3{\stepcounter{NAT@ctr}\NAT@wrout{\arabic
{NAT@ctr}}{#2}{#1}{}{#3}}
\newcommand\citename{}
\def\citename#1#2(@)(@)\@nil#3{\expandafter\NAT@apalk#1#2, \@nil{#3}}
\newcommand\harvarditem[4][]%
{\if\relax#1\relax\bibitem[#2(#3)]{#4}\else
\bibitem[#1(#3)#2]{#4}\fi }
\newcommand\harvardleft{\NAT@open}
\newcommand\harvardright{\NAT@close}
\newcommand\harvardyearleft{\NAT@open}
\newcommand\harvardyearright{\NAT@close}
\AtBeginDocument{\providecommand{\harvardand}{and}}
\newcommand\harvardurl[1]{\textbf{URL:} \textit{#1}}
\providecommand\bibsection{}
\@ifundefined{chapter}%
{\renewcommand\bibsection{\section*{\refname
\@mkboth{\MakeUppercase{\refname}}{\MakeUppercase{\refname}}}}}
{\@ifundefined{NAT@sectionbib}%
{\renewcommand\bibsection{\chapter*{\bibname
\@mkboth{\MakeUppercase{\bibname}}{\MakeUppercase{\bibname}}}}}
{\renewcommand\bibsection{\section*{\bibname
\ifx\@mkboth\@gobbletwo\else\markright{\MakeUppercase{\bibname}}\fi}}}}
\@ifclassloaded{amsart}%
{\renewcommand\bibsection{\section*{\refname}}}{}
\@ifclassloaded{amsbook}%
{\renewcommand\bibsection{\chapter*{\bibname}}}{}
\@ifundefined{bib@heading}{}{\let\bibsection\bib@heading}
\newcounter{NAT@ctr}
\renewenvironment{thebibliography}[1]{%
\bibsection\parindent \z@\bibpreamble\bibfont\list
{\@biblabel{\arabic{NAT@ctr}}}{\@bibsetup{#1}%
\setcounter{NAT@ctr}{0}}%
\ifNAT@openbib
\renewcommand\newblock{\par}
\else
\renewcommand\newblock{\hskip .11em \@plus.33em \@minus.07em}%
\fi
\sloppy\clubpenalty4000\widowpenalty4000
\sfcode`\.=1000\relax
\let\citeN\cite \let\shortcite\cite
\let\citeasnoun\cite
}{\def\@noitemerr{%
\PackageWarning{natbib}
{Empty `thebibliography' environment}}%
\endlist\vskip-\lastskip}
\let\bibfont\relax
\let\bibpreamble\relax
\providecommand\reset@font{\relax}
\providecommand\bibname{Bibliography}
\providecommand\refname{References}
\newcommand\NAT@citeundefined{\gdef \NAT@undefined {%
\PackageWarningNoLine{natbib}{There were undefined citations}}}
\let \NAT@undefined \relax
\newcommand\NAT@citemultiple{\gdef \NAT@multiple {%
\PackageWarningNoLine{natbib}{There were multiply defined citations}}}
\let \NAT@multiple \relax
\AtEndDocument{\NAT@undefined\NAT@multiple}
\providecommand\@mkboth[2]{}
\providecommand\MakeUppercase{\uppercase}
\providecommand{\@extra@b@citeb}{}
\gdef\@extra@binfo{}
\providecommand\hyper@natanchorstart[1]{}
\providecommand\hyper@natanchorend{}
\providecommand\hyper@natlinkstart[1]{}
\providecommand\hyper@natlinkend{}
\providecommand\hyper@natlinkbreak[2]{#1}
\@ifundefined{bbl@redefine}{}{%
\bbl@redefine\nocite#1{%
\@safe@activestrue\org@nocite{#1}\@safe@activesfalse}%
\bbl@redefine\@lbibitem[#1]#2{%
\@safe@activestrue\org@@lbibitem[#1]{#2}\@safe@activesfalse}%
}
\AtBeginDocument{\@ifundefined{bbl@redefine}{}{%
\bbl@redefine\@citex[#1][#2]#3{%
\@safe@activestrue\org@@citex[#1][#2]{#3}\@safe@activesfalse}%
\bbl@redefine\NAT@testdef#1#2{%
\@safe@activestrue\org@NAT@testdef{#1}{#2}\@safe@activesfalse}%
\@ifundefined{org@@lbibitem}{%
\bbl@redefine\@lbibitem[#1]#2{%
\@safe@activestrue\org@@lbibitem[#1]{#2}\@safe@activesfalse}}{}%
}}
\ifnum\NAT@sort>0
\newcommand\NAT@sort@cites[1]{%
\@tempcntb\m@ne
\let\@celt\delimiter
\def\NAT@num@list{}%
\def\NAT@cite@list{}%
\def\NAT@nonsort@list{}%
\@for \@citeb:=#1\do{\NAT@make@cite@list}%
\edef\NAT@cite@list{\NAT@cite@list\NAT@nonsort@list}%
\edef\NAT@cite@list{\expandafter\NAT@xcom\NAT@cite@list @@}}
\begingroup \catcode`\_=8
\gdef\NAT@make@cite@list{%
\edef\@citeb{\expandafter\@firstofone\@citeb}%
\@ifundefined{b@\@citeb\@extra@b@citeb}{\def\NAT@num{A}}%
{\NAT@parse{\@citeb}}%
\ifcat _\ifnum\z@<0\NAT@num _\else A\fi
\@tempcnta\NAT@num \relax
\ifnum \@tempcnta>\@tempcntb
\edef\NAT@num@list{\NAT@num@list \@celt{\NAT@num}}%
\edef\NAT@cite@list{\NAT@cite@list\@citeb,}%
\@tempcntb\@tempcnta
\else
\let\NAT@@cite@list=\NAT@cite@list \def\NAT@cite@list{}%
\edef\NAT@num@list{\expandafter\NAT@num@celt \NAT@num@list \@gobble @}%
{\let\@celt=\NAT@celt\NAT@num@list}%
\fi
\else
\edef\NAT@nonsort@list{\NAT@nonsort@list\@citeb,}%
\fi}
\endgroup
\def\NAT@celt#1{\ifnum #1<\@tempcnta
\xdef\NAT@cite@list{\NAT@cite@list\expandafter\NAT@nextc\NAT@@cite@list @@}%
\xdef\NAT@@cite@list{\expandafter\NAT@restc\NAT@@cite@list}%
\else
\xdef\NAT@cite@list{\NAT@cite@list\@citeb,\NAT@@cite@list}\let\@celt\@gobble%
\fi}
\def\NAT@num@celt#1#2{\ifx \@celt #1%
\ifnum #2<\@tempcnta
\@celt{#2}%
\expandafter\expandafter\expandafter\NAT@num@celt
\else
\@celt{\number\@tempcnta}\@celt{#2}%
\fi\fi}
\def\NAT@nextc#1,#2@@{#1,}
\def\NAT@restc#1,#2{#2}
\def\NAT@xcom#1,@@{#1}
\else
\newcommand\NAT@sort@cites[1]{\edef\NAT@cite@list{#1}}\fi
\InputIfFileExists{natbib.cfg}
{\typeout{Local config file natbib.cfg used}}{}
%%
%% <<<<< End of generated file <<<<<<
%%
%% End of file `natbib.sty'.

@ -0,0 +1,134 @@
%%
%% This is file `nicefrac.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% units.dtx (with options: `nicefrac')
%%
%% LaTeX package for typesetting nice fractions
%%
%% Copyright (C) 1998 Axel Reichert
%% See the files README and COPYING.
%%
%% \CharacterTable
%% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
%% Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
%% Digits \0\1\2\3\4\5\6\7\8\9
%% Exclamation \! Double quote \" Hash (number) \#
%% Dollar \$ Percent \% Ampersand \&
%% Acute accent \' Left paren \( Right paren \)
%% Asterisk \* Plus \+ Comma \,
%% Minus \- Point \. Solidus \/
%% Colon \: Semicolon \; Less than \<
%% Equals \= Greater than \> Question mark \?
%% Commercial at \@ Left bracket \[ Backslash \\
%% Right bracket \] Circumflex \^ Underscore \_
%% Grave accent \` Left brace \{ Vertical bar \|
%% Right brace \} Tilde \~}
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesPackage{nicefrac}[1998/08/04 v0.9b Nice fractions]
\newlength{\L@UnitsRaiseDisplaystyle}
\newlength{\L@UnitsRaiseTextstyle}
\newlength{\L@UnitsRaiseScriptstyle}
\RequirePackage{ifthen}
\DeclareRobustCommand*{\@UnitsNiceFrac}[3][]{%
\ifthenelse{\boolean{mmode}}{%
\settoheight{\L@UnitsRaiseDisplaystyle}{%
\ensuremath{\displaystyle#1{M}}%
}%
\settoheight{\L@UnitsRaiseTextstyle}{%
\ensuremath{\textstyle#1{M}}%
}%
\settoheight{\L@UnitsRaiseScriptstyle}{%
\ensuremath{\scriptstyle#1{M}}%
}%
\settoheight{\@tempdima}{%
\ensuremath{\scriptscriptstyle#1{M}}%
}%
\addtolength{\L@UnitsRaiseDisplaystyle}{%
-\L@UnitsRaiseScriptstyle%
}%
\addtolength{\L@UnitsRaiseTextstyle}{%
-\L@UnitsRaiseScriptstyle%
}%
\addtolength{\L@UnitsRaiseScriptstyle}{-\@tempdima}%
\mathchoice
{%
\raisebox{\L@UnitsRaiseDisplaystyle}{%
\ensuremath{\scriptstyle#1{#2}}%
}%
}%
{%
\raisebox{\L@UnitsRaiseTextstyle}{%
\ensuremath{\scriptstyle#1{#2}}%
}%
}%
{%
\raisebox{\L@UnitsRaiseScriptstyle}{%
\ensuremath{\scriptscriptstyle#1{#2}}%
}%
}%
{%
\raisebox{\L@UnitsRaiseScriptstyle}{%
\ensuremath{\scriptscriptstyle#1{#2}}%
}%
}%
\mkern-2mu/\mkern-1mu%
\bgroup
\mathchoice
{\scriptstyle}%
{\scriptstyle}%
{\scriptscriptstyle}%
{\scriptscriptstyle}%
#1{#3}%
\egroup
}%
{%
\settoheight{\L@UnitsRaiseTextstyle}{#1{M}}%
\settoheight{\@tempdima}{%
\ensuremath{%
\mbox{\fontsize\sf@size\z@\selectfont#1{M}}%
}%
}%
\addtolength{\L@UnitsRaiseTextstyle}{-\@tempdima}%
\raisebox{\L@UnitsRaiseTextstyle}{%
\ensuremath{%
\mbox{\fontsize\sf@size\z@\selectfont#1{#2}}%
}%
}%
\ensuremath{\mkern-2mu}/\ensuremath{\mkern-1mu}%
\ensuremath{%
\mbox{\fontsize\sf@size\z@\selectfont#1{#3}}%
}%
}%
}
\DeclareRobustCommand*{\@UnitsUglyFrac}[3][]{%
\ifthenelse{\boolean{mmode}}{%
\frac{#1{#2}}{#1{#3}}%
}%
{%
#1{#2}/#1{#3}%
\PackageWarning{nicefrac}{%
You used \protect\nicefrac\space or
\protect\unitfrac\space in text mode\MessageBreak
and specified the ``ugly'' option.\MessageBreak
The fraction may be ambiguous or wrong.\MessageBreak
Please make sure the denominator is
correct.\MessageBreak
If it is, you can safely ignore\MessageBreak
this warning
}%
}%
}
\DeclareOption{nice}{%
\DeclareRobustCommand*{\nicefrac}{\@UnitsNiceFrac}%
}
\DeclareOption{ugly}{%
\DeclareRobustCommand*{\nicefrac}{\@UnitsUglyFrac}%
}
\ExecuteOptions{nice}
\ProcessOptions*
\endinput
%%
%% End of file `nicefrac.sty'.

@ -0,0 +1,177 @@
%%
%% This is file `nomencl.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% nomencl.dtx (with options: `package')
%%
%% Copyright 1996 Boris Veytsman
%% Copyright 1999-2000 Bernd Schandl
%% email schandl@gmx.net
%% www http://members.nbci.com/schandl/nomencl
%%
%% This file can be redistributed and/or modified under the terms
%% of the LaTeX Project Public License distributed from CTAN
%% archives in the directory macros/latex/base/lppl.txt; either
%% version 1.2 of the license, or (at your option) any later version.
%%
%% \CharacterTable
%% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
%% Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
%% Digits \0\1\2\3\4\5\6\7\8\9
%% Exclamation \! Double quote \" Hash (number) \#
%% Dollar \$ Percent \% Ampersand \&
%% Acute accent \' Left paren \( Right paren \)
%% Asterisk \* Plus \+ Comma \,
%% Minus \- Point \. Solidus \/
%% Colon \: Semicolon \; Less than \<
%% Equals \= Greater than \> Question mark \?
%% Commercial at \@ Left bracket \[ Backslash \\
%% Right bracket \] Circumflex \^ Underscore \_
%% Grave accent \` Left brace \{ Vertical bar \|
%% Right brace \} Tilde \~}
%%
\ProvidesPackage{nomencl}%
[2000/12/03 v3.1a Nomenclature package (BS)]
\NeedsTeXFormat{LaTeX2e}
\newif\if@printeqref
\newif\if@printpageref
\DeclareOption{refeq}{\@printeqreftrue}
\DeclareOption{norefeq}{\@printeqreffalse}
\DeclareOption{refpage}{\@printpagereftrue}
\DeclareOption{norefpage}{\@printpagereffalse}
\DeclareOption{prefix}{\def\nomprefix{a}}
\DeclareOption{noprefix}{\def\nomprefix{}}
\newif\if@loadcfg
\DeclareOption{cfg}{\@loadcfgtrue}
\DeclareOption{nocfg}{\@loadcfgfalse}
\DeclareOption{croatian}{%
\def\eqdeclaration#1{, vidi jednad\v{z}bu\nobreakspace(#1)}%
\def\pagedeclaration#1{, stranica\nobreakspace#1}%
\def\nomname{Popis simbola}}
\DeclareOption{danish}{%
\def\eqdeclaration#1{, se ligning\nobreakspace(#1)}%
\def\pagedeclaration#1{, side\nobreakspace#1}%
\def\nomname{Symbolliste}}
\DeclareOption{english}{%
\def\eqdeclaration#1{, see equation\nobreakspace(#1)}%
\def\pagedeclaration#1{, page\nobreakspace#1}%
\def\nomname{List of Symbols and Abbreviations}}
% \def\nomname{Nomenclature}}
\DeclareOption{french}{%
\def\eqdeclaration#1{, voir \'equation\nobreakspace(#1)}%
\def\pagedeclaration#1{, page\nobreakspace#1}%
\def\nomname{Liste des symboles}}
\DeclareOption{german}{%
\def\eqdeclaration#1{, siehe Gleichung\nobreakspace(#1)}%
\def\pagedeclaration#1{, Seite\nobreakspace#1}%
\def\nomname{Symbolverzeichnis}}
\DeclareOption{italian}{%
\def\eqdeclaration#1{, equazione\nobreakspace(#1)}%
\def\pagedeclaration#1{, pagina\nobreakspace#1}%
\def\nomname{Elenco dei Simboli}}
\DeclareOption{polish}{%
\def\eqdeclaration#1{, porownaj rownanie\nobreakspace(#1)}%
\def\pagedeclaration#1{, strona\nobreakspace#1}%
\def\nomname{Lista symboli}}
\DeclareOption{portuguese}{%
\def\eqdeclaration#1{, veja equa\c{c}\~ao\nobreakspace(#1)}%
\def\pagedeclaration#1{, p\'agina\nobreakspace#1}%
\def\nomname{Nomenclatura}}
\DeclareOption{russian}{%
\def\eqdeclaration#1{, \cyrs\cyrm.\nobreakspace(#1)}%
\def\pagedeclaration#1{, \cyrs\cyrt\cyrr.\nobreakspace#1}%
\def\nomname{\CYRS\cyrp\cyri\cyrs\cyro\cyrk%
\ \cyro\cyrb\cyro\cyrz\cyrn\cyra\cyrch\cyre\cyrn\cyri%
\cyrishrt}}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\DeclareOption{slovak}{%
\def\eqdeclaration#1{, pozri rovnicu\nobreakspace(#1)}%
\def\pagedeclaration#1{, strana\nobreakspace#1}%
\def\nomname{Zoznam symbolov a skratiek}}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\DeclareOption{spanish}{%
\def\eqdeclaration#1{, v\'ease la ecuaci\'on\nobreakspace(#1)}%
\def\pagedeclaration#1{, p\'agina\nobreakspace#1}%
\def\nomname{Nomenclatura}}
\DeclareOption{ukrainian}{%
\def\eqdeclaration#1{, \cyrd\cyri\cyrv.\nobreakspace(#1)}%
\def\pagedeclaration#1{, \cyrs\cyrt\cyro\cyrr.\nobreakspace#1}%
\def\nomname{\CYRP\cyre\cyrr\cyre\cyrl\cyrii\cyrk%
\ \cyrp\cyro\cyrz\cyrn\cyra\cyrch\cyre\cyrn\cyrsftsn}}
\ExecuteOptions{norefeq,norefpage,prefix,cfg,english}
\ProcessOptions\relax
\def\makeglossary{%
\newwrite\@glossaryfile
\immediate\openout\@glossaryfile=\jobname.glo
\def\@nomenclature{%
\@bsphack
\begingroup
\@sanitize
\@ifnextchar[%
{\@@@nomenclature}{\@@@nomenclature[\nomprefix]}}%
\typeout{Writing glossary file \jobname.glo}%
\let\makeglossary\@empty}
\def\nom@verb{\expandafter\strip@prefix\meaning}
\def\nomenclature{\protect\@nomenclature}
\def\@nomenclature{%
\@bsphack
\begingroup
\@sanitize
\@ifnextchar[%
{\@@nomenclature}{\@@nomenclature[\nomprefix]}}
\def\@@nomenclature[#1]#2#3{\endgroup\@esphack}
\def\@@@nomenclature[#1]#2#3{%
\def\@tempa{#2}\def\@tempb{#3}%
\protected@write\@glossaryfile{}%
{\string\glossaryentry{#1\nom@verb\@tempa @[{\nom@verb\@tempa}]%
\begingroup\nom@verb\@tempb\protect\nomeqref{\theequation}%
|nompageref}{\thepage}}%
\endgroup
\@esphack}
\def\nomgroup#1{}
\newdimen\nomlabelwidth
\nomlabelwidth1cm\relax
\newdimen\nom@tempdim
\def\printglossary{%
\@ifnextchar[%
{\@printglossary}{\@printglossary[\nomlabelwidth]}}
\def\@printglossary[#1]{%
\nom@tempdim#1\relax
\@input@{\jobname.gls}}
\def\nomlabel#1{#1\hfil}
\def\nompreamble{}
\def\nompostamble{}
\def\nomentryend{}
\newskip\nomitemsep
\nomitemsep\itemsep
\def\theglossary{%
\@ifundefined{chapter}{\section*}{\chapter*}{\nomname}%
\nompreamble
\list{}{%
\labelwidth\nom@tempdim
\leftmargin\labelwidth
\advance\leftmargin\labelsep
\itemsep\nomitemsep
\let\makelabel\nomlabel}}
\def\endtheglossary{%
\endlist
\nompostamble}
\def\refeq{\@printeqreftrue}
\def\refpage{\@printpagereftrue}
\def\refeqpage{\@printeqreftrue\@printpagereftrue}
\def\norefeq{\@printeqreffalse}
\def\norefpage{\@printpagereffalse}
\def\norefeqpage{\@printeqreffalse\@printpagereffalse}
\def\nomeqref#1{\if@printeqref\eqdeclaration{#1}\fi\ignorespaces}
\def\nompageref#1{\if@printpageref\pagedeclaration{#1}\fi%
\nomentryend\endgroup}
\if@loadcfg
\InputIfFileExists{nomencl.cfg}{%
\typeout{Using the configuration file nomencl.cfg}}{}
\fi
\endinput
%%
%% End of file `nomencl.sty'.

@ -0,0 +1,12 @@
https://www.impinj.com/guide-to-rfid/the-different-types-of-rfid-systems.aspx
http://rfid.net/basics
http://www.technovelgy.com/ct/technology-article.asp
http://www.centrenational-rfid.com/rfid-frequency-ranges-article-16-gb-ruid-202.html
http://www.netcard.com.au/products/what-is-mifare
http://books.google.sk/books?id=FLabRYnGrOcC&pg=SA3-PA7&dq=federico+faggin&hl=sk&sa=X&ei=ISrZUvPBBsSh4gTp1IDgCA&ved=0CEMQ6AEwAw#v=onepage&q=federico%20faggin&f=false
http://www.ehow.com/info_10018768_history-microcontroller.html
http://www.robotplatform.com/electronics/microcontroller/microcontroller.html
http://www.electrical4u.com/history-of-microprocessor-and-history-of-microcontroller/
http://en.wikipedia.org/wiki/Microcontroller
http://smithsonianchips.si.edu/augarten/p38.htm

@ -0,0 +1,157 @@
\section{Program function}
The main task of a program, running inside a microcontroller is to access the data obtained by a RFID reader module and store them on a storage medium, for which an MicroSD card was chosen. The hardest part of this task is to communicate with multiple components simultaneously and moving or modifying data they hold.
Program must also react on external events, that can come from the user interface, power management or PC communication circuitry and act accordingly, mostly by putting the response on a LCD display.
%
%
%\subsection{Brief history of microprocessors and microcontrollers}
%Since microcontrollers evolved out of microprocessors, some milestones in their history are worth noting\cite{allan2001history}\cite{augarten1983state}:
%\begin{itemize}
% \item Busicom - calculator manufacturer of Japan ordered design of some specific chips from Intel corporation (1969)
% \item M. E. Hoff came out with the idea of device, which operation will be governed by instructions stored in ROM memory
% \item F. Faggin built the actual device - the first microprocessor
% \item Intel bought rights to sell the device on their own from Busicom, Intel 4004 (4 bit) came to market (1971)
% \item Texas Instruments engineers G. Boone and M. Cohran packed CPU, RAM, ROM, I/O and peripherals to the one chip, the first microcontroller was born, but it was a commercial failure
% \item Intel improved the device, the Intel 8008 (8 bit) was born (1972)
% \item TI microcontroller was employed in calculators (1972)
% \item TI put their TMS1000 microcontroller on the market with a great success, for \$2/pc, millions were sold (1974)
% \item Motorola entered the market with 68000 and Zilog with Z80, which caused the competition to grow exponentially
%\end{itemize}
%
%\subsection{Microcontroller architectures and vendors}
%Microcontrollers are produced by roughly two dozens of companies, so the great diversity exists. Advanced integration is causing that more and more functionality is packed into these devices.
%
%Some of the present MCU architectures and vendors are:
%\begin{itemize}
% \item 8051 introduced by Intel, today produced by most semiconductor manufacturers
% \item ARM
% \item MIPS
% \item AVR by Atmel
% \item PIC by Microchip
% \item DSP430, C2000 by Texas Instruments
% \item Freescale, ST Microelectronics, XMOS, \dots
%\end{itemize}
%
%\subsection{Structure of microcontroller}
%On the very basic level, the microcontroller consists of basic building blocks, illustrated on Figure \ref{mcu:1}:
%\begin{itemize}
% \item Microprocessor with Arithmetic-logic Unit (ALU), Control logic and Instruction decoder
% \item Memory
% \item Program counter
% \item Oscillator
% \item Input/Output circuitry
% \item Timers, Pulse-Width Modulation
% \item Analog-to-digital converter
%\end{itemize}
%
%\begin{figure}[ht!]
% \centering
% \includegraphics[width=\textwidth,angle=0]{mcu_structure.jpg}
% \caption{Naive representation of what is inside the microcontroller}\label{mcu:1}
%\end{figure}
%
%Some additional blocks and peripherals are be included, depending on MCU model, such as:
%\begin{itemize}
% \item Brown-out detection
% \item Serial communication interfaces\cite{susnea2006microcontrollers}
% \item USB controller
% \item Ethernet interface
% \item Watch-dog timer
% \item Interrupt routines
%\end{itemize}
%
%Every block can get really complex to explain. For simplicity, only the blocks, that are particularly important for the understanding the device will be described in deer detail.
%
%\subsection{Microcontroller memories}
%Most microcontrollers do possess three types of memory:
%
%\begin{itemize}
% \item Flash stores instructions in order they will be executed
% \item RAM stores temporary data, needed for computations
% \item EEPROM stores data, that should be remembered, such as user configurations
%\end{itemize}
%Special-function Registers (SFRs) are part of RAM memory and changing them, will cause direct change in microcontroller behaviour.
%
%\subsection{Oscillator}
%Oscillator's job is to make sure, every block knows, when to do its job. It represents the function of commander, thus the drums illustration. There are two types of oscillators used:
%\begin{itemize}
% \item external
% \item internal
%\end{itemize}
%
%\subsection{Serial communication interfaces}
%Communication interfaces are used for communication between MCU and other MCU or other devices. Most standard serial interfaces are UART, I2C and SPI.
%
%UART is used between two devices. When more devices are communicating, I2C or SPI is used. SPI provides faster communication over I2C at the expense of used pins on microcontroller.
%
%\subsection{USB controller}
%A USB port\cite{axelson2007serial} is a standard cable connection interface on personal computers and consumer electronics. USB ports allow stand-alone electronic devices to be connected via cables to a computer (or to each other).
%
%USB is serial communication interface, derived off I2C. It can be implemented on microcontroller itself, or as standalone device/module.
%
%\subsection{Other useful information}
%Bluetooth is a wireless technology, for communication between devices and/or computers at short ranges.
%Display is the device showing visual information.
%Human interface provides a way for human to control the device.
%Non-volatile memory is preserving the data, even when power is lost.
%%MicroSD card is a data storage device, mostly consisting of Flash memory.
%
%
%\nomenclature{CPU}{Central Processing Unit}
%\nomenclature{RAM}{Random-access Memory}
%\nomenclature{ROM}{Read-only memory}
%\nomenclature{I/O}{Input/output}
%\nomenclature{TI}{Texas Instruments}
%\nomenclature{Hz}{Hertz, unit of frequency}
%
%\newpage
%\section{RFID}
%RFID stands for Radio-Frequency IDentification \cite{lehpamer2012rfid}. The acronym refers to small electronic devices that consist of a small chip and an antenna. The chip typically is capable of carrying 2,000 bytes of data or less.
%
%The RFID device serves the same purpose as a bar code or a magnetic strip on the back of a credit card or ATM card; it provides a unique identifier for that object. And, just as a bar code or magnetic strip must be scanned to get the information, the RFID device must be scanned to retrieve the identifying information.
%
%From the energy point of view, RFID tags falls into one of the three categories:
%\begin{itemize}
% \item active
% \item battery-assisted passive
% \item passive
%\end{itemize}
%
%\subsection{RFID frequencies}
%RFID is considered as a non specific short range device. It can use frequency bands without a license. Nevertheless, RFID has to be compliant with local regulations.
%
%Frequencies used in RFID communication, illustrated on Figure \ref{rfid:1}:
%\begin{itemize}
% \item LF - low frequencies: 125 kHz - 134,2 kHz
% \item HF - high frequencies: 13.56 MHz
% \item UHF - ultra high frequencies: 860 MHz
% \item SHF - super high frequencies: 2.45 GHz
%\end{itemize}
%
%\begin{figure}[ht!]
% \centering
% \includegraphics[width=\textwidth,angle=0]{rfid_freq.jpg}
% \caption{Graph of the electromagnetic spectrum with the frequency bands that the RFID systems can use}\label{rfid:1}
%\end{figure}
%
%\subsection{Mifare}
%Mifare is a 13.56 MHz contactless NFC\cite{coskun2011near} technology owned by NXP (founded by Philips). It falls into high frequency, passive RFID tag category. Mifare has proven popular as the card to use in ticketing, low value transactions and in student's ISIC cards. Mifare cards are powered by an internal antenna as the card moves into a magnetic field.
%
%Cipurse is another such technology, although it is not owned by just one company, but rather alliance of companies. The next difference is that this standard is open. It's aim is to promote vendor neutrality, opposed to market Mifare dominance.
%
%%\newpage
%Some benefits of the Mifare are:
%\begin{itemize}
% \item multiple applications
% \item secure encryption prevents unauthorised access
% \item reduced maintenance, due to contactless technology
% \item alternatives to cards, such as fobs or watches
% \item only proximity is sufficient for read/write
% \item unique serial number (tag)
%\end{itemize}
%
%\subsection{RFID reader}
%An RFID reader is basically a radio frequency transmitter and receiver controlled by a microprocessor. The reader, using an attached antenna, captures data from RFID enabled smart label tags, then passes the data to a microcontroller for processing.
%

File diff suppressed because it is too large Load Diff

BIN
system_guide/tukethesis.pdf (Stored with Git LFS)

Binary file not shown.

@ -0,0 +1,229 @@
%\RequirePackage{etoolbox}
%\patchcmd{\bibliographystyle}{#1}{newbib}{}{}
\documentclass[]{tukethesis}
%% -------------------------------------------------------------------------
%% UTF-8 encoding used. Use pdflatex to compile your document
%% Tukethesis Class for Win XP and GNU/Linux
%% -------------------------------------------------------------------------
\usepackage[slovak,english]{babel}
\usepackage[utf8x]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{cmap}
\usepackage{lmodern}
%\usepackage{booktabs}
%% ---- definicia slovenskych uvodzoviek
\chardef\clqq=18 \sfcode18=0
\chardef\crqq=16 \sfcode16=0
\def\uv#1{\clqq#1\crqq}
%% ------------------------------------
\renewcommand{\figurename}{Fig.}
\renewcommand{\tablename}{Tab.}
\renewcommand{\refname}{Bibliography}
\renewcommand{\listfigurename}{List of Figures}
\renewcommand{\listtablename}{List of Tables}
\renewcommand{\contentsname}{Contents}
%%
\usepackage{latexsym}
\usepackage{dcolumn} % alignment on a 'decimal point' in tabular mode
\usepackage{hhline}
\usepackage{amsmath}
\usepackage{nicefrac} % nice fractions
\usepackage{upgreek} % e.g. $\upmu\mathrm{m}$ type micrometer (mu)
\usepackage[final]{showkeys}%color%notref%notcite%final
\usepackage[noprefix]{nomencl}
%\usepackage{pdfpages}
\makeglossary % command to make *.glo file
\usepackage{parskip}%
%%
%\usepackage[dvips]{graphicx}
%\DeclareGraphicsExtensions{.eps, .mps}
\usepackage[pdftex]{graphicx}
\DeclareGraphicsExtensions{.pdf,.png,.jpg,.mps}
\graphicspath{{figures/}} % directory for figures
%%
%% numerical citations (vancouer style)
\usepackage[numbers]{natbib}
%%
%% author-year citations (harvard style) -- prefered !!!
%\usepackage{natbib} \citestyle{chicago}
% -----------------------------------------------------------------
%% tlač !!!
\usepackage[pdftex,unicode=true,bookmarksnumbered=true,
bookmarksopen=true,pdfmenubar=true,pdfview=Fit,linktocpage=true,
pageanchor=true,bookmarkstype=toc,pdfpagemode=UseOutlines,
pdfstartpage=1]{hyperref}
\hypersetup{%
%baseurl={http://www.tuke.sk/sevcovic},
pdfcreator={pdfLaTeX},
pdfkeywords={Mcicrocontroller, RFID, device},
pdftitle={The Optimization of the Thesis Writing},
pdfauthor={Peter Babič},
pdfsubject={Bachelor's Thesis}
}
%% -----------------------------------------------------------------
%% START YOUR THESIS
%% -----------------------------------------------------------------
%%
%% PLEASE SELECT YOUR PREFERED THESIS TYPE
%%
%% A Bachelor's degree is a first degree at college or university
\bachelorthesis{System Guide}
%%
%% A Master's thesis is a second level college or university degree
%\masterthesis{Master's Thesis}
%% -----------------------------------------------------------------
%% Ak praca nema 'podnazov' zakomentujte riadky \subtitle a \podnazov,
%% alebo polozky nechajte prazdne
\author{Peter Babič}
\title{Design and implementation of a portable device for creating RFID tag lists}
\subtitle{}
\abstrakte{
This thesis shows the process of building a portable hand-held device capable of storing RFID tags along with current date and time. The process goes from the idea on the paper, through the prototyping and testing stage up to the working device. The device is backed by a microcontroller and is able to read all Mifare compatible RFID cards and identificators, preferably student's ISIC cards, store them on the MicroSD card, in the CSV format, while providing an user interface for basic operation and a Serial connection over an USB cable for advanced operation.
}
\keywords{ISIC, microcontroller, MicroSD, Mifare, RFID, tags}
\degree{Bakalár, Magister, Inžinier a pod.}
\university{Technical University of Košice}
\faculty{Faculty of Electrical Engineering and Informatics}
\facultyabbr{FEI}
\department{Department of Theoretical and Industrial Electrical Engineering}
\departmentabbr{KTPE}
\fieldofstudy{9.2.9 Applied Informatics}
\studyprogramme{Applied informatics}
\supervisor{Ing. Tibor Vince, PhD.}
\consultanta{Ing. Norbert Ádám, PhD.}
\dateofsubmission{May. 30. 2014}
\town{Košice}
\abstrakt{Táto práca ukazuje proces tvorby prenosného zariadenia, schopného ukladať RFID tagy spolu s aktuálnym časom a dátumom. Proces začína teoretickým rozborom, tiahne sa cez prototypovaciu a testovaciu časť až po fungujúce zariadenie. Zariadenie obsahuje mikrokontrolér a je kompatibilné so všetkými typmi Mifare RFID kárt a identifikátorov, avšak hlavným cieľom sú študentské ISIC karty. Dáta sú uložené na MicroSD kartu, v CSV formáte. K dispozícii je minimálne užívateľské rozhranie pre základne použitie a Sériové spojenie cez USB kábel pre rozšírené operácie.}
\klucoveslova{ISIC, mikrokontrolér, MicroSD, Mifare, RFID, tagy}
\begin{document}
\renewcommand\theHfigure{\theHsection.\arabic{figure}}
\renewcommand\theHtable{\theHsection.\arabic{table}}
\nocite{*}
\bibliographystyle{acm}
%% input the 'First page of the Thesis'
\firstpage
%% input the 'Title page of the Thesis'
%\titlepage
%% input the 'Metadatasheet of the Thesis'
%\metadatasheet
%\errata % begin the 'Errata'
%Ak je potrebné, autor na tomto mieste opraví chyby, ktoré našiel
%po vytlačení práce. Opravy sa uvádzajú takým písmom, akým je napísaná
%práca. Ak zistíme chyby až po vytlačení a zviazaní práce, napíšeme
%erráta na samostatný lístok, ktorý vložíme na toto miesto.
%
%Forma:
%\tabcolsep=10pt
%\begin{table}[!hb]
% \centering
% \begin{tabular}{|c|c|c|c|}\hline
%Page & Line & Wrong & Correct \\\hline\hline
%%12 & 6 & publikácia & prezentácia \\\hline
%%22 & 23 & internet & intranet \\\hline
%& & & \\\hline
%& & & \\\hline
%& & & \\\hline
%& & & \\\hline
% \end{tabular}
%\end{table}
%\kerrata
%
%\abstrakte % Abstract in English
%
%\abstrakt % Abstract in Slovak
%
%\endabstract % end of the Abstracts page
%% input the 'Assign of the Thesis'
%\assignthesis
%\vspace*{-1.8in}
%\centerline{\includegraphics{assign.jpg}}
%% input the 'Declaration' of the author
%\declaration
%
%
%\acknowledgement % begin the 'Acknowledgement'
%I would like to express my sincere thanks to my supervisor Ing. Tibor Vince, PhD., the main Supervisor, for his constant, and constructive guidance. Another mention should go Ing. Norbert Ádám, PhD. To all other who gave a hand, I say thank you
%very much.
%\endacknowledgement
%
%\preface % begin the 'Preface'
%This thesis is about constructing an electronic device from a scratch. It requires problem solving skills, analytical thinking and decision making. Among core technical skills used are electronics design, firmware programming and product documentation, which are all part of the product life-cycle. Practising and improving named skills was the main motivation to choose this topic.
%%Predhovor ({\it Preface}) je povinnou náležitosťou záverečnej práce, V~predhovore autor uvedie základné charakteristiky
%%svojej záverečnej práce a~okolnosti jej vzniku. Vysvetlí dôvody, ktoré
%%ho viedli k~voľbe témy, cieľ a~účel práce a~stručne informuje
%%o~hlavných metódach, ktoré pri spracovaní záverečnej práce použil.
%\endpreface
\thispagestyle{empty}
\tableofcontents
\newpage
\thispagestyle{empty}
%\addcontentsline{toc}{section}{\numberline{}List of Figures}
\listoffigures
\newpage
%\thispagestyle{empty}
%%\addcontentsline{toc}{section}{\numberline{}List of Tables}
%\listoftables
%\newpage
%
%\thispagestyle{empty}
%%\addcontentsline{toc}{section}{\numberline{}List of Symbols and
%%Abbreviations}
%\printglossary % input the 'List of Symbols and Abbreviations'
%\newpage
%
%%\addcontentsline{toc}{section}{\numberline{}List of Therms}
%\listofterms % begin the 'List of Therms'
%
%\begin{description}
% \item[File system] is used in computing to control how data is stored and retrieved. Without a file system, information placed in a storage area would be one large body of data with no way to tell where one piece of information stops and the next begins. Common file systems are: FAT, NTFS, EXT and many more.
% \item[Liquid-crystal Display] is a flat display using light modulating properties of liquid crystals. They do not emit light themselves. LCD's are used in a wide range of applications, and are energy efficient.
% \item[Microcontroller] is a compact microcomputer designed to govern the operation of embedded systems in motor vehicles, robots, office machines, complex medical devices, mobile radio transceivers, vending machines, home appliances, and various other devices. A typical microcontroller includes a processor, memory, and peripherals.
% \item[RFID] radio frequency identification: a technology that uses electronic tags placed on objects, people, or animals to relay identifying information to an electronic reader by means of radio waves.
% \item[SD card] is a non-volatile memory card format for use in portable devices. It is one of the most used memory card formats today. It divides to three categories by physical size: SD, MiniSD and MicroSD. There are also three categories, regarding it's capacity: SDSC, SDHC and SDXC.
% \item[Universal Serial Bus] is an industry standard developed in the mid-1990s that defines the cables, connectors and communications protocols used in a bus for connection, communication, and power supply between computers and electronic devices.
%
%
%\end{description}
%
%\endlistofterms
%
%\include{introduction}
%
\include{problemexpres}
%
\include{analytical}
%
\include{mainpart}
%
%\include{conclusion}
%
\bibliography{bibliography}
%
%\include{appendices}
%% begin the 'Curriculumvitae' of the author
%\curriculumvitae\protect\label{page:posledna}
%Táto časť\/ je nepovinná. Autor tu môže uviesť\/ svoje biografické
%údaje, údaje o~záujmoch, účasti na~projektoch, účasti na~súťažiach,
%získané ocenenia, zahraničné pobyty na~praxi, domácu prax, publikácie
%a~pod.
%\endcurriculumvitae
\end{document}
%%
Loading…
Cancel
Save