My libraries are in the right place, and I've tried compiling the sketch with both the Arduino 1.0 relaxed as well as the Arduino 0.22 relaxed version. Arduino Mega2560 selected.
Reference from the sketch:
Example of AP_OpticalFlow library.
Code by Randy Mackay. DIYDrones.com
#include <AP_Math.h> // ArduPilot Mega Vector/Matrix math Library
#include <SPI.h> // Arduino SPI library
#include <AP_DCM.h> // ArduCopter DCM Library
#include "AP_OpticalFlow.h" // ArduCopter OpticalFlow Library
I downloaded ArduPilotMega1.02.zip for the libraries, and got AP_DCM from the repository.
Error messages are all from following libs:
I'd appreciate a pointer to where I'm flying off course!
My guess is that there's an issue with how the sensor is connected to the APM...
I'm really not sure what's wrong. Maybe you're using a sensor with the pins in a different order from the 3dr optical flow sensor.
You know I wrote the code, I wrote the wiki page, I tried it out myself just two days ago to ensure it all worked including reading the image back from the sensor..not sure what else I can do.
Ok, so the jDrones one has a different pin ordering. That's likely the problem.
The new PX4Flow sensor from 3DR is not compatible with arducopter yet. I hope we will add support for it in AC3.2 but that's a few months from now.
It's best to provide logs or it's all guess work I'm afraid.
I have same problem. My have setup everything and grabbed image from python but the of_loiter mode doesn't performs good and even though I have enabled NTUN for data log its not saving that in Log file...?
Could anyone help with connection pinout and working example of Optical flow with any arduino (mini, nano, mega).