Article directory
25.7.2 Connecting to the autopilot
25.7.3 Additional instructions
Preface
ARK Flow Open Source Optical Flow and Distance Sensor is an open source optical flow sensor that includes a Broadcom AFBR lidar and uses the CAN protocol to communicate with the autopilot . This can be used to improve horizontal position control, especially in environments without GPS .
25.7.1 Where to buy
The sensor is available from ARK Electronics .
25.7.2 Connecting to the autopilot
1. ARK Flow uses Pixhawk standard 4 -pin JST GH debug cable to connect to the CAN bus.
2. Insert other sensors intosecond CAN interface of ARK Flow to connect multiple sensors.
3. The recommended installation direction is that the connector on the circuit board faces the rear of the aircraft, as shown in the figure below.
4. Connect the sensor to the CAN port of the autopilot .
5. Set FLOW_TYPE = 6 ( DroneCAN ).
6. Set CAN_P1_DRIVER = 1 to enable DroneCAN .
7.Set CAN_D1_PROTOCOL =1( DroneCAN ) .
Using airborne lidar:
1. Set RNGFND1_TYPE = 24 ( DroneCAN ).
2. Set RNGFND1_MAX_CM = 3000 and set the maximum ranging range of the rangefinder to 30m .
25.7.3 Additional instructions
FlowHold does not require the use of a rangefinder.
Performance can be improved by setting sensors position parameters . For example, if the sensor is mounted 2cm forward and 5cm down from the center of rotation of the frame , set FLOW_POS_X to 0.02 and FLOW_POS_Z to 0.05 .
25.7.4 Testing and Setup
See Optical Flow Sensor Testing and Setup .
25.7.5 Parameter description
1. FLOW_TYPE : Optical flow sensor type
NOTE: A reboot is required after making the change.
Values |
||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
2. CAN_P1_DRIVER :Virtual driver index used with the physical CAN interface
NOTE: A reboot is required after making the change.
Enable this option to use the CAN bus.
Values |
||||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
3. CAN_D1_PROTOCOL : Enable specific protocols on the virtual driver
Note: This parameter is for advanced users.
Note: A restart is required after making changes.
Enable this option to launch the selected protocol that will use this virtual driver.
Values |
||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
4. RNGFND1_TYPE : Rangefinder type
Type of connected rangefinder.
Values |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
5. RNGFND1_MAX_CM : Maximum distance of rangefinder
The maximum distance (in centimeters) that a rangefinder can reliably read.
Increment |
Units |
---|---|
1 |
centimeters |