Astechnology moves forward and the need for space where to live and consumerproducts increases, the human species causes a great impact on nature, damaging, consuming resources in a non-responsible way, modifying the climate, etc. In a similar way, more and more people are interested in investigating and protecting natural areas and the species of flora and fauna which inhabits them, despite the efforts of a few in the recent decades, the negative effects produced by humans are still greater.
It is very important to use technology as the main block to help nature, which ultimately helps humanity.This project aims to do that, to use technology to help conservation of naturethrough the use of sensors and wireless communications. The project consists of a data collection system that helps to know the current state of a natural area and to predict the future state of it. This project doesn’t require constant maintenance, since it’s powered by solar energy, which can be stored in batteries for when there’s no sun and has weatherproof components. The collected data is sent through the Sigfox network and then transferred to an Ubidots online database.
OBJECTIVES1. General
Develop a monitoring system for endangered species and it's habitats.
2. Specifics
· Design a monitoring system forendangered species, like the axolotl of Alchichica.
· Generate the mandatory documentation so the system can be replicated.
· Design and manufacture a specialized PCB for the integration of the system.
· Design a flotation device to test the system in the Alchichica lagoon.
THEORETICAL FRAMEWORKAprotected natural area in Mexico is one over which the nation has jurisdiction, either because it needs to be preserved, restored, or protected. At presentthere are 176 protected natural areas in Mexico, comprising more than 25million hectares.
In this case, we get focus in the application of the system in Alchichica's lagoon, which is a particular place where the Axolotl lives. This specie of Axolotl is imposible to found in other place, that is the principal characteristic of the endemic species which we want to protect in this part of the proyect.
Sigfox is a complete system for the Internet of Things, comprised of an antenna network, which works using Ultra Narrowband or UNBat 200 kHz. This allows the transmission to be fast, long range, with highnoise immunity and at a low energy consumption rate, a lightweight protocol tosend and receive data, which allows data up to 12 bytes long to be sent and asoftware which lets the complex computing to be managed in the Cloud, this software allows to redirect the data to other online applications.
In order to store the data, the Ubidots platform is used, this is asystem to collect, analyze and visualize IoT data. Ubidots has graphic toolslike indicators, plots, switches, etc. this makes easier to understand andinterpret the data.
METHODOLOGYThe data that can be collected with the prototype are: air temperature, watertemperature, Earth temperature, humidity in the air, humidity in the Earth, amount of precipitation, wind speed, water PH, water salinity and probabilityof rain.
The following sensors are required to collect this data:
- The temperature and humidity sensor AM2315. This sensor contains a thermistor temperature sensor and a capacitive humidity sensor. A small microcontroller inside does the readings and providesa simple I2C interface for reading the finished & calibrated output data. Especially nice is that this sensor is in a rugged case with mounting bracket, which makes it way superior to a normal PCB-mounted sensor.
The connection is very simple you need to connectthe red wire to 5V power, black to ground, yellow wire to your i2c data pin, and the white wire to the i2c clock pin. If you want to learn more about I2C with going to let you a great tutorial explanation created by SparkFun in the extra information part.
- The Earth temperature and humidity sensor SHT10 includes a dual-use sensor module from Sensiron in a sinteredmetal mesh encasing. The casing is weatherproof and will keep water fromseeping into the body of the sensor and damaging it but allows air to passthrough so that it can measure the humidity outside. While it is designed to besubmersible in water, it's always best to avoid long-term (over 1 hour at atime) submersion, and it obviously would only give you temperature readings.
The sensor is essentially just a Sensiron SHT-10with the 4 data/power wires brought out so any SHT-1X code for amicrocontroller will work. The sensor works with 3 or 5V logic. The 1-meterlong cable has four wires: Red = VCC (3-5VDC), Black or Green = Ground, Yellow= Clock, Blue = Data. To the function of the sensor is necessary to connect a 10K resistor from the blue Data line to VCC.
- The water temperature sensor DS18B20, Handy forwhen you need to measure something far away, or in wet conditions. While thesensor is good up to 125°C the cable is jacketed in PVC so we suggest keepingit under 100°C. Because they are digital, you don't get any signal degradationeven over long distances! These 1-wire digital temperature sensors are precise(±0.5°C over much of the range) and can give up to 12 bits of precision fromthe onboard digital-to-analog converter.
They work great with any microcontroller using a single digital pin, andyou can even connect multiple ones to the same pin, each one has a unique64-bit ID burned in at the factory to differentiate them. Usable with 3.0-5.0V systems. The connection is with three wires Red connectsto 3-5V, Blue/Black connects to ground and Yellow/White is data.
- The weather sensor. this sensor isused to measure the amount of precipitation, wind speed and wind direction; inthe prototype only the wind speed and the amount of rain are used. Rain is measuredwith a container that when full is automatically emptied and sends a digitalpulse, which must be recorded by the microcontroller, the number of times it isactivated is proportional to the amount of rain. The wind speed is measured bycounting the number of pulses per unit of time sent by the sensor, the numberof pulses is proportional to the wind speed.
None of the sensors in this kitcontain active electronics, instead they use sealed magnetic reed switches andmagnets so you’ll need to source a voltage to take any measurements. The positive side of this is that the sensors are easy to interpret:
- PH sensor ph-4502C. This is the Vernier pH Sensor, a simple device that can be used to measure the acidity andbasicity of liquids. This Vernier sensor can be used in a multitude ofapplications including acid-base titrations, pH monitoring in home aquariums, analysis of water quality in lakes and streams, and more.
Each pH sensor probe is a sealed, gel-filled, type with a hard-outer epoxy body that can function in a temperature range of 5to 80°C. Additionally, these sensors can test in the typical pH range of 0-14and each have an accuracy of +/- 0.2 pH units.
- Atmospheric pressure sensor(ICP-10100): this sensor measures the barometric pressure. It uses the I2Cprotocol to communicate with the microcontroller, so it requires two pull-upresistors in the data and clock lines, in addition to the voltage and groundline. The sensor is very low consumption. It is powered with 1.8 V.
- The salinity sensor precisely measures the total dissolved salt content of ocean or brackish water, Thissensor easily and precisely measures thetotal dissolved salt content in an aqueous solution. Measure water with a widevariety of salinities, from brackish water to ocean water, and evenhyper-saline environments. You can also study how salinity affects buoyancy ormonitor salinity values in estuaries where fresh water mixes with ocean water.
The circuit in basically composed by three sections:
The power part consists of a screw terminal and a LM7805 voltage regulator so the circuit can be powered from an external power supply up to 35 V e.g. lead acid battery, solar panel, 12 V power supply, etc. The circuit can be powered from 5V through the programming pins.
The logic control section consists of an Atmega328p, which is a low-power 8-bit AVR microcontroller, has 32 KBytes of flash memory and works at 16 MHz, this is the one used on Arduino UNO boards. It has 5 Grove connectors for I2C sensors and 6 Grove connectorsfor analog/digital sensors, it also has the pins to connect a WSSFM10R2 Sigfox module. It has a MOSFET to power on/off all the sensors when needed to save energy. It also has a reset button if needed.
The programming part consist of a FT232 IC to program the microcontroller directly through USB and a programming pin header with ICSP pins and serial pins (TXRX).
The dimensions of the circuit are 50 x 100 mm.
To design this circuit and all the context for de sensor, we started using an microcontroller based in Atmega328p just like the Arduino UNO genuine, just to confirm the correct operation of the sensors used and communication between our sigfox module with the microcontroller.
After all the design and manufacturing process, the final circuit solder and working is in the next image.
SYSTEM INTEGRATION
The project consist in to general parts, in this project you can see the firts one, without solar power source and the floating system, this because we don't count with enought time for that.
For the integration we use a cabinet with particaly characteristics, which has the necessary to stay in a open environment, this cabinet have more than enought to put up extreme weathers, all this just because the Alchichica's lagoon have a incredible weather, which is pretty difficult to predict. Now, the floating part is complete necessary, the sensing of the lagoon could be just if the data is colleted from where the lagoon reaches thirty meters deep, all this information is interpreted by a biologist. who gives us the necessary to selec the sensors tha we choose.
Is important to say that this project is complete focus in a specific axolotl specie, which only habits in Alchichica, also the cabinet represent the way of the project to be a floating system in the lagoon, but is posible use all the information to creat your own monitoring system with out circuit, which is design for a lot of differents species categories, even the cabinet could be changed for something more common or resistant, in the last part of the project we goint to give you the pattern to search and select yours sensors.
The preliminary model is in the next picture, when you can see the firts part of our project.
SEND DATA TO INTERNET
In this project we used two internet of things platformsto send data to internet and collect it. One of them is sigfox which is beenused to received data of an easy way and send to other platform in this case Ubidots which is our data base and visual interface of the project.
- SIGFOX
Is a French company founded in 2009 that buildswireless networks to connect low-power objects such as electricity meters andsmartwatches, which need to be continuously on and emitting small amounts of data.
Sigfoxoffers secure, bidirectional and ready-to-use communications services in orderto discover the potential of the Internet of things. We provide a standard formof compilation and device data with a single set of standards-based APIs.
To make your understanding easier, will be shown the next diagram extracted of the official web site of sigfox.
HOW IT WORKS
Its operation is very simple, the sigfox module mentioned above is connected directly to the circuit with its pins TX, RX, VCC and GND.
Sigfox official web site
This is an example to declarate the variables
To programing it was used the open-source Arduino software (IDE). All codes is in attachments secction.
First, is important to mention that the way that sigfox recieved data is in hexadecimal form. Because of this all the values that be decimal have to be tranform to hexadecimal form. The next code is an example to do this conversion.
In this first part we have defined 6 variables (this could be our mesures),, also have a character array and 2 character variables and 2 integer variables
#define Variable1 3.5
#define Variable2 17.5
#define Variable3 37.6
#define Variable4 161
#define Variable5 187
#define Variable6 255
#define Variable7 100
#define Variable8 5
char s[15];
int pbit1;
int pbit2;
char bit1;
char bit2;
In the void set up we have the callback to the function "calculo", which do the conversion of decimal value to hexadecimal value
void setup() {
Serial.begin(9600);
calculo(Variable1);
s[0]=bit1;
s[1]=bit2;
calculo(Variable2);
s[2]=bit1;
s[3]=bit2;
calculo(Variable3);
s[4]=bit1;
s[5]=bit2;
calculo(Variable4);
s[6]=bit1;
s[7]=bit2;
calculo(Variable5);
s[8]=bit1;
s[9]=bit2;
calculo(Variable6);
s[10]=bit1;
s[11]=bit2;
calculo(Variable7);
s[12]=bit1;
s[13]=bit2;
calculo(Variable8);
s[14]=bit1;
s[15]=bit2;
Serial.print(" ");
for(int i=0; i<=15; i++){
Serial.print(s[i]);
Serial.print(" ");}
}
This convesrion will make only one time.
void loop() {
}
The function calculo take the decimal value and do the coversion doing a division between 16.
void calculo(int variable){
pbit1=variable/16;
if(pbit1==10 ){
bit1='A';}
else if(pbit1==11){
bit1='B';}
else if(pbit1==12){
bit1='C';}
else if(pbit1==13){
bit1='D';}
else if(pbit1==14){
bit1='E';}
else if(pbit1==15){
bit1='F';}
else{bit1=pbit1+'0';}
pbit2=variable-(pbit1*16);
if(pbit2==10 ){
bit2='A';}
else if(pbit2==11){
bit2='B';}
else if(pbit2==12){
bit2='C';}
else if(pbit2==13){
bit1='D';}
else if(pbit2==14){
bit2='E';}
else if(pbit2==15){
bit2='F';}
else{bit2=pbit2+'0';}
Serial.print(bit1);
Serial.print(bit2);
}
This is an example of how send data to sigfox with Arduino Uno.
This is the declaration part of varibales and libraries. In this, we enable two pins such as clock and data. And declarate a constant integer and character array to send hexadecimal data.
#include <SoftwareSerial.h>
SoftwareSerial Sigfox(2, 3); // RX, TX
const int boton=6;
char RespuestaSigfox[50];
The void set up contains the pin mode of the button and pin7, also enables the two serial ports.
void setup() {
Serial.begin(9600);
Sigfox.begin(9600);
pinMode(boton, INPUT);
pinMode(7, OUTPUT);
}
This example is to send data from the official site of sigfox to this type of module of sigfox.
void enviar_sigfox(int x)
{
String bufer="AT$SF=";
char payload[20];
Serial.print("Enviar: ");
Serial.println(x);
//convert the data to bytes and add it to the message to send
String str1;
str1= String(x, HEX);
bufer+=str1;
bufer.toCharArray(payload,16);
//
digitalWrite(7, HIGH);
delay(1000);
enviarcomandoATSigfox("AT");
enviarcomandoATSigfox("AT$RC");
enviarcomandoATSigfox(payload);
digitalWrite(7, LOW);
}
Just send the data to sigfox if the button is low
void loop() {
if (digitalRead(boton)==LOW)
{
enviar_sigfox(60);
delay(2000);
}
}
Commands AT to sed in the serial port to active the data transfer.
void enviarcomandoATSigfox(char* comandoAT){
unsigned long x=0;
while( Sigfox.available() > 0) Sigfox.read();
x = 0;
memset(RespuestaSigfox, '\0',sizeof(RespuestaSigfox));
Sigfox.print(comandoAT);
Sigfox.print("\r\n");
Serial.print(comandoAT);
Serial.print("\r\n");
while(true){
if(Sigfox.available() != 0){
RespuestaSigfox[x] = Sigfox.read();
x++;
if (strstr(RespuestaSigfox, "\n") != NULL){
break;
}
}
}
}
The complete code is in attachments secction (Send to Ubidots).
UBIDOTS
System Integrators and OEMs effortlessly self-construct Internet of Things (IoT) applications and products with Ubidots’ data collection, analysis, and visualization tools to deliver agile solutions that improve a company’s KPIs and/or services.
- Easily Connect, Hardware and Data-sources to the Cloud
- Point-and-click, Cloud Application Development
- White-label customer-specific Applications
Interface of Ubidots
All the variables that are shown in this screenshot were declared in Ubidots in the moment that the hexadecimal data is received and allready declared as variable in sigfox (callback secction).
- SparkFun I2C Tutorial: https://learn.sparkfun.com/tutorials/i2c
- Weather Meters: https://learn.sparkfun.com/tutorials/weather-meter-hookup-guide?_ga=2.22785467.1289028104.1532966942-1777182408.1530047916
- Sigfox Foundation.(2017). Sigfox Technology Overview. JULIO-2018, de SIGFOX Sitio web: https://www.sigfox.com/en/sigfox-iot-technology-overview
- Ubidots Education. (2017). Ubidots. Julio-2018, de Ubidots Sitioweb: https://ubidots.com/
- Dirección de Comunicación y Cultura para la Conservación. (08 deseptiembre del 2016 01:20:58 PM). Áreas Naturales Protegidas. Julio-2018, deSEMARNAT Sitio web: http://www.conanp.gob.mx/regionales/
Comments