Sensors and Transducers 

A sensor is a device that measures or senses a number of physical properties and converts it into another analog quantity that can be measured electrically such as voltage, current, etc. 

A transducer is a device that is connected to a sensor so as to convert the measured values into standard analog electrical signals such as 4 to20 mA. The output can be used directly by the system controller.

A transmitter is called to the combined package sensor and transducer.  Some people use these terms interchangeably though it is not correct.

 

A pressure sensor is a device for the pressure measurement of gases or liquids. Pressure is an expression of the force required to stop a fluid from expanding and is usually stated in terms of force per unit area. A pressure sensor usually acts as a transducer; it generates a signal as a function of the pressure imposed.

The 4-20 mA current loop is the prevailing process control signal in many industries. It is an ideal method of transferring process information because the current does not change as it travels from the transmitter to the receiver. Since 4 mA is equal to 0% output, it is incredibly simple to detect a fault in the system.

Accuracy refers to how close measurements are to the “true” value, while precision refers to how close measurements are to each other. Accuracy describes the difference between the measurement and the part’s actual value and precision describes the variation we see when we measure the same part repeatedly with the same device.  

Precision can be broken down further into two components: Repeatability: The variation observed when the same operator measures the same part repeatedly with the same device. Reproducibility: The variation observed when different operators measure the same part using the same device.

 

How data is read by controller:

We shall take a pressure sensor as our example to describe the process. The actual data is generated by the sensor. Pressure value mechanical deflection of a diaphragm, which is converted to electrical energy by a strain gauge (the diaphragm and strain gauge constitute a transducer), then to a numeric integer value by an input-output module of the controller.

The value can be stored somewhere from where our application reads the raw value. We have some reading for 3 similar pressure transmitters. Ideally when the current measurement is 4 milliamperes then the raw register reading should be 0 (ideal case). Since real-world objects are away from the ideal situations due to different reasons, so we need calibration. The sensor might behave or give different values at different conditions such as varying temperatures.

Pressure Sensor Calibration :

As we see in the left-hand side image,  the slope can have different values, also it can have offset value. We compare the value with the ideal case and calculate the actual value by using the formula y = mx + c

where y is the raw value, m is the slope, x is the current (m amp) value and c is the intersection of y-axis.

=>Offset compensation

In this case,  the slope is same as in ideal case, only there is offset difference.

=>Slope compensation

https://learn.adafruit.com/calibrating-sensors/two-point-calibration