June 15, 2020

Solar Photovoltaic Cell

A solar cell or photovoltaic cell (PV cell) is an optoelectronic device that converts the energy of light directly into electricity by means of the photovoltaic effect, which is generally done by a p-n junction. Although solar cell without p-n junction is available. This process requires firstly, a material in which light absorption raises an electron to a higher energy state, and secondly, the movement of this higher energy electron from the solar cell into an external circuit. The electron dissipates energy in the external circuit and returns to the solar cell. Various materials and processes can potentially satisfy the requirements for photovoltaic energy conversion. Still, in practice, nearly all photovoltaic energy conversion uses semiconductor materials in the form of a p-n junction. The common single-junction silicon solar cell can produce a maximum open-circuit voltage of approximately 0.5 to 0.6 volts.


A photoelectric cell is a device whose electrical characteristics (such as current, voltage, or resistance) vary when exposed to light.


Reference
[1] https://en.wikipedia.org/wiki/Solar_cell
[2] https://www.pveducation.org/pvcdrom/solar-cell-operation/solar-cell-structure





June 06, 2020

Barometer (BMP 280) Interface with Arduino

The BMP280 is an absolute barometric pressure sensor by BOSCH. Its small dimensions and its low power consumption allow for the implementation in battery-powered devices as mobile phones, GPS modules, or watches. We can interface this sensor with Arduino using SPI or I2C communication.

Items required:
  • Arduino Nano
  • BMP280
  • Jumper Wire
Circuit Diagram:
Video Example:
                Coming Soon

Software:

Updated Library:

June 05, 2020

PIR Sensor Interfacing with Arduino

PIR stands for Passive Infrared Radiation. PIR sensors are more complicated than many of the other sensors explained in these tutorials because there are multiple variables that affect the sensor's input and output. To begin explaining how a basic sensor works, we'll use this rather nice diagram.

PIRs are basically made of a pyroelectric sensor (which you can see below as the round metal can with a rectangular crystal in the center),
which can detect levels of infrared radiation. Everything emits some low-level radiation, and the hotter something is, the more radiation is emitted. The sensor in a motion detector is actually split into two halves. The reason for that is that we are looking to detect motion (change), not average IR levels. The two halves are wired up so that they cancel each other out. If one half sees more or less IR radiation than the other, the output will swing high or low.
The second important thing is the lens of the sensor. PIR sensors are rather generic and for the most part, vary only in price and sensitivity. Most of the real magic happens with the optics. This is a pretty good idea for manufacturing: the PIR sensor and circuitry is fixed and costs a few dollars. The lens costs only a few cents and can change the breadth, range, sensing pattern, very easily. In the diagram up top, the lens is just a piece of plastic, but that means that the detection area is just two rectangles. Usually, we'd like to have a detection area that is much larger. To do that, we use a simple lens such as those found in a camera: they condense a large area (such as a landscape) into a small one (on film or a CCD sensor). For reasons that will be apparent soon, we would like to make the PIR lenses small and thin and moldable from cheap plastic, even though it may add distortion. For this reason, the sensors are actually Fresnel lenses:
proximity_frenelling.jpg
OK, so now we have a much larger range. However, remember that we actually have two sensors, and more importantly, we don't want two really big sensing-area rectangles, but rather a scattering of multiple small areas. So what we do is split up the lens into multiple sections, each section of which is a fresnel lens.
To interface, this module all you have to do is to read the OUT pin signal with Aduino's digital pin using the digitalRead(DataPin) function frequently and if there is any signal keep the output high.
Pinout:
  • VCC supplies power for the module. You can directly connect it to the 5V pin on the Arduino.
  • DATA pin logical voltage changes from 0 or 5 Volt with the pH value.
  • GND is the Ground Pin and needs to be connected to the GND pin on the Arduino.
Connecting This device with Arduino is very easy. VCC pin goes to Arduino 5v pin GND pin goes to Arduino Ground Pin and the OUT pin goes to Arduino D2 pin.

Circuit Diagram:


Video Example:

Software:
Interfacing part Only

Introduction to ESP-01

ESP-01 Module is basically a low-cost esp8266 module, with built-in WIFI. It was created as an Arduino WIFI module but it can also be programmed to work as standalone. Although this module is cheap but working with it is a little difficult. As it is not a breadboard-friendly module it would be a bad choice for a beginner.

Less I/O pins make it a little difficult to use in standalone mode in projects. It has 8 pins.

  • Pin1: Ground Pin
  • Pin2: GPIO2 Pin 
  • Pin3: GPIO0 Pin
  • Pin4: RXD is UART data receive pin.
  • Pin5: Vcc is for powering the Module. Only 3.3V power is required.
  • Pin6: RST is for external reset. It's active Low in nature.
  • Pin7: CH_PD is an active-high pin for Chip enable.
  • Pin8: TXD is UART data send pin.
Programming this module is a little difficult as it does not have any type of connector. Although programming can be done using Jumper Wires, NodeMCU and Arduino IDE.

Get the Datasheet from the link below:

January 24, 2020

pH Sensor Interface With Arduino

In chemistry, pH is a scale used to specify how acidic or basic a water-based solution is. Acidic solutions have a lower pH, while basic solutions have a higher pH. At room temperature (25°C or 77°F), pure water is neither acidic nor basic and has a pH of 7.
Here is a chart of different pH of different items.
This tutorial is about the interfacing of the Analog pH sensor with Arduino Nano. Then we display the data using a serial terminal.

What is an analog pH sensor?
Analog pH meter is specifically designed to measure the pH of the solution and reflect the acidity or alkalinity. It is commonly used in various applications such as aquaponics, aquaculture, and environmental water testing.
The sensor signal from the sensor goes to a circuit board that converts the signal to a (0-5) V analog signal easily readable from the Arduino board. All we have to do is to put the analog signal to any Analog pin of the Arduino (Arduino Nano in my case) and read the voltage using ADC.


Pinout:
  • VCC supplies power for the module. You can directly connect it to the 5V pin on the Arduino.
  • Data pin voltage varies from (0-5) Volt with the pH value.
  • GND is the Ground Pin and needs to be connected to the GND pin on the Arduino.
Connecting This device with Arduino is very easy. VCC pin goes to Arduino 5v pin GND pin goes to Arduino Ground Pin and the OUT pin goes to Arduino A0 pin.


Software:



Temperature Measuring Device

OLED and Digital Temperature Sensor(DS18B20) With Arduino.
In the previous section, we interfaced OLED with Arduino and Digital Temperature Sensor (DS18B20) with Arduino separately. Now we are going to merge them together to make a temperature measuring device powered by a standard 5 Volt power supply or a power bank.


Items required:

  • Arduino Nano
  • OLED Display
  • Digital Temperature Sensor (DS18B20)
  • Vero Board
  • Female Header
  • Terminal Block
  • 4.7k Resistance
  • Jumper Wire

Circuit Diagram:

Video Example:

Software:

January 12, 2020

Digital Temperature Sensor (DS18B20) Iterface with Arduino

This project is about the interfacing of a DS18B20 module with Arduino UNO. The data for temperature is displayed on the Serial Terminal and on the next phase we will display the data on OLED Display.

What is Digital Temperature Sensor?

Digital Temperature Sensor(DS18B20) has two parts one measures the data another very basic chip inside that does some analog to digital conversion and spits out a digital signal with the temperature. The digital signal is fairly easy to read using any microcontroller.
Pinout:
  • VCC supplies power for the module. You can directly connect it to the 5V pin on the Arduino.
  • Data pin transmits the temperature and humidity data in digital form.
  • GND is the Ground Pin and needs to be connected to the GND pin on the Arduino.
To connect this sensor to Arduino first we have to include two libraries specially designed for this sensor OneWire.h, DallasTemperature.h. 
Then its time to tell the Arduino in which pin the sensor is connected. For this, we use this code OneWire oneWire(ONE_WIRE_BUS);
Now we have to tell the Arduino what sensor it is, for this we use DallasTemperature sensors(&oneWire);
Finally, we have to start the library by sending sensors.begin();
Then we have to ask the ic to send the temperature by sensors.requestTemperatures();
We can store the temperature in a variable by int temp = sensors.getTempCByIndex(0); 0 (Zero) stands for the first sensor, we can connect more than one sensor in one pin.

After connecting please double-check the connections before powering up the Arduino.












DS18B20 Sensor Library

Functions under this library
sending sensors.begin(); --------------------- Starts the library 
sensors.requestTemperatures(); ------------ Requestes for the reading
sensors.getTempCByIndex(0); -------------- Gives the value of temperature.

Video Example: