Hi i am new here, And i am currently working on a project for a biogas monitoring system. I am currently working on the sensor as i am speaking. And i would like to ask about how do i make sure that the sensor i am using is calibrated properly for its intended use. And for more information this is a sensor that i bought online with the module included. This is the source code i am working on:
#define MQ136_PIN 34
#define VCC 5.0
float Ro = 17000;
void setup() {
Serial.begin(115200);
Serial.println("MQ-136 H2S Sensor Initialization...");
}
void loop() {
int sensorValue = analogRead(MQ136_PIN);
float Vout = sensorValue * (VCC / 4095.0); // Convert ADC value to voltage
float Rs = (VCC - Vout) * Ro / Vout;
float ratio = Rs / Ro;
float H2S_ppm = 10 * pow(ratio, -1.43);
// Print results
Serial.print("Raw ADC Value: ");
Serial.print(sensorValue);
Serial.print(" | Voltage: ");
Serial.print(Vout, 2);
Serial.print("V | Rs: ");
Serial.print(Rs);
Serial.print(" ohms | H2S Concentration: ");
Serial.print(H2S_ppm, 2);
Serial.println(" ppm");
delay(1000);
}
I am just aking opinions on should i go to company that has a calibration service to help me on making sure that the sensors are producing the right outputs or should i just stick to the datasheet and experiment more?
6 posts - 4 participants