Final project [trouble shooting]

I have used Mq2 Gas sensor for detection gas and smoke… but when I created smoke it is not detecting the smoke… I am not understanding the problem…
this is the exact circuit connections I made but with different colours of jumper wires.
even I gave smoke with incense stick there was no change in the value.

my code:

PinOut of MQ2 is VCC - GND - Signal right? (From left to right)

I am sorry I didn’t get you

Send a snap of your MQ2 where your pin names are written.

And I want t know that weather both the Lights(i.e., red and yellow) of MQ2 sensor will glow or only one (red) light. In my case only red light is glowing and yellow light is glowing when I created smoke, but the value is not changing in the output.

can someone please answer

There is definitely something wrong with your connections. The LED glows when it detects the smoke, right. So, your sensor is working fine.

Your MQ2 sensor’s VCC is connected to 5V of bolt right? Please check it.

Your circuit looks pretty incorrect to me honestly. LED and buzzer connections wrong.

Also, in the diagram, your black wire of buzzer isn’t connected anywhere. Nothing to do with sensor data but still.

If you are using a mini buzzer, longer pin is +ve (signal) and shorter pin is -ve (GND)

If you are using colored wire buzzer, Red is +ve (signal) and black is -ve (GND)

For LED, refer -

these are the connections I made…Screenshot 2021-07-22 130251

Check the connections physically if that’s exactly what you have done.
Share a clear image of the circuit connections you made.

Other than this, you can use a screwdriver to calibrate the sensor threshold. The + valve inside the blue box on the sensor, works like variable resistor. You can start the python program and turn the valve to left or right according to your requirement, see for any changes in the values.
-If there is no change, then return the valve to its original position.