Assuming you have 2 raspberries:
- you setup your raspberry so that it is listenning to your 2 AIS receiver in client mode (so your kplex will receeive the 2 flows)
- you setup your raspberry kplex to send the traffic to MT server
- if your 2 raspberry are using 2 different internet connection, on your internet router where you Raspberry #2 is connected, you need to redirect the flow using PAT/NAT to the local ip adress of your rapsberry #2
- if same network, then just work with local IP adresses and ports
All this seems feasible without coding, just with 2 kplex configuration and NAT/PAT potentially to me but requires testing and fine tuning :-)
if you have only 1 Raspberry: just setup 2 client AIS and setup 1 output to MT.
good luck!!!!!!!
configuration with 1 raspberries: and 2 USB receivers:
###### Local input with USB receveir #1
[serial]
filename=/dev/serial0
(maybe this need to be changed)
direction=in
baud=38400
###### Local input with USB receveir #2
[serial]
filename=/dev/serial1 (maybe this need to be changed)
direction=in
baud=38400
# Marine Traffic Output
[udp]
direction=out
port=(replace with MT port)
address=(replace with MT IP Address)
configuration with 2 raspberries:
Raspberry #1 configuration
--------------------------------------------
your kplex.conf file should look like this :
###### Local input with USB receveir #1
[serial]
filename=/dev/serial0
direction=in
baud=38400
# Sending traffic to Raspberry #2
[udp]
direction=out
port=5466
address=<IP Address of your raspberry #2> (if PAT/NAT, this is the internet IP adress of your router where there is the raspberry 2 ; if no PAT/NAT, local IP Address of your Raspberry)
Raspberry #2 configuration
--------------------------------------------
###### Local input with USB receveir #2
[serial]
filename=/dev/serial0
direction=in
baud=38400
###### Input coming from your raspberry #1
[UPD]
direction=in
port=5466
address=127.0.0.1 (in case of PAT / NAT)
# Marine Traffic Output
[udp]
direction=out
port=(MT port)
address=(MT IP Address)