Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The radar acts as a TCP/IP server and therefore listens for connections once started. The server will support up to 3 concurrent client connections, therefore the first 3 clients attempting to connect will succeed, but subsequent attempts from other clients will fail. The radar supports a primary IP address and streams data over a single port, which, by default, is the IANA allocated port of TCP 6317. The IP addresses and the port are all configurable via the radar management software. Please refer to reference Vertex documentation for more information. Note that the radar TCP server maintains state on the client connections therefore message start / stop requests, such as FFT Data, are applied on a per client basis.

Typically there are 2 types of payloads;

  • Byte array representing a structure made up from standard C++ data types
  • Byte array representing a serialised Protocol Buffer message
  • Byte arrays that represent both of the above

For more information on Google Protocol Buffers please see reference [https://developers.google.com/protocol-buffers]. Navtech can provide Protobuf message files on request.

Info
All network data is sent in Network Order i.e. big-endian.

The Complete TCP Message Structure

Image Modified

The TCP Message Header

This is the first part of every message sent using this protocol. The header serves 2 purposes; the first is to provide a byte sequence for synchronisation purposes and secondly to provide information about the body of the message.

TCP Message Header Structure

Field

Type [Size]

Description

Signature

uint8_t [16]

Unique synchronisation byte sequence

Version

uint8_t [1]

Protocol version – indicates the revision of the protocol messages

Message Id

uint8_t [1]

Message type – indicates the type of the payload

Payload Size

uint32_t [4]

The size, in bytes, of the main body of the message



Panel
borderColorsilver
borderWidth1

On this page:

Table of Contents
maxLevel3
indent10px

TCP Message Types

Message NameMessage IdDirectionDescription
Configuration10From RadarSends all the radar configuration properties required to configure the client software to correctly receive data
Configuration Request20To RadarRequests a configuration message from the radar
Start FFT Data21To RadarInstructs the radar to start sending FFT data until told to stop
Stop FFT Data22To RadarInstructs the radar to stop sending FFT data
Start Health Msgs23To RadarInstructs the radar to start sending regular health messages until told to stop
Stop Health Msgs24To RadarInstructs the radar to stop sending health messages
Reset RF Health25To RadarInstructs the radar to reset RF Health check system
FFT Data30From RadarAn azimuth of raw radar data
High Precision FFT Data31From RadarAn azimuth of high precision radar data
Health40From RadarSends a radar health status message
Contour Update50To RadarEnables the client to update the contour map on the radar
System Restart76To RadarRequest system reboot
Logging Levels90To/From RadarA list of logging levels - v2 Hardware only
Logging Levels Request100To RadarRequest a list of logging levels - v2 Hardware only
Start Nav Data120To RadarRequest system to start sending navigation data
Stop Nav Data121To RadarRequest system to stop sending navigation data
Set Nav Threshold122To RadarSet navigation threshold
Navigation Data123From RadarNavigation data records
Set Nav Range Gain and Offset124To RadarSet navigation threshold
Calibrate Accelerometer125To RadarRadar will store current accelerometer value as flat
Start Accelerometer126To RadarStart receiving accelerometer data
Stop Accelerometer127To RadarStop receiving accelerometer data
Accelerometer Data128From RadarAccelerometer Data
Navigation Alarm Data143From RadarSafeGuard Lite Alarms
Navigation Area Rules144To RadarSafeGuard Lite Area Rules

Signature

The 16 byte signature differs very slightly from the older Navtech RMB protocol. This does enable existing software to differentiate between the two protocols if required.

The new signature is as follows:

The TCP Message Body

This payload will be variable length, the size being specified in the message header. The rest of this document describes the message types.

Configuration Message

The configuration message contains all the relevant information a client application needs to process raw data from the radar. The message provides all critical data in fixed length fields at the beginning of the message. These values are the minimum required in order to successfully configure a client. These fields can be accessed using the normal process of decoding a byte stream coming across the network. The remainder of the message is made up from a variable length Protocol Buffer message which contains additional information about the radar, such as serial numbers and service dates. Advanced customer applications would be expected to decode this message data however the information is optional.

The size of this message body is specified by the payload size field in the header. The size of the Protocol Buffer message can be calculated by subtracting the size of the fixed length fields from the payload size (i.e. Payload Size – 22 bytes). A configuration message is always sent when a client first connects and is also sent in response to a request from the client.

Configuration Message Structure

FieldType [Size]Description
Azimuth Samplesuint16_t [2]Number of azimuth samples taken per rotation
Bin Size / Resolutionuint16_t [2]The range resolution per bin. In tenths of millimetres. For example 0.2997m would be 2997.
Range In Binsuint16_t [2]Configured detection range, in bins
Encoder Sizeuint16_t [2]The total number of available steps on the encoder wheel
Rotation Speeduint16_t [2]The configured rotation speed for the radar. In milliHertz i.e. 2000 = 2 Hz
Packet Rateuint16_t [2]Expected packet rate based on sample time and rotation speed
Range Gainfloat [4]Gain applied to calculated ranges based on radar calibration
Range Offsetfloat [4]Fixed offset in metres, applied to calculated ranges based on radar calibration


Info

Floats transmitted over the network are IEEE 754 compatible values converted to 32 bit unsigned integers in network order. They will need to be reverted to host order and then cast back to floats on the client.

In C++ the radar converts floats using the following code snippet:

Code Block
languagecpp
themeMidnight
union v {
	float f;
	uint32_t i;
};
v value;
value.f = 186.4f;
uint32_t networkData = htonl(value.i);


Configuration Protocol Buffer Payload

FIeldType [Size]Description
ModelstringCustomer friendly model name
MAC AddressstringNetworking MAC Address
Service Dateuint32_t [4]The date the last service was completed
Software Version NumbersSoftwareVersion PB MessageCollection of software version numbers
NVRAM ContentsNVRAM PB MessageContents of NVRAM, including radar serial number
Range Resolution HzfloatResolution of each bin in Hz
Module Serial NumberstringProcessing Module Serial Number
Auto Tune Valueint16_t [2]Current Auto Tune Value
Radar Unique Idstring (Guid)Radar's Unique Id
Data Widthint321 for 8-bit 2 for 16-bit
Range Resolution MetresfloatRange of each bin in metres
Radar Feature Flaguint32Feature Flag bit field 1 = AutoTune, 2 = Secondary Processing Module Present
Staring Modeint32Boolean to represent staring mode enabled on radar
On-Board MAC AddressstringOn-Board Networking MAC Address - 00:00:00:00:00:00 indicates no module


Info
titleConverting Bins to Range (m)

This information can be used to calculate the range of the radar in metres and also when receiving FFT data the range of each bin can be calculated. The following algorithm should be used:

Range = Range In Bins * Range Resolution (m) i.e. 3768 * 0.175 = 659.4 m (This radar has a total range of 659.4 m)

Range of single bin = Bin Number * Range Resolution (m) i.e. 100 * 0.175 = 17.5 m (Bin 100 is 17.5 m from the radar)


Configuration Request Message

This message contains no body / payload. The message is sent just as a header. On receiving this
message the radar will respond by sending a single configuration message.

Start FFT Data Request Message

This message contains no body / payload. The message is sent just as a header. On receiving this
message the radar will respond by starting the raw radar data stream.

Stop FFT Data Request Message

This message contains no body / payload. The message is sent just as a header. On receiving this
message the radar will respond by stopping the raw radar data stream.

Start Health Message

This message contains no body / payload. The message is sent just as a header. On receiving this
message the radar will start sending regular health messages. By default the interval is every 5
seconds.

Stop Health Message

This message contains no body / payload. The message is sent just as a header. On receiving this
message the radar will stop sending regular health messages.

Reset RF Health Check System

This message contains no body / payload. The message is sent just as a header. On receiving this
message the radar will reset the long term health check system.

System Restart Message

This message contains no body / payload. The message is sent just as a header. On receiving this
message the radar will reboot.

Start Navigation Data Message

This message contains no body / payload. The message is sent just as a header. On receiving this
message the radar will start sending navigation data messages.

Stop Navigation Data Message

This message contains no body / payload. The message is sent just as a header. On receiving this
message the radar will stop sending navigation data messages.

Set Navigation Threshold

This message is used to set the threshold for the navigation system

Set Navigation Threshold Message Structure

FieldType [Size]Description
Thresholduint16_t [2]Threshold to use for navigation data this should be a value between 0 - 96.5 dB multiplied by 10 e.g 75.6dB is 756

Set Navigation Gain and Offset

This message is used to set a gain and offset that is used when by the onboard navigation system, this gain and offset are applied to the ranges found using the formula [(Target Range * Range Gain * Range Resolution) + Offset].

Set Navigation Gain and Offset Message Structure

FieldType [Size]Description
Gainuint32_t [4]Gain multiplied by 1000000
Offsetuint32_t [4]Offset multiplied by 1000000

FFT/High Precision Data Message

The FFT Data message contains all the necessary information to process the amplitude data for a specific azimuth. The packet consists of 4 fixed length fields and a variable length byte array of amplitude data. Each byte of amplitude data represents a range bin. The total number of reported range bins can varying per packet depending on the radar configuration. The size of this message body is specified by the payload size field in the header. The FTT Data length can be calculated by subtracting the fixed length field sizes from the overall payload size (i.e. Payload Size – 14 bytes). FFT Data messages need to be switched on before they are sent. Once activated, FFT Data messages will be sent continuously for each sampled azimuth. FFT data will continue to be sent until the radar receives a message to stop. Clients should honour this mechanism and, where possible, send the radar a stop message before disconnecting.

FFT/High Precision Data Message Structure

FieldType [Size]Description
FFT Data Offsetuint16_t [2]The offset from the start of the payload where the FTT data starts. In this version the value will be 14 – the FFT starts at the 15th byte
Sweep Counteruint16_t [2]A counter that increments on each packet sent from the radar. The value will rollover once the maximum type size has been reached
Azimuthuint16_t [2]The azimuth at which this sample of FFT data was taken
Secondsuint32_t [4]Total number of seconds since the synchronised Epoch
Split Secondsuint32_t [4]Part seconds. This value rolls over each second
FFT Datauint8_t [n]Variable length byte array of amplitude data per range bin (If high precision then two bytes represent one bin)


Info
titleAzimuth to Bearing Algorithm

To convert from an azimuth to bearing you can use the following algorithm, utilising information from the configuration message:

Bearing = (Azimuth / Encoder Size) * 360 i.e. (2800 / 5600) * 360 = 180°

This bearing is relative to the Zero/North point of the radar, for CDR/CIR radars this is a line perpendicular to the flat part of the base.

For HDR units this point is the line running from the rear hole to the middle hole of the three on the base of the radar.

Navigation Data Message

The Navigation Data message contains the targets found for an azimuth that were above the threshold. The packet consists of 3 fixed length fields and a variable length byte array containing target information. The size of this message body is specified by the payload size field in the header. The Navigation Pairs Data length can be calculated by subtracting the fixed length field sizes from the overall payload size (i.e. Payload Size – 10 bytes).  Navigation Data messages need to be switched on before they are sent. Once activated, Navigation Data messages will be sent continuously for each sampled azimuth. Navigation data will continue to be sent until the radar receives a message to stop. Clients should honour this mechanism and, where possible, send the radar a stop message before disconnecting.

Navigation Data Message Structure

FieldType [Size]Description
Azimuthuint16_t [2]The azimuth at which this sample of data was taken
Secondsuint32_t [4]Total number of seconds since the synchronised Epoch
Split Secondsuint32_t [4]Part seconds. This value rolls over each second
Navigation Data Pairsuint8_t [n]Pairs of ranges and powers representing targets

FieldType [Size]Description
Rangeuint32_t [4]Range in metres multiplied by 1000000
Poweruint16_t [2]Power of target dB multiplied by 10 e.g 75.6dB is 756

Health Message

The health message includes critical health information about the radar. The payload consists of a number of health status structures, each one provides data on a specific metric, for example temperature, and includes details on the current measurement and whether the metric is within expected bounds or not. The health message payload is a Protocol Buffer serialised byte array. In order to de-serialise the message the client will need to use the Google library as described in reference [2]. Metrics may be added or changed within the content of the Protocol Buffer message. This would not result in a new protocol version for this message. Client applications consuming this message will need the latest Protobuf definition file from Navtech. These are available on request. Health messages need to be switched on before they are transmitted. Once active, health messages will be sent every 5 seconds. Messages will continue to be sent until the radar receives a message to stop. Clients should honour this mechanism and, where possible, send the radar a stop message before disconnecting.

FieldType [Size]Description
TemperatureHealthInfo PB MessageTemperature health information including current operating temperature
RotationHealthInfo PB MessageRotation health information including current speed
Packet RateHealthInfo PB MessageNetwork health information including current packet rate
RF Health CheckHealthInfo PB MessageRF health information including current noise deviation from the norm
Motor CurrentHealthInfo PB MessageMotor health information including current draw

Contour Update Message

The Contour Update message controls the contour mode and contour map. The contour map is held on the radar and provides a mechanism to restrict the radar detection area. The map consists of a variable range per degree (i.e. 360). When a contour map is active, data is sent out from the radar for each degree up to the range specified. If the range is zero then no data is sent for that bearing. If the contour map is disabled or in its default configuration then the full range of data is sent for every azimuth (i.e. all data). There is also a test mode which can be set on the radar – this activates a pre-configured map which exhibits a distinctive data pattern. To disable the contour map the client should send an empty update message (just header). This will leave the contour configuration intact but tell the radar to stop using it. Alternatively the client can send a full contour map, in other words a maximum range value for each azimuth. This will have the same effect. The contour map, once active, restricts the amount of data sent over the network. The more restrictive the contour map, the less data that is sent.

Contour Update Message Structure

Log Levels Get/Set Messages

The log levels get and get messages enable a user to get the logging levels and set the logging levels of the radar software. The LoggingLevelRequest message is an empty payload message, the radar will respond with a LoggingLevel message that contains a Protocol Buffer object which is a list of Log Levels. The get log levels payload is a Protocol Buffer serialised byte array. In order to de-serialise the message the client will need to use the Google library as described in reference [https://developers.google.com/protocol-buffers].

Warning
Version 2 Hardware Only

Log Levels Structure

Log Levels Buffer Payload

FieldType [Size]Description
ItemsList of LogLevel PB MessagesA list of Log Level Items

Calibrate Accelerometer Message

This message contains no body / payload. The message is sent just as a header. On receiving this
message the radar will start start the calibration process and store the values in the NVRAM.

Start Accelerometer Data Message

This message contains no body / payload. The message is sent just as a header. On receiving this
message the radar will start sending accelerometer data messages.

Stop Accelerometer Data Message

This message contains no body / payload. The message is sent just as a header. On receiving this
message the radar will start sending accelerometer data messages.

Accelerometer Data Message

This message contains the three angles representing the tilt of the radar, Θ (theta), Ψ (psi) and ɸ (phi).

Accelerometer Data Message Structure

FieldType [Size]Description
Θ (theta)float [4]Angle around axis running perpendicular to zero/north - +ve Tilted Forward, -ve Tilted Backward
Ψ (psi)float [4]Angle around axis running from base to stop of radome
ɸ (phi)float [4]Angle around axis running through radar zero/north - +ve Tilted Right, -ve Tilted Left

Navigation Alarm Data

This messages contains the six alarm states of the SafeGuard Lite feature

FieldType [Size]Description
Alarm Statesuint8_t[6]Each byte represents the alarm state of an areas so state[4] is the fifth alarms sate a value of 1 means alarm in area, 0 means no alarm 

Navigation Area Rules

This message configures the SafeGuard Lite feature with up to six areas that can cause an alarm state if a target is detected above the area threshold inside the area


Code Block
languagec#
titleC# Example of how to encode rules
public static class Utility
{
	public static uint SwapUInt32(uint value)
	{
		return (uint)((SwapUInt16((ushort)((value & 0x000ffff))) << 0x10)) | (SwapUInt16((ushort)((value >> 0x10) & 0xffff)));
	}

	public static ushort SwapUInt16(ushort value)
	{
		return (ushort)(((value & 0xff) << 8) | ((value >> 8) & 0xff));
	}
}

public class NavVector
{
	public NavVector() { }

	public NavVector(float x, float y)
	{
		X = x;
		Y = y;
	}

	public float X { get; set; }
	public float Y { get; set; }

	public byte[] ToBytes()
	{
		var x = (short)(X * 10.0f);
		var y = (short)(Y * 10.0f);
		var data = (uint)(x << 16) | (uint)y;
		return BitConverter.GetBytes(Utility.SwapUInt32(data));
	}
}

public class NavArea
{
	public NavArea()
	{
		Points = new List<NavVector>();
	}

	public List<NavVector> Points { get; set; }

	public byte[] ToBytes()
	{
		var data = new List<byte>();
		data.AddRange(BitConverter.GetBytes(Utility.SwapUInt16((ushort)Points.Count)));
		Points.ForEach(point => { data.AddRange(point.ToBytes()); });
		return data.ToArray();
	}
}

public class NavAreaRule
{
	public NavAreaRule()
	{
		Enabled = true;
		InvertBreakLogic = false;
		ThresholdDelta = 0.0f;
		BreakAllowance = 16;
		AllowanceCurveDecrement = 4;
		AreaToCheck = new NavArea();
	}

	public byte Id { get; set; }
	public bool Enabled { get; set; }
	public bool InvertBreakLogic { get; set; }
	public float ThresholdDelta { get; set; }
	public ushort BreakAllowance { get; set; }
	public ushort AllowanceCurveDecrement { get; set; }
	public NavArea AreaToCheck { get; set; }

	public byte[] ToBytes()
	{
		var ruleData = new List<byte> { Id, Enabled ? (byte)1 : (byte)0, InvertBreakLogic ? (byte)1 : (byte)0 };
		ruleData.AddRange(BitConverter.GetBytes(Utility.SwapUInt16((ushort)(ThresholdDelta * 10.0f))));
		ruleData.AddRange(BitConverter.GetBytes(Utility.SwapUInt16(BreakAllowance)));
		ruleData.AddRange(BitConverter.GetBytes(Utility.SwapUInt16(AllowanceCurveDecrement)));
		ruleData.AddRange(AreaToCheck.ToBytes());
		var data = new List<byte>();
		data.AddRange(BitConverter.GetBytes(Utility.SwapUInt32((uint)ruleData.Count)));
		data.AddRange(ruleData);
		return data.ToArray();
	}
}

public class NavUpdateAreaRules
{
	public NavUpdateAreaRules()
	{
		Rules = new List<NavAreaRule>();
	}

	public List<NavAreaRule> Rules { get; set; }

	public byte[] ToBytes()
	{
		var data = new List<byte> { (byte)Rules.Count };
		Rules.ForEach(rule => { data.AddRange(rule.ToBytes()); });
		return data.ToArray();
	}
}


Related information

Filter by label (Content by label)
showLabelsfalse
cqllabel in ( "colossus" , "vertex" )