Skip to content

Wireless-Innovation-Forum/Spectrum-Access-System

Repository files navigation

The SAS Testing and Interoperability Repository

This repository contains code and data for testing the compliance of Spectrum Access System (SAS) software. The SAS is defined by the FCC in proceeding 12-354 as the system authorizing priority access and general access to the 3550-3700MHz Citizens Broadband Radio Service.

This repository contains procedures, documentation, and tests for such software, and for the devices authorized by it.

To contribute, please first read the CONTRIBUTING file in the repository for instructions.

Data

Some of the required data is provided in folder data/. Scripts used to retrieve or generate these data are in src/data/.

USGS NED Terrain and NLCD Land cover data are not provided as part of the data/ folder, but kept instead in a separate Git repository found at: https://github.com/Wireless-Innovation-Forum/Common-Data

The process relies in cloning that repository, unzipping the geo data and pointing the SAS reference models to point to those data.

See the corresponding README.md for more details on the integration of those geo data for use with SAS.

Code prerequisites

Note: see last section for an example of full installation.

The scripts in the SAS repository depend on local environment setup to run. Here are packages and software needed to correctly operate the scripts.

This is the Python runtime which interprets the scripts in the src/ directory. It may already be running on many platforms, and if it is not already installed, is widely available. Type the command python --version to check the Python version installed on your platform.

NOTE: The current code was designed to work with both Python 2.7 and 3.7. It is recommended to only use Python 3.11 from now on. Currently untested with Python 3.12 and above.

This is the Python package management system. If you have Python installed on your system, it may already be available as well. The latest distributions of Python come with pip pre-bundled so you may not need to retrieve it separately. To check it's availability on your system run the command pip --version.

This binary library is needed to support Python shapely libraries. It will likely need to be installed separately on your system. Platform-specific instructions can be found at the above URL.

This binary library provides the mechanism to support Python XML libraries. It will likely need to be installed separately, and you may need to configure platform-specific C++ building capabilities to complete the installation. It can typically be installed with pip.

This binary library provides geospatial data library methods used to manipulate geographic datasets. It will likely need to be installed separately for your platform, and you may need to configure platform-specific C++ build capabilities to complete the installation. Source-based installation is an option. Once the libgdal package is installed, you will need to download and install the Python bindings for the library.

This library provides a variety of numerics methods and Python bindings to use them. It will likely need to be installed separately for your platform, and may be installed as part of the SciPy packages.

This Python library can be installed with pip. It provides libraries for processing geometrical objects and shapes in Python.

This Python library can be installed with pip. It provides libraries for handling KML geospatial files in Python.

This Python library can be installed with pip. It provides libraries for handling SHP geospatial files in Python.

This Python library can be installed with pip. It provides a high-level interface for retrieving FTP files with Python.

This Python library can be installed with pip. It provides JSON schema validation support.

This Python library can be installed with pip. It provides support for the OpenSSL library for Python.

This Python library can be installed with pip. It provides support for creating testing mocks.

This Python library can be installed with pip. It provides support for advanced functools such as OrderedDict and lru_cache memoization.

This Python library can be installed with pip. It provides information on running processes and system (RAM,..).

This Python library can be installed with pip. It allows to find unused network ports on a host.

For all these Python packages, a good way to test their installation is to run the Python interpreter and then issue an import xyz command, where xyz is the name of the package. Error-free import means that the package is installed successfully.

  • Security certificates, as described in src/harness/testcases/testdata/certs/README.md

Example of installation: Python3 installation using venv in Linux

Create a venv

    python3.11 -m venv ./winnf3

Activate a venv

    source ./winnf3/bin/activate

Install packages

    python -m pip install -r ./requirements.txt

Example of installation: Python3 installation using miniconda in Linux

This example uses the MiniConda environment manager.

Install miniconda from this page: https://docs.anaconda.com/free/miniconda/

Option 1: use conda-environment.yml file

    conda env create -f conda-environment.yml
    conda activate winnf3

Option 2: use conda commands

Create a conda Python 3.11 environment named winnf3:

    conda create --name winnf3 python=3.11

Activate the environment on a command shell:

    conda activate winnf3

Install the required packages.

For the reference models and various libs:

    conda install numpy
    conda install shapely
    conda install gdal
    conda install lxml
    conda install jsonschema
    conda install matplotlib
    conda install cartopy
    pip3 install pygc
    pip3 install pykml
    pip3 install xlsxwriter

Additionally for the test harness:

    conda install cryptography
    pip3 install jwt
    pip3 install portpicker
    conda install pyopenssl
    conda install pycurl
    pip3 install psutil

Additionally for the data scripts:

    pip3 install ftputil