Holger Freyther
0469cf608b
[e1] Enable dumping of LAPD frames again
...
Kill mi_set_pcap_fd from the header, introduce e1_set_pcap_fd
and call it from bsc_hack.c. Hook into abis_rsl_sendmsg and
_abis_nm_sendmsg for sending and e1inp_rx_ts for reading. It compiles
and should not cause a regression.
2009-03-31 12:14:16 +00:00
Holger Freyther
66e092bbd6
[e1input] Do not redefine PF_ISDN if it is already defined
...
Fix compile warning in e1_input.c
2009-03-31 12:13:50 +00:00
Harald Welte
7e310b12ff
Store incoming SMS into SQL database
...
* gsm_util now uses caller-allocated data (rather than callee-allocated)
* correctly parse destination address
* parse (but not transcode) non-default encodings of SMS
* reject SMS to unknown destination number
* resolve target subscriber id and store incoming SMS (without header) in 'sms' table
What we're now missing is the sending part, i.e. a regular task iterating over
all pending SMS and trying to deliver them. Also, check for pending SMS once
we get a LOCATION UPDATE.
2009-03-30 20:56:32 +00:00
Harald Welte
93d9303331
check for malloc fails
2009-03-30 09:11:45 +00:00
Harald Welte
5258fc4974
add stubs for enable/configure terminal/bts/trx/ts commands in VTY interface
2009-03-28 19:07:53 +00:00
Harald Welte
f5025b6bae
add 'show paging' for BTS to telnet interface
2009-03-28 16:55:11 +00:00
Harald Welte
273feca77f
Fix 'delete-trx1' command of bs11_config (we can now delete TRX1)
2009-03-28 16:53:25 +00:00
Holger Freyther
1047940dce
[misc] Make distcheck work again
2009-03-11 03:29:43 +00:00
Harald Welte
1bc7735ad5
* more human-readable strings instead of values
...
* vty printout of e1 driver/line/timeslot items
2009-03-10 19:47:51 +00:00
Harald Welte
c63e51daac
* correctly handle VTY_READ/VTY_WRITE events and select loop integration of VTY
2009-03-10 19:46:16 +00:00
Harald Welte
d256d4f19c
* make sure we can obtain signalling type and timslot type names
...
* make sure every e1 timeslot has a valid backpointer to its line
2009-03-10 19:44:48 +00:00
Harald Welte
4d87f24e6f
export nm_*_name() functions to get operational and availability state to strings
2009-03-10 19:43:44 +00:00
Harald Welte
44d542eba5
export list of e1 drivers and e1 lines
2009-03-10 18:24:35 +00:00
Harald Welte
ef235b547b
* don't print lchan's of type NONE
...
* better formating of VTY printing of some objects
2009-03-10 12:34:02 +00:00
Harald Welte
404cdd8951
make telnet interface use VTY code
2009-03-10 12:21:45 +00:00
Harald Welte
68628e8479
add VTY dumping functions for OpenBSC
2009-03-10 12:17:57 +00:00
Harald Welte
955049f191
import VTY code from zebra/quagga (from my cardshell project)
2009-03-10 12:16:51 +00:00
Harald Welte
32201c1aea
move is_ipaccess_bts() and parse_btstype9) to gsm_data.c
2009-03-10 12:15:10 +00:00
Harald Welte
a30b1cad9f
more verbose attribute ack/nack
2009-03-10 11:46:02 +00:00
Holger Freyther
ff9592fa10
[misc] Fix compile warnings...
2009-03-09 16:17:14 +00:00
Harald Welte
015b9ad9db
actually request the IMEI not IMEISV, since Phase 1 doesn't have IMEISV
2009-02-28 18:22:03 +00:00
Harald Welte
ddab3c78c5
introduce new 'mode' parameter to RSL ACTIVATE CHANNEL
2009-02-28 13:19:15 +00:00
Harald Welte
4a543e81cf
* more RSL and 04.08 constant defines
...
* initialize some data structures before using them in RSL
* DATA_REQ is a transparent message
* more elaborate DEBUGP statements here and there
* don't call 04.08 with zero-length RSL DATA INDICATION
* reject 04.08 CC HOLD and RETRIEVE, as we don't support them yet
2009-02-28 13:17:55 +00:00
Harald Welte
02b0e093a1
make sure all channels in one BTS use the same TSC (training sequence code)
2009-02-28 13:11:07 +00:00
Harald Welte
3cc4bf517f
make hexdump return a 'char *' rather than printing by itself
2009-02-28 13:08:01 +00:00
Harald Welte
51f38457e5
add missing header include
2009-02-24 22:36:40 +00:00
Harald Welte
65ccf88feb
fix non-randomness of TMSI by seeding the PRNG. Later we should use openssl
2009-02-24 22:36:20 +00:00
Harald Welte
41fbf443a0
enable IMSI ATTACH/DETACH
...
* this tells us whenever a MS is switched off
* also ensures that we get LOCATION UPDATe every time MS is switched on, even if it already has TMSI
2009-02-24 22:34:22 +00:00
Holger Freyther
0d4df32044
[sms] Fix the length of the of the outgoing data...
...
The returned length should be right now. The test case
is passing.
2009-02-23 04:03:33 +00:00
Holger Freyther
77217de8a5
[sms] Fix memory leak
2009-02-23 04:03:27 +00:00
Holger Freyther
3b1f3d0798
[sms] Fix two bugs regarding 7 bit coding...
...
- Fix the length (almost)
- Move the second part by 8 - b_off
e.g. with (ba) 0x62 0x61 the first bit of
0x61 goes to the highest on the first byte and
the second word contains 0x110000...
- The simple test case is almost passed... just a missing
character at the end.
2009-02-23 01:47:15 +00:00
Holger Freyther
59da07bd0e
[sms] Add test case for the 7-bit coding/decoding...
...
we don't pass it yet.
2009-02-23 00:50:38 +00:00
Holger Freyther
b4064bca6e
[db] Introduce a table for SMS
...
- created for the creation of the SMS
- sent the time the message was submitted
- sender_id the subscriber for the return path/report
- receiver_id the subscriber
- header the (optional) SMS PDU header
- payload the payload (utf8), raw data
2009-02-23 00:50:31 +00:00
Harald Welte
ba59bafc8e
remove subchan_demux debug statements, add DMUX commandline parsing
2009-02-23 00:04:04 +00:00
Harald Welte
7f93ceafef
Ignore CONNECTION FAIL INDICATION cause 0x18 to make sure our phone calls survive on BS11.
...
Apparently the BS-11 sends soem undocumented cause 0x18 as part of a CONN FAIL IND message
shortly after we establish the call. If we close the channel, the voice call
is aborted. If we ignore the message, everything just continues to work.
2009-02-23 00:02:59 +00:00
Harald Welte
b49fe96ad6
reduce lag in voice calls by reducing the subchannel muxer tx queue depth to
...
effectively three entries. In the future we should probably think of only
having a one-frame deep queue.
2009-02-22 22:28:19 +00:00
Harald Welte
ee670478e5
Add LMT event parsing
2009-02-22 21:58:49 +00:00
Harald Welte
6154898753
fix paging response parsing for phase1 phones (classmar2 can be less than 4 bytes in length)
2009-02-22 21:26:29 +00:00
Harald Welte
2a1393758d
add parsing of IMSI DETACH
2009-02-22 21:14:55 +00:00
Harald Welte
fe18d8fd89
PAGING RESPONSE could contain non-TMSI mobile identity such as IMSI
2009-02-22 21:14:24 +00:00
Harald Welte
5a065dfe2d
don't allow calls of a subscriber to himself
2009-02-22 21:13:18 +00:00
Holger Freyther
1ef983b076
[db] Print the type and id of the not found provider
2009-02-22 20:33:09 +00:00
Harald Welte
c1697105cf
use RSL debug prefix in RSL code
2009-02-22 18:18:12 +00:00
Harald Welte
074d873df9
correct E1 timeslot / TEI attribute parsing
2009-02-21 20:41:12 +00:00
Harald Welte
0558f547c7
only perform oml-tei once
2009-02-21 20:17:12 +00:00
Harald Welte
b6c92ae782
* set OML TEI and E1 timeslot in one command
...
* introduce new 'oml-tei' command of bs11_config
2009-02-21 20:15:32 +00:00
Harald Welte
fd2fb458ac
25C3 is over, so call our network OpenBSC
2009-02-21 13:00:57 +00:00
Harald Welte
099d6100e6
fix various compiler warnings while building bs11_config
2009-02-21 12:59:58 +00:00
Harald Welte
7bc4cbc45c
tlv_parser now operates on 'const' input buffer
2009-02-21 12:59:22 +00:00
Holger Freyther
3281f6e233
[build] Create a libbsc.a as noinst_LIBRARY, link bsc_hack and tests against it
...
Link the tests against the libbsc.a to avoid most of the breakage
when creating new symbols.
2009-02-20 18:33:00 +00:00
Harald Welte
11fa29c169
implement dynamic TRAU frame mapping
2009-02-19 17:24:39 +00:00
Harald Welte
f325eb4e9f
use new gsm_ts_name() funciton from debug statemens everywhere
2009-02-19 17:07:39 +00:00
Harald Welte
dbd2ea8708
add debug statement when setting up trau mapping
2009-02-19 17:07:01 +00:00
Harald Welte
23a686347d
add gst_ts_name() function to obtain human-readable channel name
2009-02-19 17:06:42 +00:00
Harald Welte
f1e6f96654
don't pass subchannel data to the TRAU decoder if we're not synchronized yet
2009-02-19 17:05:13 +00:00
Harald Welte
26aa6a1166
trau mux updates
...
* add function to map two lchans to each other
* make sure to evic old trau mux mappings before creating a new one
2009-02-19 15:14:23 +00:00
Harald Welte
ad2a12a4c3
we need tlv_parse.c in bs11_config now
2009-02-19 03:11:48 +00:00
Harald Welte
f80b7d347c
bs11_config: makes sure we disconnect properly before exiting
2009-02-19 03:11:13 +00:00
Harald Welte
fb81ae9da2
restructure and enhance bs11_config
...
* add the concept of commands in addition to options
* add commands for querying essential configuration
* add command for explicit create/delete of TRX1
* software download is now an explicit operation
2009-02-19 02:59:17 +00:00
Harald Welte
78fc0d40a6
add various BS11 management related abis_nm functions
2009-02-19 02:50:57 +00:00
Harald Welte
0313394a88
* support BS11 specific IE types in abis_nm
...
* make bs11_config compile again
* now that we have a proper TLV parser, use it to parse the status response on the serial port
2009-02-18 19:51:53 +00:00
Harald Welte
2c38aa8dcd
* make sure we use the correct GSM48 encoding type
...
* modify the RSL channel mode (BTS) side) after the 04.08 (MS side) has acked MODIFY
2009-02-18 03:44:24 +00:00
Harald Welte
0b8348d397
fix the parsing of the 'normal' availability status
2009-02-18 03:43:01 +00:00
Harald Welte
b110cee0a0
CONNECT TERRESTRIAL TRAFFIC needs to be in the CHANNEL object class in order to work
2009-02-18 03:42:35 +00:00
Harald Welte
7eb1f621e0
"the big fix", of the E1 subchannel [de]multiplexer. I don't even remember how
...
many bugs I fixed during the last couple of hours. It was never working at
any time before.
2009-02-18 03:40:58 +00:00
Harald Welte
f9227c7562
write 160byte to one E1 TS at any given time, since that is one TRAU Frame (40 bytes) per sub-channel
2009-02-18 03:39:00 +00:00
Harald Welte
23887b607f
use official TCH/F for initial channel modes rather than BS-11 specific 0x09
2009-02-18 03:37:20 +00:00
Harald Welte
41e166884e
if TRAU frame decoding doesn't work, we don't need to even try to re-encode and just send an idle frame instead
2009-02-18 03:34:55 +00:00
Harald Welte
da78376396
* ensure TCH/F are activated signalling-only
...
* add function for RSL CHANNEL MODIFY REQUEST
* add missing channel activation function to header file
2009-02-18 03:29:53 +00:00
Harald Welte
93d3f37f6c
* disable TS3 TRAU frame handling for now
...
* statically activate two sub-slots in TS2 (need to do this dynamic later)
2009-02-18 03:27:14 +00:00
Harald Welte
bb8c4061eb
* use DEBUGP in TRAU frame code
...
* make sure we actually set 'spare' bits to 1
2009-02-18 03:24:58 +00:00
Holger Freyther
ce66896d1d
[utils] Commit not working 7bit encoder...
...
No one is using it so far, so no one gets hurt...
2009-02-17 23:42:45 +00:00
Holger Freyther
62f47773ae
[utils] Style change..
2009-02-17 20:31:35 +00:00
Holger Freyther
76c9569021
[utils] Create gsm_utils for 7bit encoding and decoding...
2009-02-17 20:31:30 +00:00
Harald Welte
9e783318b0
strip mISDN hardware header before putting B-channel data into subchannel demuxer
2009-02-17 19:02:29 +00:00
Harald Welte
311d0cf245
don't reduce power quite as much to make sure we still get a singal (bs-11) and nanoBTS doesn't refuse the attribute at all
2009-02-17 17:45:59 +00:00
Harald Welte
bfaf097905
in case pagign of the 'B-end' during call setup fails, transmit message to
...
correct lchan rather than crashing
2009-02-17 17:43:33 +00:00
Harald Welte
49dfa353e3
correctly print IPAC_CONNECT_ACK debug statement
2009-02-17 15:29:58 +00:00
Harald Welte
49f48b8b77
various CC updates:
...
* correctly lchan_put the second lchan of a call at teardown
* map the RTP streams of ip.access onto each other
* fix bug that prevented a CONNECt message to ever reach the 'B' side
2009-02-17 15:29:33 +00:00
Harald Welte
167df88aae
* increased debug verbosity for ip.access BIDND_ACK processing
...
* emit a signel when the BIND is acknowledged
2009-02-17 14:35:45 +00:00
Harald Welte
4b45815b9d
CC: send correct messages (too much copy+paste) and better debug printout
2009-02-17 13:23:06 +00:00
Harald Welte
677c21f4ab
add parsing for ip.access vendor specific NM messages
2009-02-17 13:22:23 +00:00
Harald Welte
7ccf77810b
slightly more complete GSM 04.08 CC, we can now
...
* initiate phone calls from one MS
* look-up the subscriber based on dialled extension
* page the called subscriber
* send the SETUP to the called subscriber, including CLIP/CLIR
* get ALERTING notification back to caller
* relay DISCONNECT from either side to the other
This is still far from being complete, but it at least works for the most common case
2009-02-17 01:43:01 +00:00
Harald Welte
75a1fa834c
switch paging code to use a timer again, since not all BTS send reliable CCCH load indications
2009-02-17 01:39:41 +00:00
Harald Welte
09e38afbcc
* introduce a callback function when paging completes (I know this is somewhat of an overlap
...
with the signals, but I think paging always has one reason and thus one caller wants to
get notified about completion, including a caller-specific context, etc)
* introduce TLV parser definitions for GSM 04.08
* parse and generate BCD number IE's for 04.08 call control
2009-02-16 22:52:23 +00:00
Harald Welte
595ad7b762
modify the signal handler/dispatch code (sorry zecke, no offense, I just had some different ideas)
...
* introduce new notion of subsystem in addition to signal number
* no need for bitmasks of 'areas' (aka subsystems)
* pass subsystem/signal_nr/... per argument rather than by data structure
2009-02-16 22:05:44 +00:00
Harald Welte
7509926614
* introduce TLV parser definitions for RSL IE's
...
* introduce functions for ip.access specific RSL commands
2009-02-16 21:12:08 +00:00
Holger Freyther
9b177760bb
[sms] Send a notification on incoming SMS
...
Further tests of the signal class. Send a notification
on incoming SMS.
2009-02-16 19:07:18 +00:00
Harald Welte
d4c9bf3c5a
* add bs_power and ms_power attributes to each channel and use them in channel activation
2009-02-15 16:56:18 +00:00
Harald Welte
cd99387bd2
* use more constants to name the various BTS/TRX/... attributes
...
* set BS power reduction up to 30dB reduction. we want to be quiet!
2009-02-15 16:16:28 +00:00
Harald Welte
940093296e
support non-123 ARFCN on nonoBTS
2009-02-15 15:38:42 +00:00
Harald Welte
4f361fcb68
* add commond header file for ipaccess protocol
...
* query for more attributes during ipaccess-find
2009-02-15 15:32:53 +00:00
Harald Welte
e1bd2412c2
* use the correct BCCH channel type for nanoBTS
...
* remove old code
* ensure that the default BTS type really is BS-11
* document the '-t' commandline argument in the --help message
With this commit, I can get the nanoBTS 900 working with OML and RSL, register
to the network from phones. Paging is not tested yet, and voice traffic handling
is completely missing..
2009-02-15 14:40:09 +00:00
Harald Welte
362322ed81
For Phase2 and higher BTS, use the FULL IMMEDIATE ASSIGN INFO attribute, rather than IMMEDIATE ASSIGN INFO
2009-02-15 14:36:38 +00:00
Harald Welte
5c1e458376
Add support for ip.access RSL link on port 3003
2009-02-15 11:57:29 +00:00
Harald Welte
7782c14295
* generate virtual E1 TEI up/down events
...
* make debug printout a little less verbose
* introduce usleep to make things a bit slower for debugging
2009-02-15 03:39:51 +00:00
Harald Welte
8c1d0e41a7
* add bsc_hack commandline argument to select BTS type
...
* add event-based OML bring-up for nanoBTS
2009-02-15 03:38:12 +00:00
Harald Welte
e0590df524
* extend TLV parser to use a list of TLV type descriptions
...
* implement TLV type descriptions for NM
* add operational/administrative/availability state keeping logic to abis_nm
* explicitly print all NACK's in abis_nm
* make sure we produce [not just for BS-11] valid channel attributes
2009-02-15 03:34:15 +00:00
Holger Freyther
49314f6080
[paging] Do not create a request when one is already pending...
...
This is removing a memleak, saving some mallocs and a crash
in the timer expired function that attempted to remove the
paging_request from a list it was not in....
2009-02-14 23:53:20 +00:00
Holger Freyther
2fa4cb5bc9
[paging] Assign the subscriber to the channel first...
...
Assign the GSM subscriber to the lchan and then inform
the paging layer and dispatch a signal. This makes sure
that lchan is updated with the right kind of information.
2009-02-14 23:53:15 +00:00
Holger Freyther
531c0deecb
[paging] Fix crash, move_to_next can not be used....
...
move_to_next is using the last_request but we do not have
one... but we know the list is not empty so just pick the
first entry.
2009-02-14 23:35:09 +00:00
Holger Freyther
36b5d650b8
[signal] Fix misuse of llist_add_tail...
...
The to be added llist_head comes first.......
2009-02-14 23:35:06 +00:00
Holger Freyther
6b2d262888
[nm] Fix the ObjectClass for Set Channel Attribute
...
In r308 the enum for the object class was fixed and we
started to send the wrong (0x4) instead of the right (0x3)
object class. Fix that.
2009-02-14 23:16:59 +00:00
Holger Freyther
7aaf112ba7
[signal] Add consumer of the signal api, inform about paging
...
Use the new signaling API in the telnet interface to broadcast
a succeeded or failed paging request.
2009-02-14 22:51:13 +00:00
Holger Freyther
e4b3fa3633
[signal] Move the area into the struct signal_data...
...
Remove the parameter and move the signal kind into the
signal struct. Make register/deregister fully symmetric.
2009-02-14 22:51:10 +00:00
Holger Freyther
053e09d102
[signal] dispatch the paging response...
...
Inform people about the successfull paging response and
provide access to the subscriber, lchan and bts...
2009-02-14 22:51:06 +00:00
Holger Freyther
4af2b48009
[signal] Dispatch the first signal... inform about paging timeout
...
When the paging request timed out, send a signal... lchan
is NULL in case of a failure.
2009-02-14 22:51:03 +00:00
Holger Freyther
2b2d2e350e
[signal] Add generic signal registration and dispatch...
...
This will be used for generic registration and dispatching
of any kind of event. We will have different areas (like
with the debug interface) and each layer can define their
own struct for the event message... This is not tested yet
2009-02-14 22:51:00 +00:00
Harald Welte
09d38d3b61
add tlv_parser code to Makefile.am
2009-02-14 19:46:31 +00:00
Harald Welte
2fa79349aa
implement type1TV or type 2 detection
2009-02-14 19:07:10 +00:00
Holger Freyther
e36e15eb0a
[paging] Send up to avaliable_slots paging requests...
...
Send up to available_slots paging requests but only
iterate over the list once. This was not tested on
a bts.
2009-02-14 18:05:03 +00:00
Holger Freyther
83e44b01e9
[paging] Initiliaze req in paging_T3113_expired
2009-02-14 18:04:59 +00:00
Harald Welte
22af0db588
* add comments for SET BTS ATTR and SET RADIO CARRIER ATTR
...
* use OPSTART on objects whose operational state is Disabled
2009-02-14 15:41:08 +00:00
Harald Welte
923a3bdbe5
add new program to use UDP broadcast packets to find ip.access BTS in the network
2009-02-14 12:51:36 +00:00
Harald Welte
5fd8a545c8
preliminary ip.access BTS support, as of now only OML singalling works
2009-02-13 02:43:36 +00:00
Harald Welte
34a9968baf
* more extensive A-bis OML support
2009-02-13 02:41:40 +00:00
Harald Welte
7584aeac42
* add more GSM 04.08 IEIs
...
* implement function for CHANNEL MODE MODIFY
* don't use hard-coded SETUP message but construct it with tlv functions
2009-02-11 11:44:12 +00:00
Holger Freyther
334f236019
[paging] factor out list iteration... move to the next item
2009-02-11 03:00:20 +00:00
Holger Freyther
b1ffbb62ee
[paging] Send paging requests as response to the PAGING LOAD indicator
...
Kill the paging timer and send paging upon paging load notifications.
2009-02-11 01:49:15 +00:00
Holger Freyther
ed2aea8ac1
[paging] Stop the timer when the paging was successful
2009-02-11 01:18:42 +00:00
Holger Freyther
f6535bb444
[paging] Stop counting the requests... harald implemented sepc conform timer support
...
We do have a dispose timer, there is no need to discard the
paging request this way... remove the code.
2009-02-11 01:02:45 +00:00
Holger Freyther
3b91043cae
[ccch load] Enable notifications for CCCH/PAGING LOAD again
...
Set the threshold to 0% for the load indication. The paging buffer
space will be used by the paging notifications and we will ignore
the racch usage notification for now.
2009-02-11 00:43:48 +00:00
Holger Freyther
5d7e5571d5
* make sure we start sending B channel data on channel activation
2009-02-10 18:40:45 +00:00
Harald Welte
8ffcfed9e0
mISDN doesn't support select-writefd's but rather sends PH_DATA_CNF
...
indications which should trigger us sending a new data packet on the
B channel
2009-02-10 18:18:50 +00:00
Harald Welte
51cce1e617
* decrease subscriber refcount when free()ing a paging request
...
* use a new timer that stops paging requests after some time, rather than
sending them indefinitely
2009-02-10 17:35:04 +00:00
Harald Welte
cd06bfbc9d
* fill the e1_link member of every bts_trx_ts structure
...
* introduce new timer as part of every paging request
2009-02-10 17:33:56 +00:00
Harald Welte
39a1b7193c
set up a static TRAU mux mapping between on-air TS1 and TS2
2009-02-10 17:17:09 +00:00
Holger Freyther
57dd7bf626
prettier debug prints in mISDN driver
2009-02-10 01:04:22 +00:00
Holger Freyther
392209cbb5
[paging] Introduce a variable containing the free paging slots
...
Start with a large number of available slots. It is guranteed
that we will - at some point - get a paging load and will properly
update the counter and keep it updated.
2009-02-10 00:06:19 +00:00
Holger Freyther
1fd34141c2
[paging] Cleanup page -> paging in function names
2009-02-09 23:42:03 +00:00
Holger Freyther
9c564b85e6
introduce lookup of subscribers based on their extension number
2009-02-09 23:39:20 +00:00
Holger Freyther
cbc7b06534
some more primitive names for improved debug readability
2009-02-09 23:10:48 +00:00
Holger Freyther
59639e81e1
* always use bts->c0 as msg->trx for OML messages
2009-02-09 23:09:55 +00:00
Holger Freyther
fb3f5190b4
* correctly initialize link->tei and link->sapi
...
* fix debug printf
2009-02-09 23:09:15 +00:00
Holger Freyther
3630eab572
fix segfault when trying to dequeue list head as list element
2009-02-09 21:05:56 +00:00
Harald Welte
ce6efc295f
remove old misdn driver; the code is now using e1_input.c in combination
...
with src/input/misdn.c
2009-02-09 18:14:24 +00:00
Harald Welte
1fa60c8ab0
* add trau_mux implementation to relay from one incoming TRAU
...
channel to another one (simple voice call switching)
* add a way more generic E1 input layer, abstracting out the misdn
low-level interface. This also adds infrastructure for multiple TRX
in one BTS, as well as multiple BTS on one E1 link
* add a E1 subchannel multiplexer for sending multiple 16kbit sub-channels
one one 64kBps E1 channel
* add TRAU IDLE frame generation
* terminate bsc_hack in case there is a E1 / mISDN init error
* introduce 'e1_config.c' file with static configuration of our
E1 setup (which TRX/BTS is configured for which TEI/SAPI/E1). This should
later become a config file rather than a compiled C file.
WARNING: all this compiles but is not tested yet. Expect fix-up committs over
the next hours or so
2009-02-09 18:13:26 +00:00
Harald Welte
0b4c34e3ca
fix compiler warning about undeclared function by adding include file
2009-02-09 17:54:43 +00:00
Harald Welte
9383de3010
* remove excessive debug output during software load
...
* fix compiler warning about unused variable
2009-02-09 17:53:49 +00:00
Harald Welte
e79769b926
make sure certain functions are per TRX, not per BTS, such as
...
* rsl_chan_activate()
* rsl_bcch_info()
* rsl_sacch_filling()
2009-02-07 00:48:17 +00:00
Holger Freyther
33ba752057
[paging] Move the code to send the command into a separate function
...
Mostly cosmetic and in preparation for proper page load indicator
handling.
2009-02-06 22:33:25 +00:00
Holger Freyther
e64a7a3c3b
[rr] Send a Channel Release before deactivating the channel
...
After auto releasing a channel the next paging request will
not be immediately answered. The hypothesis was that we do
not release the channel properly. Implementing Channel Release
of GSM 04.08 should have fixed it, but it didn't. According
to the wireshark dissectors the message is correct though.
- Add the RR cause values to gsm_04_08.
- Implement the Channel Release message
- Invoke the release channel function before deallocating
the lchan.
2009-02-06 21:55:37 +00:00
Holger Freyther
ceb59b72c2
[paging] Move the paging state into struct gsm_bts
...
There is a 1:1 relationship between gsm_bts and the paging
operation. Move the paging state into the gsm_bts which is
simplfying the code a lot. This was hinted by LaF0rge.
(I'm not happy with the names of the structs)
2009-02-06 18:54:00 +00:00
Holger Freyther
3d949240fe
[paging] Use paging_request_remove to update last_request and free memory
...
Update the last_request when stopping the paging operation and also
free the associated memory of the request.
2009-02-06 18:08:18 +00:00
Holger Freyther
31338a16a5
[bs11-config] Really force the software upload
...
When we get a NM_MT_LOAD_END_NACK and we are supposed to
force the load we will just send data. This was already
done with NM_MT_LOAD_INIT_NACK.
2009-02-06 17:43:50 +00:00
Harald Welte
97ed1e7d43
* implement some simplistic OML EVENT STATE CHANGE REPORT parsing
...
* make sure we don't call a user_cb() function if it is NULL
2009-02-06 13:38:02 +00:00
Harald Welte
47150fbd20
stop paging a particular subscriber after we have received a PAGING RESPONSE
2009-02-06 12:52:47 +00:00
Harald Welte
763da00e97
add new routine to stop paging
2009-02-06 12:52:14 +00:00
Harald Welte
91b5b0d41d
add some initial simplistic TLV parser
2009-02-06 12:51:39 +00:00
Harald Welte
0bbb8b2fd2
increase CCCH LOAD indication threshold to 50% to remove lots of noise
2009-02-06 12:49:11 +00:00
Harald Welte
6ddd1683b5
introduce new "DEBUGPC" macro for continuing on the same line without prefix of file/line/time
2009-02-06 12:38:29 +00:00
Harald Welte
b60fa59276
add DMI and DMIB debug= commandline option parsing
2009-02-06 12:02:53 +00:00
Harald Welte
2d35ae6d3b
implement parsing of PAGING RESPONSE
2009-02-06 12:02:13 +00:00
Harald Welte
1cbfaf508a
* introduce a new '--restart' parameter to reboot BTS
...
* unconditionally create TRX1 objects
* wait for '3 Normal' before issuing disconnect
* MBCCU0/MBCCU1 state were accidentially switched
2009-02-05 19:30:22 +00:00
Harald Welte
b8427970e2
introduce abis_nm_bs11_restart() function
2009-02-05 19:27:17 +00:00
Holger Freyther
152a14718a
[paging] Use the number of different paging subchannels...
...
In our setup (1xCCCH combined, BS_AG_BLKS_RES=0,
BS_PA_MFRMS=0x3 -> 5) we have MAX(1,3-0) * 5 paging
sub-channels. Using this 15 I was able to successfully page
my phone/IMSI (934%15 -> 4).
My confusion is coming from the terms used for paging throughout
the documentation. GSM05.02 6.5.2 talks about "N = number of
paging blocks 'available' on one CCCH = (number of paging blocks
'available' in a 51-multiframe on one CCCH)xBS_PA_MFRMS" which
is already misguiding and GSM04.08 is talking about number of
different paging subchannels on the CCCH and is providing a
formula.
I deduct that N == number of different paging subchannels on the CCCH
as of GSM04.08 and will simply test this with different IMSIs and
see if I can page them as well.
2009-02-04 13:38:26 +00:00
Holger Freyther
3aa8d6c46d
[paging] This is paging my phone but it looks completely wrong...
...
- The paging block calculation is wrong but I have a hard time finding
the right information. The table of 05.02 (Table 5 of 9) looks good
but my phone is not happy with that group...
2009-02-04 02:14:45 +00:00
Holger Freyther
3b72a890c2
[paging] Implement the three Control Channel Descriptor methods...
...
This comes from GSM 05.02 and GSM 04.08
2009-02-04 00:31:39 +00:00
Holger Freyther
1adb4ff002
[paging] Keep a copy of the Control Channel Description in the bts struct
...
- Initialize Control Channel Description of SI3
- Patch the table
- Setting ATT now is easy
- Paging can now extract all required information... to determine
the right paging group.
2009-02-04 00:04:52 +00:00
Holger Freyther
d4ec5287c2
[paging] some minor cleanups. put the current request into a temporary
2009-02-03 23:18:46 +00:00
Holger Freyther
df892da697
[paging] Cosmetic changes on the timer handling and max requests
2009-02-03 21:05:49 +00:00
Holger Freyther
f07768915d
[telnet] use SO_REUSEADDR on the telnet socket
2009-02-03 20:49:51 +00:00
Holger Freyther
8c563cf4f9
[rsl] Decode RACH Load as well
...
Print the common field and ignore the Supplementary Information.
Initialize the fields to 0xffffffff in case the payload is malformed
2009-02-03 20:08:51 +00:00
Harald Welte
bf5e8df424
cosmetic fixes / more comments
2009-02-03 12:59:45 +00:00
Harald Welte
dc55db9d95
cosmetic fixes
2009-02-03 12:58:59 +00:00
Harald Welte
8f5e239388
cosmetic/coding style fixes
2009-02-03 12:57:37 +00:00
Harald Welte
6f14691c61
make bs11_config status lines shorter
2009-02-03 02:05:28 +00:00
Harald Welte
ea280446bb
add rudimentary code to debug-print the CCCH LOAD INDICATION
2009-02-02 22:29:56 +00:00
Harald Welte
5083b0b1f1
* fix warnings while compiling abis_nm.c
2009-02-02 19:20:52 +00:00
Harald Welte
5f6f149983
add limits.h for PATH_MAX
2009-02-02 14:50:29 +00:00
Harald Welte
7ed1a64d9d
* exit program if we cannot set up the serial port
...
* leave the program if ctrl+c is pressed three times even without logoff from BTS
2009-02-02 14:45:49 +00:00
Harald Welte
44227dd62f
typo
2009-02-01 22:25:58 +00:00
Harald Welte
3ffd1376b7
* add abis_nm_software_load_status() to header file
...
* new abis_nm_bs11_bsc_disconnect() function to disconnect BSC/BTS link
* add support for 'forced load' of BS-11 software to abis_nm.c and bs11_config
* remove lots of debug output
* print progress during software load
2009-02-01 22:15:49 +00:00
Harald Welte
c12d52bae4
* improve parsing of status/phase response from BTS
...
* split rs232 support into separate file (like misdn.c)
2009-02-01 21:39:06 +00:00
Harald Welte
268bb40b35
* add more detailed status printout to bs11_config
...
* add support for real LMT logon time
* add support for abis external time
* move 'create_trx1_objects' to separate function
2009-02-01 19:11:56 +00:00
Harald Welte
832822961d
Enable CCCH LOAD INDICATION always, from 0% upwards, and report it every second
2009-02-01 16:22:19 +00:00
Harald Welte
5e4d1b3663
* rename NM_MT_BS11_LOGOFF to NM_MT_BS11_LMT_LOGOFF
...
* add more BS11 specific attributes
* define all valid BS11 PA power classes
* add callback function to software load
* introduce SWL load function for BS-11 style SWL file lists
* separate activation of software from loading of software
* add function to obtain BS-11 serial number
2009-02-01 13:36:56 +00:00
Harald Welte
043d04a99a
* Use new NM_ATT_BS11 definitions instead of magic numbers
...
* rename FECTORY_LOGON into LMT_LOGON since it's not always factory level
2009-01-29 23:15:30 +00:00
Harald Welte
623d53185b
bs11_config:
...
* disable serial port POST processing
* default delay is 0
* make window size user-configurable (default: 8)
* add missing help line for the --delay option
* don't forget to create the CCLK object as part of minimal config
2009-01-29 21:14:05 +00:00
Harald Welte
1602ade492
Fix end-of-software_load detection (send segment with window number 0, wait for seg_ack)
2009-01-29 21:12:39 +00:00
Harald Welte
14f0934f0b
* use select loop based rx/tx processing in bs11_config
...
* improve parsing/generation of fake lapd header
2009-01-29 19:28:38 +00:00
Harald Welte
3b8ba215b9
* Fix BS11 software download routines in abis_nm.c
...
* Introduce user-configurable delay when sending serial msgs from bs11_config
2009-01-29 12:27:58 +00:00
Harald Welte
071f34d7c6
bs11_config:
...
* fix serial port initialization
* add bs11_state enum and work accordingly
2009-01-29 09:24:38 +00:00
Harald Welte
f186c46ff6
bs11_config: add setting of baud rate
2009-01-29 08:45:19 +00:00
Harald Welte
bb15131847
fix off-by-one error in BS11 factory logon command
2009-01-28 20:42:07 +00:00
Holger Freyther
97cce476a2
[paging] Slightly increase the timeout to not overload the BTS...
2009-01-27 23:49:40 +00:00
Holger Freyther
bf83481799
[paging] Discard paging requests after not completing them...
2009-01-27 23:46:19 +00:00
Holger Freyther
1525de0c8f
[paging] memset and improve error message
2009-01-27 23:38:27 +00:00
Holger Freyther
342a2c67de
[abis] Do not confuse me again....
2009-01-27 22:49:48 +00:00
Harald Welte
cfe6dce248
don't logon twice
2009-01-19 16:06:43 +00:00
Harald Welte
61e42ad7fd
add bs11_config as LMT alternative
2009-01-18 19:10:46 +00:00
Harald Welte
7837489a6e
abis_nm_reset_resource is a bs11 specific function
2009-01-18 19:09:22 +00:00
Harald Welte
4724f99d19
Implementation of GSM12.21 LOAD SOFTWARE (BS11 dialect thereof)
2009-01-18 18:01:49 +00:00
Harald Welte
978cb42911
add BTS TYPE field to facilitate future non-BS11 BTS support
2009-01-18 17:57:27 +00:00
Harald Welte
6f676a3541
abis_nm: use correct length in 08.59 OML header for all messages
2009-01-18 14:27:48 +00:00
Harald Welte
1bc0906436
abis_nm: more BS11 specific messages for configuration
2009-01-18 14:17:52 +00:00
Harald Welte
05188ee7a7
* prefix all BS11 specific OML functions with proper name
...
* add more BS11 specific OML commands (TRX power, logon, OML TEI, ...)
2009-01-18 11:39:08 +00:00
Harald Welte
adaf08bec8
add some more BS11 specific OML definitions
2009-01-18 11:08:10 +00:00
Harald Welte
d08de2f9e4
fix typo
2009-01-11 04:38:55 +00:00
Harald Welte
9bb7c70016
If there is already a subscriber and it does not equal to us -> moan
...
And unreference the gsm_subscriber object otherwise we would leak.
2009-01-10 03:21:41 +00:00