Stufin
Home Quick Cart Profile

DIY 4CH 6-Axis Gyro Mini Quadcopter Kit

Buy Now on Stufin

Gyroscope

6-axis (accelerometer and gyroscope combination)

Controller

4-channel RF controller

Motors

4x Brushless motors

ESCs

4x Electronic Speed Controllers

Frame

Lightweight and durable frame

Propellers

4x Optimized propellers for aerodynamics and performance

Power Distribution

Integrated power distribution board

Weight

Approximately 150g (without battery)

Dimensions

120mm x 120mm x 30mm (without propellers)

Applications

The DIY 4CH 6-Axis Gyro Mini Quadcopter Kit is suitable for various applications, including

Aerial photography and videography

Surveillance and monitoring

Research and development

Hobbyist projects and prototypes

Note

This kit requires assembly, soldering, and programming to operate. Users are advised to have basic electronics and programming knowledge before using this kit.

Pin Configuration

  • Component Documentation: DIY 4CH 6-Axis Gyro Mini Quadcopter Kit
  • The DIY 4CH 6-Axis Gyro Mini Quadcopter Kit is a compact and affordable quadcopter kit designed for hobbyists and enthusiasts. This kit features a 6-axis gyro sensor, which provides stability and balance to the quadcopter. In this documentation, we will explain the pins one by one and provide a step-by-step guide on how to connect them.
  • Pinout Diagram:
  • | Pin Number | Pin Name | Function | Description |
  • | --- | --- | --- | --- |
  • | 1 | VCC | Power | 5V power supply input |
  • | 2 | GND | Ground | Ground connection |
  • | 3 | SCL | I2C Clock | I2C clock signal for communication with the gyro sensor |
  • | 4 | SDA | I2C Data | I2C data signal for communication with the gyro sensor |
  • | 5 | RX | Serial Receive | serial data receive pin |
  • | 6 | TX | Serial Transmit | serial data transmit pin |
  • | 7 | M1 | Motor 1 Control | PWM control signal for Motor 1 |
  • | 8 | M2 | Motor 2 Control | PWM control signal for Motor 2 |
  • | 9 | M3 | Motor 3 Control | PWM control signal for Motor 3 |
  • | 10 | M4 | Motor 4 Control | PWM control signal for Motor 4 |
  • | 11 | AUX1 | Auxiliary 1 | Spare pin for custom use (e.g., LED indicator or switch) |
  • | 12 | AUX2 | Auxiliary 2 | Spare pin for custom use (e.g., LED indicator or switch) |
  • Connecting the Pins:
  • To ensure proper connection and function, follow these step-by-step instructions:
  • Power Connection (VCC and GND):
  • Connect the VCC pin (1) to a 5V power supply source (e.g., battery or power adapter).
  • Connect the GND pin (2) to the ground connection of the power supply source or a common ground point.
  • I2C Connection (SCL and SDA):
  • Connect the SCL pin (3) to the SCL pin of a compatible microcontroller (e.g., Arduino or Raspberry Pi).
  • Connect the SDA pin (4) to the SDA pin of the microcontroller.
  • Serial Connection (RX and TX):
  • Connect the RX pin (5) to the TX pin of a compatible serial communication device (e.g., FTDI adapter or serial TTL module).
  • Connect the TX pin (6) to the RX pin of the serial communication device.
  • Motor Control Connections (M1-M4):
  • Connect the M1 pin (7) to the PWM input of Motor 1.
  • Connect the M2 pin (8) to the PWM input of Motor 2.
  • Connect the M3 pin (9) to the PWM input of Motor 3.
  • Connect the M4 pin (10) to the PWM input of Motor 4.
  • Auxiliary Pins (AUX1 and AUX2):
  • These pins can be used for custom applications, such as connecting LED indicators or switches. Ensure that the pins are not connected to any conflicting signals or power sources.
  • Additional Notes:
  • When connecting motors, ensure that the correct polarity is observed to avoid damage to the motors or the quadcopter kit.
  • When using the I2C protocol, ensure that the microcontroller is configured to communicate with the gyro sensor at the correct address and baud rate.
  • Always double-check the pin connections before powering on the quadcopter kit to avoid damage or malfunction.
  • By following these instructions, you should be able to successfully connect the DIY 4CH 6-Axis Gyro Mini Quadcopter Kit and begin exploring the world of quadcopter flight.

Code Examples

DIY 4CH 6-Axis Gyro Mini Quadcopter Kit Documentation
Overview
The DIY 4CH 6-Axis Gyro Mini Quadcopter Kit is a compact and versatile quadcopter kit designed for hobbyists and enthusiasts. It features a 6-axis gyro sensor, providing stable flight performance and precise control. This kit is perfect for building and customizing mini quadcopters for various applications, such as aerial photography, racing, and robotics.
Technical Specifications
Microcontroller: ATmega328P
 Gyro Sensor: 6-axis (3-axis accelerometer, 3-axis gyroscope)
 ESC: 4x 10A Brushed ESC
 Motor: 4x 7mm Coreless Motor
 Receiver: 4CH 2.4GHz Receiver
 Power Supply: 7.4V 200mAh LiPo Battery
Setting Up the Kit
To get started with the DIY 4CH 6-Axis Gyro Mini Quadcopter Kit, follow these steps:
1. Assemble the quadcopter frame and attach the motors, ESCs, and gyro sensor.
2. Connect the receiver and battery to the flight controller.
3. Upload the flight control firmware to the microcontroller using a programming interface (e.g., Arduino IDE).
4. Calibrate the gyro sensor and configure the flight controller settings using the provided software or a serial terminal.
Code Examples
### Example 1: Basic Flight Control Using Arduino
This example demonstrates how to control the quadcopter using the Arduino IDE and the built-in flight control firmware.
```c
#include <Quadcopter.h>
Quadcopter quad;
void setup() {
  // Initialize the quadcopter
  quad.init();
// Set the motor speeds to zero
  quad.setMotorSpeeds(0, 0, 0, 0);
}
void loop() {
  // Read the receiver input
  int roll = quad RECEIVER_READ Roll;
  int pitch = quad RECEIVER_READ Pitch;
  int yaw = quad RECEIVER_READ Yaw;
  int throttle = quad RECEIVER_READ Throttle;
// Calculate the motor speeds based on the receiver input
  int motor1Speed = throttle + roll + yaw;
  int motor2Speed = throttle - roll + yaw;
  int motor3Speed = throttle + pitch - yaw;
  int motor4Speed = throttle - pitch - yaw;
// Set the motor speeds
  quad.setMotorSpeeds(motor1Speed, motor2Speed, motor3Speed, motor4Speed);
  delay(20); // 20ms refresh rate
}
```
### Example 2: Stability Control Using PID Algorithm
This example demonstrates how to implement a basic PID (Proportional-Integral-Derivative) control algorithm to stabilize the quadcopter.
```c
#include <Quadcopter.h>
#include <PID.h>
Quadcopter quad;
PID pidRoll, pidPitch, pidYaw;
void setup() {
  // Initialize the quadcopter
  quad.init();
// Initialize the PID controllers
  pidRoll.init(2.0, 0.5, 1.0); // Roll PID gains
  pidPitch.init(2.0, 0.5, 1.0); // Pitch PID gains
  pidYaw.init(2.0, 0.5, 1.0); // Yaw PID gains
}
void loop() {
  // Read the gyro sensor data
  int gyroRoll = quad GYRO_READ Roll;
  int gyroPitch = quad GYRO_READ Pitch;
  int gyroYaw = quad GYRO_READ Yaw;
// Calculate the PID outputs
  int pidOutputRoll = pidRoll.calculate(gyroRoll, 0);
  int pidOutputPitch = pidPitch.calculate(gyroPitch, 0);
  int pidOutputYaw = pidYaw.calculate(gyroYaw, 0);
// Calculate the motor speeds based on the PID outputs
  int motor1Speed = pidOutputRoll + pidOutputPitch + pidOutputYaw;
  int motor2Speed = pidOutputRoll - pidOutputPitch + pidOutputYaw;
  int motor3Speed = pidOutputPitch + pidOutputYaw - pidOutputRoll;
  int motor4Speed = pidOutputPitch - pidOutputYaw - pidOutputRoll;
// Set the motor speeds
  quad.setMotorSpeeds(motor1Speed, motor2Speed, motor3Speed, motor4Speed);
  delay(20); // 20ms refresh rate
}
```
Note: These code examples are for illustrative purposes only and may require modifications to work with your specific setup and requirements.