virtualboolinit(boolinitCommAPI,AP_PeriodicProcess*scheduler,AP_Semaphore*spi_semaphore=NULL,AP_Semaphore*spi3_semaphore=NULL);// parameter controls whether I2C/SPI interface is initialised (set to false if other devices are on the I2C/SPI bus and have already initialised the interface)
virtualvoidupdate_position(floatroll,floatpitch,floatcos_yaw_x,floatsin_yaw_y,floataltitude);// updates internal lon and lat with estimation based on optical flow
staticAP_OpticalFlow*_sensor;// pointer to the last instantiated optical flow sensor. Will be turned into a table if we ever add support for more than one sensor
enumRotation_orientation;
floatconv_factor;// multiply this number by altitude and pixel change to get horizontal move (in same units as altitude)
floatradians_to_pixels;
float_last_roll,_last_pitch,_last_altitude;
virtualvoidapply_orientation_matrix();// rotate raw values to arrive at final x,y,dx and dy values