Commit Graph

15 Commits

Author SHA1 Message Date
Harald Welte e324507676 OCTOI: initial support for E1oIP forwarding
This introduces initial support for operation as OCTOI (Osmocom
Community TDMoIP) server and client operation.

Various features are still absent (user authentication, support for
re-ordered packets), but this version is already able to provide
services to clients with dynamic IP addresses as well as servers.

The bulk of the OCTOI / E1oIP code is implemented as a shared library,
to facilitate the development of other servers and clients in the
future, and also to minimize the impact on the existing osmo-e1d code
base.

More information is available at https://osmocom.org/projects/octoi/wiki

Change-Id: I05f5ff697ca8f7dccdcf89660f12089babfcc92e
2022-03-28 12:26:09 +02:00
Sylvain Munaut 35a9cf0b99 build: Increase warnings
Go with -Wextra but removing some of the obnoxious options it brings with
it.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
Change-Id: Iaafd35ba39e272d5900b31b14d2651e0ecb8a84a
2022-01-09 11:42:41 +01:00
Pau Espin 807364dcae Bump version: 0.1.1.33-4292-dirty → 0.2.0
Change-Id: I5353aee666d88e3d439e465dd06e34a9ea4d8b29
2021-02-24 14:07:28 +01:00
Harald Welte 1e30f0dab7 Add new "osmo-e1gen" program.
osmo-e1gen is a program that re-uses large parts of osmo-e1d, but whose
main purpose is to generate a variety of error conditions in order to
test a remote E1 implementation.

Instead of using the automatisms of the icE1usb transmit IP core, it
switches it to transparent mode and uses a host-software based E1 framer
"osmo_e1f", over which we have more control than the firmware.

Change-Id: I53a86d6730eb76a9cff9eb3f4786139015c91230
2021-01-05 23:46:05 +01:00
Harald Welte 1923b4d832 move usb.c function declarations to newly-created usb.h
Change-Id: Icab91d73e37119960ca3c953bf91c2ec9d821311
2020-12-20 11:45:54 +01:00
Harald Welte 929a5a7588 e1_line.c: Split multiplex + demultiplex into separate mux_demux.c
The remaining intf_line.c really only manages the data structures.

This is useful for building other programs than osmo-e1d, such as
an upcoming E1 test utility called osmo-e1gen which will also use
the USB interface and icE1usb hardware, but not any of the mux/demux/ctl
code.

Change-Id: I1ceaea85a15e2fae1d2e041173be9d758c6d0b78
2020-12-20 11:45:44 +01:00
Harald Welte a74aaf172c Add support for icE1usb interrupt endpoint error reporting
Related: OS#4674
Change-Id: I5b0bf3cf40c623c17f2e88292e880b545c36b7b6
Depends: osmo-e1-hardware If157fde9d4ca05910b09537e19f37603c6d925f0
2020-12-20 11:29:59 +01:00
Harald Welte e894e5c621 Makefile.am: Don't put LIBS into CFLAGS
this was accidentially introduced in Change-Id I47b6e4efaad52e68e2b50a7993076f3706f86628
and causese build failures on some targets:

libtool: link: gcc -Wall -Wno-unused-result -pthread -I/usr/include/ -I/usr/include/libusb-1.0 -g -O2 -fdebug-prefix-map=/usr/src/packages/BUILD=. -fstack-protector-strong -Wformat -Werror=format-security -Wl,-z -Wl,relro -o .libs/osmo-e1d-pipe e1d-ts-pipe.o  /usr/lib/x86_64-linux-gnu/libosmovty.so /usr/lib/x86_64-linux-gnu/libosmousb.so -ltalloc /usr/lib/x86_64-linux-gnu/libosmocore.so ./.libs/libosmo-e1d.so -pthread
/usr/bin/ld: /usr/lib/x86_64-linux-gnu/libosmousb.so: undefined reference to `libusb_open'

Change-Id: I09fc640847e2701ea13a0afa759e8cc0ed75cab9
2020-07-01 13:07:14 +02:00
Harald Welte c3cefbb396 Add osmo-e1d-pipe utility
This adds the 'osmo-e1d-pipe' utlility program, which can be
used as a command-line client to open a given E1 timeslot and
connect it to stdin/stdout.  This in turn allows to rediect
file input/output via the shell.

Change-Id: Ib9d55af786c87e15465b8e73493680b35afb5913
2020-06-30 19:44:09 +02:00
Harald Welte 27b271729f Add virtual pair of E1 interfaces
The idea is to generate a pair of virtual E1 interfaces (each with
identical number of lines), where each line A:n is connected to line B:n
of the pair and vice-versa.

This allows to test E1 using applications back to back against each
other, without any physical E1 circuits in between.

Change-Id: If42c959556b17d543762546eb45dd69d25f715f2
2020-06-29 23:10:33 +02:00
Harald Welte 9144ba0373 VTY interface support
Let's add a VTY interface on TCP port 4269.  The purpose is - for now -
not for configuration storage, but for state introspection.

Change-Id: I47b6e4efaad52e68e2b50a7993076f3706f86628
2020-06-29 22:12:42 +02:00
Harald Welte 7f08470706 remove code not specific to USB from usb.c to intf_line.c
Change-Id: I7d4d4ab39cb3e7e6a7eb8e738a367122eb3fbee2
2020-06-29 17:19:13 +02:00
Harald Welte 8db1624323 port to new libosmousb
libosmousb, recently introduced to libosmocore.git, is taking care
of main loop integration of libusb into osmo_select_main().  This
means we don't need to do any polling here anymore.

Change-Id: I3f3b61dfa217d6ef8c17970b2cf1cc627bb13bbe
2020-01-06 17:37:07 +01:00
Sylvain Munaut 785476901c build: Disable some warnings that are just annoying for no reasons
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2019-07-10 15:41:08 +02:00
Sylvain Munaut cf189940be Initial code import
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2019-05-11 22:31:12 +02:00