Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F113433876
CardNorth
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Sun, May 18, 03:14
Size
477 B
Mime Type
text/x-python
Expires
Tue, May 20, 03:14 (1 d, 19 h)
Engine
blob
Format
Raw Data
Handle
26252056
Attached To
R890 mux0183
CardNorth
View Options
#!/usr/bin/env python3
import sys, socket
sys.path.append ('../lib')
from aisMsg import *
# Connect to multiplexer
client = socket.socket()
host = socket.gethostname()
client.connect(('0.0.0.0', 39150))
obj = AISmsg21()
obj.mmsi = 101010100
obj.AtoN_type = AISmsg21.BEACON_CARDINAL_N
obj.name = 'North'
obj.accuracy = 1
obj.lat = 42.0 + 0.05
obj.lon = 6.0
obj.virtual_AtoN = 1
multi = obj.Encode()
for aivdm in multi :
print(aivdm)
client.send(bytes(aivdm, 'ASCII'))
Event Timeline
Log In to Comment