Quick Start

If you already installed a C++14 compiler, git and python on your system, then you can clone this repository to a suitable folder:

git clone git@gitlab.com:steinwurf/otacast.git

After cloning the repository you will have the latest development snapshot. Unless you need to work on the latest and greatest we recommend that you switch to a released version of the library.

cd otacast
git checkout 

Configure and build the project:

python waf configure
python waf build
python waf install --destdir=otacast_install

The final install step will create a folder containing all the nessecary files needed to use the library (e.g. static library, headers etc.). You can change the output folder by passing a different path to --destdir. You can also copy/move this install folder anywhere you like.

Example

To create your first “hello world” program using OTAcast you can try the following:

#include <iostream>

#include <otacast/encoder.hpp>
#include <otacast/to_string.hpp>
#include <otacast/version.hpp>

int main()
{
    // Print the version of the library used

    // Create the encoder object with a specific finite field
    otacast::encoder encoder;


    otacast::finite_field field = otacast::finite_field::binary8;
    uint64_t block_bytes = 1024 * 1000; // 1 MB
    uint64_t symbol_bytes = 1500;
    uint64_t width = 5;

    encoder.configure(field, block_bytes, symbol_bytes, width);

    std::cout << "version:      " << otacast::version() << "\n";
    std::cout << "block_bytes:  " << encoder.block_bytes() << "\n";
    std::cout << "symbol_bytes: " << encoder.symbol_bytes() << "\n";
    std::cout << "width:        " << encoder.width() << "\n";
    std::cout << "symbols       " << encoder.symbols() << "\n";
    std::cout << "field         "
              << otacast::to_string(encoder.finite_field()) << "\n";
    return 0;
}

To compile with g++ (if you installed to the otacast_install local folder):

g++ main.cpp -std=c++14 -I otacast_install/include -L otacast_install/lib -lotacast

See the full API provided by the class encoder and class decoder objects to see all available operations.

Versions
3.0.0
2.1.0
2.0.1
2.0.0
1.0.0
Development
latest