Cruisers Forum
 


Join CruisersForum Today

Reply
 
Thread Tools Rate Thread Display Modes
Old 06-07-2016, 01:42   #1
Registered User

Join Date: Jul 2016
Posts: 3
AIS decoding

Good morning!

I am trying to create my own AIS decoder. Yet, I don't know where to start from after reading AIVDM. I only have AIVDM/AIVDO protocol decoding as reference and which seems to be quite indigest. For instance with the following frame:

!AIVDM,1,1,,A,18tHtHhP01Op01NKMKDrtOvp28@i,0*03

How can I know which message type it is?
__________________

__________________
AntoineC is offline   Reply With Quote
Old 06-07-2016, 14:13   #2
Registered User

Join Date: Apr 2014
Boat: Leopard 47PC 47 feet
Posts: 73
Re: AIS decoding

Hi Antoine,
I have never looked at this before but I glanced at the document in the protocol decoding link you included. Your example has 18tHtHhP01Op01NKMKDrtOvp28@I in the “Payload” data block. If I read this correctly, the “armoring” (where do they get these names??) uses a truncated form of ASCII using six bits per character and so the the first six bits are the message type - in your example simply a “1”. Table 4 in your decoding link gives this as a “Position Report Class A”. Table 6 gives the breakdown of this type with the next two bits being the repeat indicator (I make this as “0”) and the next 30 bits the MMSI number, a 9 digit decimal number encoded as an unsigned integer. I make this as 600194147 in your example. And so on.....
Ed
__________________

__________________
edmundsteele is offline   Reply With Quote
Old 08-07-2016, 00:36   #3
Registered User

Join Date: Jul 2016
Posts: 3
Re: AIS decoding

Thank you for your answer. I think I did a mistake when trying to decoding it because I got, with the help of the document to translate the ASCII into actual 6-bits frames.

000001 001000 111100...

Wich gives me 1, so the message type you gived,
0
But then S. Which is false as far as it isn't even a number.


The following one isn't even 0

The numbers you find actually being those of my mmsi's, can you tell me how did you did it? ?
__________________
AntoineC is offline   Reply With Quote
Old 08-07-2016, 00:56   #4
Registered User

Join Date: Jul 2016
Posts: 3
Re: AIS decoding

How, I understand, I didn't have to take them number by number but as a whole number!
__________________
AntoineC is offline   Reply With Quote
Old 08-07-2016, 06:56   #5
Registered User

Join Date: Apr 2014
Boat: Leopard 47PC 47 feet
Posts: 73
Re: AIS decoding

You have it Antoine!
BTW, if you have a scientific calculator (does anyone use these anymore?) with a “hex” “oct” “dec” button, you can convert your binary sequences into something easier to manipulate – I used hexadecimal; enter this value into your calculator and hit the “dec” button.

For example the first 8 “truncated ASCII” characters in your example were 18tHtHhP These map in binary to 000001 001000 111100 011000 111100 011000 110000 100000. The 30 bits for the MMSI number are the 9th thru the 38th bits (fields 8 to 37) which is this part 1000 111100 011000 111100 011000 11. I made this an “unsigned 32 bit integer” by padding it back out to a 32 bits with two leading zeroes giving 001000 111100 011000 111100 011. Now convert each group of 4 bits to a hexadecimal character and it becomes 23C63C63. Stuff this into your calculator, hit the “dec” button and it converts to your MMSI number of 600194147.
Ed
__________________
edmundsteele is offline   Reply With Quote
Reply

Tags
ais

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Decoding the multitude of sat phone threads. DefinitelyMe Marine Electronics 30 05-09-2015 17:06
For Sale: AIS-MULTI AIS Receiver with built in Antenna Splitter kokomodenny Classifieds Archive 1 17-09-2013 09:53
For Sale: Standard Horizon Matrix AIS+ GX 2150 VHF Radio/AIS Receiver with CMP30 Ram3 Second St westsailwill Classifieds Archive 6 23-04-2013 19:21
AIS Simulation - Run VDR to play AIS Nmea file rgleason OpenCPN 16 12-01-2013 11:28
Can You Get Radar & AIS Overlay on Laptop ? AIS Transceiver Recommendations ? lunasea.ds Marine Electronics 22 27-12-2010 14:06



Copyright 2002- Social Knowledge, LLC All Rights Reserved.

All times are GMT -7. The time now is 07:41.


Google+
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2017, vBulletin Solutions, Inc.
Social Knowledge Networks
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2017, vBulletin Solutions, Inc.

ShowCase vBulletin Plugins by Drive Thru Online, Inc.