Question: You should create a program in Matlab that allows long-term monitoring of the plant soil to ensure that the plant receives water as it needs

You should create a program in Matlab that allows long-term monitoring of the plant soil to ensure that the plant receives water as it needs it. That means measuring the soil moisture using a soil moisture sensor attached to your Arduino or Grove board. When the soil is dry, have a MOSFET or Relay board turn a water pump on to deliver water to the soil, turning off the pump when there is enough water in the soil. Then wait until the soil is dry again and start the process over again.

So that sums up what I have to do. I'm using a Grove Beginner Kit and MATLAB for this. In addition, I have to make a graph of the moisture over time.

My code so far is as follows:

You should create a program in Matlab that allows long-term monitoring ofWhat I'm struggling with is the graph I have to make. I know this code is very basic and the graphing part is completely wrong, but I honestly have no clue where to start with the graphing part. If you need any more context ask and you shall recieve.

\% The actual program clear all; close all a= arduino('COM3', 'uno'); \%set the variable readVoltage (a,A) \%check to see if moisture sensor works writeDigitalPin (a,D2,1); pause(1);writeDigitalPin (a,D2,)%check to se v= readVoltage (a,A); for v=0:96 if v>=3.5 writeDigitalPin (a,D2,1); pause(10); writeDigitalPin(a, 'D2', elseif ((v>2.9) \&\& (v

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!