A Low Cost Wireless Data Acquisition System for a Remote Photovoltaic (PV) Water Pumping System

This paper presents the design and development of a 16F877 microcontroller-based wireless data acquisition system and a study of the feasibility of different existing methodologies linked to field data acquisition from remote photovoltaic (PV) water pumping systems. Various existing data transmission techniques were studied, especially satellite, radio, Global System for Mobile Communication (GSM) and General Packet Radio Service (GPRS). The system’s hardware and software and an application to test its performance are described. The system will be used for reading, storing and analyzing information from several PV water pumping stations situated in remote areas in the arid region of the south of Tunisia. The remote communications are based on the GSM network and, in particular, on the Short text Message Service (SMS). With this integrated system, we can compile a complete database of the different parameters related to the PV water pumping systems of Tunisia. This data could be made available to interested parties over the Internet.


Introduction
With its good geographical location with respect to solar irradiance, Tunisia is considered one of the better placed countries for the utilization of solar energy.Photovoltaic (PV) water pumping is one of the principal solar applications in Tunisia, and there are several PV water pumping stations situated in remote areas in the arid region in the south of Tunisia.
Accurate information about the photovoltaic water pumping system parameters at a given location is essential to the development of this type of project.This information (in particular, water flow rate, voltage and current of the photovoltaic field, in addition to other meteorological information such as global solar irradiation on an inclined and horizontal surface and ambient temperature) is used in the design, cost analysis, and in calculations on the efficiency of a project.
For Tunisia, these data are not easily available due to the cost and maintenance and calibration requirements of the measuring equipment.Therefore, it is important to assemble a complete data base of the different parameters related to the PV water pumping systems in Tunisia.This data could be made available to interested parties on the Internet.
The utilization of electronic systems to automate experiments will thus make easier the acquisition of meteorological data in such regions.Currently, several instruments using conventional electronics or based on microprocessor data acquisition system are used to collect, register, integrate and record meteorological data and most of them are especially designed for solar energy applications [1][2][3][4][5][6][7].
More recently, Koutroulis [8,9] proposed a computer-based data-acquisition system for monitoring both meteorological data and operational parameters of a renewable energy sources system.The paper of Belmili et al. [10] presents a computer-based instrumentation system for the characterization of the photovoltaic (PV) conversion process.It is based on a data acquisition system (DAQS) design allowing the acquisition and plotting of the characterization measurements of PV modules under real meteorological test conditions.In 2008, Rosiek et al. [11] also built a data acquisition system for solar and environmental monitoring.The system is based on an ATmega 16 microcontroller, which scans eight sensors together at any programmable interval.The paper presents a study of the mentioned project, applications and some main characteristics of the prototype system and its programs.
Benghanem [12] set up an experimental microcontroller-based system to acquire the data issued from a PV installation at an isolated site.This work presented the design of a universal data acquisition system assembled from readily available components and easily accessible from a central server.In 2010, a Wireless Data Acquisition System (WDAS) using a PIC16F877 microcontroller was developed by Benghanem [13,14].The proposed WDAS is based on precision electronic circuits and a graphical environment using the LabVIEW software for processing, displaying and storing the collected data.
A paper by Tseng et al. [15] studied the feasibility of field data acquisition using GSM-SMS technology for efficient field measurements of environmental parameters in precision agriculture.The SMS data format was designed to transmit measured field data and a prototype testing system was set up to perform the associated experiments.The parameters considered included measurements of time, location, temperature, humidity, wind speed, and number of captured pests.
In this article a microcontroller-based data-acquisition system was devised.This system, described in the following sections, was designed around the 10-bit 16F877 microcontroller and will be applied to remote PV water pumping systems.This specific microcontroller was selected in order to produce a fast and low cost prototype.The information from the sensors goes to the microcontroller, where it is processed and later sent to an external EEPROM memory and passed on to a personal computer via a Global System of Mobile Communication (GSM) network and, in particular, using the Short text Message Service (SMS).

Methodology
In this section, a data acquisition system (data logger) design and the various existing techniques for remote data transmission are described.The data logger consists of a set of sensors for measuring both meteorological (e.g., solar irradiance, temperature, etc.) and photovoltaic parameters (water flow rate, photovoltaic voltage and current, etc.).The collected data are first conditioned using precision electronic circuits and then transmitted to a personal computer (PC).Figure 1 below shows the schematic diagram of an existing system design.The information from the data logger can be transmitted via direct connections such as USB, RS232, RS485 or Ethernet or remote transmission methods such as radio modems, satellite, the Internet or GSM modems/GPRS to a PC, where they are processed using the appropriate data acquisition software.Suitable software is then used to further process, display and store the collected data on the PC's data storage system.
Figure 2 shows a general scheme of the various possibilities for field data collection and its transmission to a personal computer.Bearing in mind the above considerations, we first analyze the advantages and disadvantages of some of these systems.

Transmission by Satellite
The use of the satellite data transmission offers a tempting approach for distant sites or sites with difficult alternate access, where it is impossible to install a telephone line or a radio operator network.The communication is made possible by interfacing a measurement station with a satellite transmitter, which transmits the data from the site to a reception station, as presented in Figure 3. Transmitters, antennas, interface cables and software, as well as the system considerations (for example; the width of available coverage, the transmission window, the cost and any restrictions) vary according to the satellite system used.The majority of the communications options can be integrated into our system.Satellites have great spatial and temporal coverage and are very useful in places without access to telephone lines, but it is a very expensive method with its main disadvantage being the high cost of its installation.

Transmission by GSM Modem/GPRS
The following is a description of information transfer from a data logger to a GSM Modem.Nowadays the use of mobile phones, especially GSM/GPRS, is being successfully implemented in the field of data transmission.Figure 4 presents the general scheme of field data transmission through a GSM Modem/GPRS.The information from the sensors goes to the data logger where it is processed and it is passed by an RS 232 or USB interface to the GSM Modem (SIM card), and later sent to a connected PC by another modem.In the case of the data transmission failure caused by a problem with the circuit or the GSM Modem, it remains stored in the memory.Its main advantages are the flexibility and unlimited reach, although the latter is restricted somewhat by the cellular phone penetration rate.Another advantage is the low cost per amount of transmitted data, as well as the optionality of remote control of the equipment and simple power requirtements.

Transmission by Radio Modem
Radio offers the possibility of sending and receiving a huge amount of information with reduced transmission costs.It is also a good alternative in the case of the lack of telephone lines.Its main disadvantage is the difficulty in obtaining permission to access the transmission frequency and the high price of its installation.
The data logger stores the information retrieved by the sensors until the radio modem requests the data.The Radio Modem Base Station is connected to the computer or server.The radio modem is usually running in hibernated state until base station requests a connection.The devices are presented in Figure 5.

Description of the Developed Data Logger
In this section we present a description of the field data-acquisition system developed to collect and transmit the information from the sensors down to the PC.The collected data are first conditioned using precision electronic circuits based on the 16F877 microcontroller and then interfaced to a PC using an RS232 connection.Figure 6 presents a schematic of the system design.The following is a description of the components of the data-acquisition system.The information from the sensors goes to the microcontroller, where it is processed and passed to the external 24C32A EEPROM memory and later to PC via the RS 232 interface.The treated data are converted into their real physical values (current, voltage, irradiation, etc.) and used by the personal computer to analyse the performance of the considered photovoltaic water pumping systems.The number of sensors and the signal that these sensors provide have been taken into account when designing this circuit.
Figure 7 presents the scheme of the electronic circuits of the data logger on the ISIS program.The block diagram of the interface circuit consists of two sub-circuits: the data acquisition section and the serial communication part.The interface is based on a 10-bit microcontroller (the 16F877) operating at 20 MHz, which handles all the different processes through the corresponding software.Table 1 presents the components of the electronic circuits of the data logger.The 16F877 microcontroller was specifically selected for this project in order to produce a fast and low cost prototype; it has the right mix of program and data memory.The microcontroller includes 8 Kb of internal flash program memory, together with a large RAM area and an internal EEPROM and three timers (one 16-bit timer with two 8-bit timers).An 8-channel 10-bit A/D converter is also included within the microcontroller, making it ideal for real-time systems, and monitoring applications.All port connectors are brought out to standard headers for easy connection and disconnection.
The external 24C32A EEPROM memory is a 4 K × 8 (32 K bit) Serial Electrically Erasable PROM.It has been developed for advanced, low power applications such as personal communications or data acquisition.The 24C32A also has a page-write capability of up to 32 bytes of data.It is capable of both random and sequential reads up to the 32 K boundary.Functional address lines allow up to eight 24C32A devices on the same bus, for up to 256 K bits address space.
The LF398 integrated circuit is ideally suited for a wide variety of sample-and-hold applications, including data acquisition, analog-to-digital conversion, synchronous demodulation, and automatic test setup.
The PIC16F877 is programmed using C language.The visualization of the data acquisition system results on the computer (PC) requires the implementation of a graphic interface.The desktop application was developed using WinDev10 ® .It has a communication control that provides access to the serial port for communication purposes.The desktop application is used to further process, display and store the collected data on the PC's disk. Figure 9 shows the data acquisition software interface.

Power Supply
The power supply shown in Figure 10 is an essential element of our data acquisition system; it provides the necessary voltage to supply the circuit.It must ensure good performance in terms of stability and regulation.It comprises the 5 V, 12 V power supply and the ±15 V power supply from a 9 V battery.It must provide +15 V and −15 V controlled and stabilized voltage for the current sensor using an NE 555 and 1N4148.It provides a stabilized power supply of 5 V for the microcontroller and the integrated circuits using a 78L05 voltage regulator.It should stay stable and regular at the time of the conversion.It provides a stabilized 12 V power supply for the 4-20 mA loop of a flow meter using a 78L12 voltage regulator.

The Sensors and the Interface Circuits
The sensors provide the measurement interface between the sensor systems, using the variations in physical phenomena to measure analog parameters.All analog signals are sampled sequentially and the input voltage data are calibrated to correspond to actual physical units.The calibration equations have the general form: where y i is the i th sensor output in physical units, x i is the i th sample and a i , b i are calibration constants.The proposed system consists of a set of sensors (it can record up to six different sensors) for measuring both meteorological (e.g., solar irradiance, temperature, etc.) and photovoltaic parameters (water flow rate, photovoltaic voltage and current, etc.).
The global solar radiation on an inclined and horizontal surface (H t , H) are the principal measured parameter, while pumped water flow rate, the ambient temperature, voltage and current of photovoltaic field (V, I) are also measured in order to construct a complete data base of the site and the system.The following transducers have been used for the various measurements: a turbine flow meter has been used for the flow rate measurements.These flow meters work in the 0-10 m 3 /h range with an accuracy of ±0.05%.The flow meters give a 4:20 mA analog signal calibrated to the measured flow rate.A solar cell has been used to measure the global solar radiation in the horizontal plane and in the plane of the PV arrays.Ambient temperature has been measured using an LM 35 sensor shielded from the Sun.The DC voltage and current generated by the PV arrays and the AC voltage and current drawn by the pump motors have been measured using Hall Effect transducers of appropriate ranges.The schematic shown in Figure 11, shows the block diagram of the different sensors used and the PIC16F877 microcontroller.

Solar Irradiation Sensor
The solar irradiance measurement in (W/m 2 ) is obtained by the short circuit current for a photovoltaic cell.The method of measurement consists in acquiring the short circuit current I sc which is proportional to the incident solar irradiation E. The calibration of the solar cell allows us to get the short circuit current according to the incident solar irradiation: where K is the calibration factor and H is the incident solar irradiation.Knowing K we will be able to determine solar irradiation E corresponding to a short-circuit current: For our system we used a reference cell which delivers a voltage of about 100 mV for an irradiation of 1000 W/m 2 .However we need a signal between 0 and 5 V which is the voltage level that can be handled by the microcontroller (PIC).Therefore, we need to amplify this voltage delivered by the cell.For our system we have used the TL081 operational amplifier.Figure 12 shows the solar cell device conditioning using the TL081 operational amplifier.

The Photovoltaic Voltage
The maximum voltage delivered by the photovoltaic field is very high.With such a voltage value we cannot directly attack the entry of the sensor.Hence, we need to put in a voltage divider (Figure 13).The acceptable maximum voltage at the entry of the data acquisition system is about 5 V.It is thus necessary to intercalate a voltage amplification montage based on an operational amplifier.For our system we have used the TL081 operational amplifier (Figure 14).

The Temperature Sensor
At the entry of the sensor we will place an LM35probe which is presented in the form of a plastic TO92 reference case.The role of this probe is to convert the temperature into a low voltage signal; it is calibrated in the factory in a way that it outputs voltage about 10 mV/°C, knowing that 0 V is proportional to 0 °C.Figure 15 shows the temperature device conditioning.

The Flow Rate Sensor
The flow meter gives 4-20 mA analog signal calibrated to the measured flow rate.Figure 16 presents a 4-20 mA loop which is made up of a flow meter, a XTR105 transmitter and a RCV420 receiver which carries out the power of the loop and converts the 4-20 mA into a voltage varying from 0 to +5 V.
Figure 16.The flow meter device conditioning.

The Photovoltaic Current
For the current measurement, we used a Hall Effect sensor.This sensor converts the current delivered by the PV module into a low voltage signal which will be introduced into the microcontroller.

Remote Data Transmission
Nowadays, the use of mobile phones, especially GSM/GPRS, is being successfully implemented in the field of data transmission.Having analyzed various techniques in Section 2, we suggest that the field data transmission through the GSM/GPRS modem offers the most significant advantages.In the above project, the transmission was based on the GSM cellular network.In particular the GSM short message or the SMS service, available on such networks, was extensively adopted and will be described in this section.
The GSM short message service has the characteristics of always being online, no dialing, low price, large coverage, etc.For GSM technology, short message service is the only one where no end-to-end channel set up is needed and it also provides service when the mobile device is in point-to-point communication.Short message service is a synchronous communication system for sending only one sentence per message.In a GSM system, each message is handled at an individual time and transmitted by a Short Message Service Center (SMSC).
GSM can offer speeds of up to 9.6 Kbps data communication service when on-line, whereas GPRS can offer speeds of 100 Kbps.Considering the circuit breaker data acquisition feature and the cost of communication, the GSM short message service is suitable for transmitting data in large-scale field measurement systems.There are two forms of short message service.One is point-to-point, message transmission from one user to another.The other is plot radio, where the message is sent to all registered users by SMSC.Because the point-to-point short message needs no specialized communication channel and the cost is cheap, it was adopted.
Each short message can transmit 160 encoded data of 7 bits or 140 coded data of 8 bits or 70 UNICODE code.Therefore, a GSM short message could be used to transmit data and commands for measurement and control systems which have low demands in real-time and transmission speed, so new investments for building a wireless communication network could be avoided.
The GSM module is the kernel part to realize wireless data transmissions.A MC45 wireless communication module based on the GSM standard and produced by Siemens was used in the developed application (Figure 17).Designed for use on any GSM network in the world, the Siemens MC45 is a triband GSM/GPRS engine that works in the three frequencies (GSM 900 MHz, GSM 1800 MHz and GSM 1900 MHz).The MC45 features Multislot class 10 GPRS and supports the GPRS CS-1, CS-2, CS-3 and CS-4 coding schemes.It consists of mainframe, antenna, serial communication line and power line and it provides wireless modem, wireless fax, short message and speech communication services [16].Figure 18 shows a block diagram of the MC45 module and illustrates the major functional components:  GSM/GPRS baseband block composed of: baseband controller operating at 26 MHz, ASIC power supply, flash, SRAM and application interface (board-to-board connector).
 GSM RF block composed of: RF transceiver, RF power amplifier and RF front end (antenna connector).
The short message service is suitable in the situation of data transmittance for PV water pumping systems.Remote access solutions are potentially great enhancements for digital industrial control systems because they permit an easier interface to information management systems and reduce the necessity of human presence at a system's site.Remote access hardware may not be the same in both parts, for example a GSM modem attached to control system communicates with a normal PSTN modem or even over the Internet.
Hardware architecture of an embedded system with GSM remote access capabilities is very simple; a GSM/GPRS modem is attached to one serial port of the existing system's microcontroller and software modules for communication are added to existing firmware (Figure 19).Efforts are mostly in software side, but care should be taken to avoid possible EMC problems caused by the GSM module, especially if antenna is very close to sensitive analog lines (the analog to digital converter's lines, reset or interrupt request lines of the microcontroller).Also noise on power supply lines can be a problem due to repetitive current peaks generated by the GSM module during transmission.There are two methods of sending and receiving SMS (Short Message Service): by using the text mode or by using Protocol Description Links (PDU) Mode.For our application, the first mode was chosen owing to the fact that it is simpler to use.The text mode is based on standard AT commands, and with these commands one can read, send, erase and receive SMS in text mode.

Description of the PV Water Pumping Systems
In this work, two solar water pumping stations were selected as the case study.The first station is named Bel Khchab (33.10 N, 10.05 E) and the second station is named Om Chraket (32.55 N, 11.33 E).Both stations are located at isolated sites with a Saharian climate near the city of Medenine in Southern Tunisia.The two systems are used for pumping potable water.A PV water pumping system (PVWPS) consists of a PV array, inverter, submersible pump, storage tank, and an auxiliary system of measuring devices and weather monitoring sensors; the two stations work without storage batteries.Photographs and characteristics of the PV pumping stations are shown in Figure 20 and Table 2, respectively.The modules in the two stations are mounted on a supporting structure so that the surface azimuth angle and the inclination angle of the modules are zero and 35°, respectively.

Results and Discussion
The experimental data registered in our data logger during one complete year (2009) at one hour time intervals and transmitted from the remote photovoltaic water pumping systems in the desert of Tunisia (located about 150 km from Medenine city) to the PC via the MC 45 GSM modem were analyzed.Tables 3 and 4 show the results obtained for the PV water pumping system (Bel Khchab Sstation) for four days during the months of January, March, July and October, respectively.The desert area of Medenine, in the South of Tunisia, benefits from a very significant irradiation for which the chances of success of the use of PV water pumping systems can be considered to be very strong.The mean monthly irradiance in the plane of the PV array of Medenine city is plotted in Figure 22.We find that the maximum of global solar radiation is high throughout the summer months, reaching 281 kWh/m 2 per month, and in the spring it was 274 kWh/m 2 per month.In autumn and winter we find values of 208 kWh/m 2 per month and 171 kWh/m 2 per month, respectively.Another factor which is prejudicial to the good behavior and the efficiency of the PV array is the ambient temperature.We can see in Figure 23

Conclusions
This work presents the design and the development of a wireless data acquisition system (data logger) for remote photovoltaic water pumping systems using a PIC16F877 microcontroller.The proposed wireless data acquisition system is based on precision electronic circuits and a graphical environment based on the use of the WinDev10 ® software for processing, displaying and storing the collected data.This data has been analyzed in order to evaluate the performance of a photovoltaic water pumping system.The transmission of these data to a personal computer is achieved using a GSM network and, in particular, the short text message service (SMS) based on a Siemens MC45 GSM/GPRS Module The contribution of this work is to control the functioning of remote PV water pumping systems and also to provide the different data under real conditions.The transmission of the data by a GSM network reduces considerably the cost of the system management.The data logger offers good performance at a low cost, compared with commercial data-acquisition systems.

Figure 1 .
Figure 1.Data from the PV water pumping station to the personal computer.

Figure 3 .
Figure 3. Scheme of field data transmission through satellite.

Figure 4 .
Figure 4. Scheme of field data transmission through the GSM Modem/GPRS.

Figure 5 .
Figure 5. Scheme of field data transmission through the Radio Modem.

Figure 6 .
Figure 6.Schema of system design.

Figure 7 .
Figure 7. Scheme of the electronic circuits of the data logger on the program ISIS.

Figure 9 .
Figure 9. Interface of the data acquisition software.

Figure 10 .
Figure 10.Power supply for our data logger.

Figure 11 .
Figure 11.The sensors and interface electronic circuits in the remote station.

Figure 12 .
Figure 12.The solar cell device conditioning.
U e is the output voltage, U e' is the PV field voltage and R 1 , R 2 are the voltage divider resistances.R 1 = 100 Ω, R 2 = 100 kΩ, if the voltage of the PV field as U e' = 200 V, we get: U e ≈ 0.2 V.

Figure 14 .
Figure 14.Voltage divider connected to a precision instrumentation amplifier.

Figure 19 .
Figure 19.GSM/GPRS MC45 module attached to a RS 232 serial port.

Figure 20 .
Figure 20.Photographs of the Bel Khchab (a) and Om Chraket (b) stations.(a) (b) The average daily quantity water of pumped by Station 1 is about 40 m 3 /day and is about 20 m 3 /day by Station 2. The mean monthly horizontal surface global solar radiation of Medenine city is plotted in Figure 21.From this figure, we find that the maximum monthly mean global radiation occurs in summer with 289 kWh/m 2 per month and in spring with 261 kWh/m 2 per month.In autumn and winter we find 197 kWh/m 2 per month and 153 kWh/m 2 per month, respectively.

Figure 21 .
Figure 21.Variation of mean horizontal surface monthly irradiance of the year 2009 for Medenine.

Figure 22 .
Figure 22.Variation of mean monthly irradiance in the plane of the PV array of the year 2009.
the monthly average variations of the ambient temperature for the year 2009.Temperatures can be very high and reach 44 °C, especially in the period stretching from May to September.

Figure 23 .
Figure 23.Measured monthly average ambient temperature of the year 2009 for Medenine.

Table 1 .
The electronic circuits components of the data logger.

Table 2 .
Characteristics of the PV pumping stations.

Table 3 .
Measured global irradiation on an inclined and horizontal surface by W/m 2 for the pvwps in January 1th, March 16th, July 15th, October 15th, 2009 (Bel Khchab station).