Final Video

The Solution

The Solution

Software

  1. Software Design Approach

In designing the software for our project, we utilized the Arduino programming language and framework. We followed a modular design approach, separating different functionalities into distinct components. We adhered to design principles modularity to ensure maintainability and extensibility.

Software

  1. Software Design Approach

In designing the software for our project, we utilized the Arduino programming language and framework. We followed a modular design approach, separating different functionalities into distinct components. We adhered to design principles modularity to ensure maintainability and extensibility.

Software

  1. Software Design Approach

In designing the software for our project, we utilized the Arduino programming language and framework. We followed a modular design approach, separating different functionalities into distinct components. We adhered to design principles modularity to ensure maintainability and extensibility.

  1. Flow of the Software

At a high level, our software follows a sequential flow. It starts by initializing the necessary pins and setting up the LCD display. Then, it enters a loop where it continuously performs three main tasks: bioelectric signal detection, temperature monitoring, and soil moisture sensing. Each task is executed sequentially with appropriate delays to allow for accurate readings.

  1. Flow of the Software

At a high level, our software follows a sequential flow. It starts by initializing the necessary pins and setting up the LCD display. Then, it enters a loop where it continuously performs three main tasks: bioelectric signal detection, temperature monitoring, and soil moisture sensing. Each task is executed sequentially with appropriate delays to allow for accurate readings.

  1. Flow of the Software

At a high level, our software follows a sequential flow. It starts by initializing the necessary pins and setting up the LCD display. Then, it enters a loop where it continuously performs three main tasks: bioelectric signal detection, temperature monitoring, and soil moisture sensing. Each task is executed sequentially with appropriate delays to allow for accurate readings.

3. Key Software Components
We developed several important software components for our project. Firstly, we have a component responsible for detecting and processing the bioelectric signal using the CapacitiveSensor library. Secondly, there is a component that monitors and displays the temperature using a temperature sensor and LED indicators. Lastly, we implemented a module to measure soil moisture levels using a moisture sensor and control a buzzer accordingly.

3. Key Software Components
We developed several important software components for our project. Firstly, we have a component responsible for detecting and processing the bioelectric signal using the CapacitiveSensor library. Secondly, there is a component that monitors and displays the temperature using a temperature sensor and LED indicators. Lastly, we implemented a module to measure soil moisture levels using a moisture sensor and control a buzzer accordingly.

3. Key Software Components
We developed several important software components for our project. Firstly, we have a component responsible for detecting and processing the bioelectric signal using the CapacitiveSensor library. Secondly, there is a component that monitors and displays the temperature using a temperature sensor and LED indicators. Lastly, we implemented a module to measure soil moisture levels using a moisture sensor and control a buzzer accordingly.

4. Integration with Hardware
Our software interacts with various hardware components to achieve its functionality. It communicates with the bioelectric sensors, temperature sensor, moisture sensor, LEDs, buzzer, and LCD display. We utilize specific pins and libraries to establish communication and retrieve data from these hardware components.

4. Integration with Hardware
Our software interacts with various hardware components to achieve its functionality. It communicates with the bioelectric sensors, temperature sensor, moisture sensor, LEDs, buzzer, and LCD display. We utilize specific pins and libraries to establish communication and retrieve data from these hardware components.

4. Integration with Hardware
Our software interacts with various hardware components to achieve its functionality. It communicates with the bioelectric sensors, temperature sensor, moisture sensor, LEDs, buzzer, and LCD display. We utilize specific pins and libraries to establish communication and retrieve data from these hardware components.

Code

// Define the pins for the button, LED, temperature sensor, and buzzer
const int ledPin = 12; 
const int TempPin = A1; // detect the temperature of the plant


int sensorValue; // raw analog data
int sensorMV; //corresponding voltage
float tempCent; // degrees Celsius


void setup() {
  // this is for the temp part
  pinMode(ledPin, OUTPUT); // green led
  pinMode(TempPin, INPUT); // temp sensor
  Serial.begin(9600); // Initialize the serial communication for debugging
}


void loop() {
  // read the temp
  sensorValue = analogRead(TempPin);
  sensorMV = map(sensorValue, 0, 1023, 0, 4999);
  tempCent = (sensorMV - 500) / 10.0;
  Serial.print("Temperature:");
  Serial.print(tempCent);
  Serial.println(" deg C"); //show as Celsius
  // check if the temp is above the fire threshold


if (tempCent >= 25) {
  digitalWrite(ledPin, HIGH); // when temp >=25, turn on the green light, the plant need to cold down
} else {
  digitalWrite(ledPin, LOW); // temp is ok
 }
    delay(1000);
}
#include <CapacitiveSensor.h>
const int buzzer = 8; // 
const int led = 7; // detect the temperature of the plant


// Set the Send Pin & Receive Pin.
CapacitiveSensor cs_12_3 = CapacitiveSensor(2, 4);
int pos = 0;
void setup() {
  Serial.begin(9600);
  pinMode(led, OUTPUT);
  // turn off auto calibrate on channel
  cs_12_3.set_CS_AutocaL_Millis(0xFFFFFFFF);
}
void loop() {
  // Set the sensitivity of the sensors.
  long touch1 = cs_12_3.capacitiveSensor(300);
Serial.print(touch1);
Serial.print("\n"); // Add a newline character at the end of the print statement
delay(2000);
  // When we touch the sensor, the buzzer will produce a tone.
  if (touch1 > 300) {
    tone(buzzer, 400);
  } else {
    // When we don't touch it, no tone is produced.
    noTone(buzzer);
  }
  if (touch1 >= 200 && pos == 0) {
    digitalWrite(led, HIGH);
    pos = 1;
    delay(100);
  } else if (touch1 >= 200 && pos == 1) {
    digitalWrite(led, LOW);
    pos = 0;
    delay(100);
  }
  delay(10);
}
const int dry = 579; // value for dry sensor
const int wet = 324; // value for wet sensor
void setup() {
  Serial.begin(9600);
  pinMode(A0, INPUT); // Configure A0 pin as input
}
void loop() {
  int sensorVal = analogRead(A0);
  // Check if sensorVal is within the valid range
  if (sensorVal >= wet && sensorVal <= dry) {
    int percentageHumidity = map(sensorVal, dry, wet, 0, 100);
    Serial.print(percentageHumidity);
  } else {
    // Sensor value is outside the valid range, set humidity to 0
    Serial.print(0);
  }
  Serial.println(%);
  delay(100);
}

Bioelectric Signal Detection

Bioelectric Signal Detection

  • Initialize the capacitive sensor for bioelectric signal detection (cs_12_3).

  • Read the capacitive sensor value (touch1) every second.

  • If the value of touch1 is greater than or equal to 300 and pos is 0 (indicating no touch is detected):

    • Turn on the green LED (ledPin_Green).

    • Set pos to 1 to indicate that a touch is detected.

  • If the touch1 value is greater than or equal to 300 and pos is 1 (indicating a touch was previously detected):

    • Turn off the green LED (ledPin_Green).

    • Set pos to 0 to indicate that no touch was detected.

  • Delay for 10 milliseconds before the next iteration.

  1. Temperature Detection:

    • Read the analog value from the temperature sensor (sensorValue).

    • Convert the sensor value to millivolts (sensorMV).

    • Calculate the temperature in degrees Celsius (tempCent) based on the sensor millivolt value.

    • Print the temperature value to the serial monitor.

    • If the temperature (tempCent) is equal to or greater than 25:

      • Turn on the red LED (ledPin_Red) to indicate high temperature.

    • Otherwise, turn off the red LED.

    • Delay for 1 second before the next iteration.

  2. Moisture Detection:

    • Read the analog value from the moisture sensor (sensorVal).

    • Map the sensor value to a percentage of humidity (percentageHumidity) based on the dry and wet values.

    • If the sensor value is within the valid range and the percentage humidity is less than or equal to 20:

      • Print the percentage humidity to the serial monitor.

      • Activate the buzzer (buzzer) to indicate low moisture.

    • Otherwise:

      • Print 0 to the serial monitor.

      • Deactivate the buzzer.

    • Print the humidity value (percentageHumidity) to the serial monitor.

    • Delay for 100 milliseconds before the next iteration.

The LCD display is used for visual feedback rather than input or output detection.

  • Initialize the capacitive sensor for bioelectric signal detection (cs_12_3).

  • Read the capacitive sensor value (touch1) every second.

  • If the value of touch1 is greater than or equal to 300 and pos is 0 (indicating no touch is detected):

    • Turn on the green LED (ledPin_Green).

    • Set pos to 1 to indicate that a touch is detected.

  • If the touch1 value is greater than or equal to 300 and pos is 1 (indicating a touch was previously detected):

    • Turn off the green LED (ledPin_Green).

    • Set pos to 0 to indicate that no touch was detected.

  • Delay for 10 milliseconds before the next iteration.

  1. Temperature Detection:

    • Read the analog value from the temperature sensor (sensorValue).

    • Convert the sensor value to millivolts (sensorMV).

    • Calculate the temperature in degrees Celsius (tempCent) based on the sensor millivolt value.

    • Print the temperature value to the serial monitor.

    • If the temperature (tempCent) is equal to or greater than 25:

      • Turn on the red LED (ledPin_Red) to indicate high temperature.

    • Otherwise, turn off the red LED.

    • Delay for 1 second before the next iteration.

  2. Moisture Detection:

    • Read the analog value from the moisture sensor (sensorVal).

    • Map the sensor value to a percentage of humidity (percentageHumidity) based on the dry and wet values.

    • If the sensor value is within the valid range and the percentage humidity is less than or equal to 20:

      • Print the percentage humidity to the serial monitor.

      • Activate the buzzer (buzzer) to indicate low moisture.

    • Otherwise:

      • Print 0 to the serial monitor.

      • Deactivate the buzzer.

    • Print the humidity value (percentageHumidity) to the serial monitor.

    • Delay for 100 milliseconds before the next iteration.

The LCD display is used for visual feedback rather than input or output detection.

  • Initialize the capacitive sensor for bioelectric signal detection (cs_12_3).

  • Read the capacitive sensor value (touch1) every second.

  • If the value of touch1 is greater than or equal to 300 and pos is 0 (indicating no touch is detected):

    • Turn on the green LED (ledPin_Green).

    • Set pos to 1 to indicate that a touch is detected.

  • If the touch1 value is greater than or equal to 300 and pos is 1 (indicating a touch was previously detected):

    • Turn off the green LED (ledPin_Green).

    • Set pos to 0 to indicate that no touch was detected.

  • Delay for 10 milliseconds before the next iteration.

  1. Temperature Detection:

    • Read the analog value from the temperature sensor (sensorValue).

    • Convert the sensor value to millivolts (sensorMV).

    • Calculate the temperature in degrees Celsius (tempCent) based on the sensor millivolt value.

    • Print the temperature value to the serial monitor.

    • If the temperature (tempCent) is equal to or greater than 25:

      • Turn on the red LED (ledPin_Red) to indicate high temperature.

    • Otherwise, turn off the red LED.

    • Delay for 1 second before the next iteration.

  2. Moisture Detection:

    • Read the analog value from the moisture sensor (sensorVal).

    • Map the sensor value to a percentage of humidity (percentageHumidity) based on the dry and wet values.

    • If the sensor value is within the valid range and the percentage humidity is less than or equal to 20:

      • Print the percentage humidity to the serial monitor.

      • Activate the buzzer (buzzer) to indicate low moisture.

    • Otherwise:

      • Print 0 to the serial monitor.

      • Deactivate the buzzer.

    • Print the humidity value (percentageHumidity) to the serial monitor.

    • Delay for 100 milliseconds before the next iteration.

The LCD display is used for visual feedback rather than input or output detection.

  • Use a blue wire as the bio signal detector.

  • Activate the buzzer when the moisture is lower or equal to 20%.

  • Turn on the green LED when the bio signal is detected and its value is higher than 300.

  • Utilize the moisture sensor to detect the soil moisture.

  • Display a message on the LCD when the moisture is lower than 20%.

  • Twist the trim to change the temperature.

  • Illuminate the red LED when the temperature is higher than 25℃.

  • Use a blue wire as the bio signal detector.

  • Activate the buzzer when the moisture is lower or equal to 20%.

  • Turn on the green LED when the bio signal is detected and its value is higher than 300.

  • Utilize the moisture sensor to detect the soil moisture.

  • Display a message on the LCD when the moisture is lower than 20%.

  • Twist the trim to change the temperature.

  • Illuminate the red LED when the temperature is higher than 25℃.

Description

In our project, our aim is to design a system capable of detecting bioelectric signals in plants/fruits and converting them into music. Additionally, we seek to investigate whether the sound changes when we control the temperature and moisture, and what happens in different scenarios. In conclusion, our project consists of three main parts:

  1. Bioelectric Signal Detection and Music Transformation: We develop a module to detect bioelectric signals in plants/fruits. The detected signals are transformed into music that can be played.


  2. Temperature Detection using LED: We utilize LEDs to detect temperature changes in the plant. If the temperature exceeds 25℃, the LED will light up to remind people to cool down the plant. Users can also explore different sounds by touching different parts of the plant.


  3. Moisture Detection using Buzzer and Moisture Sensor: We incorporate a buzzer and moisture sensor to detect the soil's moisture level. When the moisture level drops below 20%, the system will display a message on the LCD screen to remind people to water the plant.

In our project, our aim is to design a system capable of detecting bioelectric signals in plants/fruits and converting them into music. Additionally, we seek to investigate whether the sound changes when we control the temperature and moisture, and what happens in different scenarios. In conclusion, our project consists of three main parts:

  1. Bioelectric Signal Detection and Music Transformation: We develop a module to detect bioelectric signals in plants/fruits. The detected signals are transformed into music that can be played.


  2. Temperature Detection using LED: We utilize LEDs to detect temperature changes in the plant. If the temperature exceeds 25℃, the LED will light up to remind people to cool down the plant. Users can also explore different sounds by touching different parts of the plant.


  3. Moisture Detection using Buzzer and Moisture Sensor: We incorporate a buzzer and moisture sensor to detect the soil's moisture level. When the moisture level drops below 20%, the system will display a message on the LCD screen to remind people to water the plant.

Description

In our project, our aim is to design a system capable of detecting bioelectric signals in plants/fruits and converting them into music. Additionally, we seek to investigate whether the sound changes when we control the temperature and moisture, and what happens in different scenarios. In conclusion, our project consists of three main parts:

  1. Bioelectric Signal Detection and Music Transformation: We develop a module to detect bioelectric signals in plants/fruits. The detected signals are transformed into music that can be played.


  2. Temperature Detection using LED: We utilize LEDs to detect temperature changes in the plant. If the temperature exceeds 25℃, the LED will light up to remind people to cool down the plant. Users can also explore different sounds by touching different parts of the plant.


  3. Moisture Detection using Buzzer and Moisture Sensor: We incorporate a buzzer and moisture sensor to detect the soil's moisture level. When the moisture level drops below 20%, the system will display a message on the LCD screen to remind people to water the plant.

Arduino

Giving Voice to Plants: An Interactive Care System
for Green Enthusiasts

Giving Voice to Plants: An Interactive Care System
for Green Enthusiasts

Arduino

Giving Voice to Plants: An Interactive Care System
for Green Enthusiasts