Академический Документы
Профессиональный Документы
Культура Документы
CHAPTER 1
INTRODUCTION
There are many types of Robots, from the simple ones like a Toy car to the
advanced ones like industrial Robots. a Wi-Fi Controlled Robot using Arduino . This
Arduino based Robot can be controlled wirelessly using any Wi-Fi enabled Android
We mainly need a Arduino and ESP8266 Wi-Fi module. ESP8266’s Vcc and
GND pins are directly connected to 3.3V and GND of Arduino and CH_PD is also
connected with 3.3V. Tx and Rx pins of ESP8266 are directly connected to pin 2 and 3
of Arduino The robot can be controlled from an ordinary internet browser, using a
An Arduino Uno was choosed because it's very accessible and easy to use for
everyone, and we wanted to design a simple shield for it. In our original project, who
also control some servos and LED matrices, and interfaces with the ESP. The
Arduino in detail.
A L293D Motor Driver IC is used for driving DC motors. Input pins of motor
connected at its output pins. Here we have used 9 Volt battery for driving the Circuit
purpose. There are more computers on this planet than there are people, and most of
these computers are single-chip microcontrollers that are the brains of an embedded
system.
interact with hundreds of tiny computers every day that are embedded into our houses,
our cars, our bridges, our toys, and our work. As our world has become more complex,
so have the capabilities of the microcontrollers embedded into our devices. Therefore
the world needs a trained workforce to develop and manage products based on
embedded microcontrollers
CHAPTER 2
LITERATURE SURVEY
project. However, they serve a different application and have different technologies
implemented. Some of those papers are mentioned below stating their technology and
application.
PAPER I
TITLE: AURDINO
Jorge Kazacos Winter has developed android controlled robot automation. Main
aim of his project was the transfer of information wirelessly between a smartphone and
the robot and developing the robot and its communication system underneath a low
price and open source philosophy. He has used Arduino micro-controller and Wi-Fi
PAPER II
M.Selvam in his paper has projected design to develop a robotic system which
has a wireless camera attached to it for surveillance. Bluetooth was implemented in his
project for providing connection between robot and smartphone. The video which is
AUTHOR:M.SELVAM.
CHAPTER 3
DESIGN IMPLIMENTATION
3.1 Block diagram:
We mainly need a Arduino and ESP8266 Wi-Fi module. ESP8266’s Vcc and
GND pins are directly connected to 3.3V and GND of Arduino and CH_PD is also
connected with 3.3V. Tx and Rx pins of ESP8266 are directly connected to pin 2 and 3
of Arduino. Software Serial Library is used to allow serial communication on pin 2 and
3 of Arduino.
in detail.A L293D Motor Driver IC is used for driving DC motors. Input pins of motor
connected at its output pins. Here we have used 9 Volt battery for driving the Circuit
and DC motors.
We mainly need a Arduino and ESP8266 Wi-Fi module. ESP8266’s Vcc and
GND pins are directly connected to 3.3V and GND of Arduino and CH_PD is also
connected with 3.3V. Tx and Rx pins of ESP8266 are directly connected to pin 2 and 3
of Arduino. Software Serial Library is used to allow serial communication on pin 2 and
3 of Arduino.
in detail.A L293D Motor Driver IC is used for driving DC motors. Input pins of motor
connected at its output pins. Here we have used 9 Volt battery for driving the Circuit
and DC motors.
CHAPTER 4
HARDWARE DESCRIPTION
4.1 Arduino Microcontroller
prototyping and experimenting for artists, hackers, hobbyists, but also many
professionals.
People use it as brains for their robots, to build new digital music instruments,
or to build a system that lets your house plants tweet you when they’re dry. Arduinos
(we use the standard Arduino Uno) are built around an ATmega microcontroller —
essentially a complete computer with CPU, RAM, Flash memory, and input/output
pins, all on a single chip. Unlike, say, a Raspberry Pi, it’s designed to attach all kinds
of sensors, LEDs, small motors and speakers, servos, etc. directly to these pins, which
The Arduino connects to your computer via USB, where you program it in a
simple language (C/C++, similar to Java) from inside the free Arduino IDE by
uploading your compiled code to the board. Once programmed, the Arduino can run
with the USB link back to your computer, or stand-alone without it — no keyboard or
Looking at the board from the top down, this is an outline of what you will see
(parts of the board you might interact with in the course of normal use are highlighted)
➢ Digital Pins 0-1/Serial In/Out - TX/RX (dark green) - These pins cannot be used
for digital i/o (Digital Read and Digital Write) if you are also using serial
➢ Toggles External Power and USB Power (place jumper on two pins closest to
➢ USB (used for uploading sketches to the board and for serial communication
between the board and the computer; can be used to power the board) (yellow)
In addition to the specific functions listed below, the digital pins on an Arduino
board can be used for general purpose input and output via the pin Mode(), Digital
Read(), and Digital Write() commands. Each pin has an internal pull-up resistor which
can be turned on and off using digital Write() (w/ a value of HIGH or LOW,
respectively) when the pin is configured as an input. The maximum current per pin is
40mA.
➢ Serial: 0 (RX) and 1 (TX). Used to receive (RX) and transmit (TX) TTL serial
data. On the Arduino Diecimila, these pins are connected to the corresponding
pins of the FTDI USB-to-TTL Serial chip. On the Arduino BT, they are
Arduino Mini and LilyPad Arduino, they are intended for use with an external
interrupt on a low value, a rising or falling edge, or a change in value. See the
➢ PWM: 3, 5, 6, 9, 10, and 11 Provide 8-bit PWM output with the analog Write()
module.
➢ LED: 13. On the Diecimila and LilyPad, there is a built-in LED connected to
digital pin 13. When the pin is HIGH value, the LED is on, when the pin is
In addition to the specific functions listed below, the analog input pins support
10-bit analog-to-digital conversion (ADC) using the analog Read() function. Most of
the analog inputs can also be used as digital pins: analog input 0 as digital pin 14
through analog input 5 as digital pin 19. Analog inputs 6 and 7 (present on the Mini and
➢ I2C: 4 (SDA) and 5 (SCL). Support I2C (TWI) communication using the Wire
➢ VIN (sometimes labeled "9V"): The input voltage to the Arduino board when
it's using an external power source (as opposed to 5 volts from the USB
connection or other regulated power source). You can supply voltage through
this pin, or, if supplying voltage via the power jack, access it through this pin.
Also note that the Lily Pad has no VIN pin and accepts only a regulated input.
➢ 5V: The regulated power supply used to power the microcontroller and other
components on the board. This can come either from VIN via an on-board
➢ 3V3 (Diecimila-only) : A 3.3 volt supply generated by the on-board FTDI chip.
➢ AREF: Reference voltage for the analog inputs. Used with analog Reference().
Typically used to add a reset button to shields which block the one on the board.
Pin Description
VCC:
Digital supply voltage.
GND:
Ground.
Port A (PA7-PA0):
Port A serves as the analog inputs to the A/D Converter. Port A also serves as
an 8-bit bi-directional I/O port, if the A/D Converter is not used. Port pins can provide
internal pull-up resistors (selected for each bit). The Port A output buffers have
symmetrical drive characteristics with both high sink and source capability. When pins
PA0 to PA7 are used as inputs and are externally pulled low, they will source current if
The Port A pins are tri-stated when a reset condition becomes active, even if the
Port B (PB7-PB0):
Port B is an 8-bit bi-directional I/O port with internal pull-up resistors (selected
for each bit). The Port B output buffers have symmetrical drive characteristics with
As inputs, Port B pins that are externally pulled low will source current if the
pull-up resistors are activated. The Port B pins are tri-stated when a reset condition
becomes active, even if the clock is not running. Port B also serves the functions of
Port C (PC7-PC0):
Port C is an 8-bit bi-directional I/O port with internal pull-up resistors (selected
for each bit). The Port C output buffers have symmetrical drive characteristics with
As inputs, Port C pins that are externally pulled low will source current if the
pull-up resistors are activated. The Port C pins are tri-stated when a reset condition
PC3(TMS) and PC2(TCK) will be activated even if a reset occurs. The TD0 pin is tri-
stated unless TAP states that shift out data are entered. Port C also serves the functions
Port D (PD7-PD0):
Port D is an 8-bit bi-directional I/O port with internal pull-up resistors (selected
for each bit). The Port D output buffers have symmetrical drive characteristics with
As inputs, Port D pins that are externally pulled low will source current if the
pull-up resistors are activated. The Port D pins are tri-stated when a reset condition
Port D also serves the functions of various special features of the ATmega32.
A low level on this pin for longer than the minimum pulse length will generate
a reset, even if the clock is not running. Shorter pulses are not guaranteed to generate a
reset.
XTAL1:
Input to the inverting Oscillator amplifier and input to the internal clock
operating circuit.
XTAL2:
AVCC:
AVCC is the supply voltage pin for Port A and the A/D Converter. It should be
externally connected to VCC, even if the ADC is not used. If the ADC is used, it should
AREF:
4.2.2 Features
➢ Up to 20MHz
➢ Part: ATMEGA328P-AU
➢ 1kB EEPROM
➢ 2 8-bit Timer/Counters
➢ 16-bit Timer/Counter
➢ 6 PWM Channels
➢ Serial USART
➢ Watchdog timer
➢ Analog comparator
➢ 23 IO lines
The AVR core combines a rich instruction set with 32 general purpose working
registers. All the 32 registers are directly connected to the Arithmetic Logic Unit
executed in one clock cycle. The resulting architecture is more code efficient while
executed arithmetic instruction. This information can be used for altering program flow
in order to perform conditional operations. Note that the Status Register is updated after
all ALU operations, as specified in the Instruction Set Reference. This will in many
cases remove the need for using the dedicated compare instructions, resulting in faster
and more compact code. The Status Register is not automatically stored when entering
an interrupt routine and restored when returning from an interrupt. This must be handled
by software.
The Global Interrupt Enable bit must be set for the interrupts to be enabled. The
individual interrupt enable control The Global Interrupt Enable bit must be set for the
separate control registers. If the Global Interrupt Enable Register is cleared, none of the
interrupts are enabled independent of the individual interrupt enable settings. The I-bit
is cleared by hardware after an interrupt has occurred, and is set by the RETI instruction
to enable subsequent interrupts. The I-bit can also be set and cleared by the application
with the SEI and CLI instructions, as described in the instruction set reference.
The Bit Copy instructions BLD (Bit Load) and BST (Bit Store) use the T-bit as
source or destination for the operated bit. A bit from a register in the Register File can
be copied into T by the BST instruction, and a bit in T can be copied into a bit in a
The Half Carry Flag H indicates a Half Carry in some arithmetic operations The
Half Carry Flag H indicates a Half Carry in some arithmetic operations. Half Carry Is
useful in BCD arithmetic. See the “Instruction Set Description” for detailed
information.
The S-bit is always an exclusive or between the Negative Flag N and the Two’s
Complement Overflow Flag V. See the “Instruction Set Description” for detailed
information.
arithmetic.
operation.
The Register File is optimized for the AVR Enhanced RISC instruction set. In
order to achieve the required performance and flexibility, the following input/output
Most of the instructions operating on the Register File have direct access to
all registers, and most of them are single cycle instructions. As shown in Figure 6-2,
each register is also assigned a data memory address, mapping them directly into the
first32 locations of the user data space. Although not being physically implemented as
SRAM locations, this memory organization provides great flexibility in access of the
registers, as the X-, Y-, and Z-pointer Registers can be set to index any register.
Figure 4.6 Structure of the 32 general purpose working registers in the CPU
The registers R26:R31 have some added functions to their general purpose
usage. These registers are 16-bit address pointers for indirect addressing of the data
space. The three indirect address registers X, Y, and Z are defined as described in
In the different addressing modes these address registers have functions as fixed
The Stack is mainly used for storing temporary data, for storing local variables
and for storing return addresses after interrupts and subroutine calls. Note that the Stack
Register always points to the top of the Stack. The Stack Pointer points to the data
SRAM Stack area where the Subroutine and Interrupt Stacks are located. A Stack
The Stack in the data SRAM must be defined by the program before any
subroutine calls are executed or interrupts are enabled. Initial Stack Pointer value equals
the last address of the internal SRAM and the Stack Pointer must be set to point above
the I/O space. The number of bits actually used is implementation dependent. Note that
the data space in some implementations of the AVR architecture is so small that only
SPL is needed. In this case, the SPH Register will not be present.SPH and SPL - Stack
This section describes the different memories in the ATmega328. The AVR
architecture has two main memory spaces, the Data Memory and the Program Memory
space. In addition, theATmega328 features an EEPROM Memory for data storage. All
Reprogrammable Flash memory for program storage. Since all AVR instructions are
16 or 32 bits wide, the Flash is organized as 2/4/8/16K x 16. For software security, the
Flash Program memory space is divided into two sections, Boot Loader Section and
Application Program Section. The Flash memory has an endurance of at least 10,000
write/erase cycles. The ATmega328 Program Counter (PC) is 11/12/13/14 bits wide,
be supported within the 64 locations reserved in the Opcode for the IN and OUT
instructions. For the Extended I/O space from 0x60 - 0xFF in SRAM, only the
Register File, the I/O memory, Extended I/O memory, and the internal data SRAM. The
first 32 locations address the Register File, the next 64 location the standard I/O
memory, then 160 locations of Extended I/O memory, and the next
512/1024/1024/2048 locations address the internal data SRAM. The five different
addressing modes for the data memory cover: Direct, Indirect with Displacement,
Indirect, Indirect with Pre-decrement, and Indirect with Post-increment. In The Register
File, Registers R26 to R31 Feature the indirect addressing pointer registers. The direct
addressing reaches the entire data space. The Indirect with Displacement mode reaches
The 32 general purpose working registers, 64 I/O Registers, 160 Extended I/O
Registers, and the 512/1024/1024/2048 bytes of internal data SRAM in the ATmega328
4.2.8 Interrupts
This section describes the specifics of the interrupt handling as performed in the
the Reset Vector is affected by the BOOTRST fuse, and the Interrupt Vector start
Table 4.2 Reset and Interrupt Vectors in ATMEGA 328 and ATMEGA 328P
Vector Program Source Interrupt Definition
No. Address
1 0x0000 RESET External Pin, Power-on Reset,
Brown-out Reset and Watchdog
System Reset
2 0x0002 INT0 External Interrupt Request 0
3 0x0004 INT1 External Interrupt Request 0
4 0x0006 PCINTO Pin Change Interrupt Request 0
5 0x0008 PCINT1 Pin Change Interrupt Request 1
6 0x000A PCINT2 Pin Change Interrupt Request 2
7 0x000C WDT Watchdog Time-out Interrupt
8 0x000E TIMER2 COMPA Timer/Counter2 Compare Match A
9 0x0010 TIMER2 COMPB Timer/Counter2 Compare Match B
10 0x0012 TIMER2 OVF Timer/Counter 2 Overflow
11 0x0014 TIMER1 CAPT Timer/Counter 2 Capture Event
12 0x0016 TIMER1 COMPA Timer/Counter1 Compare Match A
13 0x0018 TIMER1 COMPB Timer/Counter1 Compare Match B
14 0x001A TIMER 1 OVF Timer/Counter1 Overflow
15 0x001C TIMER0 COMPA Timer/Counter0 Compare Match A
16 0x001E TIMER0 COMPB Timer/Counter0 Compare Match B
17 0x0020 TIME0 OVF Timer/Counter0 Overflow
18 0x0022 SPI, STC SPI Serial Transfer Complete
19 0x0024 USART, RX USART RX Complete
(datasheet). It has 14 digital input/output pins (of which 6 can be used as PWM outputs),
6 analog inputs, a 16 MHz ceramic resonator, a USB connection, a power jack, an ICSP
header, and a reset button. It contains everything needed to support the microcontroller;
simply connect it to a computer with a USB cable or power it with a AC-to-DC adapter
The Uno differs from all preceding boards in that it does not use the FTDI USB-
➢ Pin out: Added SDA and SCL pins that are near to the AREF pin and two other
new pins placed near to the RESET pin, the IOREF that allow the shields to
adapt to the voltage provided from the board. In future, shields will be
compatible with both the board that uses the AVR, which operates with 5V and
with the Arduino. Due that operates with 3.3V. The second one is a not
"Uno" means one in Italian and is named to mark the upcoming release of
Arduino 1.0. The Uno and version 1.0 will be the reference versions of Arduino,
moving forward. The Uno is the latest in a series of USB Arduino boards, and the
reference model for the Arduino platform; for a comparison with previous versions, see
power supply. The power source is selected automatically. External (non-USB) power
can come either from an AC-to-DC adapter (wall-wart) or battery. The adapter can be
connected by plugging a 2.1mm center-positive plug into the board's power jack. Leads
from a battery can be inserted in the Gnd and Vin pin headers of the POWER connector.
The board can operate on an external supply of 6 to 20 volts. If supplied with less than
7V, however, the 5V pin may supply less than five volts and the board may be unstable.
If using more than 12V, the voltage regulator may overheat and damage the board.
➢ VIN: The input voltage to the Arduino board when it's using an external power
source (as opposed to 5 volts from the USB connection or other regulated power
source). You can supply voltage through this pin, or, if supplying voltage via
➢ 5V: This pin outputs a regulated 5V from the regulator on the board. The board
can be supplied with power either from the DC power jack (7 - 12V), the USB
connector (5V), or the VIN pin of the board (7-12V). Supplying voltage via the
5V or 3.3V pins bypasses the regulator, and can damage your board. We don't
advise it.
➢ 3V3. A 3.3 volt supply generated by the on-board regulator. Maximum current
draw is 50 mA.
➢ IOREF. This pin on the Arduino board provides the voltage reference with
which the microcontroller operates. A properly configured shield can read the
IOREF pin voltage and select the appropriate power source or enable voltage
Memory:
The ATmega328 has 32 KB (with 0.5 KB used for the boot loader). It also has 2 KB of
SRAM and 1 KB of EEPROM (which can be read and written with the EEPROM
library).
Serial Communication:
The Arduino Uno has a number of facilities for communicating with a
UART TTL (5V) serial communication, which is available on digital pins 0 (RX) and
1 (TX). An ATmega16U2 on the board channels this serial communication over USB
The '16U2 firmware uses the standard USB COM drivers, and no external driver
is needed. However, on Windows, a .inf file is required. The Arduino software includes
a serial monitor which allows simple textual data to be sent to and from the Arduino
board. The RX and TX LEDs on the board will flash when data is being transmitted via
the USB-to-serial chip and USB connection to the computer (but not for serial
A Software Serial library allows for serial communication on any of the Uno's
digital pins. The ATmega328 also supports I2C (TWI) and SPI communication. The
Arduino software includes a Wire library to simplify use of the I2C bus. For SPI
4.3.2 Conclusion
In this chapter Arduino, ATmega328, and also about the Embedded system and
4.4.1 Description
L293D is a typical Motor driver or Motor Driver IC which allows DC motor to
drive on either direction. L293D is a 16-pin IC which can control a set of two DC motors
simultaneously in any direction. It means that you can control two DC motorwith a
single L293D IC. Dual H-bridge Motor Driver integrated circuit(IC).The l293d can
drive small and quiet big motors as well, check the Voltage Specification at the end of
4.4.2Concept:
voltage to be flown in either direction. As you know voltage need to change its direction
for being able to rotate the motor in clockwise or anticlockwise direction, Hence H-
bridge IC are ideal for driving a DC motor.In a single l293d chip there two h-Bridge
circuit inside the IC which can rotate two dc motor independently. Due its size it is very
much used in robotic application for controlling DC motors. Given below is the pin
There are two Enable pins on l293d. Pin 1 and pin 9, for being able to drive the
motor, the pin 1 and 9 need to be high. For driving the motor with left H-bridge you
need to enable pin 1 to high. And for right H-Bridge you need to make the pin 9 to high.
If anyone of the either pin1 or pin9 goes low then the motor in the corresponding section
4.4.3 Working:
There are 4 input pins for l293d, pin 2,7 on the left and pin 15 ,10 on the right as shown
on the pin diagram. Left input pins will regulate the rotation of motor connected across
left side and right input for motor on the right hand side. The motors are rotated on the
basis of the inputs provided across the input pins as LOGIC 0 or LOGIC 1.
In simple you need to provide Logic 0 or 1 across the input pins for rotating the
motor.
4.4.4Voltage Specification:
VCC is the voltage that it needs for its own internal operation 5v; L293D will
not use this voltage for driving the motor. For driving the motors it has a separate
provision to provide motor supply VSS (V supply). L293d will use this to drive the
motor. It means if you want to operate a motor at 9V then you need to provide a Supply
The maximum voltage for VSS motor supply is 36V. It can supply a max current
of 600mA per channel.Since it can drive motors Up to 36v hence you can drive pretty
VCC pin 16 is the voltage for its own internal Operation. The maximum voltage
4.4.5 H-Bridge:
An H-bridge is an electronic circuit which enables DC electric motors to be run
forwards or backwards. These circuits are often used in robotics. H-bridges are
The term "H-bridge" is derived from the typical graphical representation of such
When the switches S1 and S4 (according to the first figure) are closed (and S2 and S3
are open) a positive voltage will be applied across the motor. By opening S1 and
reverse operation of the motor. Using the nomenclature above, the switches S1 and S2
should never be closed at the same time, as this would cause a short circuit on the input
voltage source. The same applies to the switches S3 and S4. This condition is known
as shoot-through
4.4.6 Operation
The H-Bridge arrangement is generally used to reverse the polarity of the motor,
but can also be used to 'brake' the motor, where the motor comes to a sudden stop, as
the motors terminals are shorted, or to let the motor 'free run' to a stop, as the motor is
effectively disconnected from the circuit. The following table summarizes operation.
S1 S2 S3 S4 Result
0 1 0 1 Motor brakes
Relay or a MOSFET or even by an IC. Here we are replacing this with an IC named
Features:
➢ Per channel
➢ Per channel
➢ Enable facility
4.4.8 Description
The Device is a monolithic integrated high voltage, high current four channel
driver designed to accept standard DTL or TTL logic levels and drive inductive loads
(such as relays solenoids, DC and stepping motors) and switching power transistors. To
simplify use as two bridges each pair of channels is equipped with an enable input. A
separate supply input is provided for the logic, allowing operation at a lower voltage
kHz. The L293D is assembled in a 16 lead plastic package which has 4 center pins
connected together and used for heat sinking The L293DD is assembled in a 20 lead
surface mount which has 8 center pins connected together and used for heat sinking.
4.5 DC Motors:
Here DC Motor is used to rotate the panel in the required direction. Let us study
carrying conductor generates a magnetic field; when this is then placed in an external
magnetic field, it will experience a force proportional to the current in the conductor,
and to the strength of the external magnetic field. As you are well aware of from playing
with magnets as a kid, opposite (North and South) polarities attract, while like polarities
(North and North, South and South) repel. The internal configuration of a DC motor is
simple 2-pole DC electric motor (here red represents a magnet or winding with a
polarization).
stator, commutator, field magnet(s), and brushes. In most common DC motors (and all
that BEAMERS will see), the external magnetic field is produced by high-strength
permanent magnets1. The stator is the stationary part of the motor -- this includes the
permanent magnet pole pieces. The rotor (together with the axle and attached
electrically connected to the commutator. The above diagram shows a common motor
The geometry of the brushes, commutator contacts, and rotor windings are such
that when power is applied, the polarities of the energized winding and the stator
magnet(s) are misaligned, and the rotor will rotate until it is almost aligned with the
stator's field magnets. As the rotor reaches alignment, the brushes move to the next
commutator contacts, and energize the next winding. Given our example two-pole
motor, the rotation reverses the direction of current through the rotor winding, leading
to a "flip" of the rotor's magnetic field, driving it to continue rotating. In real life,
though, DC motors will always have more than two poles (three is a very common
number). In particular, this avoids "dead spots" in the commutator. You can imagine
how with our example two-pole motor, if the rotor is exactly at the middle of its rotation
(perfectly aligned with the field magnets), it will get "stuck" there. Meanwhile, with a
two-pole motor, there is a moment where the commutator shorts out the power supply
(i.e., both brushes touch both commutator contacts simultaneously). This would be bad
for the power supply, waste energy, and damage motor components as well. Yet another
disadvantage of such a simple motor is that it would exhibit a high amount of torque
"ripple" (the amount of torque it could produce is cyclic with the position of the rotor).
You'll notice a few things from this -- namely, one pole is fully energized at a time (but
two others are "partially" energized). As each brush transitions from one commutator
contact to the next, one coil's field will rapidly collapse, as the next coil's field will
rapidly charge up (this occurs within a few microsecond). We'll see more about the
effects of this later, but in the meantime you can see that this is a direct result of the coil
The use of an iron core armature (as in the Mabuchi, above) is quite common,
and has a number of advantages2. First off, the iron core provides a strong, rigid support
for the windings -- a particularly important consideration for high-torque motors. The
core also conducts heat away from the rotor windings, allowing the motor to be driven
harder than might otherwise be the case. Iron core construction is also relatively
inexpensive compared with other construction types. But iron core construction also
has several disadvantages. The iron armature has a relatively high inertia which limits
motor acceleration. This construction also results in high winding inductances which
limits brush and commutates life. In small motors, an alternative design is often used
which features a 'coreless' armature winding. This design depends upon the coil wire
itself for structural integrity. As a result, the armature is hollow, and the permanent
magnet can be mounted inside the rotor coil. Coreless DC motors have much lower
armature inductance than iron-core motors of comparable size, extending brush and
commutator life. The coreless design also allows manufacturers to build smaller
motors; meanwhile, due to the lack of iron in their rotors, coreless motors are somewhat
prone to overheating. As a result, this design is generally used just in small, low-power
motors. BEAMers will most often see coreless DC motors in the form of pager motors.
Consider the g a DC motor. A DC motor will have two terminals. Let the terminals are
D1 and D2. If we give positive voltage to D1 and negative voltage to D2 (simply voltage
at D1 should be more positive than the voltage at D2) the rotor will rotate in forward
words voltage at D1 is more negative than D2) then the motor will rotate in reverse
direction.
the supply voltage from 12 Volts to 6 Volts, the motor will run at half the speed. The
speed controller works by varying the average voltage sent to the motor. It could do
this by simply adjusting the voltage sent to the motor, but this is quite inefficient to do.
A better way is to switch the motor's supply on and off very quickly. If the switching is
fast enough, the motor doesn't notice it, it only notices the average effect. Now imagine
a light bulb with a switch. When we close the switch, the bulb goes on and is at full
brightness, say 100 Watts. When we open the switch it goes off (0 Watts). Now if you
close the switch for a fraction of a second, then open it for the same amount of time,
the filament won't have time to cool down and heat up, and you will just get an average
glow of 50 Watts. This is how lamp dimmers work, and the same principle is used by
speed controllers to drive a motor. When the switch is closed, the motor sees 12 Volts,
and when it is open it sees 0 Volts. If the switch is open for the same amount of time as
it is closed, the motor will see an average of 6 Volts, and will run more slowly
accordingly.
4.6.1 Introduction
applications.
GPIO2), and
It employs a 32-bit RISC CPU based on the Tensilica Xtensa L106 running at 80 MHz
(or overclocked to 160 MHz). It has a 64 KB boot ROM, 64 KB instruction RAM and
ESP8266 module is low cost standalone wireless transceiver that can be used for end-
There are many third-party manufacturers that produce different modules based on this
chip. So, the module comes with different pin availability options like,
• ESP-01 comes with 8 pins (2 GPIO pins) – PCB trace antenna. (shown in above
figure)
GPIO0 & GPIO2: - General Purpose I/O Pins. These pins decide what mode (boot or
normal) the module starts up in. It also decides whether the TX/RX pins are used for
To program the module using UART, Connect GPIO0 to ground and GPIO2 to VCC
or leave it open. To use UART for normal Serial I/O leave both the pins open (neither
Now, before we start with ESP8266 interfacing, we need to update its firmware.
Downloading Firmware’s
There are many software & hardware platforms, firmware’s and frameworks available,
Espressif AT Firmware
EspressifFreeRTOS Firmware
etc.
ESP8266 Firmware has been provided in binary format files (.BIN) that can be
These binaries are generated using ESP8266 SDK (Software Development Kit), which
compile the ESP8266 SDK. Windows user can use virtual machine.
Started Guide
After compilation, download firmware directly on ESP8266 chip over serial port.
First download ESP8266 FLASH DOWNLOAD TOOL which is the official firmware
Now select .bin files with their respective address as shown in below figure.
master\bin directory.
Ensure that you have selected the correct COM port and BAUD rate (115200 default).
Note that, to put ESP8266 in flash mode, make connections as per above figure (in
between ESP8266 and USB to Serial converter) and then only connect it to PC/laptop.
Then click on START tab in ESP8266 DOWNLOAD TOOL, and wait till it finishes.
After finishing flash process, disconnect ESP8266 module from PC/laptop and remove
After successful downloading of firmware, we can use below AT commands for server
Note: This time do not connect GPIO0 and GPIO2 pins (leave the open/unconnected).
+CWLAP:<ecn>,<ssid>,<rssi>,<mac>
List
,<ch>,<freq offset>
Access AT+CWLAP
Point OK
Quit OK
Access AT+CWQAP
WIFI DISCONNECTED
Point
+CIFSR:APIP,<IP address>
+CIFSR:APMAC,<mac address>
AT+CIFSR
Get IP +CIFSR:STAIP,<IP address>
Address (Assuming AT+CWMODE=3)
+CIFSR:STAMAC,<mac address>
OK
Query
WiFi AT+CWMODE? +CWMODE:<mode>
Mode
AT+CWMODE=<mode>
Mode: -
Set WiFi 1 = STA (station)
OK
Mode
2 = AP (Access Point)
3 = BOTH i.e. STA & AP
Query
TCP/UD
P AT+CIPMUX? +CIPMUX:<mode>
Connecti
on
AT+CIPMUX=<mode>
Set
TCP/UD Mode: -
P OK
0 = Single Connection
Connecti
on 1 = Multiple Connection
Query
TCP
AT+CIPMODE? +CIPMODE:<mode>
transmiss
ion mode
AT+CIPMODE=<mode>
Set TCP Mode: -
transmiss OK
0 = Normal mode
ion mode
1 = Transparent mode
(CIPMUX=0) AT+CIPSTART =
<type>,<addr>,<port>
Set up
(CIPMUX=1) AT+CIPSTART=
TCP/UD CONNECT
<id>,<type>,<addr>, <port>
P
OK
connectio Example (CIPMUX=0):
n
AT+CIPSTART="TCP","192.168.1
01.110",80
OK
>
(Note: write your data after > and enter
it to send it will return status like.)
(CIPMUX=0)
Recv<data length> bytes
AT+CIPSEND=<data length>
Send
SEND OK
Data (CIPMUX=1)
AT+CIPSEND=<id>,<data length> (after we receive response from server
if any for default auto receive mode)
(CIPMUX=0): + IPD, <length>: <data>
(CIPMUX=1): + IPD, <id>, <length>:
<data>
supply battery
CHAPTER 5
SOFTWARE DESCRIPTION
4.1 Arduino IDE
The Arduino Integrated Development Environment - or Arduino Software (IDE) -
contains a text editor for writing code, a message area, a text console, a toolbar with
buttons for common functions and a series of menus. It connects to the Arduino and
STEP 1
Arduino microcontrollers come in a variety of types. The most common is the Arduino
UNO, but there are specialized variations. Before you begin building, do a little
research to figure out which version will be the most appropriate for your project.
STEP 2
Connect your Arduino to the USB port of your computer. This may require a specific
USB cable. Every Arduino has a different virtual serial-port address, so you 'll need to
CHAPTER 6
EXPERIMENTAL RESULTS
CHAPTER 7
Advantages:
1. Consistency of performance.
Disadvantages:
1. High standard of maintenance required.
CHAPTER 8
Conclusion:
The project carried out by using the node mc and motor drive in the field of
mechatronics department. New things and new technology are being invented. As the
technology grows day by day, it can imagine about the future in which thing may
occupy every place. User friendly and less complex, which can readily be used in order
to perform. Several tedious and repetitive tasks. Though it is designed keeping in mind
about the need for industry, it can extended for other purposes such as commercial and
research application. The chassis of robot made by aluminium it give the efficiency and
more speed to robot. The command coding are entered in robot it is very easy to
understand. Though it is designed keeping in mind about the need for industry, it can
Future scope:
Wi-Fi will be a key access technology for Internet of Things enablement due to
cost coverage and bandwidth, challenges with mobile cellular which can be
compromised through wifi. We can introduce a spy camera in this project and we can
REFERENCES
[7] M.S.Sreejith, Steffy Joy created “Conceptual design of a wifi and gps
based robotic library using an intelligent system.
APPENDIX
SOURCE CODE
/*-----( Calling of Header File)-----*/
#include<SoftwareSerial.h>
#include <EEPROM.h>
#define MotorL1 4
#define MotorL2 5
#define MotorR1 6
#define MotorR2 7
char Receive_Channel;
void setup()
Serial.begin(9600);
ESP_Serial.begin(9600);
Robot_Int();
Ptime_get = millis();
ESP_Serial.listen();
if (Serial.available())
delay(1000);
while (Serial.available())
CMD += (char)Serial.read();
SSID_Collect();
break;
ESP_Setup();
Ptime_get = millis();
void loop()
ESP_Serial.listen();
get_server();
if (CMD.length() > 1)
if (CMD.startsWith("Forward"))
Forward();
Right_Change = 1;
Left_Change = 1;
else if (CMD.startsWith("Back"))
Back();
Right_Change = 1;
Left_Change = 1;
else if (CMD.startsWith("Right"))
if(Right_Change){
Right_Change = false;
Right();
else if (CMD.startsWith("Left"))
if(Left_Change){
Left_Change = false;
Left();
else if (CMD.startsWith("Stop"))
Stop();
Right_Change = 1;
Left_Change = 1;
CMD = "";
Ptime_get = millis();
/*
*/
void ESP_Setup()
ESP_Serial.println(F("AT+CWMODE=3"));
if (ESP_Receive("OK", 100))
Serial.println(F("Mode Set"));
ESP_Serial.println(F("ATE0"));
if (ESP_Receive("OK", 100))
Serial.println(F("Echo Stop"));
if (EEPROM.read(1023) == 255)
EEPROM.write(1023, 0);
ESP_Serial.println(F("AT+CWSAP=\"Pump1\",\"\",10,0"));
if (ESP_Receive("OK", 100))
ESP_Serial.println(F("AT+RST"));
delay(4000);
ESP_Serial.println(F("AT+CIPMUX=1"));
if (ESP_Receive("OK", 200))
ESP_Serial.println(F("AT+CWJAP?"));
if (ESP_Receive(F("+CWJAP:"), 2000))
Serial.println(F("Connected to Wifi"));
ESP_Serial.println(F("AT+CIFSR"));
if (ESP_Receive("+CIFSR:STAIP", 200))
else
ESP_Serial.println(F("AT+CIPSERVER=1,80"));
if (ESP_Receive(F("OK"), 100))
Serial.println(F("Server Started"));
ESP_Serial.println(F("AT+CIPMUX=1"));
if (ESP_Receive(F("OK"), 200))
/*
If argument satisfied with startwith then it return 1 and store the string in "MSG"
*/
String Rx_MSG;
while (millis() - Rx_Time < time_delay) // it working fine with delay 520 milisec
if (ESP_Serial.available())
Rx_MSG += Byte;
if (Byte == '\n')
if (Rx_MSG.startsWith(F("check")))
Response += Rx_MSG;
else if (Rx_MSG.startsWith(Argument))
Response = Rx_MSG;
if (Argument == "Content-Type")
Rx_Time = millis();
if (ESP_Serial.available())
Byte = ESP_Serial.read();
Rx_MSG += Byte;
Serial.println(Rx_MSG);
if (Rx_MSG[i] == '\n')
Count++;
// Serial.println(i);
Serial.println(CMD);
// Serial.println(Count);
return 1;
if (Argument == "<html>")
Serial.println(Rx_MSG);
Get_Control_CMD(Rx_MSG);
get_data(Rx_MSG);
return 1;
else
Rx_MSG = "";
} Rx_Time = millis();
return 0;
/*
This Below function will get the Control Comand from the Received String
*/
// String CMD_Byte;
CMD = "";
// Serial.println(MSG);
// MSG = "";
CMD = "";
Receive_Channel = MSG[5];
// MSG = "";
void get_server()
// String dat=DATA;
ESP_Serial.listen();
String POST = "GET " + URL_Link + DATA + " HTTP/1.0\r\n" + "Host: " + IP +
"\r\n" +
ESP_Serial.println(F("AT+CIPMUX=1"));
if (ESP_Receive(F("OK"), 200))
Serial.println(F("OK"));
StartServer:
// ESP_Serial.println(F("AT+CIPCLOSE=2"));
// if(ESP_Receive("2,CLOSED", 200))
// Serial.println(F("Chanel Close"));
// ESP_Serial.println(F("AT+CIPSTART=2,\"TCP\",\"13.232.24.83\",80"));
ESP_Serial.print(F("AT+CIPSTART=2,\"TCP\",\""));
ESP_Serial.print(IP);
ESP_Serial.println(F("\",80"));
if (ESP_Receive(F("OK"), 200))
Serial.println(F("OK"));
ESP_Serial.print(F("AT+CIPSEND=2,"));
ESP_Serial.println(POST.length());
if (ESP_Serial.find('>'))
Serial.println(F("OK in send"));
Serial.print(POST);
ESP_Serial.print(POST);
if (ESP_Receive("Content-Type", 1000));
else
Try++;
if (Try < 3)
ESP_Serial.println(F("AT+CIPSTATUS"));
delay(100);
goto StartServer;
void SSID_Collect()
unsigned char i;
SSID_Name += CMD[i];
Serial.println(SSID_Name + SSID_PSWD);
ESP_Serial.print(F("AT+CWJAP=\""));
ESP_Serial.print(SSID_Name);
ESP_Serial.print(F("\",\""));
ESP_Serial.print(SSID_PSWD);
ESP_Serial.println("\"");
if (ESP_Receive("OK", 8000))
Serial.println(F("Connected to Wifi"));
else
delay(3000);
void Robot_Int()
pinMode(MotorL1,OUTPUT);
pinMode(MotorL2,OUTPUT);
pinMode(MotorR1,OUTPUT);
pinMode(MotorR2,OUTPUT);
void Forward()
digitalWrite(MotorR1,HIGH);
digitalWrite(MotorL1,HIGH);
digitalWrite(MotorR2,LOW);
digitalWrite(MotorL2,LOW);
void Back()
digitalWrite(MotorR2,HIGH);
digitalWrite(MotorL2,HIGH);
digitalWrite(MotorR1,LOW);
digitalWrite(MotorL1,LOW);
void Left()
digitalWrite(MotorR1,HIGH);
digitalWrite(MotorL1,LOW);
digitalWrite(MotorR2,LOW);
digitalWrite(MotorL2,LOW);
delay(1000);
Stop();
void Right()
digitalWrite(MotorL1,HIGH);
digitalWrite(MotorR1,LOW);
digitalWrite(MotorR2,LOW);
digitalWrite(MotorL2,LOW);
delay(1000);
Stop();
void Stop()
digitalWrite(MotorR1,LOW);
digitalWrite(MotorL1,LOW);
digitalWrite(MotorR2,LOW);
digitalWrite(MotorL2,LOW);