Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //this outputs pot value to screen in ohms
- int gasSensor = 0; // select input pin for gasSensor
- int val = 0; // variable to store the value coming from the sensor
- void setup() {
- Serial.begin(9600);
- }
- void loop() {
- val = analogRead(gasSensor); // read the value from the pot
- Serial.println( val );
- delay(100);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement