Commit Graph

43 Commits

Author SHA1 Message Date
Pablo Neira Ayuso 136f453dd2 src: use new library libosmogsm and new path to headers in libosmocore
libosmogsm is a new library that is distributed in the libosmocore.
Now, openbsc depends on it. This patch gets openbsc with this
change.

This patch also rewrites all include path to the new
osmocom/[gsm|core]

Signed-off-by: Pablo Neira Ayuso <pablo@gnumonks.org>
2011-03-23 18:17:56 +01:00
Harald Welte f338a03b0c [BSC] Move the BTS-type specific code from bcs_init.c to bts_*.c
bsc_init.c was a big mess even only for two supported BTS models,
so before adding more BTS types, this needs a cleanup.

All the BTS specific code from bsc_init.c has now moved into
bts_{siemens_bs11,ipaccess_nanobts}.c

This has required that input_event() and nm_state_event() get both
converted to proper libosmocore signals instead of referencing external
symbols.
2011-02-11 16:26:31 +01:00
Harald Welte 9af6ddfcec License change: We are now AGPLv3+ instead of GPLv2+
The reason for this is quite simple: We want to make sure anyone
running a customized version of OpenBSC to operate a network will
have to release all custom modifiations to the source code.
2011-01-01 15:39:34 +01:00
Holger Hans Peter Freyther 6f615551a4 abis_nm: Band aid on OML initialisation by queuing messages
Instead of sending many messages we will queue the OML
messages and wait for the ACK/NACK before sending the
next message from the queue. We tag the msgb to remember
if we need to wait for an ack or not.

We keep the order of all messages, on ACKs and similiar
occassions we will drown the queue until we reach a message
that needs to be acked and then wait for that ack again.

Possible breakage can appear when we send an OML (e.g.
BS11 specific message) msg which does not need to be acked
through the abis_nm_sendmsg call. The fix will be to use
the _direct version of this method.

Re-Enable as it might have fixed something... who knows.

Conflicts:

	openbsc/include/openbsc/abis_nm.h
	openbsc/include/openbsc/gsm_data.h
	openbsc/src/abis_nm.c
	openbsc/src/gsm_data.c
2010-12-21 13:53:41 +01:00
Harald Welte f751a10018 bs11_config: show the BPORT0 / BPORT1 configuration in 'query'
This introduces abis_nm_bs11_get_bport_line_cfg() and a parser for the result.
2010-12-14 12:52:16 +01:00
Harald Welte 887deabe38 ipaccess-config / network listen: ordered list of RxLevels
Use libosmocore 'rxlev_stat' module to generate an ordered list
of ARFCN's, sorted by RxLev while performing test nr. 64
2010-07-22 21:54:19 +02:00
Harald Welte 549faada21 move ip.access netowrk listen (NWL) to network_listen.c
Also, we now re-start the network listen test after it has finished,
so if you run a test from ipaccess-find, the test will get re-started
and re-started all the time.
2010-07-22 21:54:19 +02:00
Harald Welte 81c9b9ca3e OML: Introduce minimal VTY command set to interact with OML managed objects 2010-05-31 16:40:40 +02:00
Holger Hans Peter Freyther 64278ede35 sw_load: Specify the trx_nr for the software load
For the multi TRX setup we will need to specify the right trx->nr
to be able to flash the BTS. For the BS11 case we are ignoring the
additional argument.
2010-05-13 00:41:48 +08:00
Holger Hans Peter Freyther 52fd4e4395 ipaccess: Send the reset to the BASEBAND_TRANSC and supply TRX
Send the IPA Restart to a given BTS/TRX, change the signal callbacks
to carry the trx instead of the BTS so we have an easy access to the
right TRX and change the ipaccess-config to use that TRX. This is
fixing the restart with a multi TRX setup.

Even if we have the msg->trx, use the gsm_bts_trx_by_nr and get
the TRX from the fom header. This is because the OpenBSC and the
BTS numbering might not match for the multi TRX case.
2010-05-13 00:41:30 +08:00
Holger Hans Peter Freyther aa0db809e2 abis: Pass the abis_om_obj_inst in the nm_state_event.. 2010-05-13 00:37:48 +08:00
Harald Welte 97a282b037 Create new gprs-conf branch with the non-SGSN part of the gprs branch
This new gprs-conf branch is intended to contain everything needed
to configure GPRS in the nanoBTS, but without implementing the SGSN/GGSN
functionality.

The SGSN/GGSN development will happen in a branch based on this branch
called "gprs-sgsn"
2010-03-22 19:02:04 +08:00
Harald Welte 13f52974e6 move GSM protocol definitions to include/osmocore/protocol/* 2010-02-20 18:56:00 +01:00
Harald Welte dfe6c7d910 split 'libosmocore' from openbsc codebase
This library is intended to collect all generic/common funcitionality
of all Osmocom.org projects, including OpenBSC but also OsmocomBB

The library currently includes the following modules:

bitvec, comp128, gsm_utils, msgb, select, signal, statistics, talloc, timer,
tlv_parse, linuxlist

msgb allocation error debugging had to be temporarily disabled as it depends on
'debug.c' functionality which at the moment remains in OpenBSC
2010-02-20 16:27:23 +01:00
Harald Welte 39315c4798 [OML] parse attributes depending on BTS type
Some NM attributes are defined differently depending on
the BTS type.  Having one big nm_att_tlvdef[] table for
all BTS types is no longer sufficient.  This patch

* introduces 'struct gsm_bts_model' to describe a BTS model
* adds definitions of gsm_bts_model for BS-11 and nanoBTS
* changes the abis_nm_tlv_parse() function: include a bts pointer
2010-01-10 18:01:52 +01:00
Harald Welte 2ef156db43 bis_nm_ipaccess_set_nvattr() executes on a TRX, not a BTS 2010-01-07 20:45:41 +01:00
Daniel Willmann 7b1dd748ea [abis_nm] Add abis_nm_bs11_set_pll function to change the set/work value
Whether this function changes the set or the work value depends on your
type of login. In FACTORY login it changes the set value, in FIELD login
it changes the work value (which is what is used by the BS11 to tune the
frequency).
2010-01-07 14:03:22 +01:00
Daniel Willmann 4b054c8788 [abis_nm] Add abis_nm_bs11_infield_logon to logon as user field
As this user you are able to set the PLL work value which is especially
useful if your BS11 got detuned by an inaccurate oscillator in your E1
card.
2010-01-07 14:03:22 +01:00
Daniel Willmann 493db4ee3d [abis_nm] Add generic abis_nm_bs11_logon function
Factoring out common logon functionality will allow us to logon as
different user. abis_nm_bs11_factory_logon now uses this function.
2010-01-07 14:03:21 +01:00
Sylvain Munaut 1f6c11fda8 abis_nm: Introduce & use a nm_is_running function to test gsm_nm_state
This returns true if the gsm_nm_state can be considered 'running'.
Note that we also accept availability==0xff (which is a code for
no value) because according to 12.21 it is perfectly valid.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2010-01-03 10:11:24 +01:00
Holger Hans Peter Freyther 1356c08cc8 [abis] Dispatch a IPAC restart ACK/NACK signal
* Add the NACK version to the list
* Dispatch the signal when we receive the message
* Handle it in ipaccess-config by exiting the application
2009-12-30 09:00:01 +01:00
Harald Welte d6847a940a use enum for operational state 2009-12-24 10:06:33 +01:00
Harald Welte aff237d739 [OML] fix bugs in BCCH info parser for ip.access 2009-11-13 14:41:52 +01:00
Harald Welte b40a38ff46 [ip.access] Parse cell global ID as part of BCCH info 2009-11-13 11:56:05 +01:00
Harald Welte 0f255857d4 ip.access: Introduce parser function for BCCH Info test result 2009-11-12 14:48:42 +01:00
Harald Welte daef521ea5 [OML] Add support for ip.access SET ATTRIBUTE message
Since TS 12.21 implements only SET ATTRIBUTE for some object classes,
ip.access had to extend it to be able to set attributes on arbitrary
objects.  We now introduce a function implementing that message.
2009-10-24 10:20:41 +02:00
Harald Welte 8406ec2437 [nanoBTS] move nanoBTS initialization completely into state event handler 2009-10-20 17:31:00 +02:00
Harald Welte 746d6091d9 [abis_nm] introduce and use abis_nm_ipaccess_rsl_connect() 2009-10-19 22:11:11 +02:00
Harald Welte 53f4b10b21 add ipaccess specific attribute set message
Partially apply 9ba65525eaa06a1768aaf35bdee98afcf8026e0a to get
rid of a compile problem. The other part of the mentioned commit
is still in the gprs branch.

Signed-off-by: Holger Hans Peter Freyther <zecke@selfish.org>
2009-10-09 05:26:46 +02:00
Harald Welte 2d820ccf67 add availability state abis_nm enum 2009-10-08 20:52:35 +02:00
Harald Welte 21bd3a52f1 move chcomb4pchan to public abis_nm_chcomb4pchan() function 2009-08-10 12:21:22 +02:00
Daniel Willmann 65f68fa961 Add {create, delete}-bport1 and bport0-{star, multidrop} to bs11-config
This adds the possibility to bs11-config to add the second bport and
change the line config to star or multidrop.
2009-08-10 11:49:36 +02:00
Harald Welte cf845cb8d3 add comments about channel combinations 2009-08-09 21:49:37 +02:00
Harald Welte c7310385ca implement nanoBTS frequency error test
This helps us to detect the frequency error of BS-11 if it is located
next to the nanoBTS 900.

If 'ipaccess-config -l' is called, it will produce a report like
<0020> ipaccess-config.c:85 TEST REPORT: test_no=0x42 test_res=0
<0020> ipaccess-config.c:108 ==> ARFCN  220, Frequency Error     22
<0020> ipaccess-config.c:108 ==> ARFCN    1, Frequency Error    -37
<0020> ipaccess-config.c:108 ==> ARFCN   10, Frequency Error      0
<0020> ipaccess-config.c:108 ==> ARFCN   20, Frequency Error     11
<0020> ipaccess-config.c:108 ==> ARFCN   53, Frequency Error      5
<0020> ipaccess-config.c:108 ==> ARFCN   63, Frequency Error     -4
<0020> ipaccess-config.c:108 ==> ARFCN   84, Frequency Error     11
<0020> ipaccess-config.c:108 ==> ARFCN  101, Frequency Error      0
<0020> ipaccess-config.c:108 ==> ARFCN  123, Frequency Error    -52

where in this case the ARFCN 123 is the BS-11 with a frequency error
larger than all the other (regular) BTS in the vicinity.
2009-08-08 00:02:36 +02:00
Harald Welte 1989c089da add function for performing 'CONNECT MULTI-DROP LINK" as per GSM 12.21
don't be confused, BS-11 does not need this.  But since I wrote the code
before knowing that, I can just as well commit it.
2009-08-06 17:58:31 +02:00
Harald Welte ed640c4519 add ip.access specific channel combinations 2009-08-01 18:23:01 +02:00
Harald Welte d83a127bb3 add more ipaccess 12.21 object classes, NSVC only exists once 2009-07-12 10:56:06 +02:00
Harald Welte 0efe9b7006 more ip.access abis_nm attributes
we also rename some existing attributes to reflect reality
2009-07-12 09:33:54 +02:00
Harald Welte a0c0b57c28 add more TLV parser definitiosn for IPA NM attributes 2009-07-03 12:46:27 +02:00
Harald Welte 9446d329f0 ip.access test numbers 2009-07-01 11:03:54 +02:00
Harald Welte d2f11f2923 add more ipaccess 12.21 OML extension definitions 2009-07-01 09:56:21 +02:00
Harald Welte 244b94b1de abis_nm.h: Fix various typos 2009-06-25 08:23:19 +02:00
Harald Welte 13e10daa33 move openbsc into its own subdirectory 2009-06-10 05:40:52 +08:00