Basic Landslide Detector

by cakee in Circuits > Arduino

42 Views, 0 Favorites, 0 Comments

Basic Landslide Detector

landslideDetector2.jpg
landslideDetector1.jpg
landslideDetector3.jpg

This project uses a basic system to detect ground tilt and moisture levels, helping to monitor areas prone to landslides.

Supplies

What You’ll Need:

  1. MPU6050 sensor (for tilt detection)
  2. Soil moisture sensor
  3. Arduino Uno
  4. Buzzer
  5. Battery
  6. Enclosure box

Set Up the Enclosure

Start by preparing a small enclosure to house all the components. This will protect your sensors and make the device easy to set up in the field.

Make the Connections

Now, let’s connect everything together:

  1. MPU6050 sensor: Connect the VCC and GND pins to the Arduino’s 5V and GND, respectively. Connect the SDA and SCL pins to the Arduino’s A4 and A5 pins for communication.
  2. Soil moisture sensor: Connect the sensor’s VCC to 5V, GND to GND, and the output pin to one of the Arduino’s analog pins (e.g., A0).
  3. Buzzer: Connect one side of the buzzer to the Arduino’s digital pin 7 and the other to GND.
  4. Battery: Connect a suitable battery to power the system (ensure it matches your Arduino’s requirements).

Program the Arduino

Download the code and upload it to your Arduino board after selecting the correct board in the IDE. Don’t forget to install the MPU6050 library before uploading.

Test and Place

If the MPU6050 isn’t working properly, like giving inaccurate or unstable values, here’s what you can do:

  1. Adjust Sensitivity:
  2. Open the code and find the section in setup() where sensitivity is configured.
  3. To adjust accelerometer sensitivity, look for this commented part of the code:
Wire.beginTransmission(MPU);
Wire.write(0x1C); // Register for ACCEL_CONFIG
Wire.write(0x00); // Default ±2g
Wire.endTransmission(true);
  1. Change the Wire.write(0x00) value to adjust the range:
  2. 0x00: ±2g (default)
  3. 0x08: ±4g
  4. 0x10: ±8g
  5. 0x18: ±16g


  1. To adjust gyroscope sensitivity, look for this part:
Wire.beginTransmission(MPU);
Wire.write(0x1B); // Register for GYRO_CONFIG
Wire.write(0x00); // Default ±250°/s
Wire.endTransmission(true);
  1. Change the Wire.write(0x00) value to adjust the range:
  2. 0x00: ±250°/s (default)
  3. 0x08: ±500°/s
  4. 0x10: ±1000°/s
  5. 0x18: ±2000°/s

Update these values depending on whether you want higher sensitivity (lower range) or the ability to measure larger movements (higher range).

  1. Check Orientation:
  2. Make sure the sensor is placed flat and aligned with your setup.
  3. Use the Serial Monitor to check the roll, pitch, and yaw values as you adjust the sensor's position until they make sense for your setup.
  4. Recalibrate the Sensor:
  5. Keep the MPU6050 flat and stable.
  6. Run the code as it includes the calculate_IMU_error() function. This will print error values to the Serial Monitor.
  7. Update these values in the section of the code that corrects the sensor's readings.

Tinker Around

Now that your basic landslide detector is up and running, feel free to tinker around with it! You can experiment with adjusting the sensitivity of the soil moisture sensor or the tilt angle for better performance. Adding wireless notifications, improving the buzzer alerts, or even integrating a display for real-time readings are just a few ways you could enhance the project.