source: firmware/FSC/doc/FSC.tex.backup@ 14342

Last change on this file since 14342 was 10668, checked in by neise, 14 years ago
File size: 7.5 KB
Line 
1\documentclass[a4paper]{article}
2
3%\setlength{\topmargin}{0mm} %1 inch is always there!
4%\setlength{\oddsidemargin}{0mm} %1 inch is always there!
5%\setlength{\evensidemargin}{0mm} %1 inch is always there!
6
7%\setlength{\textwidth}{16cm}
8
9% keine Kopfzeile?
10%\setlength{\headheight}{0mm}
11%\setlength{\headsep}{0mm}
12
13
14%um die deutschen Umlaute eingeben zu können
15% müssen diese 3 Pakete eingebunden werden.
16% welches der Pakete was macht, weiss ich nicht.
17\usepackage[T1]{fontenc}
18\usepackage[latin1]{inputenc}
19%\usepackage{ngerman} % nur wenn z.B. 'Inhaltsverzeichnis' auch deutsch sein soll.
20
21\usepackage{graphicx} % for pictures
22\usepackage{float} % for figures with english descriptions
23
24\restylefloat{figure} % can nor force it with H
25\restylefloat{table} % can nor force it with H
26
27\title{FSC - facts about the board}
28\author{D. Neise}
29\date{07.02.2011}
30
31\begin{document}
32
33%title page contains TOC
34\maketitle
35\tableofcontents
36\newpage
37
38%\listoffigures
39%\listoftables
40
41\section{Basic Facts and Purpose}
42% no pictures in SVN repos ... no space.
43%\emph{picture here - 3D model of FSC}
44
45This document presents electronic facts and figures of FACTs FSC board, which stands for {\bf F}act {\bf S}low {\bf C}ontrol. The name is a bit misleading, since the boards sole purpose is to monitor slowly changing parameters, such as:
46\begin{itemize}
47 \item up to 64 temperatures (RTD like sensors, e.g. Pt1000 or Pt100),
48 \item up to 4 humidities (designed for Honeywell HIH-40xx family),
49 \item the DC levels of all FACT low voltage supply channels(32 ??? channels),
50 \item the current drawn from each of these channels (converted to a voltage inside LV-supply).
51\end{itemize}
52
53FSC therefor brings an 8MHz ATmega32L micro controller(MCU), used to readout the muxed 24bit sigma delta ADC (AD7719) which is connected to the RTDs. In addition the ATmegas internal 10bit ADC is used to monitor the humidity, LV-voltages and LV-currents. The muxers on FSC belong to analog devices ADG77xx family, and are controlled by the MCU according to the users needs. The User has access to FSC via Ethernet Interface, comprised(?) by wiznets W5100, the younger brother of W5300, which is used on FACTs FAD boards. AD7719 and W5100 communicate with the MCU via an SPI bus, which results in the fact, that User interaction might slow down temperature measurement or vice versa. Additionally the user should be aware, that sigma delta ADCs have a long settling, when muxed. Redout of all 64 temperature channels takes about 13s, while the one channel might be readout with >10Hz. In addition FSC runs a 32bit timer, counting seconds since timer init. The timer is initialized to zero, when FSC is powered. User may synchronize FSCs timer to Unix time. \newline
54We do not talk here about the accelerometer on the FSC, since this piece it not part of the original proposal.
55
56\subsection{measurement modes}
57FSC knows two measurement modes. The first is \emph{on demand}. When FSC measures on demand, user may send a command telling FSC, what to measure. FSC will measure it and return the result, only after the measurement was finished. It is possible to tell FSC to measure several sensors at a time.
58If the user asked for a temperature measurement and FSC had to change the muxer setting, this might take up to 300ms.
59During a measurement on demand, FSC is not checking for incoming commands. So new commands will pile up in W5100 input FIFO. So sending a lot of on demand commands can easily delay FSC reaction a lot.
60
61The second mode is \emph{free running}. In free running mode FSC measures all activated sensors and stores the value and time tuples. Once all sensors were measured, FSC returns a measurement telegram. The user can define which sensors should be measured and which should be left out. Additionally one can tell FSC how often it should start a measurement cycle.
62\section{Ethernet Interface}
63FSC runs as a TCP/IP server, this means after W5100 was initialized, FSC will listen on one Port, but will not attempt to connect to any other server. Since W5100 does not support DHCP, FSC has a fix IP\footnote{see FACT Elogbook / doc}. The Port is not yet defined, but since FADs use Ports 5000-5007, there is a high probability, that you can access FSC via Port 5000 as well.
64For simplicity of firmware coding, the UI is non human readable, commands from User to FCS may look like this.
65\begin{table}[htpb]
66\begin{tabular}{|l|l|l|}
67\hline
68address & mnemonic & description \\
69\hline
70byte 0 & command & see reference to next subsection\\
71byte 1 & ticket no & number of commands - upcounting \\
72byte 2 & length & length of data section - if apropriate\\
73byte 3..1k & data & parameters for command - if apropriate\\
74\hline
75\end{tabular}
76\caption{composition of FSC commands}
77\label{tbl_UserCommand}
78\end{table}
79
80FSCs answers might be eigther a short acknowledgement, in case the user changed a just setting, or a measurement telegram.
81An acknowledgement contains the number of the command, which caused the FSC to answer and looks like this.
82\begin{table}[htpb]
83\begin{tabular}{|l|l|l|}
84\hline
85address & mnemonic & description \\
86\hline
87byte 0 & ticket no & number of the command, \\
88 &&causing this answer: range: 0x01 .. 0xFF \\
89byte 1 & length & length of data section \\
90byte 2 & command & first byte in data section: repeated command \\
91byte 3..1k & data & parameters for command - repetition as well\\
92\hline
93\end{tabular}
94\caption{composition of FSCs answer - acknowledgement}
95\label{tbl_FSC_ACK}
96\end{table}
97
98If the user asked for a measurement on demand, the acknowledgement contains the measurement telegram inside the data section.
99For a detailed description of the telegram refer to \emph{the right subsection}.
100In case the FSC returns data measured, because it was switched to free running mode, the message looks slightly different.
101
102\begin{table}[htpb]
103\begin{tabular}{|l|l|l|}
104\hline
105address & mnemonic & description \\
106\hline
107byte 0 & free run code & 0x00 - is defined not to \\
108&&be a legal ticket number \\
109byte 1 & length & length of data section \\
110byte 2..1k & telegram & see \emph{the right subsection}\\
111\hline
112\end{tabular}
113\caption{composition of FSCs free running massage}
114\label{tbl_FSC_MESS}
115\end{table}
116
117\newpage
118\subsection{FSC registers}
119
120FSC uses the following registers.
121\begin{table}[htpb]
122\begin{tabular}{|l|l|l|}
123\hline
124{\bf address} & {\bf name} & {\bf description } \\
125\hline
1260x00 & status & stats register - TBR (e.g. mode; timer synched?; ) \\
1270x01 & error & error register - \\
128&& TBR (AD7719 found disconnected sensor, \\
129&&HUM or TEMP too high, V or I out of range)\\
1300x02 & timer3 & \\
1310x03 & timer2 & \\
1320x04 & timer1 & \\
1330x05 & timer0 & current time\\
1340x06 & TempEn7 & \\
1350x07 & TempEn6 & \\
1360x08 & TempEn5 & \\
1370x09 & TempEn4 & \\
1380x0A & TempEn3 & \\
1390x0B & TempEn2 & \\
1400x0C & TempEn1 & \\
1410x0D & TempEn0 & \\
1420x0E & HumiEn0 & \\
1430x0F & AcceEn0 & \\
1440x10 & VoltEn4 & \\
1450x11 & VoltEn3 & \\
1460x12 & VoltEn2 & \\
1470x13 & VoltEn1 & \\
1480x14 & VoltEn0 & \\
1490x15 & CurrEn4 & \\
1500x16 & CurrEn3 & \\
1510x17 & CurrEn2 & \\
1520x18 & CurrEn1 & \\
1530x19 & CurrEn0 & \\
154... & ... & to be completed \\
155 \hline
156\end{tabular}
157\caption{FSC registers}
158\label{tbl_REG_overview}
159\end{table}
160
161
162\subsection{getting out results - the telegram}
163Most probably not every input channel will be connected to a sensor. In order not to measure unconnected channels, the user may define, which sensor is active.
164
165
166
167
168
169%\appendix
170\end{document}
Note: See TracBrowser for help on using the repository browser.