Skip to content

Maritimo is a set of applications used to decode, persist and display AIS data

License

Notifications You must be signed in to change notification settings

t-recx/maritimo

Repository files navigation

Maritimo is a set of applications used to decode, persist and display AIS data. It aims to be fast, scalable and easy to extend.

AIS (Automatic Identification System) is an automatic tracking system. AIS transmitters are equipped in vessels, navigation markers, and shore stations. These transmitters emit data related to the vessel or object they're fitted on including position, heading, speed, course and more. This information is then used by other vessels to avoid collision or by ports and maritime authorities in their traffic monitoring systems.

Applications

Name Description
Station Fetches or receives data from AIS stations via TCP or UDP
Decoder Decodes NMEA VDM/VDO messages
Persister Records decoded data in a database
Transmitter Transmits decoded data over a Signal-R hub
WebApi Queries the database via REST
Frontend Displays the information using a web frontend

Requirements

Configuration

Configuration is done via environment variables. To configure the entire system create a .env file in the main project directory and set the following variables:

Name Description
POSTGRES_USER PostgreSQL database user name
POSTGRES_DB PostgreSQL database name
POSTGRES_PASSWORD PostgreSQL database password
MARITIMO_STATION_CONNECTION_PROTOCOL Protocol to use (TCP/UDP/FILE)
MARITIMO_STATION_CONNECTION_LISTEN_PORT Listen port (UDP)
MARITIMO_STATION_HOSTNAME Station host name (TCP)
MARITIMO_STATION_PORT Station connection port (TCP)
MARITIMO_STATION_READ_TIMEOUT_SECONDS Station read timeout (TCP)
MARITIMO_STATION_FILENAME Filename with VDM/VDO sentences (FILE)
MARITIMO_STATION_INCLUDE_SENDER_IP_ADDRESS Includes the source's ip address on the encoded message
MARITIMO_DB_CONNECTION_STRING Database connection string
MARITIMO_RABBITMQ_URI URI for the RabbitMQ broker instance
MARITIMO_RABBITMQ_ENCODED_MESSAGES_QUEUE_NAME Broker queue name for encoded messages
MARITIMO_RABBITMQ_DECODED_MESSAGES_EXCHANGE_NAME Broker exchange name for decoded messages
MARITIMO_CORS_ORIGIN_WHITELIST CORS origin whitelist
MARITIMO_TRANSMITTER_BUFFER_SECONDS Seconds to buffer messages before sending them to ReceiveBuffered method
MARITIMO_DB_CACHE_MINUTES_EXPIRATION Minutes until expiration of a cache entry for a station/object
MARITIMO_LOG_LEVEL_MINIMUM Minimum logging level (TRACE / DEBUG / INFORMATION / WARNING / ERROR / NONE)
MARITIMO_PERSISTER_SAVE_MESSAGES Specifies whether to save AIS messages (might require a lot of disk space over time)

Check an example configuration file in .env.development.

Frontend configuration

An additional configuration .env file is also expected on the frontend/ directory, with the following variables set:

Name Description
REACT_APP_WEB_API_URL URL for the REST API endpoint for the latest AIS information
REACT_APP_TRANSMITTER_HUB_URL URL for the transmitter hub endpoint
REACT_APP_PHOTOS_URL URL for the photos endpoint
REACT_APP_MAP_OBJECT_LIFESPAN_HOURS Object lifespan in hours
REACT_APP_MAP_INITIAL_CENTER_LATITUDE Map's initial latitude
REACT_APP_MAP_INITIAL_CENTER_LONGITUDE Map's initial longitude
REACT_APP_MAP_INITIAL_ZOOM Map's initial zoom level
REACT_APP_MAP_MAX_ZOOM Map's maximum zoom level

Check an example configuration file in frontend/.env.development.

Running

Inside the project directory run:

$ docker compose up

Open http://localhost to access the application.

Data Contributions

Source Location
NCA Norway
Sydney Sisco Vancouver, BC
Joeri van Dooren Lombardsijde, Belgium
Rab Greenock, Scotland
LARS Sintra, Portugal
Jose Elias Diaz Vigo, Spain
Carmelo Milla Malaga, Spain
Pablo Costagliola Argentina and Uruguay
Gerrit van der Laag Netherlands
John Wiseman Lewis and Harris, Scotland
Rene Rotterdam, Netherlands
John Hearne Cork, Ireland
Manfred Schenk Vallicone, Corsica, France
Peter Roosens Mendonk, Belgium
Telcomserv Aalst, Belgium
Kinsale Angling Kinsale, Ireland
Subsea Survey Services Ltd. Cork, Ireland
ARAF/Mateus PP5FMM Florianópolis, Brazil
Alberto Pérez Cantábria, Spain
ALERT PLUS Szczecin, Poland
ADVANCED TECHNOLOGY ENGINEERING Szczecin, Poland
Erik Jõgi Miiduranna, Estonia
Peter Fässberg Trollhättan, Sweden
SigmaPlusVO Ақтау, Kazakhstan
Michael Stutzbach (DO6LSM) Borgwedel, Germany
Stephen Carns Los Angeles, USA
Regis Electronics St Lucia Gros Islet, St. Lucia
Digimap Guernsey Guernsey
Dirk Metz (SWLJO43) Wentorf, Germany
Frans Veldman Netherlands
Pedro Almeida (CT7ARQ) Esposende, Portugal

Got a station and would like to help out? Shoot me an email at [email protected].

Special thanks

This project wouldn't be possible without the open access that the Norwegian Coastal Administration offers to its AIS data and Eric S. Raymond's documentation on AIVDM/AIVDO protocol decoding.

About

Maritimo is a set of applications used to decode, persist and display AIS data

Topics

Resources

License

Stars

Watchers

Forks

Sponsor this project