💡 Read the Service Disclaimer before using the API.
The Deep Trekker BRIDGE API is a programming interface developed to enable external development with Deep Trekker systems. This API enables integration of Deep Trekker’s vehicle systems into various applications, facilitating real-time access to data and control. It supports multiple connection methods and offers detailed schemas for consistent and reliable data transfer.
This documentation describes the core types, schemas, enumerations, and construct definitions used by client-side applications and server side devices to communicate with one another. Furthermore, it also describes the various supported connection methods and means of communicating data. Altogether, this forms the entirety of the Deep Trekker API.
The JSON-based API data is inherently agnostic, allowing any communication protocol to convey Deep Trekker API data. However, Deep Trekker supports two specific connectivity methods that are officially compatible with its vehicles, controllers, and peripheral devices. These supported methods ensure seamless and reliable integration, facilitating efficient control and data exchange across the Deep Trekker ecosystem.
The most accessible connection method to the system is through the use of a TCP socket connection. This connection has no additional handshaking requirements and can be accessed via port 5005 on any of the supported hardware devices.
Simply establish a TCP connection to <device_ip_address>:5005.
Once the connection is made data will start to be received.
A WebRTC connection interface is also available, incorporating video transport, encrypted connections, and handshaking for over-the-internet control. This interface is more complex and requires significantly more development effort and expertise to utilize. If you have specific requirements necessitating a WebRTC connection, please contact support@deeptrekker.com for additional information.
The standard Deep Trekker hand controller supports the Direct Socket Connection to data readout and no vehicle control.
The BRIDGE Box and BRIDGE Box enabled products (such as Powered Reels and Consoles) have full support for the API.
All API data is transacted through the TransferPayload object. This object contains the schema payload, as well as the method type and error flagging.
Transfer payloads can use 4 different method types, as well as an error flag:
Methods
Errors
All payload data is required to satisfy the JSON schema detailed in this documentation.
Below is sample schema of the Deep Trekker REVOLUTION, detailed information about all supported devices and attributes can be found documented in this site.
From ./dist/samples/json/states/revolutionRandomState.json
{
"$schema": "https://docs.api.deeptrekker.com/dist/schemas/schema.json",
"devices": {
"81941A17B4E9": {
"model": 13,
"leftBattery": {
"percent": 11,
"voltage": 100,
"charging": false,
"leak": false
},
"rightBattery": {
"percent": 2,
"voltage": 100,
"charging": true,
"leak": true
},
"bodyLeak": true,
"sensorPod": {
"imu": {
"gyroBias": {
"x": -723,
"y": -522,
"z": 254
},
"accelerationBias": {
"x": -428,
"y": -546,
"z": 788
},
"state": 0
},
"magnetic": {
"calibrationScore": 0,
"currentVehicleScore": 100,
"state": 0
},
"model": 101
},
"cameras": {
"179AFB2DFE81": {
"model": 240,
"brightness": 48,
"exposure": {
"auto": false,
"value": 15
},
"focus": {
"auto": false,
"value": 39,
"rate": 0
},
"ip": "192.168.73.10",
"saturation": 89,
"sharpness": 58,
"streams": {
"3FBC99C06049": {
"active": true,
"resolution": {
"width": 57,
"height": 53
}
}
},
"osd": {
"enabled": false
},
"zoom": {
"ratio": 111,
"speed": -13
},
"type": "MAIN",
"version": {
"hardware": "2",
"software": "3.0"
}
}
},
"cameraHead": {
"model": 102,
"lasers": {
"enabled": true
},
"leak": false,
"light": {
"intensity": 38
},
"tilt": {
"position": -12,
"speed": 50
},
"tiltMotorDiagnostics": {
"current": 26,
"pwm": 94,
"overcurrent": false,
"rpm": 5
},
"cpuTemp": 41,
"usageTime": {
"currentSeconds": 66,
"totalSeconds": 41
}
},
"depth": 250,
"altitude": 241,
"rearLeftMotorDiagnostics": {
"current": 39,
"overcurrent": true,
"pwm": 11,
"rpm": 50,
"failure": false
},
"rearRightMotorDiagnostics": {
"current": 88,
"overcurrent": false,
"pwm": 9,
"rpm": -27,
"failure": false
},
"frontLeftMotorDiagnostics": {
"current": 33,
"overcurrent": true,
"pwm": 18,
"rpm": -40,
"failure": false
},
"frontRightMotorDiagnostics": {
"current": 46,
"overcurrent": true,
"pwm": 78,
"rpm": -80,
"failure": false
},
"verticalLeftMotorDiagnostics": {
"current": 38,
"overcurrent": false,
"pwm": 36,
"rpm": -45,
"failure": false
},
"verticalRightMotorDiagnostics": {
"current": 100,
"overcurrent": false,
"pwm": 61,
"rpm": -76,
"failure": false
},
"drive": {
"thrust": {
"forward": 29,
"yaw": -34,
"vertical": 8,
"lateral": 19
},
"modes": {
"headingLock": true,
"altitudeLock": true,
"depthLock": true,
"autoStabilization": false,
"motorsDisabled": false
}
},
"auxLight": {
"intensity": 94
},
"grabber": {
"rotate": 73,
"openClose": -84,
"openCloseMotorDiagnostics": {
"current": 42,
"overcurrent": true,
"pwm": 2,
"rpm": -76,
"failure": false
},
"rotateMotorDiagnostics": {
"current": 24,
"overcurrent": true,
"pwm": 20,
"rpm": 78,
"failure": false
}
},
"heading": 349,
"inWater": true,
"ip": "192.168.54.206",
"pitch": 86,
"position": {
"local": {
"northing": 12,
"easting": -673,
"uncertainty": 30
},
"global": {
"latitude": -33,
"longitude": -56,
"uncertainty": 5
}
},
"roll": 22,
"sensorPodLeak": true,
"cpuTemp": 37,
"waterTemp": 49,
"turns": 10,
"usageTime": {
"totalSeconds": 47,
"currentSeconds": 72
},
"velocity": {
"valid": false,
"forward": -83,
"rightward": 6,
"downward": 16,
"speed": 4
},
"version": {
"hardware": "1",
"software": "2.2"
}
}
},
"networkDiagnostics": {
"01AB23CD4567": {
"interfaceName": "ETH0",
"physicalLocation": "LOC",
"networkRole": "CCO",
"terminalEndpointIdentifier": "001",
"bridgedDestinationAddress": "1234567890AB",
"outboundRate": "120",
"inboundRate": "130",
"chipset": "Broadcom BCM56850",
"firmwareVersion": "3.5.1"
},
"89EF12AB3456": {
"interfaceName": "ETH1",
"physicalLocation": "REM",
"networkRole": "STA",
"terminalEndpointIdentifier": "002",
"bridgedDestinationAddress": "ABCDEF123456",
"outboundRate": "125",
"inboundRate": "115",
"chipset": "Intel I350",
"firmwareVersion": "2.1.0"
},
"23CD45EF6789": {
"interfaceName": "ETH2",
"physicalLocation": "LOC",
"networkRole": "STA",
"terminalEndpointIdentifier": "003",
"bridgedDestinationAddress": "DEADBEEF1234",
"outboundRate": "130",
"inboundRate": "120",
"chipset": "Broadcom BCM56840",
"firmwareVersion": "4.2.2"
}
}
}
The Deep Trekker API ("our API library") is provided as is, without warranty of any kind, either express or implied, including but not limited to the implied warranties of merchantability and fitness for a particular purpose. We make no representations or warranties that the API library will meet your requirements or that its operation will be uninterrupted or error-free. We will not be liable for any damages of any kind arising from the use of the API library, including but not limited to direct, indirect, incidental, punitive, and consequential damages.
We do not provide technical support for integrating our API library into your software application. While we strive to make our API library easy to use and provide documentation and sample code, it is your responsibility to ensure that your software is compatible with our API library and that the integration is implemented correctly. We will not be liable for any issues or errors that arise from the integration of our API library into your software application.