How to use force/preassure sensor to send data to domoticz?



  • I want to add a FSR preassure sensor to domoticz using mysensors. But how would a simple sketch that only sends raw preassure value to domotics every sec look like? I guess the Preassure sensor is only some sort of resistor where the resistance changes depenfing on the preassure.

    But are there any kind of preassure variable that can be sent to domoticz or how should I solve this?

    The original arduino preassure sketch looks like:

    int FSR_Pin = A0; //analog pin 0
    
    void setup(){
      Serial.begin(9600);
    }
    
    void loop(){
      int FSRReading = analogRead(FSR_Pin); 
    
      Serial.println(FSRReading);
      delay(250); //just here to slow down the output for easier reading
    }
    

Log in to reply
 

Suggested Topics

  • 3
  • 2
  • 10
  • 2
  • 1
  • 3

28
Online

11.2k
Users

11.1k
Topics

112.5k
Posts