AIS signals are GFSK modulated signals at 161.975 or 162.025 MHz. Packets are sent with a preamble and the HDLC packet protocol is used. Below are pictures showing frequency vs time plots.
Download flow graph here: https://www.funwithelectronics.com/wordpress/other_data/demod_gfsk_for_blog.grc
When connecting the sync_and_strobe (gr-capture_tools) block to this signal and configuring it correctly, we get this:
Zoomed in on the first part:
AIS packets are “encoded” in multiple steps:
- The fields of various sizes are packed together as a bit sequence.
- Every 8 bit bundle is then reversed
- Bit-stuffing is performed: Every 111111 is converted to 1111101
- The stream is inverted, 1101 becomes 0010
- Differential encoding is performed. So every 1 becomes a transition, every 0 causes no change
- Then the header and end word are added at the start and the end.




