Compare commits

..

3 Commits

Author SHA1 Message Date
2694f5b3fa still trying 2025-09-30 14:09:56 +02:00
f919b9ac5b testagain 2025-09-30 14:03:36 +02:00
4e88a096f7 try again 2025-09-30 13:18:16 +02:00
2 changed files with 6 additions and 3 deletions

View File

@@ -24,8 +24,9 @@ MESSAGE_TYPE_FILTER='["PositionReport"]'
# Output file for logging (optional)
DateFichier=$(date +"%Y%m%d-%H%M%S")
dir=$(dirname $0)
OUTPUT_FILE="$dir/data/raw_ais_$DateFichier.log"
dir=$(dirname $0)"/data"
OUTPUT_FILE="$dir/raw_ais_$DateFichier.log"
mkdir -p "$dir"
# Function to display usage information
show_usage() {
@@ -184,4 +185,5 @@ trap cleanup EXIT INT TERM
SUBSCRIPTION_MSG=$(create_subscription_message)
# Connect to websocket and send subscription message
echo "$SUBSCRIPTION_MSG" | websocat -n --text - -H "Sec-WebSocket-Protocol: json" -v autoreconnect:"$WEBSOCKET_URL" | process_message
echo "$SUBSCRIPTION_MSG" | websocat --ping-interval 10 --no-close --text -vv "$WEBSOCKET_URL" - | process_message
#-H "Sec-WebSocket-Protocol: json"

1
subscription.json Normal file
View File

@@ -0,0 +1 @@
{"APIKey":"8d32f42f3d7fa506ed5ed549d29279580b99303b","BoundingBoxes":[[[-90,-180],[90,180]]],"FiltersShipMMSI":["227397210"]}