Project

General

Profile

OsmoTRX » History » Version 29

ttsou, 02/19/2016 10:47 PM

1 1 ttsou
= OsmoTRX =
2 1 ttsou
3 1 ttsou
OsmoTRX is a software-defined radio transceiver that implements the Layer 1 physical layer of a BTS comprising the following 3GPP specifications:
4 1 ttsou
 * TS 05.01 "Physical layer on the radio path"
5 1 ttsou
 * TS 05.02 "Multiplexing and Multiple Access on the Radio Path"
6 1 ttsou
 * TS 05.04 "Modulation"
7 1 ttsou
 * TS 05.10 "Radio subsystem synchronization"
8 1 ttsou
9 29 ttsou
OsmoTRX is based on the OpenBTS transceiver, but setup to operate independently with the purpose of using with non-OpenBTS software and projects. Currently there are numerous features contained in OsmoTRX that extend the functionality of the OpenBTS transceiver. These features include enhanced support for various embedded platforms - notably ARM - and dual channel diversity support for the Fairwaves UmTRX. Most of these features will eventually be merged into mainline OpenBTS, but development will occur primarily on OsmoTRX.
10 6 ttsou
11 6 ttsou
== Features ==
12 6 ttsou
13 16 ttsou
'''Intel SSE Support'''
14 6 ttsou
* SSE3
15 6 ttsou
* SSE4.1
16 6 ttsou
17 20 ttsou
On Intel processors, OsmoTRX makes heavy use of the Streaming SIMD Extensions (SSE) instruction set. Accelerated operations include pulse shape filtering, resampling, sequence correlation, and many other signal processing operations. SSE3 is the minimum requirement for accelerated use.
18 1 ttsou
19 26 ttsou
SSE3 is present in the majority of Intel processors since later versions of the Pentium 4 architecture and is also present on low power Atom processors. Support is automatically detected at build time. For additional performance information, please see the performance and benchmarks section.
20 20 ttsou
21 29 ttsou
'''ARM Support'''
22 6 ttsou
* NEON
23 1 ttsou
* NEON-VFPv4
24 6 ttsou
25 20 ttsou
OsmoTRX runs on a variety of ARM processors with and without NEON coprocessors. Like SSE on Intel processors, NEON provides acceleration with SIMD vectorized instructions.
26 1 ttsou
27 20 ttsou
Tested popular architectures include ARM11 (Raspberry Pi), Cortex-A8 (!BeagleBoard), and Cortex-A15 (!ArndaleBoard). Loosely speaking, these platforms are representative of low cost embedded devices, mid-level handsets, and high-end smartphones respectively. Similarly, in order, these platforms include no NEON coprocessor, standard NEON, and NEON-VFPv4. The latter NEON variation, VFPv4, provides additional fused-multiply-accumulate (FMA) instructions useful for many DSP operations.
28 20 ttsou
29 26 ttsou
NEON support must be enabled by the user at build time. For additional information, please see the configuration and performance and benchmarks sections.
30 20 ttsou
31 6 ttsou
'''Dual Channel (UmTRX only)'''
32 7 ttsou
33 7 ttsou
Two dual channel modes are available: standard dual channel mode and diversity. In standard dual channel mode, each RF
34 7 ttsou
path of the dual channel device - currently only UmTRX - supports a different ARFCN. Each path operates independently a
35 28 ttsou
nd operates similarly to two separate devices. GSM channel capacity in this mode is doubled. This option can be configured at run time from the command line.
36 1 ttsou
37 8 ttsou
'''Dual Channel Diversity (UmTRX only)'''
38 1 ttsou
39 28 ttsou
Diversity mode is similar to the standard dual channel mode except each antenna supports both ARFCN channels. In this case, the receiver sample bandwidth is widened to handle both ARFCN's and subsequently converted and demultiplexed into separate sample streams. Each GSM receive path is fed dual signals, where antenna selection diversity is performed by taking the stronger signal on a burst-by-burst basis. This diversity setup improves uplink reception performance in multipath fading environments.
40 16 ttsou
41 28 ttsou
Limitations are increased CPU utilization and that ARFCN spacing is restricted (currently at 400 kHz) by the receiver sampling bandwidth. Setting the ARFCN spacing beyond the sampling limit will disable the diversity path and operate in standard dual channel mode. This options can be configured at run time from the command line.
42 20 ttsou
43 16 ttsou
'''Low Phase Error Modulator'''
44 16 ttsou
45 1 ttsou
The default GSM downlink signal is configured for low distortion using a linearized GMSK modulator. The implementation is based on a two pulse Laurent approximation of continuous phase modulated (CPM) signals. The baseband output signal measures with very low phase error and is capable of passing industry spectrum mask requirements. Please note that actual performance will depend strongly on the particular device in use.
46 1 ttsou
47 1 ttsou
Theoretical details can be found in the report on [http://tsou.cc/gsm/report_gmsk.pdf GMSK]. Octave / Matlab code for [http://tsou.cc/gsm/laurent.m pulse generation] is also available.
48 28 ttsou
49 28 ttsou
This option can be enabled or disabled at run time from the command line.
50 16 ttsou
51 20 ttsou
Very Low Phase Error (Ettus Research N200)
52 1 ttsou
53 1 ttsou
[[Image(http://tsou.cc/gsm/osmo-trx-phase75.gif)]]
54 1 ttsou
55 21 ttsou
Spectrum Mask (Ettus Research N200)
56 1 ttsou
57 1 ttsou
[[Image(http://tsou.cc/gsm/osmo-trx-spectrum75.gif)]]
58 1 ttsou
59 20 ttsou
== RF Hardware support ==
60 1 ttsou
61 20 ttsou
Multiple RF devices are currently supported. These include USRP family products from Ettus Research, and the UmTRX from Fairwaves.
62 1 ttsou
63 20 ttsou
||'''Fairwaves'''||'''Notes'''||
64 20 ttsou
||UmTRX||Dual channel||
65 20 ttsou
66 20 ttsou
All Ettus Research devices are supported.
67 20 ttsou
68 20 ttsou
||'''Ettus Research'''||'''Notes'''||
69 20 ttsou
||USRP1||Requires legacy libusrp driver and clocking modification||
70 20 ttsou
||USRP2||10 MHz external reference required||
71 1 ttsou
||B100||
72 1 ttsou
||B110||
73 20 ttsou
||B200||10 MHz external reference recommended||
74 20 ttsou
||B210||* Dual channel, 10 MHz external reference recommended||
75 1 ttsou
||N200||
76 1 ttsou
||N210||
77 1 ttsou
||E100||
78 1 ttsou
||E110||
79 1 ttsou
80 20 ttsou
* Ettus B210 dual channel support with OsmoTRX is currently unavailable, but is expected to be added at a later time.
81 20 ttsou
82 1 ttsou
== Embedded Platform Support ==
83 1 ttsou
84 20 ttsou
OsmoTRX has been tested on the multiple embedded platforms representing a wide range of device types. Low cost ARM devices are generally limited by memory and I/O as much CPU utilization.
85 1 ttsou
86 20 ttsou
Running a full or near full ARFCN configuration (7 simultaneous TCH channels with Combination V) may require running the GSM stack remotely, which can be configured at runtime on the command line. This limitation appears to be scheduling related more so than lack of CPU resources, and may be resolved at a later time.
87 20 ttsou
88 20 ttsou
||'''Platform'''||'''SoC'''||'''Processor'''||'''SIMD/FPU'''||'''Testing Notes'''
89 20 ttsou
||!ArndaleBoard||Samsung Exynos 5250||ARM Cortex-A15||NEON-VFPv4||7 TCH||
90 21 ttsou
||!BeagleBoard-xM||Texas Instruments OMAP3||ARM Cortex-A8||NEON||7 TCH, remote OsmoBTS stack||
91 21 ttsou
||Ettus E100||Texas Instruments OMAP3||ARM Cortex-A8||NEON||7 TCH, remote OsmoBTS stack||
92 21 ttsou
||Raspberry Pi||Broadcom BCM2835||ARM11||VFP||2 TCH, remote OsmoBTS stack||
93 1 ttsou
||Shuttle PC||NA||Intel Atom D2550||SSE3||Dual channel, 15 TCH||
94 20 ttsou
95 25 ttsou
All embedded plaforms were tested with low-phase error modulator disabled. Use of the more accurate modulator on embedded platforms has not been extensively tested.
96 19 ttsou
97 19 ttsou
== Mailing List ==
98 18 ttsou
99 1 ttsou
For development purposes, OsmoTRX is discussed on both OpenBTS and OpenBSC mailing lists at openbts-discuss@lists.sourceforge.net and openbsc@lists.osmocom.org respectively.
100 1 ttsou
101 22 ttsou
Please direct questions and bug reports to the list appropriate for the GSM stack being used.
102 19 ttsou
103 16 ttsou
Subscription information is available at [https://lists.sourceforge.net/lists/listinfo/openbts-discuss] and [http://lists.osmocom.org/mailman/listinfo/openbsc/].
104 19 ttsou
105 19 ttsou
== GPRS support ==
106 16 ttsou
107 1 ttsou
OsmoTRX supports GPRS through OsmoBTS.
108 16 ttsou
109 1 ttsou
For GPRS support with OpenBTS, please use the transceiver supplied with OpenBTS.
110 1 ttsou
111 1 ttsou
== Source code ==
112 16 ttsou
113 1 ttsou
The source code is available from git.osmocom.org (module osmo-trx).
114 1 ttsou
115 1 ttsou
Public read-only access is available via
116 18 ttsou
 git clone git://git.osmocom.org/osmo-trx
117 1 ttsou
You can browse it via cgit: http://cgit.osmocom.org/cgit/osmo-trx/
118 18 ttsou
119 18 ttsou
== Configuration and Build ==
120 19 ttsou
121 1 ttsou
The only package dependency is the Universal Hardware Driver (UHD), which is available from Ettus Research or Fairwaves depending on the device. Please note that the UHD implementation must match hardware (i.e. Ettus Research UHD for USRP devices and Fairwaves UHD with UmTRX). The one device that does not use the UHD driver is the USRP1, which is supported through the legacy libusrp driver provided in GNU Radio 3.4.2.
122 1 ttsou
123 18 ttsou
'''Intel Platforms (All)'''
124 18 ttsou
125 18 ttsou
Intel SSE support is automatically detected on Intel x86 platforms. No user intervention is necessary. The general configuration defaults to the low phase error modulator. Atom users may wish to use the low-CPU utilization modulator, which can be later enabled from the command line at runtime.
126 18 ttsou
{{{
127 18 ttsou
$ ./configure
128 18 ttsou
...
129 1 ttsou
checking whether mmx is supported... yes
130 18 ttsou
checking whether sse is supported... yes
131 18 ttsou
checking whether sse2 is supported... yes
132 18 ttsou
checking whether sse3 is supported... yes
133 18 ttsou
checking whether ssse3 is supported... yes
134 18 ttsou
checking whether sse4.1 is supported... yes
135 1 ttsou
checking whether sse4.2 is supported... yes
136 19 ttsou
...
137 18 ttsou
}}}
138 18 ttsou
139 18 ttsou
'''ARM Platforms with NEON'''
140 18 ttsou
141 18 ttsou
Many popular ARM development boards fall under this category including !BeagleBoard, !PandaBoard, and Ettus E100 USRP. This option will disable the low phase error modulator, which can be re-enabled at runtime. NEON support must be manually enabled.
142 18 ttsou
{{{
143 19 ttsou
$ ./configure --with-neon
144 18 ttsou
}}}
145 18 ttsou
146 18 ttsou
'''ARM Platforms with NEON-VFPv4'''
147 18 ttsou
148 18 ttsou
Currently very few development platforms support this instruction set, which is seen mainly in high end smartphones and tablets. Available development boards are !ArndaleBoard and ODROID-XU. This option will disable the low phase error modulator, which can be re-enabled at runtime. NEON-VFPv4 support must be manually enabled.
149 18 ttsou
{{{
150 18 ttsou
$ ./configure --with-neon-vfpv4
151 18 ttsou
}}}
152 18 ttsou
153 18 ttsou
'''ARM Platforms without NEON'''
154 18 ttsou
155 18 ttsou
This configuration mainly targets the Raspberry Pi. ARM platforms without NEON vector units are almost always very slow processors, and generally not very suitable for running OsmoTRX. Running OsmoTRX on a Raspberry Pi, however, is possible along with limited TCH (voice) channel support. Currently this configuration requires minor code changes.
156 1 ttsou
157 24 ttsou
Coming soon...
158 18 ttsou
159 16 ttsou
'''Build and Install'''
160 16 ttsou
161 16 ttsou
After configuration, installation is simple.
162 16 ttsou
163 16 ttsou
{{{
164 18 ttsou
$ make
165 19 ttsou
$ sudo make install
166 16 ttsou
}}}
167 16 ttsou
168 16 ttsou
== Running ==
169 16 ttsou
170 16 ttsou
OsmoTRX can be configured with a variety of options on the command line. In most cases, the default settings will suffice. Notable options include UHD device argument passing, which is often useful for using network based devices with firewalls, and external 10 MHz reference support.
171 16 ttsou
172 16 ttsou
{{{
173 16 ttsou
$ osmo-trx -h
174 16 ttsou
linux; GNU C++ version 4.8.1 20130603 (Red Hat 4.8.1-1); Boost_105300; UHD_003.005.004-140-gfb32ed16
175 16 ttsou
176 16 ttsou
Options:
177 16 ttsou
  -h    This text
178 16 ttsou
  -a    UHD device args
179 16 ttsou
  -l    Logging level (EMERG, ALERT, CRT, ERR, WARNING, NOTICE, INFO, DEBUG)
180 16 ttsou
  -i    IP address of GSM core
181 16 ttsou
  -p    Base port number
182 16 ttsou
  -d    Enable dual channel diversity receiver
183 16 ttsou
  -x    Enable external 10 MHz reference
184 16 ttsou
  -s    Samples-per-symbol (1 or 4)
185 16 ttsou
  -c    Number of ARFCN channels (default=1)
186 16 ttsou
}}}
187 16 ttsou
188 16 ttsou
{{{
189 16 ttsou
$ osmo-trx -a "addr=192.168.10.2"
190 16 ttsou
linux; GNU C++ version 4.8.1 20130603 (Red Hat 4.8.1-1); Boost_105300; UHD_003.004.000-b14cde5
191 16 ttsou
192 16 ttsou
Config Settings
193 16 ttsou
   Log Level............... INFO
194 16 ttsou
   Device args............. addr=192.168.10.2
195 16 ttsou
   TRX Base Port........... 5700
196 1 ttsou
   TRX Address............. 127.0.0.1
197 16 ttsou
   Channels................ 1
198 1 ttsou
   Samples-per-Symbol...... 4
199 1 ttsou
   External Reference...... Disabled
200 16 ttsou
   Diversity............... Disabled
201 16 ttsou
202 16 ttsou
-- Opening a UmTRX device...
203 16 ttsou
-- Current recv frame size: 1472 bytes
204 16 ttsou
-- Current send frame size: 1472 bytes
205 16 ttsou
-- Setting UmTRX 4 SPS
206 19 ttsou
-- Transceiver active with 1 channel(s)
207 13 ttsou
}}}
208 19 ttsou
209 19 ttsou
== Benchmarks ==
210 17 ttsou
211 13 ttsou
A variety of performance benchmarks are available for various code optimizations. These include floating point - integer conversions, convolution, and convolutional decoding. Note that convolutional decoding does not take place in OsmoTRX, but one stop higher in the Layer 1 stack - either in OsmoBTS or OpenBTS core.
212 13 ttsou
213 1 ttsou
Selected benchmark results are provided below. All tests are run on a single core only.
214 24 ttsou
215 24 ttsou
The benchmark code repository is coming soon...
216 13 ttsou
217 13 ttsou
'''Intel Haswell (i7 4770K 3.5 GHz)'''
218 13 ttsou
219 13 ttsou
{{{
220 10 ttsou
--- Floating point to integer conversions
221 10 ttsou
-- Testing 40000 iterations of 3120 values
222 1 ttsou
- Measuring conversion time
223 1 ttsou
- Elapsed time base...                  0.065508 secs
224 1 ttsou
- Validating SIMD conversion results... PASS
225 1 ttsou
- Measuring conversion time
226 1 ttsou
- Elapsed time SIMD ...                 0.011424 secs
227 1 ttsou
- Speedup...                            5.734244
228 1 ttsou
}}}
229 1 ttsou
230 1 ttsou
{{{
231 1 ttsou
[+] Testing: GSM TCH/AFS 7.95 (recursive, flushed, punctured)
232 1 ttsou
[.] Input length  : ret = 165  exp = 165 -> OK
233 1 ttsou
[.] Output length : ret = 448  exp = 448 -> OK
234 3 ttsou
[.] Pre computed vector checks:
235 3 ttsou
[..] Encoding: OK
236 3 ttsou
[..] Decoding base: 
237 3 ttsou
[..] Decoding SIMD: 
238 3 ttsou
[..] Code N 3
239 3 ttsou
[..] Code K 7
240 3 ttsou
OK
241 3 ttsou
[.] Random vector checks:
242 3 ttsou
[.] Testing baseline:
243 3 ttsou
[..] Encoding / Decoding 10000 cycles:
244 3 ttsou
[.] Elapsed time........................ 1.435066 secs
245 3 ttsou
[.] Rate................................ 3.121808 Mbps
246 1 ttsou
[.] Testing SIMD:
247 1 ttsou
[..] Encoding / Decoding 10000 cycles:
248 17 ttsou
[.] Elapsed time........................ 0.073524 secs
249 1 ttsou
[.] Rate................................ 60.932485 Mbps
250 1 ttsou
[.] Speedup............................. 19.518334
251 1 ttsou
}}}
252 1 ttsou
253 17 ttsou
'''Intel Atom (D2500 1.86 GHz)'''
254 17 ttsou
{{{
255 17 ttsou
--- Floating point to integer conversions
256 17 ttsou
-- Testing 40000 iterations of 3120 values
257 17 ttsou
- Measuring conversion time
258 17 ttsou
- Elapsed time base...                 1.147449 secs
259 17 ttsou
- Validating SSE conversion results... PASS
260 17 ttsou
- Measuring conversion time
261 17 ttsou
- Elapsed time SSE ...                 0.347838 secs
262 17 ttsou
- Quotient...                          3.298803
263 17 ttsou
}}}
264 17 ttsou
265 17 ttsou
{{{
266 17 ttsou
[+] Testing: GSM TCH/AFS 7.95 (recursive, flushed, punctured)
267 17 ttsou
[.] Input length  : ret = 165  exp = 165 -> OK
268 17 ttsou
[.] Output length : ret = 448  exp = 448 -> OK
269 17 ttsou
[.] Pre computed vector checks:
270 17 ttsou
[..] Encoding: OK
271 17 ttsou
[..] Decoding base: 
272 17 ttsou
[..] Decoding SIMD: 
273 17 ttsou
[..] Code N 3
274 1 ttsou
[..] Code K 7
275 1 ttsou
OK
276 1 ttsou
[.] Random vector checks:
277 17 ttsou
[.] Testing baseline:
278 17 ttsou
[..] Encoding / Decoding 10000 cycles:
279 17 ttsou
[.] Elapsed time........................ 11.822688 secs
280 17 ttsou
[.] Rate................................ 0.378932 Mbps
281 17 ttsou
[.] Testing SIMD:
282 17 ttsou
[..] Encoding / Decoding 10000 cycles:
283 17 ttsou
[.] Elapsed time........................ 0.550423 secs
284 19 ttsou
[.] Rate................................ 8.139195 Mbps
285 19 ttsou
[.] Speedup............................. 21.479277
286 19 ttsou
}}}
287 17 ttsou
288 17 ttsou
'''!ArndaleBoard (ARM Cortex-A15 1.7 GHz)'''
289 17 ttsou
290 17 ttsou
Please note that the Viterbi implementations on ARM is largely C based with speedup generated primarily through algorithm changes. In comparison, vector optimization on Intel platforms with SSE is currently much more aggressive, which explains the disparity on decoding performance.
291 17 ttsou
292 17 ttsou
{{{
293 17 ttsou
--- Floating point to integer conversions
294 17 ttsou
-- Testing 40000 iterations of 3120 values
295 17 ttsou
- Measuring conversion time
296 17 ttsou
- Elapsed time base...                 0.384097 secs
297 17 ttsou
- Validating SSE conversion results... PASS
298 17 ttsou
- Measuring conversion time
299 17 ttsou
- Elapsed time SSE ...                 0.100877 secs
300 17 ttsou
- Quotient...                          3.807578
301 17 ttsou
}}}
302 17 ttsou
303 17 ttsou
{{{
304 17 ttsou
[+] Testing: GSM TCH/AFS 7.95 (recursive, flushed, punctured)
305 17 ttsou
[.] Input length  : ret = 165  exp = 165 -> OK
306 17 ttsou
[.] Output length : ret = 448  exp = 448 -> OK
307 17 ttsou
[.] Pre computed vector checks:
308 17 ttsou
[..] Encoding: OK
309 17 ttsou
[..] Decoding base: 
310 17 ttsou
[..] Decoding SIMD: 
311 17 ttsou
[..] Code N 3
312 17 ttsou
[..] Code K 7
313 17 ttsou
OK
314 17 ttsou
[.] Random vector checks:
315 17 ttsou
[.] Testing baseline:
316 17 ttsou
[..] Encoding / Decoding 10000 cycles:
317 17 ttsou
[.] Elapsed time........................ 5.371288 secs
318 17 ttsou
[.] Rate................................ 0.834064 Mbps
319 17 ttsou
[.] Testing SIMD:
320 17 ttsou
[..] Encoding / Decoding 10000 cycles:
321 17 ttsou
[.] Elapsed time........................ 1.016621 secs
322 17 ttsou
[.] Rate................................ 4.406755 Mbps
323 17 ttsou
[.] Speedup............................. 5.283471
324 17 ttsou
}}}
325 17 ttsou
326 3 ttsou
'''!BeagleBoard-xM (ARM Cortex-A8 800 MHz)'''
327 3 ttsou
{{{
328 3 ttsou
--- Floating point to integer conversions
329 3 ttsou
-- Testing 40000 iterations of 3120 values
330 3 ttsou
- Measuring conversion time
331 3 ttsou
- Elapsed time base...                  6.292542 secs
332 3 ttsou
- Validating SIMD conversion results... PASS
333 3 ttsou
- Measuring conversion time
334 3 ttsou
- Elapsed time SIMD ...                 0.839081 secs
335 5 ttsou
- Quotient...                           7.499326
336 3 ttsou
}}}
337 3 ttsou
338 3 ttsou
{{{
339 4 ttsou
[+] Testing: GSM TCH/AFS 7.95 (recursive, flushed, punctured)
340 3 ttsou
[.] Input length  : ret = 165  exp = 165 -> OK
341 3 ttsou
[.] Output length : ret = 448  exp = 448 -> OK
342 3 ttsou
[.] Pre computed vector checks:
343 3 ttsou
[..] Encoding: OK
344 3 ttsou
[..] Decoding base: 
345 3 ttsou
[..] Decoding SIMD: 
346 3 ttsou
[..] Code N 3
347 3 ttsou
[..] Code K 7
348 3 ttsou
OK
349 3 ttsou
[.] Random vector checks:
350 1 ttsou
[.] Testing baseline:
351 3 ttsou
[..] Encoding / Decoding 10000 cycles:
352 3 ttsou
[.] Elapsed time........................ 21.963257 secs
353 3 ttsou
[.] Rate................................ 0.203977 Mbps
354 3 ttsou
[.] Testing SIMD:
355 3 ttsou
[..] Encoding / Decoding 10000 cycles:
356 1 ttsou
[.] Elapsed time........................ 3.083282 secs
357 1 ttsou
[.] Rate................................ 1.452997 Mbps
358 17 ttsou
[.] Speedup............................. 7.123337
359 1 ttsou
}}}
360 1 ttsou
361 1 ttsou
== Authors ==
362 1 ttsou
363 23 ttsou
OsmoTRX is currently developed and maintained by Thomas Tsou with support from Fairwaves, the Open Technology Institute, and Ettus Research. The code is derived from the OpenBTS project, which was originally developed by David Burgess and Harvind Samra at Range Networks.
Add picture from clipboard (Maximum size: 48.8 MB)