Thursday, 16 June 2011

Storing wishlists

I have been searching for a good way to store stuff that I want to buy in a meaningful place so that I can check them in a shop from my cell phone for a good time now. I tried some note taking applications but I didn't really find them easy enough to use.

I just came up with a solution that fits me. I have been using (as it was known before) to store bookmarks but I kind of stopped using it about two years when bookmark synchronization came to browsers (or rather I started using that feature). Bookmark sync isn't really useful for this sort of stuff, though, because it will just clutter your bookmarks folder. works better because it focused more on tag based browsing of your bookmarks so there is no problem having hundreds or even thousands of bookmarks stored there. So now I can just bookmark wishlist items and tag them accordingly (e.g. "books" and "wishlist"). In the store I'll just start up Andricious, and open bookmarks tagged "wishlist". Of course I need to do some cleaning once in a while to keep the list meaningful but then again, I'd need to do that with any system.

I like this approach because it is so flexible. Only real requirement is that the pages are named in a meaningful way (so that the name fits into the screen).

It will be interesting to see what happens to delicious now that it's moving to Yahoo. Hope they don't ruin it.

Monday, 13 June 2011

HTPC is dead, long live HTPC?

I haven't been happy with my HTPC box. UI is clunky, SW keeps crashing and the remote that came with the chassis is downright horrible. And rthere are still some issues to solve which I just can't be arsed with.

So an idea struck me on my way to work: I'll move the box next to my other PC. It has already Linux  - something I have been missing since I bought a new comp and it has plenty of processing power (iGPU is plenty enough for my use).

All I need is one of these and a DLNA server for Linux. There are plenty, I think I'll check out at least these (funny there doesn't seem to be any available from Ubuntu's repositories):

TVMobili looks like the prime candidate at the moment. Main requirement is that it can strem .ISO files since that's the format our DVDs are at the moment. And hopefully it won't have any problems with our Sony BD player.

If the free players don't work I could have a go with Wild Media Server.

Tuesday, 7 June 2011

LTE Downlink Air-Interface

I found the explanations on how the air-interface in LTE DL works a bit complicated (well, it is complicated...) especially since it took some time to figure out how data is actually mapped. As a reminder, downlink is when data is sent from eNodeB (LTE base station) to UE (user equipment). Uplink is the other way around.

Data in the downlink is sent using OFDMA (Orthogonal Frequency Division Multiple Access). The bandwidth, which there are several possible (e.g. 5MHz and 20MHz), is divided to 15kHz subcarriers. So for instance in 5MHz bandwidth there are 300 subcarriers.

Data is mapped in two domains: frequency and time. Symbols represent the frequency domain and frames represent time domain. One symbol represents all subcarriers and is created with IFFT (Inverse Fast Fourier Transformation). Each subcarrier "holds" one modulation symbol per symbol. A modulation symbol's size depends on the modulation used, there are four different used: BPSK (1 bit/sym, this is not used to transfer any data, just ACK messages), QPSK (2 bits/sym), 16QAM (4 bits/sym) and 64QAM (6 bits/symbol). Data is sent/received one symbol at a time so the more bits that can be squeezed to one modulation symbol the better (downside is that the more bits there are the better the signal quality has to be). Bandwidth obviously also affects throughput since the larger the bandwidth, the more subcarriers there are.

One UE has at least 12 subcarriers. but can have any multiple of 12. 

That's the frequency domain. It can be thought in a way as n*sc (n=number of bits per modulation symbol and sc sc = number of sub carriers) bit pattern created by running IFFT on the modulation symbols.

In time domain a frame is split into ten subframes (each taking 1 ms) which in turn are split into two slots. Each slot holds seven symbols (with normal cyclic prefix which is the norm, with extended cyclic prefix which used when distances between eNodeB and UEs are long there are six). Data allocation for UE is done by Resource Blocks which consists of Resource Elements. One RE is one slot on one subcarrier and one Resource Block is made up of 12 subcarriers and one slot (this is why subcarriers are always divided in sets of 12). So one RB has 84 RE's with normal cyclic prefix. 

The figure below tries to simplify this by starting from the modulation symbol, in this case QPSK modulated. The value of this modulation symbol is 00 in this case. This is located in the second slot in the frame's first subframe and in the last slot. After FFT (which does the opposite to IFFT) the end result is that bits 26 and 27 are represented as '00'. The figure shows one frame and 12 subcarriers, so the yellow part represents one Resource Block and each individual box is one Resource Element.

This example was for single antenna usage, with MIMO things are even more complex. In diversity mode data is just sent on several layers (LTE term for antenna streams) simultaneously which improves data quality when the conditions are poor but with spatial multiplexing data is actually split between layers and have to combined again in the receiver. This increases throughput.

This of course isn't data per se, there are still many operations required in the PHY layer (L1) to get the actual data that upper layers can use. Air interface handles codewords which are created from transport blocks (received from the MAC layer) by doing the following procedures on them:
  • CRC attachment,
  • Insertion of filler bits,
  • Code block segmentation,
  • Additional CRC attachment,
  • Channel coding (turbo coding),
  • Rate matching,
  • Code block concatenation.
I won't explain these here but these operations are quite straightforward.

After this these codewords are modulated, mapped into resource elements, IFFT is performed, cyclic prefix is added, D/A conversion is done and finally the signal is mixed to RF. And this RF signal is then received by the UE and the same operations are done in reverse.

In single antenna mode, using 64QAM in the 20MHz BW and normal cyclic prefix maximum throughput is 100.8 Mbps. It works out like this:
  • 1200 subcarriers.
  • 6 bits per modulation symbol.
  • 7 modulation symbols per slot, 2 slots per subframe (1ms).
  • => 1200 * 6 * 20 = 100.8 kbits/1ms = 100.8 Mbps.
With 4x4 spatial multiplexing absolute maximum throughput for LTE is 403.2 Mbps.

These numbers represent total throughput. Actual data throughput is smaller because there are also channels that carry control and other data (PDCCH, PCFICH, PHICH and PRACH channels - I'm not going to explain these here, maybe on some upcoming blog post) which take up resource elements, reference and synhcronization signals etc. The data itself is also coded with CRC attachments, filler bits and channel coding. Overhead depends mainly on bandwidth and channel conditions (modulation is dropped from 64QAM to 16QAM and even QPSK and channel coding uses more bits are channel conditions detoriate).