# libais **Repository Path**: vcan123/libais ## Basic Information - **Project Name**: libais - **Description**: No description available - **Primary Language**: Unknown - **License**: Apache-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2024-01-10 - **Last Updated**: 2024-07-01 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README ============ Introduction ============ .. image:: https://travis-ci.org/schwehr/libais.svg?branch=master :target: https://travis-ci.org/schwehr/libais .. image:: https://scan.coverity.com/projects/5519/badge.svg :target: https://scan.coverity.com/projects/5519 .. image:: https://codeclimate.com/github/schwehr/libais/badges/gpa.svg :target: https://codeclimate.com/github/schwehr/libais .. image:: https://badge.fury.io/py/libais.svg :target: http://badge.fury.io/py/libais Library for decoding maritime Automatic Identification System messages. See Also ======== `Automatic Identification System `_ Other open source AIS projects: - `GPSd `_ - `AisLib `_ - `noaadata `_ - `ais-areanotice `_ - `OpenCPN `_ - `aisparser `_ - `nmea_plus `_ Building ======== Building with Python -------------------- .. code-block:: console $ python setup.py build $ python setup.py install Testing with Python -------------------- .. code-block:: console $ virtualenv ve $ source ve/bin/activate $ python setup.py test Building with CMake ------------------- .. code-block:: console $ cmake . $ make Building with legacy Makefile ----------------------------- .. code-block:: console $ make -f Makefile-custom test Usage ===== There are two interfaces to libais, one high-level iterator based one and a low-level fast C++ only one. The iterator based interface is accessed the following way: .. code-block:: python import ais.stream with open("file.nmea") as f: for msg in ais.stream.decode(f): print msg To use the low-level C++ interface directly, you need to handle multi-line messages and padding yourself: .. code-block:: python import ais ais.decode('15PIIv7P00D5i9HNn2Q3G?wB0t0I', 0) ais.decode('402u=TiuaA000r5UJ`H4`?7000S:', 0) ais.decode('55NBjP01mtGIL@CW;SM`_ - IMO Circ 236 - IMO Circ 289 - EU RIS Developing ---------- The C++ code was switched to the Google style in November, 2012. Indenting should be by 2 spaces. http://google-styleguide.googlecode.com/svn/trunk/cpplint/ .. code-block:: console $ git clone https://github.com/schwehr/libais $ cd libais $ virtualenv ve $ source ve/bin/activate $ pip install -e .[tests] $ python setup.py test $ py.test --cov=ais --cov-report term-missing or .. code-block:: console $ git clone https://github.com/schwehr/libais $ cd libais $ virtualenv ve $ source ve/bin/activate $ pip install -e .[test] $ python setup.py develop $ python setup.py test $ py.test --cov=ais --cov-report term-missing