diff --git a/a4.md b/a4.md index ee95142..314f6bd 100644 --- a/a4.md +++ b/a4.md @@ -1 +1,17 @@ -# Channel access method for shared mediums \ No newline at end of file +# Channel access method for shared mediums + +## Time Division (TDMA) +assigns time-slots to each transmitter in which they are allowed to send. +Dynamic slots can be used to adjust for variable bit-rate streams. + +## Frequency Division (FDMA) +assigns parts of the total bandwidth into multiple channels. + + +## Code Division (CDMA) +Uses orthogonal codes assigned to transmitters, allowing them to send on the same time and frequency. + +Both TDMA and FDMA need guard intervals that remain relatively fixed with rising numbers of participants. +CDMA in comparison is directly limited by the Shannon-Hartley channel capacity, +meaning that an increased noise floor introduced by an increasing number of transmitters results in temporarily decreased call quality, +whereas other channel division methods would usually result in permanently decreased quality. \ No newline at end of file diff --git a/cdma.Rmd b/cdma.Rmd new file mode 100644 index 0000000..a35c9f1 --- /dev/null +++ b/cdma.Rmd @@ -0,0 +1,40 @@ +--- +title: "CDMA" +subtitle: "Software Defined Radio" +output: pdf_document +date: "`r Sys.Date()`" +--- +# Assignment +In the R environment for statistical computing, develop +software support for generating a CDMA composite +signal. Provide four parallel communication channels +with corresponding characteristic code sequences of 5 +bits length. Define software support for accepting +ASCII characters (via a terminal or reading from a data +file), converting ASCII characters into binary data, +coding with the respective code sequence of the given +communication channel, and decoding and deciding +on the receiving side. + +```{r setup, include=FALSE} +knitr::opts_chunk$set(echo = TRUE) +``` + +## Getting Input +We first get input by reading a file `input.txt`, where each line (0-3) is one communication channel. +Because UTF8 maintains compatibility with ASCII, the UTF8 conversion can be used assuming that the input is only ASCII. +ASCII characters require 7 bits of information per character. +```{r input} +lines <- readLines('./input.txt') +lines_bin <- unlist(lapply(lines, utf8ToInt)) +``` + +```{r input-demo, echo=FALSE} +print(lines) +print(lines_bin) +``` + +## Orthogonal Code +For an orthogonal code, we are looking for vectors $(a,b,...n)$ in that satisfy pairwise orthogonality $a \perp b$. + + diff --git a/input.txt b/input.txt new file mode 100644 index 0000000..d68dd40 --- /dev/null +++ b/input.txt @@ -0,0 +1,4 @@ +a +b +c +d