summaryrefslogtreecommitdiff
path: root/gpsd_json.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2011-04-20 17:44:16 -0400
committerEric S. Raymond <esr@thyrsus.com>2011-04-20 17:44:16 -0400
commit0a1c0519d81e2aa53cde6736a2d3611038e985cf (patch)
tree09fcdf728d051beabc3443127e01e9acaffce7b1 /gpsd_json.c
parent65bfe8487a68e9910764d2cf1d93a8aef19c22c0 (diff)
downloadgpsd-0a1c0519d81e2aa53cde6736a2d3611038e985cf.tar.gz
Support IMO236 FID 15. And polish the code generator a bit.
Diffstat (limited to 'gpsd_json.c')
-rw-r--r--gpsd_json.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/gpsd_json.c b/gpsd_json.c
index 0b336056..f5b8053b 100644
--- a/gpsd_json.c
+++ b/gpsd_json.c
@@ -1780,7 +1780,11 @@ void json_aivdm_dump(const struct ais_t *ais,
ais->type6.dac1fid32.cdir,
ais->type6.dac1fid32.cspeed);
break;
- case 16: /* IMO236 - Number of persons on board */
+ case 15: /* IMO236 - Extended Ship Static and Voyage Related Data */
+ (void)snprintf(buf + strlen(buf), buflen - strlen(buf),
+ "\"airdraught\":%u",
+ ais->type6.dac1fid15.airdraught);
+ case 16: /* IMO236 - Number of persons on board */
(void)snprintf(buf + strlen(buf), buflen - strlen(buf),
"\"persons\":%u", ais->type6.dac1fid16.persons);
imo = true;