npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

ggsimulator

v0.1.9

Published

GEOGATE-Simulator simulate one/many GPS/AIS receiver/transpondeur

Downloads

9

Readme

GeoGate Simulator

GeoGate is an opensource GPS/AIS tracking server framework, that enable easy integration of multiple GPS trackers in WEB applications. It provides data acquisition drivers for typical tracker devices or phone's GPS apps. It handle multiple database backend, and support GeoJSON, AIS & NMEA encoding/decoding. It embed support for multiple classes of trackers, phone-apps, as well an NMEA & AIS simulator.

GeoGate-Simulator

Is the component that support GPS/AIS receiver/transceiver emulation. It can either emulate a single or multiple devices.

Install

   npm install ggsimulator

OnLine demo

   tcp://sinagot.net 5001 (one GPS/GPRMC + 10 AIS targets) in the bay of Quiberon (South Brittany, Europe)

Command line

   # Standalone GPS/AIS device
   node ./bin/DevSimulator.js --verbose --gpxfile=sample/gpx-file/opencpn-sample.gpx --mmsi=0 --tic=1  # MMSI=0 force GPRMC formatting
   node ./bin/DevSimulator.js --verbose --gpxfile=sample/gpx-file/opencpn-sample.gpx --mmsi=12312345 --tic=10 --shipname='Youpi' --class='A' --speed=15 --length=150 --width=10

   # One GPS and Multiple AIS targets loop for ever
   node ./bin/HubSimulator.js --gpxdir=./sample/hub-route --port=5001 --loopwait=1 --debug=3

API Usage

   var GGsimulator = require("ggsimulator").Simulator;
   var config =
       { gpxfile : "../sample/gpx-file/opencpn-sample.gpx"
       , mmsi    : 1234      // my prefered fake MMSI
       , tic     : 1         // send a position every 10s
       , loopwait: 0         // stop at end of gpxfile
       , debug   : 4         // [0-9] 4= see event emit without listening to them
    };
    var simulator = new GGsimulator (config);
    simulator.event.on("position",MyEventHandler4Position);   // GPS position report
    simulator.event.on("static"  ,MyEventHandler4Statics);    // AIS static data report

    // Check ./sample/geojson for a working solution with a custom message formating

API/lib

require("ggsimulator").Simulator : parses a single GPX file, generates intermediary points and emits position/statics events require("ggsimulator").Dispatch : supports TCP client/server services. Dispatches outgoing messages to connected clients require("ggsimulator").NmeaAisEncoder : formats outgoing messages to GPRMC/AIVDM standard as requested by chart applications like OpenCPN

Sample

./sample/geojson/GeoJsonExample.js A small application that leverages a basic custom encoding.