summaryrefslogtreecommitdiffstats
path: root/src/host
AgeCommit message (Collapse)AuthorFilesLines
2013-01-05osmocon: make romloader output much less verboseSteve Markgraf1-20/+5
Most of the output was only for debug purposes anyway. Signed-off-by: Steve Markgraf <steve@steve-m.de>
2013-01-02mobile/gsm411: Fix printf format warningSylvain Munaut1-1/+1
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2013-01-02mobile/gsm411: Adapt to new libosmocore API for SMC/SMR by adding idSylvain Munaut1-8/+8
Here we just use the transaction ID Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2013-01-02host/cell_log: Prevent buffer overflow when displaying arfcn rangeSylvain Munaut1-5/+4
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2013-01-02host/l23: Added custom frequecy range to cell_log.Dario Lombardo2-5/+59
Written-by: Dario Lombardo <lomato@libero.it> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2013-01-02l23 sysinfo: defer SI4 CBCH mobile allocation until SI1 is receivedAlex Badea1-0/+1
When parsing SI4, there's a check and a log message saying that CBCH MA is ignored until SI1 is received. Then the MA is decoded anyway -- incorrectly -- such that it remains incorrect even after receiving the next SI1. Fix that with an "else". Signed-off-by: Alex Badea <vamposdecampos@gmail.com> Signed-off-by: Andreas Eversberg <jolly@eversberg.eu>
2012-12-29Fix: Check if cell is barred, before performing location updatingAndreas Eversberg1-0/+9
If not checked, the MM process will crash, due to an endless loop of trying to do location updating to barred cell.
2012-11-22Rename various "rxlev" variable to "rxlev_dbm" and correct their signessAndreas Eversberg10-47/+47
All levels in range of 0..63 are now uint8_t and use "rxlev" as variable name. All levels in range of -110..-47 are now int8_t and use "rxlev_dbm" as variable name.
2012-11-22fix previous commit: use dbm2rxlev()Harald Welte2-2/+2
As andreas points out, there are structure members that are called 'rxlev' but which don't use the scaling (0..63) of the GSM specs, but which are already a signed type and in dBm. So they need to be converted. TODO: Rename those structure members to rxlev_dbm or something that explicitly states it is _not_ an 'RXLEV' value in terms of GSM.
2012-11-20Tell L1CTL_FBSB_REQ the expected received signal levelHarald Welte7-7/+11
As Dieter points out, this drastically improves the resiliance to high receive levels on the C155. We cannot blindly assume a received signal level of -85 dBm if the BTS is 2m away and we actually receive -40 dBm. This patch extends the L1CTL_FBSB_REQ data structure in layer 1 with the respective field, as well as the l1ctl_tx_fbsb_req() API function called from the various layer23 apps. "mobile" and "bcch_scan" already did a PM request and thus know the expected signal power. "ccch_scan" and "cbch_sniff" apparently don't do, so the -85 dBm constant is now hardcoded into the host-side source code there, and should probably be fixed in a follow-up patch.
2012-11-16Fix wrong print of scan freq when using gsm_print_arfcn twice for the same ↵Pavel Baturko1-4/+12
log message
2012-11-15Fix: Correctly convert ARFCN to index.Joshua Lackey1-1/+4
If you enable PCS, you'll never make it out of power-measurement without this patch.
2012-10-30Fix: Change T200 of LAPDm if SAPI 0 and SAPI 3 share bandwidth on SDCCHAndreas Eversberg3-0/+42
We use 1 second on FACCH and 2 seconds on SACCH when SMS is transfered during a call on TCH. There is no impact on bandwidth, because SAPIs use differen channels. In order to correctly transfer SMS during SDCCH, the T200 must be raised from 1 (SAPI 0) to 2 (SAPI 0 and 3), so T200 will not timeout before receiving acknowledge from BTS. This is because both SAPIs share the same ressource on SDCCH. After release of SAPI 3, T200 is lowered back to 1.
2012-10-30Fixed decoding of hexadecimal LAI componentsAndreas Eversberg6-27/+44
libosmocore has changed its LAI decoding from hex to decimal. This caused wrong decoding of MCC and MNC. In order to provide required hex transcoding, special hex encoding and decoding function are added to mobile/sysinfo.c.
2012-10-01Drop unused imports from the python utilities.Paul Wise1-1/+0
2012-09-17Fix linking with GNU ld 2.22 and libgpsKevin Redon4-6/+9
Error: gcc -Wall -I/home/kevredon/osmocom-bb/src/shared/libosmocore/include -I/home/kevredon/osmocom-bb/src/shared/libosmocore/include -g -O2 -D_HAVE_GPSD -lgps -o cell_log main.o app_cell_log.o cell_log.o geo.o ../common/liblayer23.a /home/kevredon/osmocom-bb/src/shared/libosmocore/build-host/src/.libs/libosmocore.a /home/kevredon/osmocom-bb/src/shared/libosmocore/build-host/src/gsm/.libs/libosmogsm.a /home/kevredon/osmocom-bb/src/shared/libosmocore/build-host/src/codec/.libs/libosmocodec.a -lm ../common/liblayer23.a(gps.o): In function `osmo_gpsd_cb': /home/kevredon/osmocom-bb/src/host/layer23/src/common/gps.c:79: undefined reference to `gps_waiting' Fix: Holger told me to do so (he knows better then me about autoconf) - set CFLAGS and LIBS for LIBGPS in layer23 - add libgps CFLAGS and LIBS in Makefile.am for common, misc, mobile I would have done the following (which also works): -AC_CHECK_LIB(gps, gps_waiting, CFLAGS+=" -D_HAVE_GPSD" LDFLAGS+=" -lgps",,) +AC_CHECK_LIB(gps, gps_waiting, CFLAGS+=" -D_HAVE_GPSD" LDFLAGS+=" -lgps" LIBS+=" -lgps",,)
2012-09-08use msgb_pull() to get bytes from start of message, not msgb_get()Harald Welte1-26/+26
msgb_get() is for getting bytes from the end of a message, but it was broken in libosmocore for a long time (until it was fixed today).
2012-09-08layer23: gsm48_decode_lai() is now in libosmogsmHarald Welte1-14/+0
2012-07-12layer23: Fixed size of power offset (SI 3 rest octets)Andreas Eversberg1-1/+1
This is importaint on certan cells to finish BCCH scanning. If SI2ter indication is falsely detected, BCCH reading will timeout, because no expected SI2ter is received.
2012-03-29host/l1ctl: Make sure to initialize tn in neigh_pm_reqSylvain Munaut1-1/+3
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2012-03-01l23: Add option for mobile-app to bind to other interfaces than localhostTim5-7/+24
Signed-off-by: Tim Ehlers <osmocom@ehlers.info> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2012-02-14mobile: Add vty option to force rekeying for every new channelTim Ehlers6-3/+40
Written-by: Tim Ehlers <osmocom@ehlers.info> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2012-02-08host/osmocon: allow uploading of files > 64kb in romload-modeSteve Markgraf1-1/+1
Signed-off-by: Steve Markgraf <steve@steve-m.de>
2012-02-04Framebuffer: Script for font conversion.Christian Vogel1-0/+294
bdf_to_c.py is a python script that converts a bdf-file into the format expected by the osmocom-bb framebuffer (defined in <fb/font.h>.
2012-02-02Just a quick bug fix to gsm322.c.Kurtis Heimerl1-2/+3
Basically, there were two commands in an "else" block without brackets, causing the "end = 1023+299" command to execute regardless of the state of index. Signed-off-by: Andreas Eversberg <jolly@eversberg.eu>
2012-01-17host: Add support for the new gpsd APIPaul Wise1-1/+22
Written-by: Paul Wise <pabs3@bonedaddy.net> Acked-by: Peter Stuge <peter@stuge.se> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2012-01-02layer23/mobile: Fixed cell re-selection after loosing signalAndreas Eversberg1-3/+4
Test showed that loosing the signal in dedicated mode caused a complete rescann of all cells. By keeping the cell selected, the process can use the neighbour cell informations to do a quick search for the best cell afterwards.
2012-01-02layer23/mobile: Minor fix of debugging outputAndreas Eversberg1-1/+1
2012-01-02layer23/mobile: Fixed variable type, so home network is detected correctlyAndreas Eversberg2-2/+2
2012-01-02layer23/mobile: Enable SIM reader by defaultAndreas Eversberg1-2/+1
If there is no SIM card in the reader, the SIM process would automatically proceed without SIM anyway.
2011-12-14host/osmocon: correct parsing of -mAlexander Huemer1-2/+3
Written-by: Alexander Huemer <alexander.huemer@xx.vu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-12-11layer23: Call talloc_free unconditionallyHolger Hans Peter Freyther1-5/+2
talloc_free will check for NULL and return -1. _talloc_free(void *pyr) { if (unlikely(ptr == NULL)) { return -1; } ...
2011-11-25Removed obsolete gsm48-andreas directory from "host" treeAndreas Eversberg1-23/+0
It was part of early development of layer 3 protocols, but obsolete since a long time ago.
2011-11-22layer23/ccch_scan: Replace fprintf() with LOGP() and print SI-idSteve Markgraf1-1/+2
Signed-off-by: Steve Markgraf <steve@steve-m.de>
2011-11-22layer23/ccch_scan: Print Paging Requests of type 3Steve Markgraf1-1/+27
Signed-off-by: Steve Markgraf <steve@steve-m.de>
2011-11-22layer23/ccch_scan: Print channel type of correct TMSI for Paging Request Type 2Steve Markgraf1-1/+1
Signed-off-by: Steve Markgraf <steve@steve-m.de>
2011-11-21layer23/bcch_scan: bscan_sig_cb() should return something in all casesSteve Markgraf1-1/+1
Found with clang: bcch_scan.c:277:5: error: non-void function 'bscan_sig_cb' should return a value Signed-off-by: Steve Markgraf <steve@steve-m.de>
2011-11-17mobile/MM: Fixed handling of T3230 (MM connection timeout)Andreas Eversberg1-1/+2
If network will not respond to (additional) service request, the timeout will abort the pending MM connection and return to the state before the MM connection was requested or wait for network command.
2011-11-17mobile/MM: Fixed handling of T3220 (IMSI detach timeout)Andreas Eversberg1-3/+20
If network will not terminate radio connection, the timeout will abort the radio connection.
2011-11-13host/mobile: Indicate unsupported TS 04.14 test messages in logAndreas Eversberg1-0/+5
There is no support for TS 04.14. A logging message will inidcate this, if a tester requests test functions. A STATUS message will be sent as it is for for other usupported protocol types received. Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-11-13host/mobile: Adding (partly implemented) supplementary service supportAndreas Eversberg12-18/+1358
Use VTY to request your extension number form OpenBSC: en service 1 *100# Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-11-13host/mobile: Mobile will use SMS Service Center Address from SIMAndreas Eversberg7-29/+85
In case the SMS Service Center Address is not set in the config, the Address from the SIM card is used. The mobile checks if either one is defined, otherwise it will refuse sending SMS. Since records of SIM are read, this patch includes fixes to talk correctly with the SIM client. Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-11-13host/mobile/sms: Adding SMS support for osmocomBB/mobileAndreas Eversberg12-16/+1085
Both MO and MT SMS are supported. Transmission an reception can be controlled via VTY: en sms 1 <destination> <text> All received SMS are stored in "~/.osmocom/bb/sms.txt". SMS transmission is performed on SAPI 3 datalink, using DCCH or ACCH. Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-11-13host/mobile/sms: Adding SAPI 3 support to MM and RR layersAndreas Eversberg5-126/+601
RR now handles SAPI 3 datalink. MM connections now have and individual sapi, so MM can use right SAPI for communication with other layers, as well as releasing the right MM connections in case of link release. Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-11-13host/layer23: Flush L1CTL/SAP workqueues when exittingAndreas Eversberg2-0/+2
Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-11-13host/layer23: SIM client now supports reading records correctlyAndreas Eversberg1-2/+19
Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-11-13host/mobile: Whitespace fixes, no functional changesSylvain Munaut6-50/+50
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-11-13host/layer23: Removed local copy of LAPDm, using libosmocore instadAndreas Eversberg18-2716/+6
Since libosmocore already has LAPDm implementation, we don't need the local copy of LAPDm code anymore. Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-11-13host/mobile: Bring mncc.h in sync with OpenBSC and LCRAndreas Eversberg1-0/+1
Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-11-13host/mobile: Fixed paging response with correct identity typeAndreas Eversberg2-20/+35
In case we got paged with IMSI, but even if we have a valid TMSI, we need to respond with IMSI, because the network may not know our TMSI anymore. Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>