Skip to content

Releases: anteoas/ais2geojson

v0.5

25 Jun 10:49
Compare
Choose a tag to compare
feat: added `navStatus` and `posAcc` fields

v0.4

09 Jan 12:52
Compare
Choose a tag to compare
feat: added trueHeading field

v0.3

02 Mar 11:56
Compare
Choose a tag to compare
bugfix: fixes printf's %ld and %d

v0.2: doc: remove completed TODOs

02 Mar 11:46
Compare
Choose a tag to compare
these were done in prior commits

v0.1: feat: adds SMI field

02 Mar 10:28
Compare
Choose a tag to compare
now the geojson's `smi` property field should be properly set:

 ➤ make ; and ./test/test.sh
cc -lm -I./aisparser -o ais2geojson \
	ais2geojson.c \
	aismsg_pos.c \
	./aisparser/nmea.c ./aisparser/sixbit.c ./aisparser/vdm_parse.c
{"type":"Feature","geometry":{"type":"Point","coordinates":[8.977640,63.592667]},"properties":{"mmsi":"257212340","aistype":1,"sog":0.0,"smi":0,"ts":1442764800}}

{"type":"Feature","geometry":{"type":"Point","coordinates":[13.770750,68.037033]},"properties":{"mmsi":"257074640","aistype":3,"cog":350.1,"sog":6.0,"smi":0,"ts":1488372074}}
expected:
{"type":"Feature","geometry":{"type":"Point","coordinates":[13.77075,68.03703333333334]},"properties":{"mmsi":257074640,"cog":350.1,"sog":6,"trueHeading":350,"aistype":3,"smi":0,"ts":"2017-03-01T13:41:14"}}

{"type":"Feature","geometry":{"type":"Point","coordinates":[8.674092,63.873138]},"properties":{"mmsi":"257003350","aistype":18,"cog":96.6,"sog":6.5,"ts":1488372074}}
expected:
{"type":"Feature","geometry":{"type":"Point","coordinates":[8.674091666666667,63.87313833333334]},"properties":{"mmsi":257003350,"cog":96.6,"sog":6.5,"trueHeading":511,"aistype":18,"ts":"2017-03-01T13:41:14"}}

{"type":"Feature","geometry":{"type":"Point","coordinates":[12.407562,66.434598]},"properties":{"mmsi":"258599000","aistype":1,"cog":288.0,"smi":1,"ts":1488372074}}
expected:
{"type":"Feature","geometry":{"type":"Point","coordinates":[12.407561666666668,66.43459833333333]},"properties":{"mmsi":258599000,"cog":288,"sog":10.2,"trueHeading":285,"aistype":1,"smi":1,"ts":"2017-03-01T13:41:14"}}