The l1 interface does not explicitly set the flag for 11 bit
rach when a rach request is received. Since the current and
previous octphy firmwares do not support 11 bit rach requests,
the flag should be explicitly set to zero.
Change-Id: Ifa165c56e54d272caafa45d1bf0e177848fcdfbd
Firmware releases OCTSDR-2G-02.07.00-B1314-BETA and newer require
to align the GPRS frame number (fn-3) for ph_data indications.
To preserve compatibility the header version is checked during
compile time and the right method is compiled in.
Change-Id: Ib93d5fb3b34ff92f10021a0e9ce9c8aa3044b7ff
CBCH is activated when the SAPI for TS0 is activated. Since the CBCH can be
configured on any physical TS, we wait until all (TS7 is the last) physical
timeslots are configured.
Change-Id: Ie307bf9f370a346686e3bd8c8a8483953a1bc279
the function is_meas_complete() uses the *_meas_rep_fn104[]
lookup tables, defined at the beginning of the source file.
These lookup tabels contain a lot of magic numbers. This
commit adds a more elaborated comment with a reference
to the specification/section in order make the values
understandable.
Change-Id: Ic6e4037f965772e6b851c67662d5e7bf64cc04eb
the function ber10k_to_rxqual() has only a very brief
comment with the spec reference. This commit adds a more
explainatory comment that makes it easier to understand
from where the ber10k constants are taken.
Change-Id: I3d3488c97d0bffa7d449d3675afcc75b2a6a2703
* move BTS model name resolution into separate function
* add convenience wrappers for BTS type and number fo TRX and use then
in L1 interface
Change-Id: I4649100df8f1b8e095f210fc294567ba014c0b6a
Related: OS#1614
SI2quater support as per 3GPP TS 44.018 will require chnages to the way
System Information is stored because it uses 1:n instead of 1:1 mapping
between SI type and generated SI content. This should not affect other
SI types though. To facilitate this transition:
* convert the code to always use GSM_LCHAN_SI helper instead of
accessing buffer directly
* move duplicated code to inline function
* add logging for buffer truncation and corresponding length values
Requires I74e4e3cb86364cec869a1472a41b4a95af0d50dd in OpenBSC.
Change-Id: Ie97be6ead6ce6d2d425fbfac8429bb90afb95acc
Related: RT#8792
While at it - do not serialize NULL as a string when delivering OML
Failure Report.
Change-Id: I41a731bd719aee0bbb98d3236405fb3a7f3ddec0
Related: OS#1615
When a new TRX is allocated using gsm_bts_trx_alloc() (see gsm_data_shared.c in
openbsc.git), than it is added to the list in order. When octphy is shutting
down the BTS, it uses llist_for_each_entry() to iterate the tansceiver list to
shut all transceivers down. This means it starts the shut down process with
the primary TRX and then continues with the secondary transceivers in order.
However, octphy does not allow to close primary TRX if the secondary TRX is
open. The shutdown sequence must begin with the secondary transceivers and
finish with the primiary transceiver as last item.
The problem can be easily fixed by iterating the transceiver list in reverse
order using llist_for_each_entry_reverse() instead of llist_for_each_entry()
Since this is a change in the common code, all BTS models (not only octphy)
are affected, but from the logical perspective, this change makes sense
for all other BTS models too.
Change-Id: I18485de586b402610f9e98053d69e92bc9b18dc2
Make it possible to store:
* Static vs. DHCP mode
* IPv4 address
* Netmask
* GW IPv4 address
* DNS IPv4 address
Add a simple CRC8 and pick 0xFF as initial value so an all
zero EEPROM will not generate a 0 CRC. The code tries to
differentiate exit code between unreadable EEPROM and CRC error.
This is a reference to see if we want to have store it in the
EEPROM or not.
Change-Id: Id8a37fe952ef2a8ef36778729f506f900accf8d1
RTP jitter increases continuously because duration is not
updated when speech resumes in DTX mode.
Change-Id: Ib51ed95a449369222c957b3acebd9ce1f66c5435
Add optional MS timing offset (3GPP TS 45.010 § 1.2) to RSL MEASUREMENT
RESULT (3GPP TS 48.058 § 8.4.8). The value is calculated either directly
from corresponding BTS measurement or from 3GPP TS 48.058 § 9.3.17
Access Delay (for known TA) and is invalidated after RSL report is sent
until new measurement indication or RACH is received.
Change-Id: I4dfe5c48834a083e757d5de3236a02e15a238b28
Related: OS#1574
add support for the TX/RX antenna-id feature that has been
introduced with release OCTSDR-2G-02.07.00-B1314-BETA. The
user can now set individual ID numbers for the TX and for
the RX antenna.
Change-Id: I872fe3c4d7b593358a4ce2f02cf0726611b9f3aa
With octasics latest release (octsdr-2g-02.07.01-B1351-beta), some struct
members are moved or renamed. This patch adds ifdef-logic and configure
checks to restore compatibilty.
Change-Id: I73287983e8bed8bf64b2ab87e6b810c2c59ea6fd
Making use of the multi-trx feature requires to tell osmo-bts that
more than one transceiver are available. Otherwise it will complain
that not enough transceivers are available. This can be quite
confusing, even a correct config file will fail to parse if it
specifies more transcrivers than available.
This patch adds a hint to the error message so that the user knows
that he should check the -t commandline option
Change-Id: Ifbeacd9d43f7c6cd74a1e1b33288e66828fe843f
Some header file versions support multi-trx and some do not. After
to compiling it is very difficult to find out if the binary is
multi-trx capable por not. This patch adds a log line that should
rule out any doubts.
Change-Id: I257c0a5e7c5ff5df2f0a603d1ede6db5679382e0
octphy_hw_get_rf_ant_tx_config() uses define constant
cOCTVC1_HW_MSG_RF_PORT_INFO_ANTENNA_RX_CONFIG_CID instead of
cOCTVC1_HW_MSG_RF_PORT_INFO_ANTENNA_TX_CONFIG_CID. This commit
replaces exchanges the wrong constant with the correct one.
Change-Id: Ie4de23daf79bb07ca0c0b818eefe350d18d27e4d
In case a system has a high-gain external PA (like a 40dB PA) connected
externally, we cannot simply switch the transceiver to 0 dBm in
trx_init() only to then start the ramping at much lower levels once the
PHJ completes in trx_init_compl_cb(). The result would be a short
0 + 40 dBm spike followed by later ramping. We want to avoid that
spike, particularly its associated inrush current, so let's bring up the
board with smething very conservative like -50 dBm, and then ramp from
there.
Change-Id: I0ad91fce64f65e0213c9fcfde3390ace519055db
Fixes: SYS#3259
Currently the channel combination II is used for TCH/H, which
allows only one lchan to be allocated. The reason is that it
saves a bit of CPU by disabling UL burst detection on lchan 1.
There is also the channel combination III, which allows to
increase channel capacity, providing two lchans on a single
TCH/H timeslot.
Ideally we should implement some dynamic II <-> III switching
depending on the network load level. But for now this change
replaces the channel combination of TCH/H by III, until dynamic
switching is implemented.
Fixes issue: https://osmocom.org/issues/1795
Change-Id: I8fd4abb42c153fcd26bcfe22a2554b5c2d02d810
* DTXu: don't set marker for broken frames
* do not attempt to send 0-length bursts to avoid flood of errors after
bts startup
Change-Id: Icb536f951386b9abe34c0dacbb203f3db1e41bb3
The macro L1SAP_IS_PTCCH(fn) only detects a PTCCH channel at fn%52 = 12,
the detection logic has been extended in order to detect PTCCH at fn%52 = 38.
See also 3GPP TS 05.02, Clause 7, Table 6 of 9
Change-Id: Ia6f3333121e5e920c5e1d562a081d0a1b58a1153
The ra parameter indicates the reason for the received rach
request. osmo-bts uses the ra parameter to determine if the
received rach request is packet access related. If yes,
osmo-bts will forward the request to the PCU.
In order to determine if the ra is packet related or not,
the higher 4 bits must be equel to 0x7 and at least one of
the lower 4 bits must be zero.
The current method lacks checking of the lower 4 bits. It
would also accept 0b01111111, which is reserved for future
use. This commit extends the check to take also the last
4 bits into accound.
See also: 3GPP TS 04.08, Table 9.9
Change-Id: I5eb88c42a91e158d9bfa4105ec9636035baf8959
Log error when handover RACH is detected on wrong channel: according to
3GPP TS 44.018 it can only be seen on SACCH and DCCH.
Change-Id: Iacbcc8441d6cfbb8f808948a8baddde1ebca488a
Related: OS#1898
The VTY commands show phy 0 rf-port-stats and show phy 0 clk-sync-stats
do not output their results on the VTY console. If one of those commands
is entered the user is prompted to view the logtext, which is an
uncomfortable solution. This commit adds the missing functionality to
print the information in the VTY as well.
octphy_hw_api.c contains two value_string structs (radio_std_vals and
clocksync_state_vals) which are now exported in octphy_hw_api.h in
order to access them from octphy_vty.c
Change-Id: Iae5aa91fe2ebba7c2874eed88b15ed66e8c9cd61
This bug was introduced during moving oml definitions from osmo-bts to libosmocore
in libosmocore 0bee65c0d89f81a4b90aa3d484016d9ba680dd46 and
osmo-bts 2cf6b73a4278627331bdbbb4addf1a8bc1d964ce:
The type of abis_nm_att_tlvdef_ipa was changed from struct tlv_definition to
const struct tlv_definition, so:
* create static abis_nm_att_tlvdef_ipa_local variable for oml attribute
definitions
* copy abis_nm_att_tlvdef_ipa to abis_nm_att_tlvdef_ipa_local
* merge abis_nm_att_tlvdef with abis_nm_att_tlvdef_ipa_local
* use abis_nm_att_tlvdef_ipa_local in oml_tlv_parse function
Change-Id: Ia9f3c94ab247adeecb26a01c3ccd6f3a8c17ba1c
This issue occurs in case of osmo-trx restart which leads to losing clock from osmo-trx.
Function bts_shutdown from common/bts.c should be used in this case for proper bts shutdown.
Change-Id: Ie65cf2e8f98cb8bf3314a00048aa53c1f8cd4c25
The simplistic approach of sysmobts_get_nominal_power() is insufficient
to cope for devices that have an internal PA. The Actual transceiver
board is driven to a certain level (0..23 dBm typically), and the
external PA must be handled independent of that. Increasing the return
value of sysmobts_get_nominal_power() would result in the sysmoBTS
mainboard attempting to reach a higher power, which is wrong.
This change affects sysmoBTS 1020 and 1100. It causes power-ramping to
be used by default. For 1002 and 2050, no behavior change is expected.
Change-Id: Ieff75d5becaa80a2097b6e744c75c2d16259c9a4
This issue occurs in case of osmo-nitb restart which leads to abis connection closure.
Function bts_shutdown from common/bts.c should be used in this case for proper bts shutdown.
Change-Id: Id025e703dd5c91896d450d200e88e46552f178f0
According to Table 4 in 3GPP TS 45.003 j=11, b=3 case corresponds to
k=91 and not j=12 as was previously used.
Change-Id: Iad3cf545b2f7e16276466cc37dd7a1e7858467e5
pinst->u.osmotrx.hdl should be allocated before reading phy_instance parameters from config file and applying them.
So allocation of pinst->u.osmotrx.hdl should be moved from l1if_open function to bts_model_phy_instance_set_defaults function,
which is proper place for this allocation according to start-up procedure of osmo-bts.
Change-Id: I6e23f92644400acb268818c9373a8fb10c003da1
Move rxgain and tx-attenuation (power) parameters from phy_link layer to phy_inst layer.
Rxgain and tx-attenuation parameters should be set for each phy_inst and send for each osmo-trx channel accordingly via control commands.
Change-Id: I4861a59d10d1ef91954e0c6ea265e66dec08844f
It's useful to know RTP statistics (number of packets lost, jitter, etc)
when looking at voice call quality issues. Right now this information is
not avialable anywhere and this looks like the best place to start.
Change-Id: Ife9f27c43157b4a1bf71aba41cd7b0f5f41ac99f
The vty write for phy/inst is broken, leading to a written-out config being
unparsable; fix all of these:
- in common/vty.c, actually call bts_model_config_write_phy_inst().
- in sysmo and lc15 write the phy instance elements in
bts_model_config_write_phy_inst() and not in bts_model_config_write_phy(),
which lead to writing the members above their parent 'instance'.
- sysmo, lc15 and oct omit the bts_model_config_write_phy_inst()
implementation. This did not cause a compilation problem because it
was in fact never called.
- sysmo writes 'clock-source None' when clk_src is zero, leading to unparsable
config (related: OS#1944). Instead omit the 'clock-source' when zero.
- osmo-bts-trx seems to be the only part that lacks nothing, yet it
also didn't work properly because bts_model_config_write_phy_inst()
was never called.
This problem existed since commit d784e50747
"Introduce new phy_link and phy_instance abstraction"
Change-Id: Icc54fa70045c8fa58e78cf9f788c21a437edfbd4
In case our SI enums ever move past 31, this static assert will warn us to
enlarge osmo_si_shifted.
Change-Id: I4185d7de590329ff5f523b241721c586ffdbcd8b