osmocom-bb/src/target/trx_toolkit
Pau Espin 55afe0072b trx_toolkit: Add cmdline arg to set bind addr
Previous hardcoded default of 0.0.0.0 was inappropiate in some
scenarios, as it sets the SRC addr of the packets sent through the
socket based on the routing.

For instance, if iface IF1 has assigned two IP addresses A and B,
A being the first addr of the interface, and osmo-bts-trx is
configured with "osmotrx ip local A" and "osmotrx ip remote B",
the following happens:

  CMD POWER OFF src=A:5801 dst=B:5701
  RSP POWER OFF src=A:5701 dst=A:5701 <-- A is assigned as src addr.

But osmo-bts-trx is waiting for packets from B:5701, and the packet
is dropped with ICMP Unreachable. If addr binding is forced in
fake_trx to B, then everthing's fine.

Let's extend the UDPLink in order to allow manual, but optional
setting of bind address, and add a corresponding cmdline
argument to all executables.

Change-Id: I7be18fef40967fb7551f4115f22cbbd9cdb0840d
2018-04-04 17:14:26 +00:00
..
.gitignore Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +07:00
README Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +07:00
burst_fwd.py Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +07:00
burst_gen.py trx_toolkit: Add cmdline arg to set bind addr 2018-04-04 17:14:26 +00:00
burst_send.py trx_toolkit: Add cmdline arg to set bind addr 2018-04-04 17:14:26 +00:00
clck_gen.py trx_toolkit: Add cmdline arg to set bind addr 2018-04-04 17:14:26 +00:00
copyright.py Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +07:00
ctrl_cmd.py trx_toolkit: Add cmdline arg to set bind addr 2018-04-04 17:14:26 +00:00
ctrl_if.py Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +07:00
ctrl_if_bb.py trx_toolkit: Add cmdline arg to set bind addr 2018-04-04 17:14:26 +00:00
ctrl_if_bts.py trx_toolkit: Add cmdline arg to set bind addr 2018-04-04 17:14:26 +00:00
data_dump.py Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +07:00
data_if.py Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +07:00
data_msg.py Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +07:00
fake_pm.py Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +07:00
fake_trx.py trx_toolkit: Add cmdline arg to set bind addr 2018-04-04 17:14:26 +00:00
gsm_shared.py Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +07:00
rand_burst_gen.py Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +07:00
trx_sniff.py Rename 'fake_trx' to 'trx_toolkit' 2018-03-13 02:10:02 +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. Currently
    only a single MS may work with a single BTS.

  - 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.