Sunday 13 May 2018

AIS Installation

A short description of how I've installed the Matsutec HA-102 AIS transponder. This isn't meant to be a permanent installation - we think it's a good idea for crossing the channel but we've offered it to my work yacht club at the end of the season. If we think it's a good idea I might add a receive only RTL-SDR one or I might buy another Matsutec.
The two main challenges are the antenna and a display. We have a spare VHF antenna and for tests we have just run that up the shrouds. A proper solution is work-in-progress. The GPS antenna is a small magnetic one from Ebay. It works a treat. You can see it on the top left of the photo.

Another challenge is the main cable on the Matsutec. It is long and bulky and non-standard. It carries the 12V and two NMEA outputs, one for GPS and one for AIS. I've used it only for power and hidden it behind the plywood mount.

The RS232 port on the Matsutec is bidirectional and carries both the GPS and AIS so I'm using that.

The reason the display is a challenge is that our current cockpit chart plotter has only one NMEA input. The old one had two. So we need a multiplexer to combine AIS and depth. Also the AIS is high speed (38.4. kbit/s) and the depth is low speed (4.8 kbit/s) so we need a rate adapting multiplexer. I'm using kplex on a Raspberry Pi 3 at the moment.
So the Pi has three USB/Serial port adapters fitted. It should be four but there seems to be a dead USB port on my Pi. One goes to the AIS and one to the chart plotter. They are both set up to be high speed. The third is split. The input comes from the depth unit and the output goes to the DSC radio. Kplex sends either the chart plotter's GPS info or the AIS transponders GPS info to the DSC radio, whichever is turned on.

Here is the chart plotter showing AIS targets.


And here is it showing an AIS proximity alarm.

The Pi3 with USB/Serial adaptors is a really cheap and simple way to get a four port NMEA 0183 Multiplexer with wifi but it isn't necessarily a good way.

There are two reliability problems.

The first problem is that the Pi is driven from a micro SD card which has to be mounted read/write. This leave open the chance that the SD card could be corrupted on power-down. I'll think about this. It hasn't happened to me.

The second problem is more serious. The power-up sequence (on Raspian Stretch at least) more-or-less randomly associates physical and logical USB ports. So there is no way of knowing which port is which in the software. I've got a work around at the moment because the low speed depth and VHF port uses a different chip in the USB to serial dongle than the other two. I can detect this (using a udev rule) and give the low speed port and alias that kplex can see. So kplex sets that one to 4800 baud and the other two to 38400 baud and it knows which one to send the GPS out to.

But if I had four working ones I'd have a problem.

I'm working on a solution to that using different hardware.

Another problem with the Pi3 is that most of the cases you can buy have lots of holes in them. I don't want mildew growing on the Pi so I've brought it home with me. My alternative hardware solution will fix this too.

1 comment:

Unknown said...

matsutec HA-102 RS422 (out)TX+
(out) TX- Data cable What color is it?