SlideShare a Scribd company logo
Chapter IV
Sensor Communication & Data acquisition system
4. Sensor Interfacing/communcation
• As we try to discuss in the first chapter of this course; There are different types
of sensors and acutators that we use in our daily life.
Sensors; position/distance, speed, Temprature, presence sensors etc
Actuators; LEDs, motors, solonoids, spreakers etc.
• Those sensors and actuators have a means of communication with
the centeral processing unit or what it call microcontrollers or
microprocessors(Programmable logic device).
• Sensors may be digital or analog .
• Microcontrollers are capable of processing only digital data.
Intr. to Mechatronics Prepare by: Bereket 2
4. Sensor comm…
Intr. to Mechatronics Prepare by: Bereket 3
4. Sensor comm…
i. Analog Input ports
• Analog ports are necessary to connect sensors to our controller.
• Also are known as Analog to Digital Convertor(ADC)
• They receive analog signal and convert them to a digital number with in a
certain numerical range.
• The analog signal is measured after a predefined period of time passes. At
each time period, the voltage is recorded as a number.
• This number then defines a signal of 0's and 1's.
• Most microcontrollers today are 8 bit, meaning they have a range of 256 (2^8
= 256).
• There are a few that are 10 bit, 12 bit, and even 32 bit, but as we increase
precision we also need a much faster processor.
Intr. to Mechatronics Prepare by: Bereket 4
4. Sensor commu…
• For example, suppose a sensor reads 0V to an 8 bit ADC this would give us a
digital output of 0. 5V would be 255.
• Now suppose a sensor gave an output of 2.9V, doing the math:
2.9V/5V = X/255 → X = (2.9*255)/5 = 148
• This bit range could also be seen as a resolution.
• Higher resolutions mean higher accuracy, but occasionally can mean slower
processing and more susceptibility to noise.
• For example, suppose we had a 3 bit controller which has a range of 2^3 = 8.
• Then we have a distance sensor that outputted a number 0 → 7 (a total of 8)
that represents the distance between our robot and the wall.
Intr. to Mechatronics Prepare by: Bereket 5
4. Sensor commu…
• If our sensor can see only 8 feet, then we get a resolution of 1 bit per foot (8
resolution / 8 feet = 1).
• But then suppose we have an 8 bit controller,
we would get 256/8 = 32 ~ 1 bit per centimeter - way more accurate
and useful! With the 3 bit controlle.
• The sensor output must not exceed our digital logic voltage (usually 0V →
5V), and then plug that output directly to the analog port
Intr. to Mechatronics Prepare by: Bereket 6
4. Sensor commu…
ii. Digital I/O Ports
• Digital ports are like analog ports, but with only 1 bit (2^1 = 2)
hence a resolution of 2 - on and off.
• Digital ports for that reason are rarely used for sensors; except for maybe
on/off switches.
• We can use them to control motors or LED's.
• Send a high 5V signal to turn something on, or a low 0V to turn something off.
Or if we want to have an LED at only half brightness, or a motor at half speed,
send a square wave.
• Square waves are like turning something on and off so fast
Intr. to Mechatronics Prepare by: Bereket 7
4. Sensor commu…
iii. Serial Communication and Timers
• A serial connection on a microcontroller is very useful for communication.
• We can use it to program the controller from a computer, and to output data
from the controller to a computer (great for debugging), or even to operate
other electronics such as digitalvideo cameras.
• Usually the microcontroller would require an external IC to handle everything,
such as an RS232.
• I^2C (pronounced 'Isquared-C') is also useful for communicating.
• It's actually somewhat complicated, but usually the manufacturer has
simplified it.
Intr. to Mechatronics Prepare by: Bereket 8
4. Sensor commu…
• A timer is the method by which the microcontroller measures the
passing of time - such as for a clock, sonar, a pause/wait command,
timer interrupts, etc.
iv. Motor Driver
• To run a dc motor we need to either have an H-Bridge or a Motor Driver IC.
• The IC is great for small robots that do not exceed 1 or 2 amps per motor and
the rated motor voltage is not higher than about 12V.
• The home made H-Bridge would need to be used if we wanted to exceed those
specs with a heat sink onto the motor driver.
Intr. to Mechatronics Prepare by: Bereket 9
4. Sensor commu…
2- Standard Interfacing Circuits
i. Output Device Interfacing
• Many output devices will require a transistor switching circuit.
• In most cases a Darlington pair formed from two transistors is ideal.
Intr. to Mechatronics Prepare by: Bereket 10
4. Sensor commu…
• Note that it is usual to connect a back EMF suppression diode across the
output device.
• This is essential with devices such as relays, solenoids and motors which
create a back EMF when power is switched off.
Intr. to Mechatronics Prepare by: Bereket 11
4. Sensor commu…
• A relay can be used to switch higher power devices such as
motors and solenoids.
• If desired, the relay can be powered by a separate power supply, so, for
instance, 12V solenoids can be controlled by the microcontroller.
• Note the use of a back EMF suppression diode across the relay contacts. This
is to prevent damage to the transistor when the relay switches off.
Intr. to Mechatronics Prepare by: Bereket 12
4. Sensor commu…
Data acquisition system
• Data acquisition is the process by which physical phenomena from
the real world are transformed into electrical signals that are
measured and converted into a digital format for processing,
analysing, and storage by a computer
• A data acquisition system is a device or an integrated system used to
collect information about the state or condition of various
parameters of any process.
Intr. to Mechatronics Prepare by: Bereket 13
4. Sensor commu…
• A Data Acquisition System ( DAQ) is a combination of computer hardware
and software that gathers stores or processes data in order to control or
monitor some sort of physical process. The basic elements of a data
acquisition system
1. Sensors and transducers
2. Field wiring
3. Signal conditioning
4. Data acquisition hardware
5. PC (operating system)
6. Data acquisition software
•
Intr. to Mechatronics Prepare by: Bereket 14
4. Sensor commu…
• Sesors measure physical variables such as pressure, flow, & motion into
electrical signals.
• Field wiring used to connect different hardware components.
• The signal conditioning device amplifies and filters the sensor signal
• Data acquisition hardware is used to convert analog signal to digital and
digital signal to analog.
• The computer provides a processor, a system clock, a bus to transfer data,
memory and disc space to store data.
• Software includes both operating system and data acquisition software.
• The software allows exchanging information between the hardware and
computer.
Intr. to Mechatronics Prepare by: Bereket 15
4. Sensor commu…
Data acquisition system structure
Intr. to Mechatronics Prepare by: Bereket 16
4. Sensor commu…
Intr. to Mechatronics Prepare by: Bereket 17
End of Chapter IV
Intr. to Mechatronics Prepare by: Bereket 18

More Related Content

Similar to Introduction_to_Mechatronics_Chapter4.pdf

FA PRESENTATION.pptx
FA PRESENTATION.pptxFA PRESENTATION.pptx
FA PRESENTATION.pptx
ShubhamPatel256416
 
Sensor and Actuators using Rasberry Pi controller
Sensor and Actuators using Rasberry Pi controllerSensor and Actuators using Rasberry Pi controller
Sensor and Actuators using Rasberry Pi controller
ArsalanAthar
 
Gsm based garbage disposal
Gsm based garbage disposalGsm based garbage disposal
Gsm based garbage disposal
Suhanthi Devraj
 
Zigbee based trolley cart access system using rfid
Zigbee based trolley cart access system using rfidZigbee based trolley cart access system using rfid
Zigbee based trolley cart access system using rfid
Sam Joey
 
Hp embedd and_robotics
Hp embedd and_roboticsHp embedd and_robotics
Hp embedd and_robotics
Pallavi Bharti
 
Training Report on embedded Systems and Robotics
Training Report on embedded  Systems and RoboticsTraining Report on embedded  Systems and Robotics
Training Report on embedded Systems and Robotics
NIT Raipur
 
Pwm technique for dc motor Using Arduino
Pwm technique for dc motor Using ArduinoPwm technique for dc motor Using Arduino
Pwm technique for dc motor Using Arduino
KATHANSANJAYSHAH
 
Hp embedd system and basic obotics
Hp embedd system and basic oboticsHp embedd system and basic obotics
Hp embedd system and basic obotics
Pallavi Bharti
 
Gsm based smart card information for lost atm cards
Gsm based smart card information for lost atm cardsGsm based smart card information for lost atm cards
Gsm based smart card information for lost atm cards
Somanchi Aditya
 
Fingerprint Biometrics
Fingerprint BiometricsFingerprint Biometrics
Fingerprint Biometrics
Rudra Prasad Maiti
 
weather monitoiring system.pptx
weather monitoiring system.pptxweather monitoiring system.pptx
weather monitoiring system.pptx
PranayBathini1
 
unit-3.pptx
unit-3.pptxunit-3.pptx
unit-3.pptx
VigneshRavi83
 
micro manit.pptx
micro manit.pptxmicro manit.pptx
micro manit.pptx
bhaveshagrawal35
 
Programmable Logic Controller
Programmable Logic ControllerProgrammable Logic Controller
Programmable Logic Controller
Arul Kumar
 
MPC of TWT based Transmitter
MPC of TWT based TransmitterMPC of TWT based Transmitter
MPC of TWT based Transmitter
Abhishek Sutrave
 
IRJET- IoT based Industrial Automation
IRJET-  	  IoT based Industrial AutomationIRJET-  	  IoT based Industrial Automation
IRJET- IoT based Industrial Automation
IRJET Journal
 
UNIT 4 & 5 - I nterfacing_Lecture7.pptx
UNIT 4 & 5 - I         nterfacing_Lecture7.pptxUNIT 4 & 5 - I         nterfacing_Lecture7.pptx
UNIT 4 & 5 - I nterfacing_Lecture7.pptx
naveen088888
 
Lectute instrumentation and process control data acquisition
Lectute instrumentation and process control data acquisitionLectute instrumentation and process control data acquisition
Lectute instrumentation and process control data acquisition
rama52
 
Concept of Digital measurement, block Diagram & study of Voltmeter
Concept of Digital measurement, block Diagram & study of VoltmeterConcept of Digital measurement, block Diagram & study of Voltmeter
Concept of Digital measurement, block Diagram & study of Voltmeter
Abhishek Choksi
 
222116610_2 Assiment.pptx
222116610_2 Assiment.pptx222116610_2 Assiment.pptx
222116610_2 Assiment.pptx
bhaveshagrawal35
 

Similar to Introduction_to_Mechatronics_Chapter4.pdf (20)

FA PRESENTATION.pptx
FA PRESENTATION.pptxFA PRESENTATION.pptx
FA PRESENTATION.pptx
 
Sensor and Actuators using Rasberry Pi controller
Sensor and Actuators using Rasberry Pi controllerSensor and Actuators using Rasberry Pi controller
Sensor and Actuators using Rasberry Pi controller
 
Gsm based garbage disposal
Gsm based garbage disposalGsm based garbage disposal
Gsm based garbage disposal
 
Zigbee based trolley cart access system using rfid
Zigbee based trolley cart access system using rfidZigbee based trolley cart access system using rfid
Zigbee based trolley cart access system using rfid
 
Hp embedd and_robotics
Hp embedd and_roboticsHp embedd and_robotics
Hp embedd and_robotics
 
Training Report on embedded Systems and Robotics
Training Report on embedded  Systems and RoboticsTraining Report on embedded  Systems and Robotics
Training Report on embedded Systems and Robotics
 
Pwm technique for dc motor Using Arduino
Pwm technique for dc motor Using ArduinoPwm technique for dc motor Using Arduino
Pwm technique for dc motor Using Arduino
 
Hp embedd system and basic obotics
Hp embedd system and basic oboticsHp embedd system and basic obotics
Hp embedd system and basic obotics
 
Gsm based smart card information for lost atm cards
Gsm based smart card information for lost atm cardsGsm based smart card information for lost atm cards
Gsm based smart card information for lost atm cards
 
Fingerprint Biometrics
Fingerprint BiometricsFingerprint Biometrics
Fingerprint Biometrics
 
weather monitoiring system.pptx
weather monitoiring system.pptxweather monitoiring system.pptx
weather monitoiring system.pptx
 
unit-3.pptx
unit-3.pptxunit-3.pptx
unit-3.pptx
 
micro manit.pptx
micro manit.pptxmicro manit.pptx
micro manit.pptx
 
Programmable Logic Controller
Programmable Logic ControllerProgrammable Logic Controller
Programmable Logic Controller
 
MPC of TWT based Transmitter
MPC of TWT based TransmitterMPC of TWT based Transmitter
MPC of TWT based Transmitter
 
IRJET- IoT based Industrial Automation
IRJET-  	  IoT based Industrial AutomationIRJET-  	  IoT based Industrial Automation
IRJET- IoT based Industrial Automation
 
UNIT 4 & 5 - I nterfacing_Lecture7.pptx
UNIT 4 & 5 - I         nterfacing_Lecture7.pptxUNIT 4 & 5 - I         nterfacing_Lecture7.pptx
UNIT 4 & 5 - I nterfacing_Lecture7.pptx
 
Lectute instrumentation and process control data acquisition
Lectute instrumentation and process control data acquisitionLectute instrumentation and process control data acquisition
Lectute instrumentation and process control data acquisition
 
Concept of Digital measurement, block Diagram & study of Voltmeter
Concept of Digital measurement, block Diagram & study of VoltmeterConcept of Digital measurement, block Diagram & study of Voltmeter
Concept of Digital measurement, block Diagram & study of Voltmeter
 
222116610_2 Assiment.pptx
222116610_2 Assiment.pptx222116610_2 Assiment.pptx
222116610_2 Assiment.pptx
 

Recently uploaded

官方认证美国密歇根州立大学毕业证学位证书原版一模一样
官方认证美国密歇根州立大学毕业证学位证书原版一模一样官方认证美国密歇根州立大学毕业证学位证书原版一模一样
官方认证美国密歇根州立大学毕业证学位证书原版一模一样
171ticu
 
ACEP Magazine edition 4th launched on 05.06.2024
ACEP Magazine edition 4th launched on 05.06.2024ACEP Magazine edition 4th launched on 05.06.2024
ACEP Magazine edition 4th launched on 05.06.2024
Rahul
 
KuberTENes Birthday Bash Guadalajara - K8sGPT first impressions
KuberTENes Birthday Bash Guadalajara - K8sGPT first impressionsKuberTENes Birthday Bash Guadalajara - K8sGPT first impressions
KuberTENes Birthday Bash Guadalajara - K8sGPT first impressions
Victor Morales
 
Comparative analysis between traditional aquaponics and reconstructed aquapon...
Comparative analysis between traditional aquaponics and reconstructed aquapon...Comparative analysis between traditional aquaponics and reconstructed aquapon...
Comparative analysis between traditional aquaponics and reconstructed aquapon...
bijceesjournal
 
IEEE Aerospace and Electronic Systems Society as a Graduate Student Member
IEEE Aerospace and Electronic Systems Society as a Graduate Student MemberIEEE Aerospace and Electronic Systems Society as a Graduate Student Member
IEEE Aerospace and Electronic Systems Society as a Graduate Student Member
VICTOR MAESTRE RAMIREZ
 
Embedded machine learning-based road conditions and driving behavior monitoring
Embedded machine learning-based road conditions and driving behavior monitoringEmbedded machine learning-based road conditions and driving behavior monitoring
Embedded machine learning-based road conditions and driving behavior monitoring
IJECEIAES
 
Eric Nizeyimana's document 2006 from gicumbi to ttc nyamata handball play
Eric Nizeyimana's document 2006 from gicumbi to ttc nyamata handball playEric Nizeyimana's document 2006 from gicumbi to ttc nyamata handball play
Eric Nizeyimana's document 2006 from gicumbi to ttc nyamata handball play
enizeyimana36
 
132/33KV substation case study Presentation
132/33KV substation case study Presentation132/33KV substation case study Presentation
132/33KV substation case study Presentation
kandramariana6
 
Textile Chemical Processing and Dyeing.pdf
Textile Chemical Processing and Dyeing.pdfTextile Chemical Processing and Dyeing.pdf
Textile Chemical Processing and Dyeing.pdf
NazakatAliKhoso2
 
学校原版美国波士顿大学毕业证学历学位证书原版一模一样
学校原版美国波士顿大学毕业证学历学位证书原版一模一样学校原版美国波士顿大学毕业证学历学位证书原版一模一样
学校原版美国波士顿大学毕业证学历学位证书原版一模一样
171ticu
 
Casting-Defect-inSlab continuous casting.pdf
Casting-Defect-inSlab continuous casting.pdfCasting-Defect-inSlab continuous casting.pdf
Casting-Defect-inSlab continuous casting.pdf
zubairahmad848137
 
Properties Railway Sleepers and Test.pptx
Properties Railway Sleepers and Test.pptxProperties Railway Sleepers and Test.pptx
Properties Railway Sleepers and Test.pptx
MDSABBIROJJAMANPAYEL
 
CHINA’S GEO-ECONOMIC OUTREACH IN CENTRAL ASIAN COUNTRIES AND FUTURE PROSPECT
CHINA’S GEO-ECONOMIC OUTREACH IN CENTRAL ASIAN COUNTRIES AND FUTURE PROSPECTCHINA’S GEO-ECONOMIC OUTREACH IN CENTRAL ASIAN COUNTRIES AND FUTURE PROSPECT
CHINA’S GEO-ECONOMIC OUTREACH IN CENTRAL ASIAN COUNTRIES AND FUTURE PROSPECT
jpsjournal1
 
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
insn4465
 
Computational Engineering IITH Presentation
Computational Engineering IITH PresentationComputational Engineering IITH Presentation
Computational Engineering IITH Presentation
co23btech11018
 
5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...
5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...
5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...
ihlasbinance2003
 
ISPM 15 Heat Treated Wood Stamps and why your shipping must have one
ISPM 15 Heat Treated Wood Stamps and why your shipping must have oneISPM 15 Heat Treated Wood Stamps and why your shipping must have one
ISPM 15 Heat Treated Wood Stamps and why your shipping must have one
Las Vegas Warehouse
 
New techniques for characterising damage in rock slopes.pdf
New techniques for characterising damage in rock slopes.pdfNew techniques for characterising damage in rock slopes.pdf
New techniques for characterising damage in rock slopes.pdf
wisnuprabawa3
 
Recycled Concrete Aggregate in Construction Part III
Recycled Concrete Aggregate in Construction Part IIIRecycled Concrete Aggregate in Construction Part III
Recycled Concrete Aggregate in Construction Part III
Aditya Rajan Patra
 
Redefining brain tumor segmentation: a cutting-edge convolutional neural netw...
Redefining brain tumor segmentation: a cutting-edge convolutional neural netw...Redefining brain tumor segmentation: a cutting-edge convolutional neural netw...
Redefining brain tumor segmentation: a cutting-edge convolutional neural netw...
IJECEIAES
 

Recently uploaded (20)

官方认证美国密歇根州立大学毕业证学位证书原版一模一样
官方认证美国密歇根州立大学毕业证学位证书原版一模一样官方认证美国密歇根州立大学毕业证学位证书原版一模一样
官方认证美国密歇根州立大学毕业证学位证书原版一模一样
 
ACEP Magazine edition 4th launched on 05.06.2024
ACEP Magazine edition 4th launched on 05.06.2024ACEP Magazine edition 4th launched on 05.06.2024
ACEP Magazine edition 4th launched on 05.06.2024
 
KuberTENes Birthday Bash Guadalajara - K8sGPT first impressions
KuberTENes Birthday Bash Guadalajara - K8sGPT first impressionsKuberTENes Birthday Bash Guadalajara - K8sGPT first impressions
KuberTENes Birthday Bash Guadalajara - K8sGPT first impressions
 
Comparative analysis between traditional aquaponics and reconstructed aquapon...
Comparative analysis between traditional aquaponics and reconstructed aquapon...Comparative analysis between traditional aquaponics and reconstructed aquapon...
Comparative analysis between traditional aquaponics and reconstructed aquapon...
 
IEEE Aerospace and Electronic Systems Society as a Graduate Student Member
IEEE Aerospace and Electronic Systems Society as a Graduate Student MemberIEEE Aerospace and Electronic Systems Society as a Graduate Student Member
IEEE Aerospace and Electronic Systems Society as a Graduate Student Member
 
Embedded machine learning-based road conditions and driving behavior monitoring
Embedded machine learning-based road conditions and driving behavior monitoringEmbedded machine learning-based road conditions and driving behavior monitoring
Embedded machine learning-based road conditions and driving behavior monitoring
 
Eric Nizeyimana's document 2006 from gicumbi to ttc nyamata handball play
Eric Nizeyimana's document 2006 from gicumbi to ttc nyamata handball playEric Nizeyimana's document 2006 from gicumbi to ttc nyamata handball play
Eric Nizeyimana's document 2006 from gicumbi to ttc nyamata handball play
 
132/33KV substation case study Presentation
132/33KV substation case study Presentation132/33KV substation case study Presentation
132/33KV substation case study Presentation
 
Textile Chemical Processing and Dyeing.pdf
Textile Chemical Processing and Dyeing.pdfTextile Chemical Processing and Dyeing.pdf
Textile Chemical Processing and Dyeing.pdf
 
学校原版美国波士顿大学毕业证学历学位证书原版一模一样
学校原版美国波士顿大学毕业证学历学位证书原版一模一样学校原版美国波士顿大学毕业证学历学位证书原版一模一样
学校原版美国波士顿大学毕业证学历学位证书原版一模一样
 
Casting-Defect-inSlab continuous casting.pdf
Casting-Defect-inSlab continuous casting.pdfCasting-Defect-inSlab continuous casting.pdf
Casting-Defect-inSlab continuous casting.pdf
 
Properties Railway Sleepers and Test.pptx
Properties Railway Sleepers and Test.pptxProperties Railway Sleepers and Test.pptx
Properties Railway Sleepers and Test.pptx
 
CHINA’S GEO-ECONOMIC OUTREACH IN CENTRAL ASIAN COUNTRIES AND FUTURE PROSPECT
CHINA’S GEO-ECONOMIC OUTREACH IN CENTRAL ASIAN COUNTRIES AND FUTURE PROSPECTCHINA’S GEO-ECONOMIC OUTREACH IN CENTRAL ASIAN COUNTRIES AND FUTURE PROSPECT
CHINA’S GEO-ECONOMIC OUTREACH IN CENTRAL ASIAN COUNTRIES AND FUTURE PROSPECT
 
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
 
Computational Engineering IITH Presentation
Computational Engineering IITH PresentationComputational Engineering IITH Presentation
Computational Engineering IITH Presentation
 
5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...
5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...
5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...
 
ISPM 15 Heat Treated Wood Stamps and why your shipping must have one
ISPM 15 Heat Treated Wood Stamps and why your shipping must have oneISPM 15 Heat Treated Wood Stamps and why your shipping must have one
ISPM 15 Heat Treated Wood Stamps and why your shipping must have one
 
New techniques for characterising damage in rock slopes.pdf
New techniques for characterising damage in rock slopes.pdfNew techniques for characterising damage in rock slopes.pdf
New techniques for characterising damage in rock slopes.pdf
 
Recycled Concrete Aggregate in Construction Part III
Recycled Concrete Aggregate in Construction Part IIIRecycled Concrete Aggregate in Construction Part III
Recycled Concrete Aggregate in Construction Part III
 
Redefining brain tumor segmentation: a cutting-edge convolutional neural netw...
Redefining brain tumor segmentation: a cutting-edge convolutional neural netw...Redefining brain tumor segmentation: a cutting-edge convolutional neural netw...
Redefining brain tumor segmentation: a cutting-edge convolutional neural netw...
 

Introduction_to_Mechatronics_Chapter4.pdf

  • 1. Chapter IV Sensor Communication & Data acquisition system
  • 2. 4. Sensor Interfacing/communcation • As we try to discuss in the first chapter of this course; There are different types of sensors and acutators that we use in our daily life. Sensors; position/distance, speed, Temprature, presence sensors etc Actuators; LEDs, motors, solonoids, spreakers etc. • Those sensors and actuators have a means of communication with the centeral processing unit or what it call microcontrollers or microprocessors(Programmable logic device). • Sensors may be digital or analog . • Microcontrollers are capable of processing only digital data. Intr. to Mechatronics Prepare by: Bereket 2
  • 3. 4. Sensor comm… Intr. to Mechatronics Prepare by: Bereket 3
  • 4. 4. Sensor comm… i. Analog Input ports • Analog ports are necessary to connect sensors to our controller. • Also are known as Analog to Digital Convertor(ADC) • They receive analog signal and convert them to a digital number with in a certain numerical range. • The analog signal is measured after a predefined period of time passes. At each time period, the voltage is recorded as a number. • This number then defines a signal of 0's and 1's. • Most microcontrollers today are 8 bit, meaning they have a range of 256 (2^8 = 256). • There are a few that are 10 bit, 12 bit, and even 32 bit, but as we increase precision we also need a much faster processor. Intr. to Mechatronics Prepare by: Bereket 4
  • 5. 4. Sensor commu… • For example, suppose a sensor reads 0V to an 8 bit ADC this would give us a digital output of 0. 5V would be 255. • Now suppose a sensor gave an output of 2.9V, doing the math: 2.9V/5V = X/255 → X = (2.9*255)/5 = 148 • This bit range could also be seen as a resolution. • Higher resolutions mean higher accuracy, but occasionally can mean slower processing and more susceptibility to noise. • For example, suppose we had a 3 bit controller which has a range of 2^3 = 8. • Then we have a distance sensor that outputted a number 0 → 7 (a total of 8) that represents the distance between our robot and the wall. Intr. to Mechatronics Prepare by: Bereket 5
  • 6. 4. Sensor commu… • If our sensor can see only 8 feet, then we get a resolution of 1 bit per foot (8 resolution / 8 feet = 1). • But then suppose we have an 8 bit controller, we would get 256/8 = 32 ~ 1 bit per centimeter - way more accurate and useful! With the 3 bit controlle. • The sensor output must not exceed our digital logic voltage (usually 0V → 5V), and then plug that output directly to the analog port Intr. to Mechatronics Prepare by: Bereket 6
  • 7. 4. Sensor commu… ii. Digital I/O Ports • Digital ports are like analog ports, but with only 1 bit (2^1 = 2) hence a resolution of 2 - on and off. • Digital ports for that reason are rarely used for sensors; except for maybe on/off switches. • We can use them to control motors or LED's. • Send a high 5V signal to turn something on, or a low 0V to turn something off. Or if we want to have an LED at only half brightness, or a motor at half speed, send a square wave. • Square waves are like turning something on and off so fast Intr. to Mechatronics Prepare by: Bereket 7
  • 8. 4. Sensor commu… iii. Serial Communication and Timers • A serial connection on a microcontroller is very useful for communication. • We can use it to program the controller from a computer, and to output data from the controller to a computer (great for debugging), or even to operate other electronics such as digitalvideo cameras. • Usually the microcontroller would require an external IC to handle everything, such as an RS232. • I^2C (pronounced 'Isquared-C') is also useful for communicating. • It's actually somewhat complicated, but usually the manufacturer has simplified it. Intr. to Mechatronics Prepare by: Bereket 8
  • 9. 4. Sensor commu… • A timer is the method by which the microcontroller measures the passing of time - such as for a clock, sonar, a pause/wait command, timer interrupts, etc. iv. Motor Driver • To run a dc motor we need to either have an H-Bridge or a Motor Driver IC. • The IC is great for small robots that do not exceed 1 or 2 amps per motor and the rated motor voltage is not higher than about 12V. • The home made H-Bridge would need to be used if we wanted to exceed those specs with a heat sink onto the motor driver. Intr. to Mechatronics Prepare by: Bereket 9
  • 10. 4. Sensor commu… 2- Standard Interfacing Circuits i. Output Device Interfacing • Many output devices will require a transistor switching circuit. • In most cases a Darlington pair formed from two transistors is ideal. Intr. to Mechatronics Prepare by: Bereket 10
  • 11. 4. Sensor commu… • Note that it is usual to connect a back EMF suppression diode across the output device. • This is essential with devices such as relays, solenoids and motors which create a back EMF when power is switched off. Intr. to Mechatronics Prepare by: Bereket 11
  • 12. 4. Sensor commu… • A relay can be used to switch higher power devices such as motors and solenoids. • If desired, the relay can be powered by a separate power supply, so, for instance, 12V solenoids can be controlled by the microcontroller. • Note the use of a back EMF suppression diode across the relay contacts. This is to prevent damage to the transistor when the relay switches off. Intr. to Mechatronics Prepare by: Bereket 12
  • 13. 4. Sensor commu… Data acquisition system • Data acquisition is the process by which physical phenomena from the real world are transformed into electrical signals that are measured and converted into a digital format for processing, analysing, and storage by a computer • A data acquisition system is a device or an integrated system used to collect information about the state or condition of various parameters of any process. Intr. to Mechatronics Prepare by: Bereket 13
  • 14. 4. Sensor commu… • A Data Acquisition System ( DAQ) is a combination of computer hardware and software that gathers stores or processes data in order to control or monitor some sort of physical process. The basic elements of a data acquisition system 1. Sensors and transducers 2. Field wiring 3. Signal conditioning 4. Data acquisition hardware 5. PC (operating system) 6. Data acquisition software • Intr. to Mechatronics Prepare by: Bereket 14
  • 15. 4. Sensor commu… • Sesors measure physical variables such as pressure, flow, & motion into electrical signals. • Field wiring used to connect different hardware components. • The signal conditioning device amplifies and filters the sensor signal • Data acquisition hardware is used to convert analog signal to digital and digital signal to analog. • The computer provides a processor, a system clock, a bus to transfer data, memory and disc space to store data. • Software includes both operating system and data acquisition software. • The software allows exchanging information between the hardware and computer. Intr. to Mechatronics Prepare by: Bereket 15
  • 16. 4. Sensor commu… Data acquisition system structure Intr. to Mechatronics Prepare by: Bereket 16
  • 17. 4. Sensor commu… Intr. to Mechatronics Prepare by: Bereket 17
  • 18. End of Chapter IV Intr. to Mechatronics Prepare by: Bereket 18