Themyscira Wireless update

Mychaela Falconia mychaela.falconia at gmail.com
Wed Sep 21 17:46:43 UTC 2022


Hello FreeCalypso community,

I've been silent for two and a half months, so it is time for an
update.  I still haven't returned to working on the handset side of
GSM - I am still working on my own GSM network at home, whimsically
named Themyscira Wireless after the fictional paradise island of
Amazons.  As far as actual GSM functionality goes, ThemWi is a mostly
straightforward setup of Osmocom CNI software driving a sysmoBTS - but
the real work is in interconnecting this private GSM network with USA
PSTN, by which I mean the USA segment of the global, worldwide, fully
interconnected, E.164-routing PSTN.

The main thing I have to share on this front is the code I have
written so far and continue to develop further:

https://www.freecalypso.org/hg/themwi-system-sw/

My big innovation is that I am NOT using the "standard" solution of
osmo-sip-connector plus Asterisk or FreeSWITCH.  Instead of this
"standard" solution I am writing (already wrote mostly) my own suite
of ThemWi system daemon processes that connect to OsmoMSC's MNCC
socket on one end and talk SIP on the other end, effectively taking
the place of osmo-sip-connector.  The big difference is that while
o-s-c is meant to connect only to a local PBX instance (not directly
to an outside PSTN-via-SIP connectivity provider), my themwi-sip-in
(already written) and themwi-sip-out (to be written) processes talk
SIP to the outside world, to whichever service is used to achieve PSTN
connectivity via SIP - bulkvs.com service in my case.

My progress so far is that I got inbound calls working in the signaling
plane.  I got a pool of 10 USA phone numbers from BulkVS, and whenever
anyone calls one of these numbers from the outside world, BulkVS
servers send a SIP call (beginning with an INVITE UDP packet) to my
gateway server which I registered with them.  My themwi-sip-in process
listens on port 5060 and receives these SIP calls, and as of last
night, it works to the point of connecting these calls all the way
through to GSM phones connected to ThemWi network.  Every valid
incoming SIP call turns into MNCC_SETUP_REQ toward OsmoMSC, turning
into CC SETUP messages toward actual phones, and the end result is
that whenever someone calls the number (regular USA phone number) from
the outside, the GSM phone rings and shows the calling number - on my
own ThemWi network, *without* involving T-Mobile or any other
mainstream carrier!  All subsequent signaling works correctly: if I
press 'answer' on the target GSM phone, the calling phone shows the
call being connected (answer supervision passes through), I can then
hang up on either side and the other side receives disconnect signaling
correctly, as well as other signaling scenarios such as the caller
giving up before the callee answers or the callee rejecting the call.

What is still missing is the voice traffic path.  Like most (all?)
PSTN-via-SIP connectivity providers, BulkVS offers only G.711 and G.729
codecs and none of GSM (no 06.10, no AMR, not any others), whereas
Osmocom's existing MGW (OsmoMGW) does no transcoding whatsoever,
meaning not only no tandem transcoding, but also no "standard"
transcoding between GSM codecs and G.711 for PSTN.  Therefore, I need
to implement the latter transcoding myself, and my themwi-system-sw
architecture already has a place for it: my themwi-mgw process with
RTP gateway endpoints (I prefer to call them 'gateway' rather than
'bridge') with explicitly different sides, one GSM side and one PSTN
side.  This themwi-mgw already exists in its skeletal form, but the
actual RTP forwarding function (with the necessary transcoding)
remains to be implemented.

Hasta la Victoria, Siempre,
Mychaela aka The Mother


More information about the Community mailing list