New Low Cost STM32F4 based PPZ UAV Autopilot In China

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

New Low Cost STM32F4 based PPZ UAV Autopilot In China

xukejing

Paparazzi Hyper X Autopilot


The office word file with Figs can be downloaded at :http://pan.baidu.com/s/1hrhywfE 

The source code that should be added to paparazzi folder can be downloaded at http://pan.baidu.com/s/1bnLnJCN


1 Overview


Hyper X UAV autopilot board is based on the 100 pins STM32F407VGT6 Cortex M4 168MHz processor featuring a Floating point unit (FPU), up to 192k of RAM and 1024k of FLASH.


It is based on STM32 Discovery board and is a ultra low cost UAV autopilot board that is made by cheap electronic components/modules, which you can get easily n the Chinese market (e.g. GY-86 10DOF 8.5� in http://www.taobao.com). So it is suit for China's national conditions.


                     STMicroelectronics STM32F4VGT6 Cortex M4 MCU, up to 168Mhz with floating point unit (FPU), 192 KB RAM, 1024 KB Flash


                     on-board STLinkv2 with SWD header (capable of programming onboard or external MCU)


                     on-board power regulator for the MCU (3V or 5V Input)


                     MPU6050 Gyro/Accelerometer sensor and MXR9500 Accelerometer with 16 bit ADC (Big Rotorcraft Edition).


                     HMC5883 magnet field sensor.


                     MS5611 high precision pressure sensor


                     UBLOX GPS NEO 6M


                     2 x 3.3V TTL UART (UART3, UART6, 5V tolerant)


                     1 x I2C 5V bus (I2C2, 5V tolerant)


                     11 x Servo PWM outputs


                     4 x status LED (orange, green, red, blue,)


                     2 x UART (UART3, UART6)


                     LIS302DL MEMS 3 axis accelerometer on SPI1


                     6 x ADC inputs (one is used for BAT voltage)


                     1 x Spektrum input (with bind pin)


                     8 x Radio PWM inputs


So, except for a Modem unit with the Hyper X you have all necessary sensors for full features all in one Rotorcraft or Fixedwing solution.


2 Detail Features


10 DOF IMU GY-86


Tiny, low cost 8.5�, 5V and 3.3V input (onboard voltage regulator), I2C interface.


Chinese GY-86 is a low cost and precise solution for normal aircraft with a excellent baro sensor. GY-86 (MPU6050-HMC5883-MS5611) is similar to Drotek 10DOF, but have different I2C address. The slave address of the MPU-6050 is b110100X which is 7 bits long. The LSB bit of the 7 bit address is determined by the logic level on pin AD0. When it is used in GY-86, the address of the devices should be b1101000 (pin AD0 is pull-down to GND). Because of the I2C data bytes are defined to be 8-bits long, so the I2C address of GY-86 should be defined as b11010000(0XD0)


File: conf/airframes/myplane.xml

<subsystem name="imu" type="gy86_10dof">

<configure name="GY86_I2C_DEV" value="i2c2"/>

<define name="IMU_GY86_ORIENTATION_IC_UP" value="1"/>

</subsystem>


The Measurement Specialties MS5611 is an excellent barometer/pressure sensor. The sensor can be used as I2C device. Reading the baro is not part of the IMU driver. If you want to use it for altitude estimation in the autopilot the following line needs to be added to your airframe file: <define name="USE_BARO_MS5611"/>


To see the sensors data in the log file set the SENSOR_SYNC_SEND in your airframe file. Every time new data is available it will be sent directly.


File: conf/airframes/myplane.xml

  <modules>

    ...

     <load name="baro_ms5611_i2c.xml">

     <define name="SENSOR_SYNC_SEND"/>

<define name="MS5611_I2C_DEV" value="i2c2"/>

     <define name="MS5611_SLAVE_ADDR=0xEE"/>

     <define name="MS5611_SEND_BARO_ALTITUDE"/>

    </load>

  </modules>


PPM Encoder


ArduPPM is a 8 channels ppm encoder firmware for the APM project, which is second generation ppm encoder code designed for APM boards. Now the ArduPPM is employed by Hyper X UAV autopilot board and is running on an Arduino Pro Mini that is a microcontroller board based on the ATmega328.


More informationhttps://github.com/diydrones/ardupilot/tree/master/Tools/ArduPPM



3 Pinout




LED

Pin #

Name

Type

Description

Color

PD13

LED_3

Out

above LIS302DL

Orange

PD12

LED_4

Out

left of LIS302DL

Green

PD14

LED_5

Out

right of LIS302DL

Red

PD15

LED_6

Out

below LIS302DL

Blue

PA9

LED_9

Out

same as USB power (VBUS, needs to be enabled in header file)

Green


 


UART3

Pin #

Name

Type

Description

PD8

UART3 TX

Out

UART3 Serial Output

PD9

UART3 RX

In

UART3 Serial Input


 


UART6

Pin #

Name

Type

Description

PC6

UART6 TX

Out

UART6 Serial Output

PC7

UART6 RX

In

UART6 Serial Input


 


I2C2

Pin #

Name

Type

Description

PB10

I2C2 SCL

I/O

I2C2 Serial Clock

PB11

I2C2 SDA

I/O

I2C2 Serial Data


 


ADC

Pin #

Name

Type

Description

PB1

AUX1

I/O

ADC_1

PC5

AUX2

I/O

ADC_2

PC4

AUX3

I/O

ADC_3

PA4

AUX4/BAT

I/O

ADC_4, is used for BAT voltage

PC1

AUX5

I/O

ADC_5

PC2

AUX6

I/O

ADC_6


 


PWM

Pin #

Name

Type

Description

PE9

PWM0

Out

Servo 1

PE11

PWM1

Out

Servo 2

PE13

PWM2

Out

Servo 3

PE14

PWM3

Out

Servo 4

PE5

PWM4

Out

Servo 5

PE6

PWM5

Out

Servo 6

PA3

PWM6

Out

Servo 7

PA2

PWM7

Out

Servo 8

PA1

PWM8

Out

Servo 9

PA0

PWM9

Out

Servo 10

PB14

PWM10

Out

Servo 11

PB15

PWM11

Out

Servo 12


 


PPM

Pin #

Name

Type

Description

PC9

PPM

In

PPM input


 


4 Daughterboard


Hyper X is based on the STM32F4 Discovery and is designed for Chinese students. It is as simple as possible. The impedance matching resistors and voltage conversion chips on I2C or UART ports are omitted. In order to ensure adequate safety margin, 100ohm impedance matching resistors are added on PWM output ports, and 100nf filter capacitors are mounted at UART power ports. 1n4148 diode clamp circuits (may affect ADC’s precision) are created at ADCs 1 to 4. The ADC 5 and 6 have no diode clamp circuits and can collect small voltage signal normally.



5 Build the code


1 Unpack paparazzi.tar that is provided by me


2 copy all files in folder “Pararazzi” to ~/paparazzi (which is the same path of your paparazzi folder)


3 launch paparazzi center (cd ~/paparazzi && ./paparazzi)


4 select MYAC in A/C


5 Build and Upload


6 Enjoy


6 Firmware Flashing


FLASH_MODE=STLINK is set as default


STLINK


   with onboard STLinkV2 over SWD


   required hardware: usb to mini USB cable


   required software: st_flash and st_util from Texane


Reply | Threaded
Open this post in threaded view
|

Re: New Low Cost STM32F4 based PPZ UAV Autopilot In China

wang siqi
碉堡了大哥,向您学习!
请问您这一套下来大概得多少钱?
Reply | Threaded
Open this post in threaded view
|

Re: New Low Cost STM32F4 based PPZ UAV Autopilot In China

xukejing
Hi wang siqi ,
The hardware of Hyper X total costs me about 200 CNY. The GY-86 10DOF module is only 8.5 EUR in China's market (www.taobao.com). Resistors and diodes cost me less than 1 CNY.
As you know, it is an ultra low cost UAV autopilot board (total costs 27 EUR)
Reply | Threaded
Open this post in threaded view
|

Re: New Low Cost STM32F4 based PPZ UAV Autopilot In China

chekoda
This is very wonderful!
Are you still in the testing stage?Refer to the introduction documents, you haven't make the PCB.
Reply | Threaded
Open this post in threaded view
|

Re: New Low Cost STM32F4 based PPZ UAV Autopilot In China

Hwarm
Dear chekoda,
currently i have the old Narze32 running with paparazzi.
To test the new pcb and to make the board files for it is on the to do list.
Regards
Heinrich


Am 02.04.2016 14:13, schrieb chekoda:

> This is very wonderful!
> Are you still in the testing stage?Refer to the introduction documents, you
> haven't make the PCB.
>
>
>
> --
> View this message in context: http://lists.paparazziuav.org/New-Low-Cost-STM32F4-based-PPZ-UAV-Autopilot-In-China-tp17792p17845.html
> Sent from the paparazzi-devel mailing list archive at Nabble.com.
>
> _______________________________________________
> Paparazzi-devel mailing list
> [hidden email]
> https://lists.nongnu.org/mailman/listinfo/paparazzi-devel
>


_______________________________________________
Paparazzi-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/paparazzi-devel