Skip to main content

JANUS Messages

JANUS is a standardized physical and data link layer for acoustic underwater communications designed and implemented by NATO's Centre for Maritime Research and Experimentation (CMRE). The standard is described in the NATO ANEP-87 specification. Further details about JANUS are available at the wiki page maintained by CMRE.

Janus baseline bit allocation
JANUS baseline bit allocation, from JanusWiki.com.

Janus Bitstream

One defining feature of Janus is its configurable payload scheme. Each message begins with an acquisition pattern, followed by modulated bits. The definition of these bitfields is variable based on message content.

In the baseline bit allocation table above, bits 31-56 are the application data block. The definition of this block depends on the ClassUserID and ApplicationType bitfields found earlier in the message.

Popoto Modem Implementation of Janus

The Popoto Janus modem fully implements all ratified Janus Class IDs, currently including Class IDs 0, 2, and 16.

Within the Popoto Modem, each field exported in the class definition is represented by a field in a JSON-encoded message. In this way, a JSON-encoded message can be translated directly into a Janus message class.

The following examples show supported message types, along with links to the class descriptions on JanusWiki.com. Each JSON structure should be encoded on a single line and passed to the transmitJSON API of pshell or another Popoto API, such as C++, Python, or MATLAB.

Class User ID 000: Emergency

ApplicationType 1: Position Message

Refer to the Emergency Position Message Format wiki page for details about the fields associated with the emergency position message.

{
"ClassUserID": 0,
"ApplicationType": 1,
"Nationality": "AB",
"Latitude": "90.000000",
"Longitude": "0.000000",
"Depth": "8190",
"Speed": "0.000000",
"Heading": "180",
"MobilityFlag": "1",
"ForwardingCapability": "1",
"TxRxFlag": "0",
"ScheduleFlag": "1",
"Schedule": "10"
}

ApplicationType 2: Status Message

Refer to the Emergency Status Message Format wiki page for details about the fields associated with the status message.

{
"ClassUserID": 0,
"ApplicationType": 2,
"Nationality": "ZX",
"O2": "17.000000",
"CO2": "5.000000",
"CO": "0.000000",
"H2": "5.000000",
"Pressure": "103.199997",
"Temperature": "50.000000",
"Survivors": "1",
"MobilityFlag": "1",
"ForwardingCapability": "1",
"TxRxFlag": "0",
"ScheduleFlag": "1",
"Schedule": "10",
"RepeatFlag": "1"
}

ApplicationType 3: Position + Status Message

Refer to the Emergency Position and Status Message Format wiki page for details.

{
"ClassUserID": 0,
"ApplicationType": 3,
"Nationality": "PT",
"Latitude": "38.386547",
"Longitude": "-9.055858",
"Depth": "16",
"Speed": "1.400000",
"Heading": "0.000000",
"O2": "17.799999",
"CO2": "5.000000",
"CO": "76.000000",
"H2": "3.500000",
"Pressure": "45.000000",
"Temperature": "21.000000",
"Survivors": "43",
"MobilityFlag": "1",
"ForwardingCapability": "1",
"TxRxFlag": "0",
"ScheduleFlag": "0"
}

Class User ID 002: Underwater AIS

Refer to the Underwater AIS Message Format wiki page for details about the fields associated with the underwater AIS message.

The example below shows how to construct a representative Class ID 002, ApplicationType 8 underwater AIS message for transmission by the Popoto Modem. This AIS message has two contacts.

{
"ClassUserID": 2,
"ApplicationType": 8,
"MobilityFlag": 1,
"Schedule": 0,
"TxRxFlag": 1,
"ForwardingCapability": 0,
"Contacts": [
{
"UserID": "0",
"Type": "15 =n.a.",
"Latitude": "-89.999001",
"Longitude": "0",
"Depth": "0.000000",
"Speed": "0.000000",
"Heading": "180",
"NavigationalStatus": "15 = Undefined/default"
},
{
"UserID": "1073741823",
"Type": "9 = Bottom node",
"Latitude": "-89.6485",
"Longitude": "-0.351552",
"Depth": "0.000000",
"Speed": "0.000000",
"Heading": "180",
"NavigationalStatus": "0 = Under way, using engine"
}
]
}

Class User ID 016: NATO JANUS Reference

Refer to the NATO Janus Reference Implementation wiki page for a description of the application types and fields in the NATO Janus Reference Class ID.

This class is used for underwater chat applications or for transmission of other short messages. ApplicationType 0 does not include a CRC to ensure delivery, while ApplicationType 1 validates the message with a CRC16.

ApplicationType 0

{
"ClassUserID": 16,
"ApplicationType": 0,
"StationID": "4",
"MobilityFlag": "1",
"ForwardingCapability": "1",
"DestinationID": "0",
"ParameterSetID": "0",
"Payload_Size": "16",
"Payload": {
"Data": [49, 50, 51, 52, 53, 54, 55, 56, 57, 48, 49, 50, 51, 52, 53, 54]
}
}

ApplicationType 1

{
"ClassUserID": 16,
"ApplicationType": 1,
"StationID": "4",
"MobilityFlag": "1",
"ForwardingCapability": "1",
"TxRxFlag": "1",
"AckRequest": "1",
"DestinationID": "0",
"ParameterSetID": "0",
"Payload_Size": "16",
"Payload": {
"Data": [49, 50, 51, 52, 53, 54, 55, 56, 57, 48, 49, 50, 51, 52, 53, 54]
}
}