The front camera is an OmniVision ov7725 and the datasheet is available on the web.

The bottom camera is a “cresyn qcif”, I could not find further information for this camera.

You can download a on-board c program (source+binary) to convert the drone into a giant optical mouse. Hold the drone at a fix distance above ground and the program will report the movement in the horizontal plane.

i2c bus

The cameras are configured via the i2c bus. The front camera is on /dev/i2c-1 address 0×21, the bottom camera is on /dev/i2c-0 address 0x5d.

Bottom Camera Initialization

i2cset -y 0 0x49 0x0a 0x85     - sets Vdd4 to 3.0V
gpio 59 -d ho 1                - set CE enabled

After this the camara is visible on /dev/i2c-0 address 0x5d. Now send configuration via i2c. The configuration sent over the i2c bus can be extracted from a “strace” of program.elf, but I did not dig furter into this.

Front Camera Initialization

gpio 101 -d ho 0      - set PWDN_H 1=power down,0=active
gpio 109 -d ho 1      - set CE_H 1=enabled,0=not enabled

However: This still does not make the camera visible on the i2c bus. Running program.elf does make it visible on the bus, after which “gpio 101 -d ho 1″, “gpio 101 -d i”,  ”gpio 109 -d ho 0″, or “gpio 109 -d i” will make it disappear from the i2c bus.

This blog page is dedicated to the GPIOs of the AR Drone. You can download a custom GPIO driver here.

nr I/O Description
 29 O ??? disable NAND flash write protection on P6 dev 1=disable write prot (FC6050 Parrot platform) fc6050.c
 34 O ??? disable NAND flash write protection on P6 dev 1=disable write prot
 43 O ??? Reset_Wlan 1=reset
 59 O Camera1 (Facing Down) CE 1=enabled,0=not enabled
 63 O Red LED 0=off,1=on
 64 O Green LED 0=off,1=on
 68 O Motor1 /Select 0=selected,1=deselected
 69 O Motor2 /Select 0=selected,1=deselected
 70 O Motor3 /Select 0=selected,1=deselected
 71 O Motor4 /Select 0=selected,1=deselected
 89 ? ??? CAM0_VSYNC
101 O Camera0 (Horizontal) PWDN_H 1=power down,0=active
106 I Motor Cutout
107 O Motor Enable 1=Enable
108 I Reset Button 0=unpressed,1=pressed
109 O Camera0 (Horizontal) CE_H 1=enabled,0=not enabled
127 O USB Connector Pin1 - Vusb
130 O Navboard Connector Pin2 - PGED2
131 O Navboard Connector Pin4 - PGEC2
132 O Navboard Connector Pin6 - /MCLR
158 I Pair Button 0=unpressed,1=pressed

Extension Port Pinout

Pin1 Vusb +5V (USB red)
Pin2 Vbat +11.7
Pin3 USB D- (USB white)
Pin4 RX (Serial data input to Drone)
Pin5 USB D+ (USB green)
Pin6 TX (Serial data output from Drone)
Pin7 GRD (USB black)
Pin8 No Pin

This blog page is dedicated to the I2C components of the AR Drone. You can download a custom i2c driver for the voltage measurements of the PMAAC here.


0×49 Atmel AT73C246 Power Management and Analog Companions (PMAAC)
0×50 24C32WI eeprom
0x5d Bottom camera


 0×21 Horizontal Camera – OmniVision ov7725


This blog page is dedicated to the NavBoard of the AR Drone.

You can download an on-drone c program (source+compiled) to convert raw NavData into physical angle, rotation rate, height and temperature values.

Navboard Init

The following script  starts the navigation board data stream without first starting & killing program.elf. The script has been tested on an AR.Drone with firmware 1.7.4 and 1.3.3 and navboard hardware version 0xc0. I.e. the reply to command 15 is 0xc0.

The stty command sets up the serial port. The gpio command switches the /RESET pin of the navboard to high, and the echo command instructs the navboard to start the data stream. 

stty -F /dev/ttyPA2 460800 -parenb -parodd cs8 -hupcl -cstopb cread clocal -crtscts -ignbrk -brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr -icrnl -ixon -ixoff -iuclc -ixany -imaxbel -opost -olcuc -ocrnl onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0 -isig -icanon -iexten -echo echoe echok -echonl -noflsh -xcase -tostop -echoprt echoctl echoke
gpio 132 -d ho 1
echo -en "\x01" > /dev/ttyPA2

After this initialization the following command gets a navboard data packet:

dd if=/dev/ttyPA2 count=1 bs=46 | hexdump -C

Navboard Data Packet

After the navboard has been initialized and acquisition has been started, it sends a 46 byte data frame every 5ms (200Hz) over serial port /dev/ttyPA2. The structure of a data frame is:

 u16 size;                // +0x00 Size of the following data (always 0x2C)
 u16 seq;                 // +0x02 Sequence number, increases every update
 u16 acc[3];              // +0x04 Raw data (10-bit) of the accelerometers multiplied by 4
 u16 gyro[3];             // +0x0A Raw data for the gyros, 12-bit A/D converted voltage of the gyros. X,Y=IDG, Z=Epson 
 u16 gyro_110[2];         // +0x10 4.5x Raw data (IDG), gyro values with another resolution (see IDG-500 datasheet) 
 u16 acc_temp;            // +0x14 Accs temperature -- startup value 120 @ 25C, rising to 143
 u16 gyro_temp;           // +0x16 XYGyro temperature (IDG), 12-bit A/D converted voltage of IDG's temperature sensor -- startup value 1532 @ 25C, rising to 1572
 u16 vrefEpson;           // +0x18 ZGyro v_ref (Epson), 12-bit A/D converted reference voltage of the Epson sensor 
 u16 vrefIDG;             // +0x1A XYGyro v_ref (IDG), 12-bit A/D converted reference voltage of the IDG sensor  
 u16 us_echo;             // +0x1C bit15=1 echo pulse transmitted, bit14-0 first echo. Value 30 = 1cm. min value: 784 = 26cm
 u16 checksum;            // +0x1E Checksum = sum of all values except checksum (22 values)
 u16 us_echo_start;       // +0x20 Array with starts of echos (8 array values @ 25Hz, 9 values @ 22.22Hz)
 u16 us_echo_end;         // +0x22 Array with ends of echos   (8 array values @ 25Hz, 9 values @ 22.22Hz)
 u16 us_association_echo; // +0x24 Ultrasonic parameter -- maybe echo number starting with 0. max value 3758. examples: 0,1,2,3,4,5,6,7  ; 0,1,2,3,4,86,6,9
 u16 us_distance_echo;    // +0x26 Ultrasonic parameter -- no clear pattern
 u16 us_courbe_temps;     // +0x28 Ultrasonic parameter -- counts up from 0 to approx 24346 in 192 sample cycles of which 12 cylces have value 0
 u16 us_courbe_valeur;    // +0x2A Ultrasonic parameter -- value between 0 and 4000, no clear pattern. 192 sample cycles of which 12 cylces have value 0
 u16 us_courbe_ref;       // +0x2C Ultrasonic parameter -- coutns down from 4000 to 0 in 192 sample cycles of which 12 cylces have value 0

Navboard Commands

The following lists the commands that can be sent to the navboard. The list is obtained from ARDrone_SDK_Version_1_7_20110525\ARDroneLib\Soft\Common\ardrone_common_config.h

ADC_CMD_STARTACQ                = 1,  /**command to start acquisition with ADC                             **/
ADC_CMD_STOPACQ                 = 2,  /**command to stop acquisition with ADC                              **/
ADC_CMD_RESYNC                  = 3,  /**command to resync acquisition with ADC                            **/
ADC_CMD_TEST                    = 4,  /**command to ADC send a test frame (123456)                         **/
ADC_CMD_VERSION                 = 5,  /**command to ADC send his number : version (MSB) subversion (LSB) **/
   Example: reply to cmd 5 is 0x37 00 04 00 <--> version 4.37
ADC_CMD_SELECT_ULTRASOUND_22Hz  = 7,  /**set the ultrasound at 22,22Hz                                      **/
ADC_CMD_SELECT_ULTRASOUND_25Hz  = 8,  /**set the ultrasound at 25Hz                                         **/
ADC_CMD_SEND_CALIBRE            = 13, /**command to ADC to send the calibration                             **/
ADC_CMD_RECEVED_CALIBRE         = 14, /**command to ADC to receved a new calibration                        **/
ADC_CMD_GET_HARD_VERSION        = 15, /**get the hard version of the navboard                               **/
   Example: reply to cmd 15 is 0xc0 <--> version 11.0
ADC_CMD_ACTIVE_SEPARATION       = 16, /**enabled the separation of sources ultrasound                       **/
ADC_CMD_STOP_SEPARATION         = 17, /**disables the ultrasound source separation                          **/
ADC_CMD_RECEVED_PROD            = 18, /**command to ADC to receved the prod data                            **/
ADC_CMD_SEND_PROD               = 19, /**command to ADC to send the prod data                               **/
ADC_CMD_ACTIVE_ETALONAGE        = 20, /**command to ADC to send PWM ultrasond in continue                   **/
ADC_CMD_ACTIVE_ULTRASON         = 21, /**command to ADC to stop send PWM ultrasond in continue              **/
ADC_CMD_ACTIVE_TEST_ULTRASON    = 22, /**teste de la perturbation de l'ultrason par le wifi                 **/

Navboard Connector Pinout

1 : +Vcc (5v)
2 : PGED2/RP10(1)/CN16/PMD2/RB10 (8) (ICSP)  <--> GPIO 130
3 : Txd (to Navboard)
4 : PGEC2/RP11(1)/CN15/PMD1/RB11 (9) (ICSP)  <--> GPIO 131
5 : Rxd (from Navboard)
6 : /MCLEAR (18)                             <--> GPIO 132
7 : GND
8 : GND


© 2015 Tech Toy Hacks Suffusion theme by Sayontan Sinha