Update notes and documents
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
Signed-off-by: Severin Kaderli <severin@kaderli.dev>
This commit is contained in:
parent
113d31a592
commit
91978e22d9
10 changed files with 155 additions and 37 deletions
|
@ -1 +1,13 @@
|
||||||
\chapter{Preliminaries}
|
\chapter{Preliminaries}
|
||||||
|
\section{Web Worker}
|
||||||
|
Web Workers are a web API that allows running JavaScript code in background threads in the browser. This way you can run CPU intensive processes without stalling the main thread and locking up the UI.
|
||||||
|
|
||||||
|
There's a few limitations with Web Workers. A Web Worker doesn't have access to the DOM, the window object and some web APIs.
|
||||||
|
|
||||||
|
The main thread and Web Workers can communicate together using messages. They can send their messages using a postMessage method and the other side receives a message event it can act upon. \cite{WebWorkers}
|
||||||
|
|
||||||
|
Web Workers are used in this project to put a load on the CPU to modify the magnetic field without locking up the website itself.
|
||||||
|
|
||||||
|
\section{Manchester Code}
|
||||||
|
|
||||||
|
\section{Hall Sensor}
|
||||||
|
|
|
@ -1,15 +1,8 @@
|
||||||
\chapter{Personas}
|
\chapter{Personas}
|
||||||
This chapter describes the personas with their goals and problems that they want
|
This chapter describes the personas with their motivations, goals and problems that they want
|
||||||
to have solved. These personas are later used in the use cases and requirements
|
to have solved. These motivations are then later used to create and describe the requirements in \autoref{chapter:requirements}.
|
||||||
in \autoref{chapter:requirements}.
|
|
||||||
|
|
||||||
\section{Alice}
|
\textbf{Alice} \\
|
||||||
Alice wants to be able to receive a small piece of data over a website, similar
|
Alice wants to be able to receive a small piece of data over a website, similar
|
||||||
to a QR code, with her smartphone but without other people being able to see the
|
to a QR code, with her smartphone but without other people being able to see the
|
||||||
"code" over her shoulders.
|
code over her shoulders. She also wants to be able to receive data to her smartphone while it has connection available e.g. when it's in airplane mode.
|
||||||
|
|
||||||
\section{Eve}
|
|
||||||
Eve wants to be able to transmit data from a secure system (e.g. a server) to
|
|
||||||
her smartphone in an otherwise airgapped system (no internet or other
|
|
||||||
connectivity methods available) in a limited amount of available time (e.g. 30
|
|
||||||
minutes).
|
|
||||||
|
|
|
@ -2,43 +2,73 @@
|
||||||
\label{chapter:requirements}
|
\label{chapter:requirements}
|
||||||
|
|
||||||
\section{Functional Requirements}
|
\section{Functional Requirements}
|
||||||
\begin{table}[ht]
|
\begin{table}[H]
|
||||||
\begin{reqTblr}{lll}
|
\begin{reqTblr}{l p{11.8cm}}
|
||||||
ID & F01 \\
|
ID & F01 \\
|
||||||
Title & Website Transmits Data using MI \\
|
Title & Calibration on Website \\
|
||||||
Persona & Persona 1, Persona 2 \\
|
Application & Website \\
|
||||||
Description & Description here...
|
Description & Alice visits the website and starts the calibration mode on the website. While in calibration mode the the website continously puts load on the CPU.
|
||||||
\end{reqTblr}
|
\end{reqTblr}
|
||||||
\caption{Functional Requirement 01}
|
\caption{Functional Requirement 01}
|
||||||
\end{table}
|
\end{table}
|
||||||
|
|
||||||
\begin{table}[ht]
|
\begin{table}[H]
|
||||||
\begin{reqTblr}{lll}
|
\begin{reqTblr}{l p{11.8cm}}
|
||||||
ID & F02 \\
|
ID & F02 \\
|
||||||
Title & Smartphone Receives the Data \\
|
Title & Calibration on App \\
|
||||||
Persona & Persona 1, Persona 2 \\
|
Application & Smartphone App \\
|
||||||
Description & Description here...
|
Description & In the app Alice can start the calibration process. By putting her smartphone on different location on her laptop the app will tell her the current strength of the magnetic field. The point with the strongest magnetic field is the optimal place for data transmission.
|
||||||
\end{reqTblr}
|
\end{reqTblr}
|
||||||
\caption{Functional Requirement 02}
|
\caption{Functional Requirement 02}
|
||||||
\end{table}
|
\end{table}
|
||||||
|
|
||||||
\begin{table}[ht]
|
\begin{table}[H]
|
||||||
\begin{reqTblr}{lll}
|
\begin{reqTblr}{l p{11.8cm}}
|
||||||
ID & F03 \\
|
ID & F03 \\
|
||||||
Title & Smartphone Displays the Data \\
|
Title & Text Entry \\
|
||||||
Persona & Persona 1, Persona 2 \\
|
Application & Website \\
|
||||||
Description & Description here...
|
Description & The website contains a text input field. Alice can enter any ASCII string in this text input.
|
||||||
\end{reqTblr}
|
\end{reqTblr}
|
||||||
\caption{Functional Requirement 03}
|
\caption{Functional Requirement 03}
|
||||||
\end{table}
|
\end{table}
|
||||||
|
|
||||||
|
\begin{table}[H]
|
||||||
|
\begin{reqTblr}{l p{11.8cm}}
|
||||||
|
ID & F04 \\
|
||||||
|
Title & Sending Data \\
|
||||||
|
Application & Website \\
|
||||||
|
Description & Alice visits the website, enter a text and then clicks on the send send button. The website will attempt to send the string in the input field using MI. The data will be sent continously until Alice stops the sending by clicking on the stop button.
|
||||||
|
\end{reqTblr}
|
||||||
|
\caption{Functional Requirement 04}
|
||||||
|
\end{table}
|
||||||
|
|
||||||
|
\begin{table}[H]
|
||||||
|
\begin{reqTblr}{l p{11.8cm}}
|
||||||
|
ID & F05 \\
|
||||||
|
Title & Receiving Data \\
|
||||||
|
Application & Smartphone App \\
|
||||||
|
Description & Alice can start the receiving mode in the app. By putting her smartphone on the laptop she can receive the data that is sent by the website. The app displays the received text on the screen.
|
||||||
|
\end{reqTblr}
|
||||||
|
\caption{Functional Requirement 05}
|
||||||
|
\end{table}
|
||||||
|
|
||||||
|
|
||||||
|
\newpage
|
||||||
\section{Non Functional Requirements}
|
\section{Non Functional Requirements}
|
||||||
\begin{table}[ht]
|
\begin{table}[H]
|
||||||
\begin{reqTblr}{lll}
|
\begin{reqTblr}{l p{11.8cm}}
|
||||||
ID & N01 \\
|
ID & N01 \\
|
||||||
Title & Smartphone Requires No Connectivity \\
|
Title & Working in Airplane Mode \\
|
||||||
Persona & Persona 1, Persona 2 \\
|
Description & Alice can receive data using the app on her smartphone even if she has put her phone in airplane mode.
|
||||||
Description & Description here...
|
|
||||||
\end{reqTblr}
|
\end{reqTblr}
|
||||||
\caption{Non Functional Requirement 01}
|
\caption{Non Functional Requirement 01}
|
||||||
\end{table}
|
\end{table}
|
||||||
|
|
||||||
|
\begin{table}[H]
|
||||||
|
\begin{reqTblr}{l p{11.8cm}}
|
||||||
|
ID & N02 \\
|
||||||
|
Title & Transfer Rate \\
|
||||||
|
Description & The transfer speed between the laptop and smartphone should at least be \SI{2}{\bit\per\second}
|
||||||
|
\end{reqTblr}
|
||||||
|
\caption{Non Functional Requirement 02}
|
||||||
|
\end{table}
|
||||||
|
|
|
@ -1 +1,29 @@
|
||||||
\chapter{Solution}
|
\chapter{Solution}
|
||||||
|
The solution consists of two separate applications: a website used for transmitting data and a smartphone application used for receiving data. Transmission between the two application happens using a simple protocol on top of magnetic induction.
|
||||||
|
|
||||||
|
\section{Protocol}
|
||||||
|
The main communication protocol works over magnetic induction. By putting load on a CPU the resulting magnetic field can be changed. Using a magnetometer in a smartphone these changes can be measured and interpreted.
|
||||||
|
|
||||||
|
For simplification purposes the protocol in this project is used to transmit ASCII text but in reality any bit stream can be transmitted.
|
||||||
|
|
||||||
|
To indicate the start of a message in the transmission a preamble is used. The preamble used in this protocol is 3 high signals, followed by 1 low signal, followed by 3 high signals.
|
||||||
|
|
||||||
|
\subsection{Sending}
|
||||||
|
\begin{enumerate}
|
||||||
|
\item{Convert the text to an ASCII encoded bit stream}
|
||||||
|
\item{Encode the ASCII bit stream using manchester encoding}
|
||||||
|
\item{Start the transmission by sending the preamble}
|
||||||
|
\item{Transmit the manchester encoded bit stream}
|
||||||
|
\item{Repeat from step 3 until transmission is stopped}
|
||||||
|
\end{enumerate}
|
||||||
|
|
||||||
|
\subsection{Receiving}
|
||||||
|
\begin{enumerate}
|
||||||
|
\item{Detect the preamble}
|
||||||
|
\item{Decode the received manchester encoded bit stream}
|
||||||
|
\item{Convert the ASCII bit stream to text}
|
||||||
|
\end{enumerate}
|
||||||
|
|
||||||
|
\section{Website}
|
||||||
|
|
||||||
|
\section{App}
|
||||||
|
|
|
@ -30,6 +30,11 @@
|
||||||
\usepackage{pgfgantt}
|
\usepackage{pgfgantt}
|
||||||
\usepackage{rotating}
|
\usepackage{rotating}
|
||||||
|
|
||||||
|
\usepackage{siunitx}
|
||||||
|
\sisetup{per-mode=symbol}
|
||||||
|
|
||||||
|
\usepackage{float}
|
||||||
|
|
||||||
% https://tex.stackexchange.com/a/24827
|
% https://tex.stackexchange.com/a/24827
|
||||||
\makeatletter
|
\makeatletter
|
||||||
\def\input@path{{documentation/thesis/content}}
|
\def\input@path{{documentation/thesis/content}}
|
||||||
|
@ -75,6 +80,9 @@
|
||||||
\bibliographystyle{plainurl}
|
\bibliographystyle{plainurl}
|
||||||
\bibliography{thesis}
|
\bibliography{thesis}
|
||||||
|
|
||||||
|
\listoffigures
|
||||||
|
\listoftables
|
||||||
|
|
||||||
\appendix
|
\appendix
|
||||||
\chapter{First appendix Chapter}
|
\chapter{First appendix Chapter}
|
||||||
\end{document}
|
\end{document}
|
||||||
|
|
|
@ -13,3 +13,4 @@
|
||||||
## Next Steps
|
## Next Steps
|
||||||
- Test different worker amounts
|
- Test different worker amounts
|
||||||
- Finish personas, use cases and requirements
|
- Finish personas, use cases and requirements
|
||||||
|
- Plan protocol and signal
|
||||||
|
|
17
notes/2022-10-27_meeting.md
Normal file
17
notes/2022-10-27_meeting.md
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
# Meeting 2022-10-27
|
||||||
|
## Attendees
|
||||||
|
* Severin Kaderli
|
||||||
|
* Reto König
|
||||||
|
|
||||||
|
## Progress
|
||||||
|
* Requirements
|
||||||
|
* Solution
|
||||||
|
* Mockups
|
||||||
|
|
||||||
|
## Topics
|
||||||
|
|
||||||
|
|
||||||
|
## Next Steps
|
||||||
|
- Postamble
|
||||||
|
- Consider other protocols (checksums, preamble, postamble)
|
||||||
|
- Risks of transmission failure
|
|
@ -14,7 +14,7 @@
|
||||||
|
|
||||||
# 2022-09-25
|
# 2022-09-25
|
||||||
* Another test with a speaker
|
* Another test with a speaker
|
||||||
* No change measurable in magnetmeter even if I can see the coil vibrate
|
* No change measurable in magnetometer even if I can see the coil vibrate
|
||||||
* I assume the change in the magnetic field is too small to be measured
|
* I assume the change in the magnetic field is too small to be measured
|
||||||
* Finish project plan
|
* Finish project plan
|
||||||
|
|
||||||
|
@ -80,3 +80,23 @@
|
||||||
* Eve
|
* Eve
|
||||||
* Wants to transmit data in an airgapped system
|
* Wants to transmit data in an airgapped system
|
||||||
* eg.
|
* eg.
|
||||||
|
|
||||||
|
# 2022-10-25
|
||||||
|
* Flesh out requirements
|
||||||
|
* Signal
|
||||||
|
* Preamble
|
||||||
|
* 3 Hi
|
||||||
|
* 1 Low
|
||||||
|
* 3 Hi
|
||||||
|
* Protocol
|
||||||
|
* Manchester Encoded Bits
|
||||||
|
* Clock of 250ms
|
||||||
|
|
||||||
|
# 2022-10-26
|
||||||
|
* Start documenting solution
|
||||||
|
* Start documenting some preliminaries
|
||||||
|
* Update requirements and personas
|
||||||
|
* Create mockups for app and website
|
||||||
|
|
||||||
|
# 2022-10-27
|
||||||
|
* Prepare meeting notes
|
||||||
|
|
|
@ -9,20 +9,21 @@
|
||||||
<body>
|
<body>
|
||||||
Hello World!
|
Hello World!
|
||||||
<script>
|
<script>
|
||||||
|
const time = 250;
|
||||||
let workers = [];
|
let workers = [];
|
||||||
|
|
||||||
function startWorkers() {
|
function startWorkers() {
|
||||||
for (let i = 0; i < 8; i++) {
|
for (let i = 0; i < 8; i++) {
|
||||||
workers.push(new Worker("worker.js"));
|
workers.push(new Worker("worker.js"));
|
||||||
}
|
}
|
||||||
setTimeout(stopWorkers, 2000);
|
setTimeout(stopWorkers, time);
|
||||||
}
|
}
|
||||||
|
|
||||||
function stopWorkers() {
|
function stopWorkers() {
|
||||||
for (const worker of workers) {
|
for (const worker of workers) {
|
||||||
worker.terminate();
|
worker.terminate();
|
||||||
}
|
}
|
||||||
setTimeout(startWorkers, 2000);
|
setTimeout(startWorkers, time);
|
||||||
}
|
}
|
||||||
startWorkers();
|
startWorkers();
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -32,3 +32,11 @@
|
||||||
year = "2012",
|
year = "2012",
|
||||||
title = "Near field magnetic induction Communication in Body Area Network",
|
title = "Near field magnetic induction Communication in Body Area Network",
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@online{WebWorkers,
|
||||||
|
author = "MDN contributors",
|
||||||
|
title = "Web Workers API",
|
||||||
|
year = "2022",
|
||||||
|
url = "https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API",
|
||||||
|
urldate = "2022-10-26"
|
||||||
|
}
|
||||||
|
|
Reference in a new issue