Skip to main content

Setting up Dummy and LogCollector for a TETRAPack connection

Hardware requirements

  • Raspberry Pi (4 is ideal, 2GB is ok), with PSU and SD card
  • icE1USB
  • A USB-Ethernet Adapter
  • A CTS (DUH)

Prep work

  • Make sure you understand how TetraPack works, its topology, how Dummy and LogCollector operate with each other, etc.
  • Before going any further, read this!
  • Open up the icE1USB (from the back, with the SMA connector), and swap the jumpers so they match this picture:image.png

CTS Setup

  1. Get a clear view of how the CTS is configured, and its necessary configuration files: bssparams.txt, set_x_gp, gm, sc, sub.csv, etc. Please make sure everything works as a standalone site before starting this entire endeavour!
  2. You also need good way to remotely connect to the CTS management interface (VNC is a good option).
  3. Plan ahead and make a list of the BrandMeister TGs you want your CTS to handle. Add them already to set_x_gp and gm.csv, reboot everything and make sure they already work locally in standalone mode.
  4. Open up bssparams.txt on your CTS, and do the following edits. Don't change anything else at this state:
    ## Base-Station Parameters ################################################################
    #### Set the name to something simple, short, no special caracters
    /base-station/name = "CTSNAME";
    #### set this to id 1
    /base-station/base-station-id = 1;
    #### add or replace:
    /base-station/standalone-mode = false;
    #### add or replace:
    /base-station/use-local-site-fall-back = false;
    
    ## SDS Gateway Parameters #################################################################
    #### Remove all other lines, replace by:
    /system/sds-gateway/host-1 = { issi = 262999; ip-address = "44.225.64.18";};
    /system/sds-gateway/host-2 = { issi = 250999; ip-address = "44.225.64.19";};
    /system/sds-gateway/host-3 = { issi = 16777184; ip-address = "44.225.64.20";};
    
    ## E1 Layout Parameters ###################################################################
    ### Remove all other E1 layout lines, and replace byt this:
    /network/E1-layout/time-slot-01 = { source-type = "SIGNALLING"; };
    /network/E1-layout/time-slot-02 = { source-type = "SIGNALLING"; };
    /network/E1-layout/time-slot-03 = { source-type = "SIGNALLING"; };
    /network/E1-layout/time-slot-04 = { source-type = "SIGNALLING"; };
    
    /network/E1-layout/time-slot-17 = { source-type = "BS"; base-station-id = 1; l-transceiver-id = 11; };
    #Dummy transceivers
    /network/E1-layout/time-slot-22 = { source-type = "BS"; base-station-id = 7; l-transceiver-id = 11; u-transceiver-id = 12;};
    /network/E1-layout/time-slot-23 = { source-type = "BS"; base-station-id = 7; l-transceiver-id = 13; u-transceiver-id = 14;};
    /network/E1-layout/time-slot-24 = { source-type = "BS"; base-station-id = 7; l-transceiver-id = 15; u-transceiver-id = 16;};
    
    /network/E1-layout/time-slot-25 = { source-type = "DISP"; };
    /network/E1-layout/time-slot-26 = { source-type = "ISDN"; };
    
    /network/E1-layout/time-slot-27 = { source-type = "ISDN"; };
    /network/E1-layout/time-slot-28 = { source-type = "ISDN"; };
    /network/E1-layout/time-slot-29 = { source-type = "ISDN"; };
    
    
    ## Network Topology Parameters ############################################################
    #### Remove all other network topology parameters, and replace by this. Don't forget to change CTSNAME to the same name as in line 3!
    /network/topology/gateway-pc     = { name = "Gateway Server"; E1-connection-1 = "BS-7"; };
    /network/topology/base-station-1 = { name = "CTSNAME"; E1-connection-1 = "BS-7"; };
    /network/topology/base-station-7 = { name = "DUMMY"; E1-connection-1 = "BS-1"; E1-connection-2 = "GW-PC"; };
    
    
  5. Save and reboot the CTS, make sure it still works.
  6. Copy bssparams.txt over to your local PC, you'll need it for your Raspberry Pi.
  7. Write down the IP address of your CTS BSC computer (mine was 10.10.15.31, but yours will probably be different). 

Software Stack Install

  1. Prepare an SD card with a 64-bit Raspbian Bullseye (Debian 11)
  2. Update/Upgrade the OS after boot:
    sudo apt get update && sudo apt upgrade
    reboot

  3. Add the Osmocom repo, as per Osmocom's documentation:
    sudo su
    OSMOCOM_REPO="https://downloads.osmocom.org/packages/osmocom:/latest/Debian_11" 
    wget $OSMOCOM_REPO/Release.key
    mv Release.key /etc/apt/trusted.gpg.d/osmocom-latest.asc
    echo "deb [signed-by=/etc/apt/trusted.gpg.d/osmocom-latest.asc] $OSMOCOM_REPO/ ./" > /etc/apt/sources.list.d/osmocom-latest.list
    apt get update
  4. Install Osmocom E1D:
    sudo apt install osmo-e1d
  5. Add the TetraPack repository:
    wget https://packages.tetrapack.online/install/public.key
    mv public.key tetrapack.asc
    sudo apt-key add tetrapack.asc
    sudo echo "deb [arch=arm64] http://packages.tetrapack.online/repository/ bullseye main" > /etc/apt/sources.list.d/tetrapack.list
    sudo apt update
  6. Install TetraPack dummy and cts-logcollector
    sudo apt install tetrapack-dummy cts-logcollector
  7. Plug in the icE1USB to your Rpi, recover the interface serial number:
    sudo lsusb -d 1d50:6145 -v 2> /dev/null | grep iSerial
  8. Open (with for instance nano) /etc/osmocom/osmo-e1d.cfg, copy/paste this:
    log syslog daemon
    e1d
    	interface 0 icE1usb
    	usb-serial [interface serial number]
    	line 0
  9. Reload the service:
    sudo systemctl restart osmo-e1d

LogCollector - CTS Management interface setup

  1. Connect the USB/Ethernet interface to the Pi, and connect an Ethernet cable from BSC management port to the usb dongle. 
  2. Set a static IP on the interface (probably eth1) on the same range as the BSC, by editing /etc/dhcpcd.conf and adding this:
    #Don't forget to edit your ip address to match the range of your BSC!
    interface eth1
    static ip_address=10.10.15.20
    static routers=10.10.15.1
  3. Test if you can connect via telnet:
    telnet [BSC IP ADDR] 51600
    #If you get "220 Network Management Interface is ready.", you're good to go!
  4. Stop LogCollector:
    sudo systemctl stop cts-logcollector@default.service
  5. Open /opt/LogCollector/default.env, and change the ip address:
    # [IP of basestation] [dummy instance name] [basestation ID (1-8)]
    COMMAND_ARGUMENTS=[YOUR BSC IP] default 1
  6. Enable/Restart LogCollector, wait for a bit and see if you get data coming from the CTS when you place a call or attach to a group:
    sudo systemctl enable cts-logcollector@default.service
    sudo systemctl start cts-logcollector@default.service
    #Let's monitor syslog to see if it recovers logs from the CTS. You should see a bunch of lines show up.
    tail -f /var/log/syslog | grep cts
  7. If it works, great! LogCollector is ready. Ctrl+C to quit tail, carry on to the rest