Skip to content

CruiserProject/Cruiser-Documentation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 

Repository files navigation

Cruiser-Documentation

Documentation for Cruiser Project.

Documentation maintainer: @hanzheteng

1. Introduction

The aim of Cruiser Project is to establish An Intelligent Aerial Security System.

Based on a Matrice 100 and the SDK from DJI, we developed an intelligent security guard system with utilitarian functions, including automatically flying along predetermined paths, identifying and categorizing objects, pedestrian tracking, etc. The onboard computer is responsible for real-time algorithms running on a robot operating system, and the ground station is mainly responsible for extra computing. The drone can be commanded by a mobile app, which is developed by our android engineers.

By the system we designed, the campus police could save their labor and surveil the campus in a more efficient and thorough way, providing a safer environment for students.

This project originated from a National-level College Students' Innovative Entrepreneurial Training Plan Program, and then also participated in the 15th Challenge Cup National College Students’ Extracurricular Academic Science and Technology Works Contest.

2. Repositories

Repositories Description ( Functions ) Platform Collaborators
OnboardROS
  • Movement control
  • Object detection and tracking
  • Autonomous landing by Hough circle detection
  • Executing command from mobile terminal
@Cuijie12358
@hanzheteng
@XiangqianMa
@ShoupingShan
GroundStation
  • Object detection and classification
  • Abnormal behavior detection
@finaldong
@ShoupingShan
MobileController
  • Autonomous cruising mission
  • Object detection and tracking
  • Android 5.1 or above
@TrafalgarZZZ
@hwding

3. CDT Protocol

Cruiser Data Transmission(CDT) Protocol.

3.1 Protocol Introduction

DJI Onboard SDK OPEN Protocol provide a method for communication between Mobile and Onboard device called Data Transparent Transmission.

Under this mechanism, we could send message to Autopilot first and Autopilot will transfer this message to Mobile or Onboard device.

CMD Frame
CMD SET CMD ID CMD VAL
( CDT DATA )

DJI Onboard SDK OPEN Protocol is only used between Onboard and Autopilot. With CMD SET 0x00 CMD ID 0xFE we could send message from Onboard to Mobile. With CMD SET 0x02 CMD ID 0x02 Onboard device could get message from Mobile.

So we define a new set of command and acknowledge messages within CMD VAL called Cruiser Data Transmission (CDT).

3.2 CDT Frame

CDT DATA
CDT SET CDT ID CDT VAL
Field Offset(byte) Size(byte)
CDT SET 0 1
CDT ID 1 1
CDT VAL 2 vary by CDTs

3.3 Function List

  • Data type : unsigned char[ ]
  • M-O : from Mobile to Onboard -- CDT ID is an odd number
  • O-M : from Onboard to Mobile -- CDT ID is an even number
  • CMD : command
  • ACK : acknowledge
 
CDT SET CDT ID CDT VAL
Size(byte)
Direction Description
0x00 --- --- --- --- ( reserved )
0x01

Visual Landing
0x01 --- M-O Start - CMD
0x02 --- O-M Start - ACK
0x03 --- M-O Stop visual detection - CMD
0x04 --- O-M Stop - ACK
0x06 --- O-M Land vertically
0x08 --- O-M Land successfully
0x42 2 + 2 O-M Delta X and Y position (meter)
( 2 bytes char instead of 1 float )
0x44 2 + 1 O-M Circle center and radius
( 1 point and 1 length )
0x02

Object Tracking
0x01 --- M-O Start - CMD
0x02 --- O-M Start - ACK
0x03 --- M-O Stop - CMD
0x04 --- O-M Stop - ACK
0x11 2 + 2 M-O Object position to be tracking
( 2 diagonal points of a rectangle )
0x12 --- O-M Position - ACK
0x42 2 + 2 O-M Delta X and Y position (meter)
( 2 bytes char instead of 1 float )
0x44 2 + 2 O-M Current position of object
( 2 diagonal points of a rectangle )

4. Robot Operating System

4.1 ROS Node Info

Node name Sub topic Pub topic Description Collaborators
dji-sdk/... ( many ) ( many )
/dji_sdk/local_position
Official SDK DJI
dji_sdk_read_cam --- /dji_sdk/image_raw
/dji_sdk/camera_info
Get camera image and publish DJI
mobile_msg /dji_sdk/data_received_from_remote_device
cruiser/landing_move
cruiser/tracking_move
cruiser/tracking_position_now
cruiser/landing_flag
cruiser/tracking_flag
cruiser/tracking_position
Read message from Mobile and pub @Cuijie12358
@hanzheteng
landing_alg_node /dji_sdk/image_raw
/dji_sdk/local_position
cruiser/landing_flag
cruiser/landing_move Hough circle detection @ShoupingShan
@XiangqianMa
landing_move_node /dji_sdk/local_position
cruiser/landing_move
--- Movement control @Cuijie12358
@hanzheteng
tracking_alg_node /dji_sdk/image_raw
/dji_sdk/local_position
cruiser/tracking_flag
cruiser/tracking_position
cruiser/tracking_move
cruiser/tracking_position_now
Object tracking algorithm @ShoupingShan
@XiangqianMa
tracking_move_node /dji_sdk/local_position
cruiser/tracking_flag
cruiser/tracking_move
--- Movement control @Cuijie12358
@hanzheteng

4.2 ROS Topic Format

Topic name Format Message file Description
dji-sdk/ ... ( many ) ( many ) Official SDK
cruiser/landing_flag bool flag Flag.msg Start or stop landing flag
cruiser/landing_move bool state
float32 delta_X_meter
float32 delta_Y_meter
DeltaPosition.msg Delta X and Y distance
in ground coordinate system
cruiser/tracking_flag bool flag Flag.msg Start or stop tracking flag
cruiser/tracking_move bool state
float32 delta_X_meter
float32 delta_Y_meter
DeltaPosition.msg Delta X and Y distance
in ground coordinate system
cruiser/tracking_position float32 a_width_percent
float32 a_height_percent
float32 b_width_percent
float32 b_height_percent
TrackingPosition.msg Two points on screen in percentage
cruiser/tracking_position_now float32 a_width_percent
float32 a_height_percent
float32 b_width_percent
float32 b_height_percent
TrackingPosition.msg Two points on screen in percentage

5. Update Log

Activate Error problem solving on DJI FORUM: http://forum.dev.dji.com/thread-26936-1-1.html (Please switch to Chinese forum first, otherwise the link would lead to another wrong page.)

Releases

No releases published

Packages

No packages published