Servers by jDrones

Hereflow sensor with UAVCAN, optical flow not recognized


We connected the Hereflow to the Pixhawk4Mini and used Qgroundcontrol to flash it with Arducopter 4.0.0. Afterwards we proceeded with setting up the parameters as instructed in and connected the HereFlow using CAN.

After rebooting, when opening the MAVLink Inspector and selecting OPTICAL_FLOW, it displays a refresh rate of 0 Hz, a count of 0 and no values. Unfortunately, we have found no way of getting a response from the optical flow of the sensor.

We actually did get a response from the range sensor, it seems to work precisely. We found it under DISTANCE_SENSOR.current_distance.

Do you have an idea of how to proceed to get the optical flow data?

Any help would be greatly appreciated :slight_smile:

did you set flow_type=6 and you can driver to 1?

Give it a look to this link

Hi, thank you for the quick answer!

Yes, we set those two. As described in, we set these:

CAN_P1_DRIVER= 1 to enable UAVCAN
RNGFND1_MAX_CM = 300 to set range finder’s maximum range to 3m

Is there more parameters that are relevant?

We’ve found an issue in Copter-4.0.0 in which it wasn’t sending the optical flow messages unless the EKF had a height estimate which makes testing more difficult. Could you try with Copter-4.0.1-rc2 (the latest beta)?

If that doesn’t work then it would be good to provide a log file.

By the way, I’ve found that the HereFlow range finder performs very poorly. I think it will be difficult to get good performance unless a longer range and more reliable range finder is used. I might update the wiki to mention this.

1 Like

Hi, thank you for the quick answer!

Perhaps that is the problem then. We did get some readings from the range sensor, do you know how to make that propagate to the EKF height estimate?

I can try with Copter-4.0.1-rc2 next time I am in the lab. This may be a noob question, but do you know how to do it? In Qgroundcontrol only Copter-4.0.0 was listed.

I guess we can expect superior performance from something that cheap, small and lightweight. We will only be using it indoors, so we don’t have very high demands from it. Still, we have a terraranger unit we can use in addition.

1 Like


I’m afraid that I’m not sure how to load beta firmwares using QGC although I think it is possible. It’s also possible to directly download the firmware to your PC from but you’ll need to find the correct directory that matches the board you’re using. Also I’m not sure how to upload a custom firmware using QGC but again I suspect it’s possible.

Hi again,

I tried to flash the beta version(4.0.1-rc2). There was a option in the Qgroundcontrol interface, so that was easy.

I get the error Check BRD_TYPE: Failed to update IO firmware. In the interface to set BRD_TYPE, I could not find Pixhawk4Mini(which we are using). There were not even an option for Pixhawk4.

Without setting more parameters, I could not monitor the sensor values, so I do not yet know if it works. I will have a look at it in the weekend, when I have more time.

1 Like

After some playing around with the different firmwares, I got it to work. Now we can read changes in the mavlink messages related to optical flow in the Qgroundcontrol monitor. We have not done a flight test yet, but at leas the sensor driver seems to work.

Thank you very much!


what parameters/firmware did you use to get the hereflow working on the pixhawk 4 mini? im trying to get the hereflow working on it and cant seem to get any values from it. Ive changed all the parameters above but still nothing.

I think it worked with the parameters above when we finally got v4.0.1-rc2 properly installed. We have changed some other parameters too, but I can try to send you a dump of the ones we have at the moment when I get to the lab.

Here is a dump of our current settings. Most of them is not relevant, but you can try to search in the file for the ones you want to know about. Unfortuanetley, I do not remember which that deviates from the default settings. phmini30.1.param (28.6 KB) Does this help?


It’s important to use Copter-4.0.1 in order to see the flow sensor values in the ground station. There was an issue in Copter-4.0.0 where it wouldn’t send the values unless the vehicle had a good position estimate which is often not the case when you’re setting up a vehicle.

1 Like

Hello, I was able to get it working just using the parameters given for the hereflow in its manual and also using the copter - 4.0.1 firmware. Just to confirm for others using this.

Servers by jDrones