Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
en:iot-open:hardware2:sensors_electric [2023/10/02 14:18] pczekalskien:iot-open:hardware2:sensors_electric [2024/05/27 11:58] (current) ktokarz
Line 1: Line 1:
-==== Electrical Characteristic Sensors ==== +====== Electrical Characteristic Sensors ====== 
-Electrical characteristic sensors measure the voltage and amperage of the electric current. When the voltage and current sensors are used concurrently, the consumed power of the device can be determined. Electrical characteristic sensors can determine whether the device's circuit is working correctly. Different sensor circuits must be used to measure direct current (DC) and alternating current (AC). If the parameters of the mains are to be measured, it must be done using transformers for safety reasons.+{{:en:iot-open:czapka_b.png?50| General audience classification icon }}{{:en:iot-open:czapka_e.png?50| General audience classification icon }}\\ 
 +Electrical characteristic sensors measure the voltage and amperage of the electric current. When the voltage and current sensors are used concurrently, the device'consumed power can be determined. Electrical characteristic sensors can also determine whether the device's circuit is working correctly. Different sensor circuits must be used to measure direct current (DC) and alternating current (AC). For safety reasons, the parameters of the mains must be measured using transformers.
  
-===Voltage Sensor===+== Potentiometer == 
 +A potentiometer is a type of resistor whose resistance can be adjusted using a mechanical lever. The device consists of three terminals. The resistor between the first and the third terminal has a fixed value, but the second terminal is connected to the lever. Whenever the lever is turned, a slider of the resistor is moved; it changes the resistance between the second terminal and side terminals. Variable resistance causes the change of the voltage, which can be measured to determine the position of the lever. Thus, the potentiometer output is an analogue value.\\ 
 +Potentiometers are commonly used as a control level, for example, a volume level for the sound and joystick position. They can also be used to determine the angle in feedback loops with motors, such as servo motors. The potentiometer symbol is present in figure {{ref>potentiometer1}}, a device in figure {{ref>potentiometer2}} and a connection to the Arduino board in figure {{ref>potentiometer3}}. 
 + 
 +<figure potentiometer1> 
 +{{ :en:iot-open:getting_familiar_with_your_hardware_rtu_itmo_sut:arduino_and_arduino_101_intel_curie:potentiometer_symbol_europe.png?100 | Symbol of a potentiometer}} 
 +<caption>A symbol of a potentiometer</caption> 
 +</figure> 
 + 
 +<figure potentiometer2> 
 +{{ :en:iot-open:getting_familiar_with_your_hardware_rtu_itmo_sut:arduino_and_arduino_101_intel_curie:potentiometer_c.jpg?200 | Potentiometer}} 
 +<caption>A potentiometer</caption> 
 +</figure> 
 + 
 +<figure potentiometer3> 
 +{{ :en:iot-open:getting_familiar_with_your_hardware_rtu_itmo_sut:arduino_and_arduino_101_intel_curie:sch_apz_shemas_potentiometer.png?200 | Arduino and potentiometer circuit}} 
 +<caption>Arduino and potentiometer circuit</caption> 
 +</figure> 
 + 
 +An example code: 
 +<code c> 
 + 
 +//Potentiometer sensor output is connected to the analogue A0 pin 
 +int potentioPin = A0;  
 +//The analogue reading from the potentiometer output 
 +int potentioReading;       
 +  
 +void setup(void) { 
 +  //Begin serial communication 
 +  Serial.begin(9600);    
 +  //Initialize the potentiometer analogue pin as an input 
 +  pinMode(potentioPin, INPUT);  
 +
 +  
 +void loop(void) { 
 +  //Read the analogue value of the potentiometer sensor 
 +  potentioReading = analogRead(potentioPin);  
 +  Serial.print("Potentiometer reading = "); //Print out 
 +  Serial.println(potentioReading); 
 +  delay(10); 
 +
 +</code> 
 + 
 +== Voltage Sensor ==
 A voltage sensor is a device or circuit for voltage measurement. A simple DC (direct current) voltage sensor consists of a voltage divider circuit with an optional amplifier for a tiny voltage measure. For measuring the AC (alternating current), the input is connected to the rectifier diode or bridge to rectify AC to DC and a capacitor to flatten the voltage. The resulting voltage can be measured with an analogue digital converter of the microcontroller. For safety, while measuring the mains voltage, an optoelectrical isolator should be added at the output, or a transformer should lower the voltage at the input.\\ A voltage sensor is a device or circuit for voltage measurement. A simple DC (direct current) voltage sensor consists of a voltage divider circuit with an optional amplifier for a tiny voltage measure. For measuring the AC (alternating current), the input is connected to the rectifier diode or bridge to rectify AC to DC and a capacitor to flatten the voltage. The resulting voltage can be measured with an analogue digital converter of the microcontroller. For safety, while measuring the mains voltage, an optoelectrical isolator should be added at the output, or a transformer should lower the voltage at the input.\\
 A voltage sensor can detect a power failure and measure if the voltage is in the range required. IoT applications include monitoring appliances, power lines, and power supplies.\\ A voltage sensor can detect a power failure and measure if the voltage is in the range required. IoT applications include monitoring appliances, power lines, and power supplies.\\
Line 8: Line 52:
  
 <figure sensor_voltage1> <figure sensor_voltage1>
-{{ :en:iot-open:getting_familiar_with_your_hardware_rtu_itmo_sut:arduino_and_arduino_101_intel_curie:voltage_senor_c.jpg?200 | Voltage sensor module}}+{{ :en:iot-open:getting_familiar_with_your_hardware_rtu_itmo_sut:arduino_and_arduino_101_intel_curie:voltage_senor_c.jpg?200 | Voltage sensor module 0–25 V}}
 <caption>Voltage sensor module 0–25 V</caption> <caption>Voltage sensor module 0–25 V</caption>
 </figure> </figure>
Line 16: Line 60:
 <caption>Arduino and voltage sensor schematics</caption> <caption>Arduino and voltage sensor schematics</caption>
 </figure> </figure>
- 
  
 The example code: The example code:
Line 53: Line 96:
 </code> </code>
  
-===Current Sensor===+== Current Sensor ==
  
 A current sensor is a device or a circuit for current measurement. A simple DC sensor consists of a high-power resistor with low resistance. The current value is obtained by measuring the voltage on the resistor and applying a formula derived from Ohm's law. Other non-invasive measurement methods involve hall effect sensors for DC and AC and inductive coils (current transformer) for AC.\\ A current sensor is a device or a circuit for current measurement. A simple DC sensor consists of a high-power resistor with low resistance. The current value is obtained by measuring the voltage on the resistor and applying a formula derived from Ohm's law. Other non-invasive measurement methods involve hall effect sensors for DC and AC and inductive coils (current transformer) for AC.\\
Line 60: Line 103:
  
 <figure sensor_current1> <figure sensor_current1>
-{{ :en:iot-open:hardware2:20230925_114306_copy.jpg?200 | Current transformer module for AC}}+{{ :en:iot-open:hardware2:20230925_114306_copy.jpg?300 | Current transformer module for AC}}
 <caption>Current transformer module for AC</caption> <caption>Current transformer module for AC</caption>
 </figure> </figure>
  
 <figure sensor_current2> <figure sensor_current2>
-{{ :en:iot-open:getting_familiar_with_your_hardware_rtu_itmo_sut:arduino_and_arduino_101_intel_curie:current_sen_c.jpg?200 | Analogue current meter module}}+{{ :en:iot-open:getting_familiar_with_your_hardware_rtu_itmo_sut:arduino_and_arduino_101_intel_curie:current_sen_c.jpg?200 | Analogue current meter module 0–50 A}}
 <caption>Analogue current meter module 0–50 A</caption> <caption>Analogue current meter module 0–50 A</caption>
 </figure> </figure>
  
 <figure sensor_current3> <figure sensor_current3>
-{{ :en:iot-open:getting_familiar_with_your_hardware_rtu_itmo_sut:arduino_and_arduino_101_intel_curie:sch_apz_shemas_current.png?400 | Arduino and current sensor module schematics}}+{{ :en:iot-open:getting_familiar_with_your_hardware_rtu_itmo_sut:arduino_and_arduino_101_intel_curie:sch_apz_shemas_current.png?350 | Arduino and current sensor module schematics}}
 <caption>Arduino and current sensor module schematics</caption> <caption>Arduino and current sensor module schematics</caption>
 </figure> </figure>
en/iot-open/hardware2/sensors_electric.1696256312.txt.gz · Last modified: 2023/10/02 14:18 by pczekalski
CC Attribution-Share Alike 4.0 International
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0