add comments to the source
[ri1617.git] / architecture / commmi.tex
1 The only thing the microcontroller has to communicate back with the server is
2 an update of the SDS and a request for an SDS value.
3 Since all SDSs have a numeric identifier the engine can just send a request
4 message with the identifier to the server. A detailed description of the
5 message for sending and receiving SDSs is described in
6 Tables~\ref{tbl:sdssend},~\ref{tbl:sdsrecv}.
7
8 As said before, publication of SDS values is not done automatically to save
9 bandwidth. Therefore the tasks need to have a way of requesting the latest SDS
10 value and a way of publishing an updated value. This is elaborated more upon in
11 the next section.\todo{Type safety of SDS access}
12
13 \begin{table}[ht]
14 \centering
15 \begin{tabular}{ll}
16 \toprule
17 Bytes & Description\\
18 \midrule
19 \multicolumn{2}{c}{\textbf{Request}}\\
20 $1$ & SDS send code \verb#'s'#\\
21 $2-3$ & SDS identifier as a 16-bit integer\\
22 $4-5$ & Length of the message 16-bit integer\\
23 $n$ & Value of the SDS identifier\\
24 \bottomrule
25 \end{tabular}
26 \caption{Message format for a SDS-send operation}\label{tbl:sdssend}
27 \end{table}
28
29 \begin{table}[ht]
30 \centering
31 \begin{tabular}{ll}
32 \toprule
33 Bytes & Description\\
34 \midrule
35 \multicolumn{2}{c}{\textbf{Request}}\\
36 $1$ & SDS send code \verb#'r'#\\
37 $2-3$ & SDS identifier as a 16-bit integer\\
38 \midrule
39 \multicolumn{2}{c}{\textbf{Response}}\\
40 $1-2$ & Length of the message as a 16-bit integer\\
41 $n$ & Value of the SDS\\
42 \bottomrule
43 \end{tabular}
44 \caption{Message format for a SDS-receive operation}\label{tbl:sdsrecv}
45 \end{table}