Age | Commit message (Collapse) | Author | Files | Lines |
|
Change-Id: Ibcf258d8bf8595e286682e0bc59391b239ea7642
|
|
There was no a simple range check for both (NO)HANDOVER commands,
so an out-of-range access was possible. For example, a command:
CMD HANDOVER 0 -3
might enable EDGE at run-time, because:
a[i] == *(a + i)
Let's fix this.
Change-Id: I24a5f70e8e8097f218d7cbdef8cb10df2c35416f
|
|
Change-Id: If69a478121a31aa7df945548cc17271c476d6a6b
|
|
It looks like the author of control command parsing code was not
familar with simple pointer arithmetics, so excessive amount of
memory and useless memcopying was used to parse a single command.
Let's introduce two pointers, one of which will point to the
beginning of a command, another to the beginning of its arguments.
Also, let's simplify the command matching by using a separate
function called 'MATCH_CMD'.
Change-Id: I226ca0771e63228cf5e04ef9766057d4107fdd11
|
|
Previously it was assumed that a sender should zero-terminate
each command being sent. Otherwise, this could cause to printing
garbage. Let's do this manually, using the length of received
data as a position for '\0'.
Change-Id: I69f413f33156c38a853efc5a8cdc66fbfb0ca6af
|
|
No need to keep this value on stack.
Change-Id: If9ffb03b9e7b642f45732ba5938977bca271f1c7
|
|
This patch is a preparation for next patches, which add full VTY cfg
support.
Change-Id: I3d5b0576aa96869756f1629a40306c0043b6304b
|
|
Before this patch, the binding of the listening sockets was hardcoded to
a local IP.
Change-Id: I9ba184a1251c823e413a9230943ed263e52142ec
|
|
Stop calling writeClockInterface() when receiving commands in Transceiver::driveControl,
otherwise it fools osmo-bts-trx clock skew check because it is always sending a clock
indication with the same fn when it issues any commands during the time in between
CMD POWEROFF and RSP POWERON, because fn is not increased during that period.
Also use mForceClockInterface flag to delay delivery of first IND CLOCK until we start
serving frames, otherwise the first one is sent and only after a long period of time
the next clock indications are sent, when the radio starts to process bursts. That makes
osmo-bts-trx unhappy because it expects to receive an IND CLOCK aprox at least every
400 frames. This way also we send the first IND CLOCK after the RSP POWERON 0 response.
Change-Id: I91b81a4d7627cec39c1814a39ed4be306681b874
|
|
Change-Id: Ib3fbe768048b2a34a75ace9688e306720e67019a
|
|
Upon issuing POWEROFF command to a running transceiver, UHD
interfacing thread state may become undefined if the device
is stopped with I/O threads still active. Bad behavior is
device dependent with only network based USRP devices
affected. USB based device thread behavior stops and shutdowns
as expected. Tested with N200, X300, and B210.
Tested solutions include the following:
1. Set pthread_setcanceltype() with PTHREAD_CANCEL_ASYNCHRONOUS
2. Add sleep delay to allow I/O threads to timeout before
stopping the device
3. Wait for I/O threads to join after cancellation before stopping
the device
This patch resolves the issue by with the third approach. Number 1
is not guaranteed to always work with UHD internals as driver code
may explicitly set thread parameters. Using sleep calls to fix
order-of-operation issues is almost never a good idea.
Change-Id: Ib72ab98a27a02084b040319046c92d1c4157ae4c
|
|
Change-Id: I49f30699786c52736ef334dae61f7bbd65d878d5
Fixes: Coverity CID 149353, 149356
|
|
Change-Id: I2cad47160e53f65612bd1da8998c83a0a22bce9b
|
|
Change-Id: I5a888890e26858c0fbb2ddb7ef23cb0fd66a64b4
|
|
Change-Id: I3cbe8e6e4f39dde02c945e6c9086c040e276845c
|
|
Required to move Transceiver::detectBurst to sigProcLib.
Change-Id: I3e0e74a98bbca4d19657f50a5fb447f078663c9b
|
|
vectorSlicer() converts soft-bits from -1..+1 to 0..1 while we want
to keep SoftVector in -1..+1 mode until the last minute, because at some
point we'll want to transmit -1..+1 to osmo-bts instead of converting it
from 0..1 back to -1..+1 on the osmo-bts side.
Plus it removes code duplication - we call it once instead of twice.
Change-Id: Idd6ddd7ac219afb0df055a692632678b66373764
|
|
Change-Id: Ibcef8d7d4a2c06865bed7e4091ccc8dbbd494d77
|
|
Change-Id: I9bf97f2dc03fea9bebcf43198dfb05f6e4694e9c
|
|
Place conditional brackets on handover table reset. Reset table
only on successful start or restart.
Change-Id: I74032b49785bd68835a0a68cb0f14cdaab4fcd26
|
|
The time-of-arrival (TOA) value out of sigProc is specified
in symbols or, equivalently, 1 sample per symbol and does
not need to be normalized.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Input burst construction was declared static causing the first
downlink burst from upstream to determine subsequent burst size
and modulation. Consequently, fixed sequence EGPRS tests would
pass, however, switching between 8-PSK and GMSK bursts would
fail with only one modulation type being transmitted.
Internally generated test sequences '-r' option were not affected
because the bursts are not received through the socket interface.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Previous checks on multi-channel TSC and ARFCN settings would fail
if channels were initialized out of order. Namely, if channel 0
was not configured first, osmo-trx would error on the control
interface leading osmo-bts to fail.
Allow global TSC setting on all channels with added logging notice.
Notify if channel frequency is unexpected - which may happen if
channels are setup out of order - but do no report as error.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
These warnings simply echo the socket command arguments with no
indication of any unexpected or improper operation.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
The command line EDGE option will enable 8-PSK burst
detection on any slot where a normal burst is expected.
The burst search order is 8-PSK first followed by GMSK.
EDGE will force 4 SPS sampling on Tx and Rx. Along with
twice the search correlation from 8-PSK and GMSK, EDGE
will increase CPU utilization. Whether the increase is
notable or not is dependent on the particular machine.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Allow EGPRS 8-PSK length bit vectors of length 444 (148 * 3)
to pass in through the Tx socket interface. Length is the sole
factor in determining whether to modulate a bit vector using
GMSK or 8-PSK.
Tested with 8-PSK training sequences with random payload
originating from osmo-bts. Output verified with Agilent E4406A.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Reduce the burst detection threshold to pass more bursts to upper
layers, but force stricter requirements on the computation itself.
For the latter, we now require at least 5 samples (rather than 2)
to compute a peak-to-average value.
End result is increased burst detection at low SNR conditions with
a small increase in false positive bursts when no signal is present.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
OsmoTRX does not support the use of multiple TSC settings per
internal TRX instance. There should not be an error to modifiy
the TSC value after POWERON. Setting TSC value on TRX channels
other then 0 is a NOP operation that should only error if the
requested TSC differs from that of TRX channel 0.
Reported-by: Max <msuraev@sysmocom.de>
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Current UDP receive reads up to MAX_UDP_LENGTH bytes into the
passed in buffer, which may lead to buffer overflow if the
write buffer is of insufficient size.
Add mandatory length argument to UDP socket receive calls.
Reported-by: Simone Margaritelli <simone@zimperium.com>
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
used.
|
|
|
|
Previously MAXDLY value was applied to Normal Bursts, which was nice
when working with sloppy test equipment like CMD57, but useless for
real world usage. At the same time documentation and de facto usage
of MAXDLY in OsmoBTS and OpenBTS assumed that it actually applies to
Access Bursts (RACH). So this patch changes osmo-rx behavior to apply
MAXDLY to RACH bursts and introduces a new command MAXDLYNB for the
old behavior.
|
|
When EDGE is enabled with the '-e' option, the random burst generator
switches from GMSK normal bursts to 8-PSK EDGE bursts.
$ ./osmo-trx -e -r 7
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Setup generators for empty, random, and dummy bursts. This moves error
prone burst length handling out of the Transceiver and into the signal
processing core.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Create EDGE slot type in the Transceiver. When EDGE mode is enabled
for a particular slot, blind detection will be performed by
correlating against EDGE followed by normal bursts if no EDGE burst
is found.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Allow setting the device to non single SPS sample rates - mainly
running at 4 SPS as the signal processing library does not support
other rates. Wider bandwith support is required on the receive path
to avoid 8-PSK bandlimiting distortion for EDGE.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
DFE equalizer is unused and has been experiencing code rot for
multiple years. The effect is a significant amount of baggage being
carried in the Transceiver and interfaces.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Samples per symbol used by the transceiver is not configurable through
the socket interface once running, so stop pretending like it could be.
Initialize all tables and midambles at start.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
This also fix a bug of using bool type for noise instead of float.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
As a side change - get rid of passing toa and amp arguments as pointers and use
references instead.
The commit doesn't change behaviour, but makes the code cleaner.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
We can't rely on an assumption that if we can't decode a burst - it's noise.
There are many rasons why we can't decode a burst even if it's well above the
noise level. Just one example is a RACH burst which can be overlapped with
another RACH burst up to a level both are completely unrecognizable. Another
example is when a burst is destroyed by bad multi-path.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
It does more harm than good. the current noise calculation is too error
prone, so we can't trust it. And we end up loosing perfectly good bursts
because of that.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
There are two primary changes in this commit:
1) Return values of detect functions changed form bool to int to actually pass
the return value from the inner function and notify higher levels about clipping.
Previously the information was lost due to conversion to bool.
2) Clipping level is not the final verdict now. We still try to demod a burst
and mark it as clipped only if the level is above the clipping level AND we can't
demod it. The reasoning for this is that in real life we want to do as much as
possible to demod the burst, because we want to get as much from our dynamic
range as possible. So a little bit of clipping is fine and is expected. We just
don't want too much of it to break our demod.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|
|
Receive thread receives data from the device, which is a more stable source of
clocking than the transmit side. If transmit side has a hiccup, osmo-trx doesn't
send the clock indication, and transmit side is getting completely lost in time.
With this patch we ensure that clock indication keeps coming.
Signed-off-by: Tom Tsou <tom.tsou@ettus.com>
|