How does it work?
Pollution Click is based on the WSP2110, a VOC gas sensor from Winsen. The MQ-135 can detect the presence and concentration of toxic gases in the air, such as toluene, benzene, methanal, and alcohol. It consists of a heater and metal oxide semiconductor material on the ceramic substrate of subminiature Al2O3, which are fetched out by electrode down-lead and encapsulated in a metal socket and cap. Besides its high sensitivity, the WSP2110 is also characterized by a detection range from 1 to 50 ppm for toluene, benzene, methanal, and alcohol.
The WSP2110 provides an analog representation of polluted concentration in the air sent directly to an analog pin of the mikroBUS™ socket labeled OUT. The analog output voltage the sensor provides varies in proportion to the toxic gas concentration; the higher the toxic gas concentration in the air, the higher the output voltage. Also, this Click board™ has a built-in potentiometer that allows users to adjust the load resistance of the MQ-135 circuit for optimum performance. The ENA pin can be used to enable the gas sensor.
This Click board™ can be operated only with a 5V logic voltage level. The board must perform appropriate logic voltage level conversion before using MCUs with different logic levels. However, the Click board™ comes equipped with a library containing functions and an example code that can be used, as a reference, for further development.
Specifications
Type
Air Quality,Gas
Applications
Can be used for the development of domestic and industrial gas alarms and portable gas detectors
On-board modules
WSP2110 – VOC gas sensor from Winsen
Key Features
Low power consumption, high sensitivity, fast response, stable and long life, simple drive circuit, sensitivity adjustment, and more
Interface
Analog,GPIO
Feature
No ClickID
Compatibility
mikroBUS™
Click board size
M (42.9 x 25.4 mm)
Input Voltage
5V
Pinout diagram
This table shows how the pinout on Pollution Click corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).
Onboard settings and indicators
Label | Name | Default | Description |
---|---|---|---|
LD1 | PWR | – | Power LED Indicator |
P1 | – | Populated | Calibration Potentiometer |
Pollution Click electrical specifications
Description | Min | Typ | Max | Unit |
---|---|---|---|---|
Supply Voltage | – | 5 | – | V |
Detection Range | 1 | – | 50 | ppm |
Software Support
We provide a library for the Pollution Click as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Package can be downloaded/installed directly from NECTO Studio Package Manager (recommended), downloaded from our LibStock™ or found on Mikroe github account.
Library Description
This library contains API for Pollution Click driver.
Key functions
-
This function read ADC data.
-
This function gets load voltage from read ADC value.
-
This function gets the corrected resistance of the sensor.
Example Description
Example code reads ADC value and measures quantity of organic gases in the air.
void application_task ( void )
{
pollution_data_t tmp;
tmp = pollution_generic_read( &pollution );
log_printf( &logger, " ADC value : %d ppmrnn", tmp );
Delay_ms( 1000 );
value_volt = pollution_measure_load_voltage( &pollution, tmp );
log_printf( &logger, " Load voltage : %0.2f Vrnn", value_volt );
Delay_ms( 1000 );
value_res = pollution_get_corrected_resistance( &pollution, tmp );
log_printf( &logger, " Corrected resistance : %0.2f kOhmrnn", value_res );
log_printf( &logger, "---------------------------------------------rnn" );
Delay_ms( 1000 );
}
The full application code, and ready to use projects can be installed directly from NECTO Studio Package Manager (recommended), downloaded from our LibStock™ or found on Mikroe github account.
Other Mikroe Libraries used in the example:
- MikroSDK.Board
- MikroSDK.Log
- Click.Pollution
Additional notes and informations
Depending on the development board you are using, you may need USB UART click, USB UART 2 Click or RS232 Click to connect to your PC, for development systems with no UART to USB interface available on the board. UART terminal is available in all MIKROE compilers.
mikroSDK
This Click board™ is supported with mikroSDK – MIKROE Software Development Kit. To ensure proper operation of mikroSDK compliant Click board™ demo applications, mikroSDK should be downloaded from the LibStock and installed for the compiler you are using.
For more information about mikroSDK, visit the official page.