Jump to content
chicken

[POTM] dAISy - A Simple AIS Receiver

Recommended Posts

Hi Ross,

Yes, you can feed the serial data out of the HAT into an Arduino or ESP8266. It's 8N1 UART at 38400. You can expect a few hundred messages / minute in very busy areas down to a few per minute in quieter locations.

The AIS payload is encoded into !AIVDM messages. If you want to do more with the AIS data than just forwarding it, you will have to decode the !AIVDM message and then make sense of the binary AIS payload embedded in them. You can find detailed documentation of !AIVDM and payload structure that here.

As you can see, it's pretty exhaustive. If you want to process AIS messages on the Arduino/ESP8266, you likely will have to focus on a few message types. 1, 2, 3, 5, 18,19 are the most important for tracking ships. This here is an Arduino library for AIS decoding that I found, but I never used it so can't vouch for it.

Happy to share logs of real-world AIS data if that's helpful. If interested, send me a PM.

Regards,
Adrian

Share this post


Link to post
Share on other sites
Hi Adrian!
I tried to figure it out myself, but .... without your help it will not work.
Please, if you have time, answer a few questions.
I'm trying to run your project on si4463 (revision B1), but with 26Mhz quartz.
WDS 3.2.11.0 does not correctly open your WDS_si4463_revb1_direct_rx.xml.
I have the "Direct RX" mode, in the "RF parameters" tab there is no "Preamble pattern" item.
Tab "Packet" is completely absent.
In the "GPIO and FRR" tab, WDS 3.2.11.0 shows a complete absurdity (((...
Could you show how these things are tuned for you? Or prompt
Where can I find WDS 3.2.6.0?
Thank!
Sorry for the google translator.

Share this post


Link to post
Share on other sites

Thank you very much! Can this configuration be applied to si4463? You wrote about si4463,
"Unfortunately two pins (GPIO2 and GPIO3) are reserved to control the RF
switch that connects the antenna with RX or TX channels. But after a
few minor changes to my code I had dAISy working.

Here's the branch on Github: https://github.com/astuder/dAISy/tree/E10-M4463D
The wiring changed:

GPIO0 -> P2.0

NIRQ -> P2.5

GPIO2, GPIO3 -> no longer connected to the LaunchPad"

Or I need for your "dAISy-E10-M4463D"
GPIO0 configure RX_DATA_CLK.
GPIO1 configure RX_DATA.
GPIO2 DONOTHIG.
GPIO3 DONOTHIG.
NIRQ configure CCA.
SDO DONOTHIG (or maybe SDO configure Output SPI serial data out? ).

Thank!

 

 

 

 

Share this post


Link to post
Share on other sites

The Si4463 is backward compatible, as long as the chips have the same revision (B1 in this case).

The pin out depends on the breakout board that you use for your project. I don't have a screenshot as I never updated the dAISy-E10-M4463D project to the new version of WDS. dAISy requires CLK and DATA from the radio, which the 4362 config files map to GPIO2 and GPIO3. If necessary, move them to other pins as they are available on your breakout board.

But don't change CTS (GPIO1) as this pin is essential for SPI communication!

Share this post


Link to post
Share on other sites

It works))) Thanks Adrian! I do not have an AIS source, but I have a WAV file that I send from my HackRF and it works))

I get a lot of errors, but I think this is the subtlety of setting frequency, gain and other HackRF settings.
Again, sorry for the google translator.

_LA_.jpg

Share this post


Link to post
Share on other sites

Happy to hear that 🙂

Yeah, probably keep gain to a minimum. I would go with -50 dBm or less.

And no worries about Google Translate, it does a great job.

Share this post


Link to post
Share on other sites

Hi Adrian! I was in St. Petersburg, recorded the AIS broadcast and was surprised when I played it on the second frequency 162.025 at home ... it works too!))) But WDS is set to 161.975. Do you programmatically switch channels by RSSI level and after what time? If you can tell me where in the program it is. I'm not a programmer at all. Here's a video of how your dAISy looks at me))

Share this post


Link to post
Share on other sites

Hi Varnak,

The dAISy software does change the channel every so often. The code for switching between the channels start at line 329 in packet_handler.c
https://github.com/astuder/dAISy/blob/master/packet_handler.c#L329

The receiver will switch to the other channel when the state is PH_RESET, which is the case after an error, successful message, or when there is no start of message within PH_SYNC_TIMEOUT (defined in line 27) clock ticks (one tick being 1/9600 second). Statistically, it will miss at least 50% of the message as it can only listen on one channel at a time.

Regards,
Adrian

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×