AgeCommit message (Collapse)AuthorFilesLines
2013-11-15Transceiver52M: Use independent noise vectors for each channelThomas Tsou4-24/+27
Each ARFCN channel may be independently configureted and possibly on separate hardware, so don't share a single vector for noise estimate calculations. Allow a non-pointer based iterator so we can get away with using the default copy constructor. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Ignore detected bursts at the noise floorThomas Tsou1-4/+5
The transceiver has the ability to detect bursts below the noise floor, but little hope in successful decoding, so don't even try. We still use the detected burst to differentiate against noise vs actual data. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Check time slot validity of incoming burstsThomas Tsou1-0/+5
In errant cases, GSM core may send bursts with invalid slot values, which is allowed by the GSM::Time object. If we find a burst like this coming into the transceiver, then drop it immediately. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Add dual channel diversity receiver optionThomas Tsou11-50/+390
This patch add support for dual channel diversity on the receive path. This allows two antennas two shared antennas to be used for each ARFCN handling channel in the receiver. This configuration may improvde performance in multi-path fading environments, however, noise andpotential interference levels are increased due to the higher bandwidth used. The receive path is oversampled by a factor of four for a rate of 1.083333 Msps. If the receive paths are tuned within a maximum channel spacing (currently set at 600 kHz), then both ARFCN frequencies are processed by each channel of the receiver. Otherwise, the frequency shifted diversity path is disabled and standard non-diversity operation takes place. Diversity processing is handled by selecting the path with the higheset energy level and discarding the burst on the second path. Selection occurs on a burst-by-burst basis. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Refactor receive path outer burst handlingThomas Tsou2-95/+141
Separate the large pullRadioVector() call, which forms the central portion of the receive path burst processing. Break out RACH, normal burst, and demodulation into separate methods. This makes the burst handling from the FIFO read to soft bit output somewhat more manageable. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: sigproc: Wrap internal phase on frequency shiftThomas Tsou1-0/+4
The call into table lookup will loop on values outside of the table range. With continuously increasing phase, this leads to an eventual permanent hard spin. Wrap the phase value to prevent that from happening. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: UHD: Add string descriptors to device-offset pairsThomas Tsou1-10/+11
As we add more channel combintions including but not limited to new devices, signal processing schemes, and diversity, we'll need to handle more special cases. Add string descriptions for just a bit more sanity. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Add vectorized radio burst capabilityThomas Tsou5-26/+62
This patch allows multiple signalVectors to be stored within a single radioVector object. The motivation is to provide a facility for diversity and/or MIMO burst handling. When no channel value is specified, single channel bevhaviour is maintained. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Rearrange socket port assignemntsThomas Tsou1-4/+8
Style change for clarity only. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Dynamically allocate correlation vectorsThomas Tsou1-6/+10
Stack allocating the correlation output generates a call to the copy constructor of an zero valued vector. We can avoid this extra copy constructor with a pointer reference and dynamic allocation. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Allow separate in/out vectors for delay and decimationThomas Tsou2-55/+65
Allow non-in-place use of the delay setting. Internally, the delay call creates a new vector and copies the contents back into the original. Instead, provide the option to return the computed output vector directly and remove an an extra copy in the process. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Setup sinc() call directly with table lookupThomas Tsou1-2/+23
On Beagle Board the call into the sinc() function is generating a lot of load on the peak interpolation. Simplify the sinc() function with a dedicated table lookup. Eventually, this table may be removed in favour of using a precomputed filterbank for fractional delay determination. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Preallocate head room for burst correlationThomas Tsou3-4/+17
Set a transceiver high level length value that specifies the largest number of complex or real filter taps that we will encounter. This allows preallocation of head room and prevents an extra allocation and copy on every incoming receive burst. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: UHD: Continue on receive and send timeoutsThomas Tsou2-8/+0
With testing on current UHD releases, currently 003.005.xxx series, timeout errors on both receive and transmit are recoverable on network and USB based devices. Remove the fatal error conditions. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Set priority on downlink socket threadThomas Tsou1-0/+2
Clock indications passed up to GSM core originate on the transciever downlink side. Set priority to keep the flow of clock updates consistent. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Default to 1 sample-per-symbol low powered devicesThomas Tsou1-3/+10
This includes ARM Cortex A8 and A15 powered device such as Beagle Board, Gumstix driven E100 USRP, and Arndale board. Set the reduced SPS value automatically for the user. For x86, if we don't support SSE3, then the architecture is probably ancient and not with using. Drop the sampling down anyways to at least make an attempt. Non floating point SIMD devices (e.g. Raspberry Pi) also fall in this category Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Precompute fractional delay filtersThomas Tsou1-14/+59
Preallocate and compute a bank of fractional sample delay filters. The number of filters to allocate is specified by the DELAYFILTS preprocessor definition with a default value of 64. The filters themselves are sinc pulse generated with 20 taps and Blackman-harris windowed . Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Separate signalVector into it's own fileThomas Tsou5-110/+161
Break out the signalVector object and clean up the interface in the process. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Remove extra copy in receive drive pathThomas Tsou3-14/+17
Currently the code allocations a signalVector and then copies into a radioVector. This is unnecessary because the latter is a derived class making the first allocation unnecessary. Modify the radioVector constructor to allow direct use in the case above. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Dynamically allocate convolution input vectorsThomas Tsou2-21/+31
This prevents the use of a copy constructor in the downlink modulator and prevents a secondary memory allocation during the convolution. Avoid both cases by dynamically allocating with preloaded head room. The latter provides enough memory before the first sample in the burst to cover the length of the filter taps. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Add NEON complex-complex multiplyThomas Tsou6-2/+131
Complex-complex block multiples are used for phase rotation of bursts. Optimization targeted from perf profiling. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Use USRP1 type window for B2xx devicesThomas Tsou1-6/+12
B2xx is a USB based device so use the USRP1 based adaptive flow control window for transmit bursts. This adds additional stability primarily on ARM platforms. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Set variable thread priority levelsThomas Tsou6-10/+14
The transceiver and underlying device drivers are threaded. use the following priority levels. 0.50 - UHD driver internal threads 0.45 - Receive device drive thread 0.44 - Transmit device drive thread 0.43 - UHD asynchronous update thread (error reporting) 0.42 - Receive burst processing thread(s) Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Add ARM NEON supportThomas Tsou12-5/+743
Similar to the existing Intel SSE cases, add support for NEON vector floating point SIMD processing. In this case, use ARM assembly directly as the NEON intrinsics do not generate preferential code output. Currently support NEON vectorized convolution and floating point integer conversions. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-15Transceiver52M: Add multi channel transceiver supportThomas Tsou12-509/+743
This patch primarily addresses devices with multiple RF front end support. Currently device support is limited to UmTRX. Vectorize transceiver variables to allow multiple asynchronous threads on the upper layer with single downlink and uplink threads driving the UHD I/O interface synchronously. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-08Transceiver52M: Remove unnecessary UHD clock setting callThomas Tsou1-10/+1
There is no need to create this method. Just call the UHD interface directly. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-08Transceiver52M: Remove unused files and utilitiesThomas Tsou8-615/+2
USRPping and sigProcLibTest are in an unmaintained state, while the intended functionality remains unknown. Stored filter taps are also unused and should also be removed. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-08Transceiver52M: Separate transceiver per-slot state informationThomas Tsou2-103/+163
Collect the slot information into an indpendent state object. This will allow us to easily create multiple instances of internal state variables without having to replicate the transceiver object itself. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-08Transceiver52M: Delay socket allocation to heapThomas Tsou2-17/+22
For multiple transceiver connections, it is inappropriate to allocate all sockets in the transceiver constructor due to not knowing how many connections are avaialble in advance and for error checking purposes. Instead, store the base socket address port combination and setup the sockets in the initialization call. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-08Transceiver52M: Remove transmit logging optionThomas Tsou2-52/+0
The current status and operability of this compile option is unknown. Remove due to lack of use, demand, and maintenance. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-08build: Remove subversion referencesThomas Tsou1-3/+0
We do not use subversion. We do not need to refer to subversion reference numbers. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-07Transceiver52M: Reset overrun and underrun indicatorsThomas Tsou1-0/+5
Underruns are only explicitly set on the downlink side. Overruns are logged but unused. In either case, reset indicators to false to avoid sending false state information. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-07Transceiver52M: Fix SSE preprocessor definitionThomas Tsou1-1/+1
Using non-SSE4.1 enabled architecture would cause undefined reference to 'convert_si16_ps' call. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-04build: Set UHD driver as default configurationThomas Tsou2-37/+12
Currently the default configuration is to not build the full transceiver, which is pointless. Set the UHD driver, which includes either Ettus or Fairwaves variants, as the default. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-11-04Transceiver52M: Separate architecture specific filesThomas Tsou8-138/+194
Move x86 specific files into their own directory as this area is about to get crowded with the addition of ARM support. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Update RSSI calculationThomas Tsou1-3/+4
Use the same measurement method for RSSI as the noise level. Previous method was to use the peak correlation amplitude relative to the expected value. This created two very different amplitude approaches between the noise measurement and RSSI measurement, which would throw off the upper layer MS power control loop. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Update noise measurement calculationThomas Tsou4-55/+63
Previous removal of the energy detector requirement broke the noise level calculation loop. The previous adaptive approach was finicky - noticably at high gain levels. Since we no longer use the energy threshold for primary burst gating, we can return to a simpler world. In the new approach, we compute a running average of energy levels and track them with a noise vector. A timeslot that passes the correlator threshold is a valid burst. These are not used in the noise calculation. Everything else is considered noise and used to compute the noise level with respect to full scale input level, which for almost all supported devices is 2^15. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Move reference select from compile time to databaseThomas Tsou7-20/+20
Enabling the external reference on UHD devices through the configure time switch is awkward. Use a database variable "TRX.Reference" with '0' or '1' value for internal and external references respectively. Use internal reference is no entry is defined. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Delay UHD messaging registration until after startThomas Tsou1-3/+3
We want to push UHD logs to the OpenBTS logging system, but most device errors occur at startup, so keep the output on stdout until after device initialization. That way obvious errors are easily viewable before seeing the useless TRX timeout message. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Deallocate high level resources on shutdownThomas Tsou2-27/+34
This primarily addresses the error case at initialization. In the event that the transceiver fails to start, we should be able cleanly shutdown and release while providing a useful reason for exiting. After the radio is started and threads launched, there are no thread state variables or shutdown messaging between threads, and the transceiver cannot be consistently shutdown. This issue remains to be solved. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Reduce and place bounds checking on I/O buffersThomas Tsou2-32/+50
Previous send and receive buffers at the radio interface were arbitrarily set to a sufficient size. For normal (non-resampling) devices, use a block (chunk) size of 625 samples. For 64 or 100 MHz resampling devices, use 4 times the reduced resampling numerator or denominator and provide bounds checking where appropriate. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Add 64 MHz resampling option with B100Thomas Tsou6-46/+88
Move B100 to the resampling interface with default clocking. This temporarily resolves undetermined FPGA clocking issues. This also provides extensible support for multiple clocking rates and resampling ratios. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Remove support for ancient libusrp versionsThomas Tsou3-33/+6
Current functionality with these old versions is questionable. There is no reason to use any version of GNU Radio / libusrp older than 3.3. Version 3.4.2 is the only recommended version for USRP1 users. Non-USRP1 users must use UHD driver from Ettus Research. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Add B210 supportThomas Tsou1-7/+10
Identical to B200 support, but explicitly check for the device type name. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Setup dual sample rate transceiverThomas Tsou10-161/+228
This patch applies oversampling, when selected with 4 sps, to the downlink only, while running the receiver with minimal sampling at 1 sps. These split sample rates allow us to run a highly accurate downlink signal with minimal distortion, while keeping receive path channel filtering on the FPGA. Without this patch, we oversample the receive path and require a steep receive filter to get similar adjacent channel suppression as the FPGA halfband / CIC filter combination, which comes with a high computational cost. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Generate delay filter with SSE memory alignmentThomas Tsou1-24/+41
This requires an additional memcpy() on the signal vector constructor, but allows the interpolation filter to use SSE optimzationed convolution. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Separate main transmit and receive drive threadsThomas Tsou2-15/+24
This patch primarily addresses observed repeated overrun conditions in embedded environments - namely ARM. The heartbeat of the transceiver is derived from the receive sample stream, which drives the main GSM clock. Detach the transmit thread from the receive loop to avoid interfering with the receive I/O, which is sensitive to overrun conditions if pull process is interrupted. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Disable equalizationThomas Tsou1-1/+1
Unsupported at 4 sps, and performance benefits remain to be proven at 1 sps. Disable until further testing. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Reduce RACH and TSC correlation windowsThomas Tsou1-8/+8
Start the correlation search window at 4 symbols before the expected correlation peak. End the search at 10 symbols and 4 + maximum expected delay for RACH and TSC bursts respectively. This change lowers receive side cpu utilization while maintaining reasonable timing jitter and accuracy tolerance. Signed-off-by: Thomas Tsou <tom@tsou.cc>
2013-10-18Transceiver52M: Narrow resampling filter bandwidthThomas Tsou1-8/+11
This patch only applies to resampling use at 4 samples-per-symbol. By extention that means only USRP2 / N2xx devices are affected. At 4 samples-per-symbol we restrict output bandwidth to roughly roughly 700 MHz, which combined with the 2 pulse Laurent approximation yields < 0.5 degrees of RMS phase error at the resampler output. Signed-off-by: Thomas Tsou <tom@tsou.cc>