osmocom-bb/src/target/trx_toolkit
Vadim Yanitskiy ebf676597b trx_toolkit/fake_trx.py: basic TRXD version 0x01 support
Since the new TRXD header format has been introduced, FakeTRX needs
to be able to fill it correctly. In particular, the following:

  - Modulation, which can be determined from the burst length;
  - Training Sequence Code (and set), which needs to be detected
    by comparing the burst bits of L12TRX message against known
    training sequences (only GMSK and the default TS set for now);
  - C/I (Carrier-to-Interference ratio), which can be simulated
    later on, as instructed on the TRXC interface ('FAKE_CI').

The actual TRXD header version is stored in the instance of class
DATAInterface. By default (at startup), legacy version 0 is used.
The version negotiation is supposed to be performed on the TRXC
interface, and to be implemented in a follow-up change.

Different Transceivers may use different header versions, thus in
FakeTRX.send_data_msg() we need to override the original version
of the L12TRX message, and generate the corresponding PDU.

Limitations:

  - NOPE / IDLE indications are not (yet) supported;
  - TSC detection: GMSK modulation only.

Change-Id: I164f5ae4ce7694d6e324aab927a04e96d489ebd8
Related: OS#4006
2019-07-16 04:07:34 +00:00
..
.gitignore Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +07:00
README trx_toolkit/README: update fake_trx.py description 2019-01-14 23:52:31 +00:00
app_common.py trx_toolkit: merge copyright.py into app_common.py 2018-12-08 02:10:50 +07:00
burst_fwd.py trx_toolkit/fake_trx.py: basic TRXD version 0x01 support 2019-07-16 04:07:34 +00:00
burst_gen.py trx_toolkit: merge copyright.py into app_common.py 2018-12-08 02:10:50 +07:00
burst_send.py trx_toolkit/burst_send.py: exit if DATA dump parsing failed 2018-12-16 07:14:11 +07:00
clck_gen.py trx_toolkit/clck_gen.py: avoid logging \0-terminator 2019-05-17 19:40:31 +07:00
ctrl_cmd.py trx_toolkit: use 'TRXC' and 'TRXD' in logging messages 2019-01-14 23:52:31 +00:00
ctrl_if.py trx_toolkit: use 'TRXC' and 'TRXD' in logging messages 2019-01-14 23:52:31 +00:00
ctrl_if_trx.py trx_toolkit/{ctrl,data}_if.py: add init log message 2019-01-14 23:52:31 +00:00
data_dump.py trx_toolkit: use generic logging module instead of print() 2018-12-07 05:36:20 +07:00
data_if.py trx_toolkit/fake_trx.py: basic TRXD version 0x01 support 2019-07-16 04:07:34 +00:00
data_msg.py trx_toolkit/data_msg.py: legacy flag is only for version 0x00 2019-07-02 13:48:06 +07:00
fake_pm.py trx_toolkit/fake_trx.py: refactor global class hierarchy 2018-12-18 05:47:11 +07:00
fake_trx.py trx_toolkit/fake_trx.py: basic TRXD version 0x01 support 2019-07-16 04:07:34 +00:00
gsm_shared.py trx_toolkit/gsm_shared.py: introduce a new enum TrainingSeqGMSK 2019-07-16 04:07:34 +00:00
rand_burst_gen.py trx_toolkit/rand_burst_gen.py: use TrainingSeqGMSK and BurstType enums 2019-07-16 04:07:34 +00:00
transceiver.py trx_toolkit/transceiver.py: add optional transceiver name 2019-01-14 23:52:31 +00:00
trx_list.py trx_toolkit/transceiver.py: add support for child transceivers 2019-01-13 16:05:27 +07:00
trx_sniff.py trx_toolkit: fix missing / useless imports 2018-12-16 07:14:11 +07:00
udp_link.py trx_toolkit: Add cmdline arg to set bind addr 2018-04-04 17:14:26 +00:00

README

TRX toolkit is a set of tools intended for hacking and debugging
a TRX interface between both transceiver and L1 software, and
emulating a virtual Um-interface between OsmocomBB and OsmoBTS.

Brief description of available applications:

  - fake_trx.py - main application, that allows to connect both
    OsmocomBB and OsmoBTS without actual RF hardware. It's also
    possible to emulate more than two transceivers, so multiple
    MS and/or BTS instances can be connected.

  - clck_gen.py - a peripheral tool aimed to emulate TDMA frame
    clock generator. Could be used for testing and clock
    synchronization of multiple applications. It should be noted,
    that one relays on generic system timer (via Python), so
    a random clock jitter takes place.

  - ctrl_cmd.py - another peripheral tool, which could be used
    for sending CTRL commands directly in manual mode, and also
    for application fuzzing.

  - burst_gen.py - a tool for sending GSM bursts either to L1
    (OsmoBTS or OsmocomBB) or to TRX (OsmoTRX and GR-GSM TRX).
    Currently it is only possible to generate random bursts of
    different types: NB, FB, SB, AB.

  - burst_send.py - a tool for sending existing bursts from a
    capture file either to L1 (OsmoBTS or OsmocomBB) or to
    TRX (e.g. OsmoTRX or GR-GSM TRX).

  - trx_sniff.py - Scapy-based TRX protocol sniffer. Allows one
    to observe a single connection between TRX and L1, and vice
    versa. Also provides some capabilities for filtering bursts
    by direction, frame and timeslot numbers, and for recording
    captured messages to a binary file.

Please note that TRX toolkit is not using libosmocore's CTRL
interface, so 'CTRL' in scope of this code base actually means
control interface of TRX or control protocol. In order to avoid
possible confusion, we use 'TRXC' and 'TRXD' in logging.