Evolving Open-Source Technologies Offer Options for Remote Sensing and Monitoring in Agriculture

A variety of sensing and monitoring systems have been developed based on the concept of open-source and on open-source hardware and software components. Availability and relatively low cost of hardware components and availability and ease of use of software components allow access to sensing and monitoring technologies that were previously unattainable to many potential users. Advances in electronic monitoring and evolving cellular communications technologies are increasingly offering more, simpler, and less expensive options for remote monitoring. Due to the near-future cessation of 2G and 3G cellular network services, however, many existing monitoring systems will need to be redesigned to operate on alternative cellular networks. A soil-moisture monitoring system was developed incorporating updated open-source Arduino microcontrollers and the recently introduced LTE Cat-M1 cellular network to transmit sensor measurements via the cellular network for access on an internet website. The monitoring system costs approximately US$130 to construct the electronic circuitry and less than US$1 per month for cellular network access and data transmission. Data were transmitted with a 95% success rate, and the monitoring system operated continuously throughout an entire crop growing season with no battery recharge or maintenance requirements. The design and operation of the monitoring system can serve as a basis for other remote monitoring systems.


Introduction
The concept of open sharing of ideas and designs, collaborative efforts, and supportive community has enabled researchers and others to develop unique and custom devices to satisfy specific requirements and needs [1] [2]. Availability and relatively low cost of hardware components and availability and ease of use of software components allow access to sensing and monitoring technologies that were previously unattainable to many potential users.
An open-source hardware and software project that has been popular with developers is the Arduino microcontroller development platform (https://www.arduino.cc). The Arduino hardware consists of a microcontrollerbased development board designed to allow convenient access to the microcontroller's various features, including input/output pins, analog-to-digital converters, analog and digital communications protocols, timers, and non-volatile memory. The many features allow a user to interface and interact with external components, such as sensors, motors, displays, data-storage devices, and wireless data-transmission devices, to create custom monitoring and control systems. The Arduino Integrated Development Environment (IDE) software provides a programming environment for the user to write and upload programs to the microcontroller to control the operation of the system.
A key component of a sensing and monitoring system is the accessibility of the information collected by the system. While the information can be collected and stored at the location of the system, accessing the location and retrieving the data can be time-consuming and inconvenient, especially for remotely located systems. Many wireless technologies exist and have been explored for transmitting data [3] [4] [5], but rapid expansion and widespread coverage of modern cellular networks have resulted in a communications network that is accessible to many in most parts of the world. Agricultural researchers have begun deploying open-source monitoring systems and cellular communications to aid in efforts related to irrigation and water management [6] [7] [8], soil moisture monitoring [9] [10] [11] [12], water use [13], and weather and rainfall monitoring [14] [15].
As the user base of the Arduino microcontroller platform has expanded, in terms of the interests and number of users and the sophistication of Arduino-based projects, the capabilities of the microcontroller are becoming a limiting factor. The original Arduino development board included a specific microcontroller and a standardized physical size and microcontroller pin configuration.

Materials and Methods
A monitoring system was developed to measure and transmit soil-moisture sensor measurements for use in determining the proper timing of irrigation applications and for monitoring water resources in the root zone. The system was comprised of open-source hardware and software components and was designed to allow internet access of sensor measurements from remotely located agricul-  Table 1, and the completed hardware circuit components of the monitoring system are shown in Figure 2. The devices were initialized, and program variables and input/output pins configured.
The main program section was then entered, which consisted of calls to program subroutines. Separate subroutines were written for accomplishing various tasks; making moisture-sensor measurements, transmitting data via cellular modem, and putting the circuit into a low-power sleep mode. Operation of the program and its subroutines is described briefly below. The microcontroller program is open-source and freely available by contacting the authors. Soil-moisture measurements are obtained by reading each sensor individually. The voltage-divider circuit is energized by setting one end pin of the circuit high and the other end pin low, causing electricity to flow through the circuit with one polarity, and the center voltage is read with an analog-to-digital converter. The polarity is then reversed by reversing the voltage settings on the two end pins, and the center voltage read again. This is repeated five times to avoid long-term polarization of, and damage to, the sensors, and to obtain an average measurement. The resistance of the sensor, which varies in proportion to the moisture level of the sensor, is calculated using the standard voltage-divider equation. A calibration equation is then applied to the calculated resistance to estimate the water potential of the soil (see [2] for more detailed information about the circuit and calibration).
The microcontroller then turns on and establishes communication with the cellular modem to transmit data to an internet-based data-hosting website, described below. The modem registers with the cellular network and enables cellular data services and reads the voltage of the circuit's battery. The microcontroller assembles the sensor data and battery voltage into the proper format for internet traffic and performs the data transmission. The status of the transmission is monitored, and if unsuccessful, the modem makes up to three attempts to send the data successfully.
Following successful data transmission, the program terminates internet and cellular data services. The microcontroller's internal real-time clock is reset, and the next measurement time is specified, and the microcontroller, sensor circuit, and cellular modem are put into a low-power sleep mode. The circuit remains in the low-power mode until the next measurement time, a two-hour interval, when an internal alarm is sent, and the microcontroller is awakened. It is powered on and the measurement and data-transmission process is repeated.
To provide timely and convenient access to sensor data, the data are sent to an internet-based data-hosting service. The service, ThingSpeak viewing of a data stream from any location using a standard web browser. To encourage initial exploration of the use of web-based data-hosting services, Thing-Speak allows a user to have access to the website at no cost. To set up a webpage, the user creates a log-in account and configures the incoming data stream (number of data values, description of the data) and output data graphs (length of data series, graphical features). A unique channel number is assigned to the webpage, used to view the specific webpage, and a keycode is generated that is used to upload data to the webpage. To upload data, a website URL is assembled in a specific format containing the address of the data-hosting website, the webpage's keycode, and data-stream values. The URL is sent and when the webpage receives the data stream, the output data graphs are updated immediately. The data streams are stored on the ThingSpeak website and the user can download all data values for use elsewhere or for further analysis at any time.

Field Deployment
Soil-moisture monitoring systems developed in this study were deployed in

Conclusions
A variety of sensing and monitoring systems have been developed for remote monitoring in agricultural and environmental applications. As advances in electronic  Internet of Things applications and gain information to address specific needs.

Disclaimer
Mention of a trade name, proprietary product, or specific equipment does not constitute a guarantee or warranty by the United States Department of Agriculture and does not imply approval of the product to the exclusion of others that may be available.