Projects

  • Travis

SoilSense: IoT For Farmers

Background:

There has been an alarming increase in the number of farmers who have committed suicide due to financial reasons, especially in India. Over the past three decades, there have been nearly 60,000 deaths in India alone. Looking at this problem, I figured that if I could create something that makes their crop output either higher or more consistent, then the problem would be mitigated.


Note: I worked on this project with other interns at Stanley Black & Decker as part of an "Intern Innovation Challenge" where we were tasked with finding problems and creating business models around solving them. We ended up winning first place (see below).

My Solution:

As a first step, I came up with a sensor module that relays data such as ambient temperature, pH, soil moisture, soil temperature, and sunlight intensity up to the cloud so that the farmer can view this data and make more informed decisions.

SoilSense: Finished Prototype


How I Built It:

I chose to use a Particle Photon to control this. This microcontroller is programmed in a language similar to Arduino (C/C++) with many helpful library functions. It doesn't use much energy and it has a Wi-Fi antenna built-in. When I built this project, the Particle Argon and Particle Boron didn't exist yet. If I had to rebuild it, I would have used those boards as they have mesh Wi-Fi and mesh LTE built-in. On a farm, there would probably be shoddy cellular connection so a meshed system would work well because only one of the sensor modules would have to be connected to the access point.

SoilSense: Internals

Yes, the components are hot glued down.


The case was designed by a co-intern in CATIA and printed in Carbon Fiber on a Markforged Mark Two. This is, of course, very overkill for this application but the Mark Two makes beautiful, highly accurate 3D prints so it seemed like a good idea at the time.

SoilSense: Rendering

There were a few technical challenges that I had to figure out how to solve. In particular:

Power Issues - The idea is that the sensor module would be on ground-level near crops on a farm. I decided not to use solar panels because mud would easily cover the panel and taller crops would block out the sun making the panel all but ineffective. Without solar panels, this sensor module would have to run on battery. However, I don't think that farmers would want to charge this that often, so I wanted the SoilSense to last at least one growing season (roughly six months) on a single charge. Although the Photon has pretty low power consumption, it is still significant enough (80mA @5V) that running it for six months under normal operating conditions would require a huge battery. One thing I realized was that farmers do not need updated data every millisecond, second, or even minute. Farmers probably only need updated data every half hour or so.


Therefore, I could program the Photon to go into deep sleep mode for half an hour, turn back on, send the data, and then go back into deep sleep mode. Deep sleep mode saved a lot of power (power calculations below).

^Code to put Photon into deep sleep mode.

The Particle Photon usually runs at 80mA, but it'll be running for most of the day on deep sleep mode that only uses 80μA. With this change, a common 10Ah power bank such as this one could make the sensor module last 207 days even with the 3.7V to 5V step-up conversion (assuming a 5% loss)!


Waterproofing - Since I was planning to put this sensor outside, the entire sensor had to be waterproofed especially because some farmers, like those in India, rely on flooding as a method of irrigation. When designing the case, it was important to include an O-ring around the inner portion so that water could not leak in. The charging port micro-USB is a special port meant for waterproof phones with its own O-ring. If I was actually going to put this into production, I would also apply a conformal coating to the PCB to waterproof it. Also because the soil moisture sensor was fragile and prone to oxidation, I wired the moisture sensor to two stainless steel bolts to act as probes.


Using the webhook integrations from Particle, I had the data published to the Particle Cloud service where it would be redirected to the Ubidots dashboard.


Note: The final version of the dashboard didn't have the weird scaling issues and it had a lot more datapoints displayed. I would upload a screenshot of that, but my Ubidots trial expired and this is the only screenshot I took during the trial.

Competition:

SBD Innovation Challenge Winning Team

Intern Innovation Challenge Plaque

We got first place in the intern competition! It was a great experience working with these people and developing this prototype :D

Future:

Now that I have multiple sensor modules sending multiple sensor readings to the cloud, I need some way of processing the data to extract insights. If I had data on which plants farmers grew each year and which ones did poorly and which ones did well, I would be able write a program that finds the optimal levels of pH, temperature, soil moisture, etc for each crop and tell the farmer which part of the farm is best for which type of plants and the sensors could control the irrigation system.