osmocom-bb.git
13 years agolayer23: use correct sizeof(sockaddr) for connecting to L1CTL socket
David Wilson [Thu, 9 Dec 2010 03:33:02 +0000 (03:33 +0000)]
layer23: use correct sizeof(sockaddr) for connecting to L1CTL socket

connect's addrlen should be sizeof(local), not the contained path's length.

With the previous code, on OS X connect() will fail with ENOENT.

This permits layer23 to work on OS X using the pl2303 driver,
/dev/tty.usbserial , MacPorts arm-elf-gcc and RANLIB=arm-elf-ranlib

Signed-off-by: Harald Welte <laforge@gnumonks.org>
13 years agoMerge commit 'ab1246e0b5ffa0ac8d7b8e8fbe7c51bc22c8e751'
Sylvain Munaut [Sun, 28 Nov 2010 14:31:20 +0000 (15:31 +0100)]
Merge commit 'ab1246e0b5ffa0ac8d7b8e8fbe7c51bc22c8e751'

13 years agoprotocol: introduce gsm_03_41.h
Alex Badea [Sat, 27 Nov 2010 21:35:08 +0000 (23:35 +0200)]
protocol: introduce gsm_03_41.h

This currently contains definitions for the BTS->MS SMSCB message.

Signed-off-by: Alex Badea <vamposdecampos@gmail.com>
13 years agogsm_08_58: add struct and constants for RSL_IE_CB_CMD_TYPE
Alex Badea [Sat, 27 Nov 2010 21:34:46 +0000 (23:34 +0200)]
gsm_08_58: add struct and constants for RSL_IE_CB_CMD_TYPE

Signed-off-by: Alex Badea <vamposdecampos@gmail.com>
13 years agogsm_04_12: fix 04.13 typos
Alex Badea [Sat, 27 Nov 2010 18:00:39 +0000 (20:00 +0200)]
gsm_04_12: fix 04.13 typos

There are two occurrences of "413" in the 04.12 header file.
These are probably typos; correct them to "412".

Signed-off-by: Alex Badea <vamposdecampos@gmail.com>
13 years agowireshark: fixes for the SMSCB dissector
Alex Badea [Sun, 28 Nov 2010 13:45:17 +0000 (15:45 +0200)]
wireshark: fixes for the SMSCB dissector

Fix dissection of message ID, and cosmetic adjustments
to line up the bitfields.

Signed-off-by: Alex Badea <vamposdecampos@gmail.com>
13 years agofw/layer1: Fix reset of dedicated channel state
Sylvain Munaut [Sun, 28 Nov 2010 13:40:08 +0000 (14:40 +0100)]
fw/layer1: Fix reset of dedicated channel state

Thanks to Alex Badea <vamposdecampos@gmail.com> for pointing
this out.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agobuild: Use absolute path in the CFLAGS for libosmocore target build
Sylvain Munaut [Wed, 24 Nov 2010 09:05:49 +0000 (10:05 +0100)]
build: Use absolute path in the CFLAGS for libosmocore target build

There is now subdirectories to build !

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agowireshark: update SMSCB dissector patch
Alex Badea [Sat, 27 Nov 2010 16:31:49 +0000 (18:31 +0200)]
wireshark: update SMSCB dissector patch

Now factored out to its own dissector module, and supporting
message block reassembly.

Signed-off-by: Alex Badea <vamposdecampos@gmail.com>
13 years agofw/layer1: Fix missing include in prim_pm.c
Sylvain Munaut [Wed, 24 Nov 2010 08:43:11 +0000 (09:43 +0100)]
fw/layer1: Fix missing include in prim_pm.c

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agowireshark: add CBS/SMSCB dissector patch [WIP]
Alex Badea [Tue, 23 Nov 2010 19:03:03 +0000 (21:03 +0200)]
wireshark: add CBS/SMSCB dissector patch [WIP]

Signed-off-by: Alex Badea <vamposdecampos@gmail.com>
13 years agohost layer23: add a small cbch_sniff application
Alex Badea [Sun, 21 Nov 2010 20:46:11 +0000 (22:46 +0200)]
host layer23: add a small cbch_sniff application

Tune to the ARFCN specified on the commandline (-a).  Then, if
a CBCH Channel Description IE is found in System Information Type 4,
switch to dedicated mode on that particular channel to receive
the CBCH.

13 years agolayer23 sysinfo: fix parsing of CBCH Mobile Allocation
Alex Badea [Sun, 21 Nov 2010 20:45:23 +0000 (22:45 +0200)]
layer23 sysinfo: fix parsing of CBCH Mobile Allocation

When calling gsm48_decode_mobile_alloc(), read the length
byte from payload data[], rather than from si->data[].

13 years agolayer23 sysinfo: store chan_nr when decoding CBCH Channel Description
Alex Badea [Sun, 21 Nov 2010 20:45:22 +0000 (22:45 +0200)]
layer23 sysinfo: store chan_nr when decoding CBCH Channel Description

13 years agoMakefile: introduce 'make nofirmware' target to build host-only tools
Harald Welte [Sun, 21 Nov 2010 17:24:10 +0000 (18:24 +0100)]
Makefile: introduce 'make nofirmware' target to build host-only tools

13 years agorita_pll: Compute values for T-GSM 810
Harald Welte [Sun, 21 Nov 2010 17:10:46 +0000 (18:10 +0100)]
rita_pll: Compute values for T-GSM 810

13 years ago[layer23] VTY uses CAPITAL letters for all optional parameter names
Andreas.Eversberg [Sat, 20 Nov 2010 08:58:44 +0000 (08:58 +0000)]
[layer23] VTY uses CAPITAL letters for all optional parameter names

This makes it easier to understand the VTY help. Every parameter name
is shown in capital letters, every keyword is shown in lower case.

13 years ago[layer23] VTY supports "show this" to show current MS node only
Andreas.Eversberg [Sat, 20 Nov 2010 08:34:31 +0000 (08:34 +0000)]
[layer23] VTY supports "show this" to show current MS node only

13 years ago[layer23] Adding LAC and TMSI (both optional) to test card (rplmn)
Andreas.Eversberg [Sat, 20 Nov 2010 08:32:32 +0000 (08:32 +0000)]
[layer23] Adding LAC and TMSI (both optional) to test card (rplmn)

13 years ago[layer23] Adding LAI to debug output of LOCATION UPDATING REQEST
Andreas.Eversberg [Sat, 20 Nov 2010 08:30:45 +0000 (08:30 +0000)]
[layer23] Adding LAI to debug output of LOCATION UPDATING REQEST

13 years ago[layer23] Bugfix: Exit, if init function fails
Andreas.Eversberg [Sat, 20 Nov 2010 08:19:38 +0000 (08:19 +0000)]
[layer23] Bugfix: Exit, if init function fails

13 years agoutils: Fix typo. It is ascii.
Holger Hans Peter Freyther [Fri, 19 Nov 2010 18:20:46 +0000 (19:20 +0100)]
utils: Fix typo. It is ascii.

13 years agogsmtap.h: Add GSMTAP_TYPE_SIM
Harald Welte [Thu, 18 Nov 2010 22:54:20 +0000 (23:54 +0100)]
gsmtap.h: Add GSMTAP_TYPE_SIM

13 years agotoplevel Makefile: accept arguments for host ./configure calls
Alex Badea [Wed, 17 Nov 2010 21:35:18 +0000 (23:35 +0200)]
toplevel Makefile: accept arguments for host ./configure calls

Append $(HOST_CONFARGS) to ./configure scripts for 'host' applications.

This allows e.g. cross-compiling on an x86 build system for an OpenMoko
gta0x host, using an invocation such as:

$ make HOST_CONFARGS="--host=arm-angstrom-linux-gnueabi"

Signed-off-by: Alex Badea <vamposdecampos@gmail.com>
13 years agotarget uart: remove REG_OFFS() macro side-effect
Alex Badea [Wed, 17 Nov 2010 21:35:17 +0000 (23:35 +0200)]
target uart: remove REG_OFFS() macro side-effect

Don't assign to the variable given as argument.  This prevents
clobbering the local 'reg' variables in uart_reg_{read,write}(),
which would in turn prevent the latch bits from being restored
correctly.

Signed-off-by: Alex Badea <vamposdecampos@gmail.com>
13 years agotarget uart: fix preservation of LCR
Alex Badea [Wed, 17 Nov 2010 21:35:16 +0000 (23:35 +0200)]
target uart: fix preservation of LCR

Store old_lcr only when switching to LCR == 0xBF.  We don't want
to clobber old_lcr when switching back, otherwise we can't restore
the previous LCR value.

Signed-off-by: Alex Badea <vamposdecampos@gmail.com>
13 years agoosmocon: make beacon interval configurable via cmdline
Alex Badea [Wed, 17 Nov 2010 21:35:15 +0000 (23:35 +0200)]
osmocon: make beacon interval configurable via cmdline

Beacons with the default 50 mS interval are too far apart to
be picked up by the OpenMoko gta0x Calypso chip.  Make them
configurable via a -i commandline argument.

As recommended in the OpenMoko wiki[1], an interval of 13 mS works.

[1] http://wiki.openmoko.org/wiki/GSM/Flashing (-od fluid argument)

Signed-off-by: Alex Badea <vamposdecampos@gmail.com>
13 years agofw/l1/mframe_sched: Fix the TCH_A entries to include the MF_F_SACCH flag
Sylvain Munaut [Sun, 14 Nov 2010 09:13:04 +0000 (10:13 +0100)]
fw/l1/mframe_sched: Fix the TCH_A entries to include the MF_F_SACCH flag

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agofw/layer1: Use dbm2rxlev instead of just '+110' so that overflows are handled
Sylvain Munaut [Sun, 14 Nov 2010 15:08:08 +0000 (16:08 +0100)]
fw/layer1: Use dbm2rxlev instead of just '+110' so that overflows are handled

Without this, we would sometime get +143 dBm reported ... which is obviously
false.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years ago[layer23/mobile] Better overview of "show ms" VTY command
Andreas.Eversberg [Sun, 14 Nov 2010 15:15:38 +0000 (15:15 +0000)]
[layer23/mobile] Better overview of "show ms" VTY command

Combined "sh ms" and "sh states" to a more detailed "sh ms". The
look-and-feel is more router like now.

13 years ago[layer23] Cleanup of mobile application
Andreas.Eversberg [Sun, 14 Nov 2010 11:52:57 +0000 (11:52 +0000)]
[layer23] Cleanup of mobile application

All functions for handling mobile instances and mobile relevant parts are
moved to mobile/app_mobile.c, the mobile/main.c and mobile/mncc.c become a
simple out-of-the-box mobile application. (making calls)

The mobile/main.c can be replaced easily by a different application now.
this application may have it's own call control implementation (layer 4).
Full configurations via VTY is still possible and required in this case.

13 years ago[layer23] Prevent layer23 apps from abort, if socket to layer1 fails
Andreas.Eversberg [Sun, 14 Nov 2010 11:50:14 +0000 (11:50 +0000)]
[layer23] Prevent layer23 apps from abort, if socket to layer1 fails

13 years agoMerge commit '7f6615a37df0dadbe86fdfc980e0a8a15013a80e'
Sylvain Munaut [Sat, 13 Nov 2010 21:48:15 +0000 (22:48 +0100)]
Merge commit '7f6615a37df0dadbe86fdfc980e0a8a15013a80e'

13 years agoMove the generate backtrace call from MSGB_ABORT to osmo_panic handler
Sylvain Munaut [Sat, 13 Nov 2010 21:47:47 +0000 (22:47 +0100)]
Move the generate backtrace call from MSGB_ABORT to osmo_panic handler

This has two benefits:
 - All people calling osmo_panic() will have the backtrace
 - It makes the thing build in 'target' mode in osmocom-bb

And one downside:
 - The osmo_panic handler is now in the backtrace
(I can live with that :)

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years ago[layer23] Added support for multiple MS instances
Andreas.Eversberg [Sat, 13 Nov 2010 18:45:09 +0000 (18:45 +0000)]
[layer23] Added support for multiple MS instances

To create another instance: 'ms <name> create'

To remove an instance: 'no ms <name>'

If no instance exists, 'ms 1' is created automatically on startup.

Each instance can be enabled / disabled by using 'shutdown' or
'no shutdown'. Multiple instances may share the same layer2 socket (same
phone hardware), but in this case only one instance can be enabled at the
same time. This makes it much easier to select different settings without
modifying them.

A 'shutdown' initiates the IMSI detach procedure before shutdown is
completed. A 'shutdown force' will immidiately shutdown.

There is no need to restart the software anymore, if fundamental settings
are changed. In this case, a 'shutdown' followed by a 'no shutdown' will
do the job.

If you already have an old osmocom.cfg, you need to "no shutdown" it.
Everything else behaves as before.

13 years ago[layer23] msgb_free() must in l1ctl.c must called after reading its header
Andreas.Eversberg [Sat, 13 Nov 2010 18:23:57 +0000 (18:23 +0000)]
[layer23] msgb_free() must in l1ctl.c must called after reading its header

13 years agopanic: Fix type warning - osmo_panic_handler_t is already a pointer ...
Sylvain Munaut [Sat, 13 Nov 2010 17:00:25 +0000 (18:00 +0100)]
panic: Fix type warning - osmo_panic_handler_t is already a pointer ...

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agogsm_utils: Define 4 upper bits as "flags" and mask them out in utility functions
Sylvain Munaut [Sat, 13 Nov 2010 16:51:37 +0000 (17:51 +0100)]
gsm_utils: Define 4 upper bits as "flags" and mask them out in utility functions

This way those function don't care about the flags they don't know about

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agoadd definitions for sciphone G2
Harald Welte [Tue, 9 Nov 2010 18:17:48 +0000 (19:17 +0100)]
add definitions for sciphone G2

13 years agoadd some header files about MTK GSM related peripherals
Harald Welte [Tue, 9 Nov 2010 17:19:06 +0000 (18:19 +0100)]
add some header files about MTK GSM related peripherals

13 years agomsgb: fix printing of msgb pointer during MSGB_ABORT()
Harald Welte [Tue, 9 Nov 2010 12:42:26 +0000 (13:42 +0100)]
msgb: fix printing of msgb pointer during MSGB_ABORT()

13 years agomsgb: don't compare unsigned int with int (fix lcr build)
Harald Welte [Tue, 9 Nov 2010 12:41:48 +0000 (13:41 +0100)]
msgb: don't compare unsigned int with int (fix lcr build)

13 years agotarget_dsp/calypso: Makefile rework
Sylvain Munaut [Thu, 30 Sep 2010 21:12:06 +0000 (23:12 +0200)]
target_dsp/calypso: Makefile rework

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget_dsp/calypso: Small updates bin2cfile.py script
Sylvain Munaut [Wed, 29 Sep 2010 16:45:58 +0000 (18:45 +0200)]
target_dsp/calypso: Small updates bin2cfile.py script

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/dsp: Implement section loading with bootloader
Sylvain Munaut [Wed, 29 Sep 2010 18:13:26 +0000 (20:13 +0200)]
target/fw/dsp: Implement section loading with bootloader

This works for both the default ROM bootloader and for our
custom one.

This will allow to implement easy patch loading.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/dsp: Create a common function to start running code
Sylvain Munaut [Wed, 29 Sep 2010 16:43:56 +0000 (18:43 +0200)]
target/fw/dsp: Create a common function to start running code

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agolayer23/mobile: Enable half_v1 support
Sylvain Munaut [Fri, 22 Oct 2010 09:52:38 +0000 (11:52 +0200)]
layer23/mobile: Enable half_v1 support

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/l1: Fix TCH/H1 by properly loading the TCH mode during TCH_A task
Sylvain Munaut [Sat, 6 Nov 2010 15:00:12 +0000 (16:00 +0100)]
target/fw/l1: Fix TCH/H1 by properly loading the TCH mode during TCH_A task

Altough quite counterintuitive, the TCH_A task does some voice coding
work ... at least during TCH/H subchannel 1 ...

Go figure ...

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/l1: Fix TCH/H by properly scheduling the TCHD task during 'off' slots
Sylvain Munaut [Sat, 30 Oct 2010 19:13:41 +0000 (21:13 +0200)]
target/fw/l1: Fix TCH/H by properly scheduling the TCHD task during 'off' slots

Apparently the DSP needs to be run even during the slots without
actual bursts exchange.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years ago[layer23] Call application sends CC Capability on incoming call
Andreas.Eversberg [Sun, 7 Nov 2010 10:48:12 +0000 (10:48 +0000)]
[layer23] Call application sends CC Capability on incoming call

It is required to make DTMF work on incoming calls also.

13 years agolayer23/misc: Update .gitignore for ./cell_log
Steve Markgraf [Sat, 6 Nov 2010 13:52:12 +0000 (14:52 +0100)]
layer23/misc: Update .gitignore for ./cell_log

Signed-off-by: Steve Markgraf <steve@steve-m.de>
13 years agolayer23/mobile: Fix 'implicit declaration' warning for mncc_answer()
Steve Markgraf [Sat, 6 Nov 2010 13:45:39 +0000 (14:45 +0100)]
layer23/mobile: Fix 'implicit declaration' warning for mncc_answer()

Signed-off-by: Steve Markgraf <steve@steve-m.de>
13 years agomsgb_abort(): better formatting
Harald Welte [Fri, 5 Nov 2010 06:50:40 +0000 (07:50 +0100)]
msgb_abort(): better formatting

13 years agogenerate backtrace in msgb_abort()
Harald Welte [Fri, 5 Nov 2010 06:49:39 +0000 (07:49 +0100)]
generate backtrace in msgb_abort()

This helps us to debug where we encounter insufficient headroom...

13 years agoChange msgb_abort() function in MSGB_ABORT argument with variable arguments
Harald Welte [Fri, 5 Nov 2010 06:47:41 +0000 (07:47 +0100)]
Change msgb_abort() function in MSGB_ABORT argument with variable arguments

This enables callers to provide format string and arguments to it

Also, put conditionals into the macro, and remove them from the caller
site.

13 years agogsm0808: Move the clear request from bsc_msc_ip to here
Holger Hans Peter Freyther [Thu, 4 Nov 2010 11:42:50 +0000 (12:42 +0100)]
gsm0808: Move the clear request from bsc_msc_ip to here

This method should use the msgb_tlv_put routines instead
of the stuff it is doing. This will be cleaned up.

13 years agogsm0808: Add a method to create a new DTAP message with a msgb
Holger Hans Peter Freyther [Thu, 4 Nov 2010 11:26:06 +0000 (12:26 +0100)]
gsm0808: Add a method to create a new DTAP message with a msgb

13 years agoselect.c: Change license terms from GPLv2 (from ulogd) to GPLv2+
Harald Welte [Sun, 31 Oct 2010 12:56:45 +0000 (13:56 +0100)]
select.c: Change license terms from GPLv2 (from ulogd) to GPLv2+

13 years agolayer23: Use the new rach_req format in l1ctl and update l23 apps to use it
Andreas.Eversberg [Sat, 30 Oct 2010 15:30:59 +0000 (17:30 +0200)]
layer23: Use the new rach_req format in l1ctl and update l23 apps to use it

This removes an old hack

Written-by: Andreas Eversberg <jolly@eversberg.eu>
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/layer1: Change L1CTL RACH req to properly use all slots
Andreas.Eversberg [Sat, 30 Oct 2010 15:27:03 +0000 (17:27 +0200)]
target/fw/layer1: Change L1CTL RACH req to properly use all slots

Written-by: Andreas Eversberg <jolly@eversberg.eu>
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years ago[layer23] cell_log's scanning depth now depends on movement speed
Andreas.Eversberg [Sat, 30 Oct 2010 12:30:00 +0000 (12:30 +0000)]
[layer23] cell_log's scanning depth now depends on movement speed

13 years ago[layer23] Fixed T3 value in RACH confirm message
Andreas.Eversberg [Sat, 30 Oct 2010 08:53:22 +0000 (08:53 +0000)]
[layer23] Fixed T3 value in RACH confirm message

13 years agolayer23/mobile: Add configuration option for automatically answering calls
Steve Markgraf [Wed, 27 Oct 2010 18:30:13 +0000 (20:30 +0200)]
layer23/mobile: Add configuration option for automatically answering calls

Signed-off-by: Steve Markgraf <steve@steve-m.de>
13 years agolayer23: typo/cosmetic fixes in cell_log.c and mnccms.c
Steve Markgraf [Wed, 27 Oct 2010 18:26:05 +0000 (20:26 +0200)]
layer23: typo/cosmetic fixes in cell_log.c and mnccms.c

Signed-off-by: Steve Markgraf <steve@steve-m.de>
13 years agogsm0808: Fix the format of the clear IE...
Holger Hans Peter Freyther [Wed, 27 Oct 2010 10:36:05 +0000 (12:36 +0200)]
gsm0808: Fix the format of the clear IE...

This is really TLV...

13 years agogsm0808: Add a method to create a clear command message.
Holger Hans Peter Freyther [Wed, 27 Oct 2010 09:49:24 +0000 (11:49 +0200)]
gsm0808: Add a method to create a clear command message.

Use the msgb_tv_put functions for putting the data into
the message. Do not support the extended error reports.

13 years agomsgfile: Allow to have comments in the simple CSV file
Holger Hans Peter Freyther [Tue, 26 Oct 2010 07:31:16 +0000 (09:31 +0200)]
msgfile: Allow to have comments in the simple CSV file

13 years agotarget/fw/layer1: correctly initialize afc_retries
Steve Markgraf [Mon, 25 Oct 2010 16:05:04 +0000 (18:05 +0200)]
target/fw/layer1: correctly initialize afc_retries

Otherwise, when it reached AFC_RETRY_COUNT, no new FB0 tasks
were scheduled, and you needed to restart the phone in order to
successfully sync to a cell

Signed-off-by: Steve Markgraf <steve@steve-m.de>
13 years agotarget/fw/l23_api: Enable/Disable audio path appropriately
Sylvain Munaut [Mon, 18 Oct 2010 20:38:08 +0000 (22:38 +0200)]
target/fw/l23_api: Enable/Disable audio path appropriately

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/l23_api: Properly sync tch in DM EST REQ
Sylvain Munaut [Mon, 18 Oct 2010 20:37:32 +0000 (22:37 +0200)]
target/fw/l23_api: Properly sync tch in DM EST REQ

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/layer1: Add support for the various TCH multi frame tasks
Sylvain Munaut [Sun, 19 Sep 2010 13:51:26 +0000 (15:51 +0200)]
target/fw/layer1: Add support for the various TCH multi frame tasks

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/layer1: Add initial version of TCH primitives
Sylvain Munaut [Sun, 19 Sep 2010 13:49:48 +0000 (15:49 +0200)]
target/fw/layer1: Add initial version of TCH primitives

The initial bringup is mainly Dieter Spaar's work. I took the
logic and rewrote it, adapting to later scheduler changes and
adding support for several other things (tch_mode, initial HR
support, various cleanup, ...).

Initially-Written-by: Dieter Spaar <spaar@mirider.augusta.de>
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/calypso: Fix dsp_load_tch_param to set fn_report for TCH/H
Sylvain Munaut [Sun, 17 Oct 2010 19:21:56 +0000 (21:21 +0200)]
target/fw/calypso: Fix dsp_load_tch_param to set fn_report for TCH/H

The previous code was only valid for TCH/F ...

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/layer1: Store the GSM48 constants in l1s.tch_mode instead of DSP cste
Sylvain Munaut [Fri, 22 Oct 2010 09:54:53 +0000 (11:54 +0200)]
target/fw/layer1: Store the GSM48 constants in l1s.tch_mode instead of DSP cste

At this point in the code, we don't know if we're TCH/H or TCH/F, so
just store the speech mode and we'll figure out what to tell the DSP
in the task code itself.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/layer1: Fix msgb leak when prim_rx is half executed
Sylvain Munaut [Sun, 17 Oct 2010 19:20:51 +0000 (21:20 +0200)]
target/fw/layer1: Fix msgb leak when prim_rx is half executed

If the task interrupted because of a reset, an allocated msgb
will be present and we need to free it instead of just loosing
the reference to it.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/include: Fix missing apc helper declaration
Sylvain Munaut [Sun, 17 Oct 2010 19:19:37 +0000 (21:19 +0200)]
target/fw/include: Fix missing apc helper declaration

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/layer1: Use common DSP API memcpy instead of repeating code
Sylvain Munaut [Fri, 15 Oct 2010 19:02:02 +0000 (21:02 +0200)]
target/fw/layer1: Use common DSP API memcpy instead of repeating code

Also get rid of some early debug print that aren't needed now.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agotarget/fw/dsp: Add utility function to memcpy to/from the API
Sylvain Munaut [Fri, 15 Oct 2010 19:00:54 +0000 (21:00 +0200)]
target/fw/dsp: Add utility function to memcpy to/from the API

Copying to/from the DSP API shared memory must be done using
16 bits word only. Using those method, we avoid the hassle of
repeating the code when we copy buffer back and forth.

API address must be 16 bits aligned but for our purpose, it's
good enough.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agolayer23/vty_interface: Fix typos, AMR is v3 not v1
Sylvain Munaut [Fri, 22 Oct 2010 09:51:58 +0000 (11:51 +0200)]
layer23/vty_interface: Fix typos, AMR is v3 not v1

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years ago[layer23] Fix of LAPDm when handling "timer recovery state"
Andreas.Eversberg [Mon, 25 Oct 2010 20:33:39 +0000 (20:33 +0000)]
[layer23] Fix of LAPDm when handling "timer recovery state"

Sylvain found out that the state was not cleared when receiving an RR
response with F-bit == 1. The missing handling is now added and tested.

Furthermore there is a minor fix to prevent underflow when resending last
frame in "timer recovery state".

13 years ago[layer23] Reverted commit ece1463...
Andreas.Eversberg [Sun, 24 Oct 2010 22:31:06 +0000 (22:31 +0000)]
[layer23] Reverted commit ece1463...

The timer recovery state is cleared already,if  a supervisory frame
response is received with "F bit set to 1".

13 years agocodec: Fix bit order table definition for GSM HR
Sylvain Munaut [Sun, 24 Oct 2010 19:13:40 +0000 (21:13 +0200)]
codec: Fix bit order table definition for GSM HR

There is two tables: one for unvoiced frames and one for voiced frames.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agocodec: Add the missing bits for include to install and pkgconfig to work
Sylvain Munaut [Sun, 24 Oct 2010 16:23:10 +0000 (18:23 +0200)]
codec: Add the missing bits for include to install and pkgconfig to work

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agoIntroducing "gsmmap" to convert SYSTEM INFORMATION log into a KML map
Andreas.Eversberg [Sun, 24 Oct 2010 14:12:58 +0000 (14:12 +0000)]
Introducing "gsmmap" to convert SYSTEM INFORMATION log into a KML map

13 years ago[layer23] Adding application to scan/receive and log SYSTEM INFORMATIONS
Andreas.Eversberg [Sun, 24 Oct 2010 13:39:37 +0000 (13:39 +0000)]
[layer23] Adding application to scan/receive and log SYSTEM INFORMATIONS

13 years ago[layer23] Moving sysinfo.c and gps.c (.h) to liblayer23
Andreas.Eversberg [Sun, 24 Oct 2010 13:30:17 +0000 (13:30 +0000)]
[layer23] Moving sysinfo.c and gps.c (.h) to liblayer23

This makes sense, since multiple applications use it.

13 years ago[layer23] Fixed conditions for complete set of SYSTEM INFORMATION
Andreas.Eversberg [Sun, 24 Oct 2010 12:55:31 +0000 (12:55 +0000)]
[layer23] Fixed conditions for complete set of SYSTEM INFORMATION

13 years ago[layer23] Old SYSTEM INFORMATION 5 and 6 must be removed when entering DM
Andreas.Eversberg [Sun, 24 Oct 2010 12:34:53 +0000 (12:34 +0000)]
[layer23] Old SYSTEM INFORMATION 5 and 6 must be removed when entering DM

13 years ago[layer23] Moving decoding of SYSTEM INFORMATION to sysinfo.c
Andreas.Eversberg [Sun, 24 Oct 2010 12:30:37 +0000 (12:30 +0000)]
[layer23] Moving decoding of SYSTEM INFORMATION to sysinfo.c

This way the decoding can be re-used by other applications.

13 years ago[layer23] Added debugging for GPS at logging.c
Andreas.Eversberg [Sun, 24 Oct 2010 12:23:05 +0000 (12:23 +0000)]
[layer23] Added debugging for GPS at logging.c

13 years ago[layer23] Fix of GPS states
Andreas.Eversberg [Sun, 24 Oct 2010 12:20:08 +0000 (12:20 +0000)]
[layer23] Fix of GPS states

13 years agolayer23/lapdm: Properly handle S frame with F=1 when in timer recovery
Sylvain Munaut [Sat, 23 Oct 2010 18:47:26 +0000 (20:47 +0200)]
layer23/lapdm: Properly handle S frame with F=1 when in timer recovery

This is the signal to exit recovery mode !
See GSM 04.06 Section 5.5.7

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
13 years agoMerge commit 'dc0ebdfbdf3b1a381754c6ef4a59b0354eba7705'
Sylvain Munaut [Sun, 24 Oct 2010 10:05:12 +0000 (12:05 +0200)]
Merge commit 'dc0ebdfbdf3b1a381754c6ef4a59b0354eba7705'

13 years agoRemoved solved issues from gsm48-andreas/issues.txt
Andreas.Eversberg [Sun, 24 Oct 2010 11:20:51 +0000 (11:20 +0000)]
Removed solved issues from gsm48-andreas/issues.txt

The remaining issues have only todo with openBSC and should be fixed,
the issues.txt will be obsolete then.

13 years agobitvec: Fix decoding of H / L values
Andreas.Eversberg [Sun, 24 Oct 2010 09:59:33 +0000 (11:59 +0200)]
bitvec: Fix decoding of H / L values

it returns if a given bit in the vector is "high" or "low".
the bitval that represents "high" depends on the bit position.
bitval2mask returns that. so we must check if the bit in the vector
equals the returned bitval.

13 years ago[layer23] Don't request a channel, if SYSINFO 3 is not available
Andreas.Eversberg [Wed, 20 Oct 2010 18:16:12 +0000 (18:16 +0000)]
[layer23] Don't request a channel, if SYSINFO 3 is not available

SI3 is required in order to request a channel the correct way. If not
yet received, the process crashes due to an arithmetic exception.

13 years ago[layer23] Fix of channel request cause "OTHER or SDCCH"
Andreas.Eversberg [Wed, 20 Oct 2010 18:12:44 +0000 (18:12 +0000)]
[layer23] Fix of channel request cause "OTHER or SDCCH"

13 years ago[layer23] Completed GPS reading process
Andreas.Eversberg [Wed, 20 Oct 2010 18:09:31 +0000 (18:09 +0000)]
[layer23] Completed GPS reading process

This includes "double" values of logitude and latitude, as well as time
stamp, and if the values are valid or not (GPS fix).

13 years agomsgb: Add non-inlined helper functions to ease with language bindings
Holger Hans Peter Freyther [Mon, 18 Oct 2010 16:22:31 +0000 (18:22 +0200)]
msgb: Add non-inlined helper functions to ease with language bindings

It is easier from languages that dlopen libosmocore to have a function
to access this data than to poke at the bytes of the struct directly. Add
copyright for this method and the reset method I did earlier this year.

13 years agogsm0480: Add method create own number response
Holger Hans Peter Freyther [Mon, 18 Oct 2010 14:56:43 +0000 (16:56 +0200)]
gsm0480: Add method create own number response