Table of Contents
Welcome
Table of Contents
Title
BENTHAM SCIENCE PUBLISHERS LTD.
End User License Agreement (for non-institutional, personal use)
Usage Rules:
Disclaimer:
Limitation of Liability:
General:
FOREWORD
PREFACE
Consent for Publication
CONFLICT OF INTEREST
ACKNOWLEDGEMENTS
BIOGRAPHY OF AUTHORS
SECTION A: Arduino and its Interfacing
Introduction to Arduino, Arduino IDE and Proteus Software
Abstract
Advantages
1.1. Arduino Uno
1.2. Arduino Mega
1.3. Arduino Nano
1.4. Arduino IDE
1.4.1. Steps to Install Arduino IDE
1.4.2. Basic Commands
1.5. Introduction to Proteus Simulation Software
1.5.1. Steps to Design a Proteus Simulation Model
Arduino Interfacing with Display Devices
Abstract
2.1. Light Emitting Diode (LED)
2.1.1. Circuit Diagram
2.1.2. Program
2.1.3. Proteus Simulation Model
2.2. Seven Segment Display
2.2.1. Circuit Diagram
2.2.2. Program
2.2.3. Proteus Simulation Model
2.3. Liquid Crystal Display
2.3.1. Circuit Diagram
2.3.2. Program
2.3.3. Proteus Simulation Model
Arduino Interfacing with Digital Sensors
Abstract
3.1. Flame sensor
3.1.1. Circuit Diagram
3.1.2. Program
3.1.3. Proteus Simulation Model
3.2. PIR Sensor
3.2.1. Circuit Diagram
3.2.3. Program
3.2.3. Proteus Simulation Model
3.3. Gas Sensor
3.3.1. Circuit Diagram
3.3.2. Program
3.3.3. Proteus Simulation Model
Arduino Interfacing with Analog Sensors
Abstract
4.1. Ultrasonic Sensor
4.1.1. Circuit Diagram
4.1.2. Program
4.1.3. Proteus Simulation Model
4.2. Temperature (LM35) Sensor
4.2.1. Circuit Diagram
4.2.2. Program
4.2.3. Proteus Simulation Model
Arduino Interfacing with Actuators
Abstract
5.1. DC motor control with transistor ‘H’ bridge
5.1.1. Circuit Diagram
5.1.2. Program
5.1.3. Proteus Simulation Model
5.2. DC motor control with L293D
5.2.1. Circuit Diagram
5.2.2. Program
5.2.3. Proteus Simulation Model
5.3. Stepper motor
5.3.1. Circuit Diagram
5.3.2. Program
5.3.3. Proteus Simulation Model
5.4. Servo motor
5.4.1. Circuit Diagram
5.4.2. Program
5.4.3. Proteus Simulation Model
5.5. Servo motor control with POT
5.5.1. Circuit Diagram
5.5.2. Program
5.5.3. Proteus Simulation Model
5.6. AC motor
5.6.1. Circuit Diagram
5.6.2. Program
5.6.3. Proteus Simulation Model
Arduino Interfacing with Wireless Modems
Abstract
6.1. XBee Modem
6.1.1. Configuration of XBee
6.1.2. XBee Interfacing with Arduino
6.1.3. Circuit Diagram
6.1.4. Program
6.1.5. Proteus Simulation Model
MATLAB GUI
Abstract
7.1. Graphical User Interface (GUI)
7.1.1. Steps to Create GUI in MATLAB
SECTION B: Arduino Interfacing with MATLAB using I/O Package
Simulink and Arduino I/O Package
Abstract
8.1. Get started with Simulink Arduino I/O Package
8.1.1. Steps to Install Arduino I/O Package in MATLAB
8.1.2. Making Arduino Compatible with MATLAB
8.1.3. Creating Model in Simulink
8.2. Read Blocks
8.3. Write Blocks
Digital Read/Write and Analog Read/Write with Arduino I/O Package
Abstract
9.1. Digital Read/Write
9.1.1. Circuit Diagram
9.1.2. Simulink Model
9.2. Analog Read/write
9.2.1. Circuit Diagram
9.2.2. Simulink Model
Digital Read with Proximity and Touch Sensor and Digital Write on LED with Arduino I/O Package
Abstract
10.1. Circuit Diagram
10.2. Simulink Model
Key Touch Sensor Based Home Automation with Arduino I/O Package
Abstract
11.1. Circuit Diagram
11.2. Simulink Model
Sun Tracker System Using LDR with Arduino I/O Package
Abstract
12.1. Circuit Diagram
12.2. Simulink Model
Robot Control and Sensor Data Acquisition System with Arduino I/O Package
Abstract
13.1. Circuit Diagram
Two Analog Sensors [POT and LM35] Interfacing with Arduino I/O Package
Abstract
14.1. Circuit Diagram
Three Sensors Data Acquisition and Feedback System with MATLAB and Arduino I/O Package
Abstract
15.1. Circuit diagram
SECTION C: Arduino Interfacing with MATLAB without I/O Package
Building Automation System
Abstract
16.1. Circuit Diagram
16.2. Program
Robot Control with MATLAB GUI
Abstract
17.1. Circuit Diagram
17.2. Program
One Analog Channel and Digital Write Using MATLAB GUI
Abstract
18.1. Circuit diagram
18.2. Program
BIBLIOGRAPHY
Arduino Meets MATLAB
Interfacing, Programs and
Simulink
Authored by:
Rajesh Singh
School of Electronics & Electrical Engineering, Lovely Professional University
Jalandhar, Punjab, India
Anita Gehlot
School of Electronics & Electrical Engineering, Lovely Professional University
Jalandhar, Punjab, India
Bhupendra Singh
Schematics Microelectronics, Dehradun, Uttrakhand, India
&
Sushabhan Choudhury
Department of Electronics & Electrical Engineering, University of Petroleum
and Energy Studies, Dehradun, Uttrakhand, India
BENTHAM SCIENCE PUBLISHERS LTD.
End User License Agreement (for non-institutional, personal use)
This is an agreement between you and Bentham Science Publishers Ltd. Please read this License Agreement carefully before using the ebook/echapter/ejournal (“Work”). Your use of the Work constitutes your agreement to the terms and conditions set forth in this License Agreement. If you do not agree to these terms and conditions then you should not use the Work.
Bentham Science Publishers agrees to grant you a non-exclusive, non-transferable limited license to use the Work subject to and in accordance with the following terms and conditions. This License Agreement is for non-library, personal use only. For a library / institutional / multi user license in respect of the Work, please contact: [email protected].
Usage Rules:
All rights reserved: The Work is the subject of copyright and Bentham Science Publishers either owns the Work (and the copyright in it) or is licensed to distribute the Work. You shall not copy, reproduce, modify, remove, delete, augment, add to, publish, transmit, sell, resell, create derivative works from, or in any way exploit the Work or make the Work available for others to do any of the same, in any form or by any means, in whole or in part, in each case without the prior written permission of Bentham Science Publishers, unless stated otherwise in this License Agreement.You may download a copy of the Work on one occasion to one personal computer (including tablet, laptop, desktop, or other such devices). You may make one back-up copy of the Work to avoid losing it. The following DRM (Digital Rights Management) policy may also be applicable to the Work at Bentham Science Publishers’ election, acting in its sole discretion:25 ‘copy’ commands can be executed every 7 days in respect of the Work. The text selected for copying cannot extend to more than a single page. Each time a text ‘copy’ command is executed, irrespective of whether the text selection is made from within one page or from separate pages, it will be considered as a separate / individual ‘copy’ command.25 pages only from the Work can be printed every 7 days.
3. The unauthorised use or distribution of copyrighted or other proprietary content is illegal and could subject you to liability for substantial money damages. You will be liable for any damage resulting from your misuse of the Work or any violation of this License Agreement, including any infringement by you of copyrights or proprietary rights.
Disclaimer:
Bentham Science Publishers does not guarantee that the information in the Work is error-free, or warrant that it will meet your requirements or that access to the Work will be uninterrupted or error-free. The Work is provided "as is" without warranty of any kind, either express or implied or statutory, including, without limitation, implied warranties of merchantability and fitness for a particular purpose. The entire risk as to the results and performance of the Work is assumed by you. No responsibility is assumed by Bentham Science Publishers, its staff, editors and/or authors for any injury and/or damage to persons or property as a matter of products liability, negligence or otherwise, or from any use or operation of any methods, products instruction, advertisements or ideas contained in the Work.
Limitation of Liability:
In no event will Bentham Science Publishers, its staff, editors and/or authors, be liable for any damages, including, without limitation, special, incidental and/or consequential damages and/or damages for lost data and/or profits arising out of (whether directly or indirectly) the use or inability to use the Work. The entire liability of Bentham Science Publishers shall be limited to the amount actually paid by you for the Work.
General:
Any dispute or claim arising out of or in connection with this License Agreement or the Work (including non-contractual disputes or claims) will be governed by and construed in accordance with the laws of the U.A.E. as applied in the Emirate of Dubai. Each party agrees that the courts of the Emirate of Dubai shall have exclusive jurisdiction to settle any dispute or claim arising out of or in connection with this License Agreement or the Work (including non-contractual disputes or claims).Your rights under this License Agreement will automatically terminate without notice and without the need for a court order if at any point you breach any terms of this License Agreement. In no event will any delay or failure by Bentham Science Publishers in enforcing your compliance with this License Agreement constitute a waiver of any of its rights.You acknowledge that you have read this License Agreement, and agree to be bound by its terms and conditions. To the extent that any other terms and conditions presented on any website of Bentham Science Publishers conflict with, or are inconsistent with, the terms and conditions set out in this License Agreement, you acknowledge that the terms and conditions set out in this License Agreement shall prevail.
Bentham Science Publishers Ltd.
Executive Suite Y - 2
PO Box 7917, Saif Zone
Sharjah, U.A.E.
Email: [email protected]
FOREWORD
This book titled Arduino meets MATLAB. .. Interfacing, Programs and Simulink will provide a platform for the beginners to get started with Arduino and its interfacing with the MATLAB. The book provides the basic knowledge of the programming and interfacing of the devices with Arduino and MATLAB. This book also explains in a lucid manner the basic steps to understand the interfacing and programming with Arduino and MATLAB. This book goes from basic to advanced level of Arduino and interfacing with various input/output devices through various communication modules in well defined sequence which will be easily understandable to the undergraduate and post graduate students. This book will be specially beneficial to those researchers looking for hardware based implementation platforms.
The USP of this book lies in the fact that a new concept has been introduced for the researchers and students for prototype development of the real time projects using Arduino, MATLAB and I/O devices in the single platform. Another important point to mention will be that this book is entirely based on the practical experience of the authors while undergoing projects with the students and industries.
Dr. Babu Sena Paul
Department of Electrical and Electronic Engineering Technology
University of Johannesburg
South Africa
PREFACE
The primary objective of writing this book is to provide a platform for the beginners to get started with Arduino and its interfacing with the MATLAB. The book provides the basic knowledge of the programming and interfacing of the devices with Arduino and its interfacing with MATLAB.
The aim is to explain the basic steps to understand the interfacing and programming to interface Arduino with MATLAB.