Download as pdf or txt
Download as pdf or txt
You are on page 1of 55

SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

CHAPTER 1
INTRODUCTION
Individuals have constantly created innovation to bolster their requirements as from
the start of humankind. The fundamental reason for development in innovation is ought for
more independency and this leads to improving tasks and making regular one simpler and
speedier. One significant task that individuals invest maximum measure of energy is in
shopping. Shopping center is a spot where individuals get their everyday necessities running
from sustenance items, garments, electrical machines and so forth. Some of the time clients
have issues with respect to the unspecific data about the item marked down and misuse of
superfluous time at the counters.
In this innovative world, each grocery store and supermarkets utilize shopping trolleys
with a specific end goal to help clients to choose and store the items which they expect to buy.
Customers usually purchase the products required and place them in their carts and thereafter
wait at the counters for payments of bills. The payment of bills at the counters is really
troublesome and time-consuming process which thereby increasing a heavy crowd at the
counters. The fundamental motivation behind this system is to show the proposition of a design
and arrangement of an inventive framework for obtaining of items in markets. This cart
explores rising versatile innovations and programmed recognizable proof advancements, as an
approach to enhance the nature of administrations given by retailers and to expand the customer
esteem consequently permitting to save time and cash with this device an excellent opportunity
will be developed which assists the customers by showing the catalog of products and their
respective costs. This approach thereby helps the inventory management unit with an instinctive
upgrade on each purchase of product. This smart cart has the capability to make shopping more
relax able, comfortable and systematic for the customers as well as making easier for the store
management. Further the doesn’t require the extra staff to handle the customers, so profit
margins can be increased for store owners.

1.1 Existing System

In existing system, customer will not know the amount of total purchase, until he went
to the counter for paying bill. One can remove certain product, once he approaches to the
counter, where he decides which product should be reverted back. To avoid this type of
troubles, we develop a smart trolley, where one can know the total bill of the products
purchased and bill amount is also sent to the billing section wirelessly.

1.2 Proposed System


A customer goes into a shopping center then she/he first take a trolley. Every last trolley
is joined with a scanner tag per user and a RFID per user. The framework work is the point at
which the customer buys a thing, the customer must be examining the thing first with help of
standardized tag are available in each item utilizing the RFID per user.Through the RFID tag
the scanning purpose will be done in less time and there is no need of human labours.The name
and price of the product will be displayed on the LCD of the smart trolley by the controller.

Page | 1
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

1.3 Block Diagram of proposed system

POWER SUPPLY

R
F
I LCD

D
T RFID
ARDUINO
READER
A BUZZER

G
S
LED

Page | 2
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

CHAPTER 2

LITERATURE SURVEY

2.1 RFID & Barcode processing


RFID and barcodes are similar in that they are both data collection technologies, which
means they automate the process of data collection. However, they also differ significantly in
many areas. If compared, RFID technology is found to be simpler than the barcode technology.
Barcode scanner requires line of sight whereas RFID can be read without the line of sight. It is
possible to scan RFID tags from a larger distance. The barcode requires a direct line of sight to
the printed barcode, because of which the barcode has to be printed on the outer side of product,
thus subjected to huge amounts of wears and tears. It is also limited to re-utilization of the
barcodes. As barcode lacks with the read and write facility, it is not possible to add to the
information that is already existing on it. The main advantage of using the RFID tags is that
rewriting on RFID tags is possible. An RFID reader can gain the information of the tag from a
distance of about 300 feet, whereas barcode technology cannot be scanned from a distance of
more than 15 feet. Barcode coded items can only be read individually whereas multiple tags
can be read by RFID reader simultaneously. RFID technology is better than barcode technology
in terms of speed. RFID tags can be read much faster than the barcode tags. As it requires a
direct line of sight, barcode reading is comparatively slower than the RFID tag reading.

2.2 RFID & Barcode approaches

A barcode reader takes about one second to successfully interpret two tags, whereas in
the same time the RFID reader can interpret around 40 tags. RFID tags are well protected and
implanted inside the product, and thus they are not subjected to too many wears and tears. The
barcode requires a direct line of sight to the printed barcode, because of which the barcode has
to be printed on the outer side of product, thus subjected to huge amounts of wears and tears.
It is also limited to re-utilization of the barcodes. As barcode lacks with the read and write
facility, it is not possible to add to the information that is already existing on it. The main
advantage of using the RFID tags is that rewriting on RFID tags is possible.

2.3 Analysis
The utility of trolley will be first one of its kind for commercial use. This device records
the data of different products with the help of the suitable sensors like RFID Tags. This
recorded data helps the shop owner with the detailed analysis of shopping by the customer &
their preferences through computer printout of the same can be obtained trolley, there is no
need to wait in billing queue and thinking about budget. The microcontroller-based trolley will
automatically show the bill to customer. It gives number of products in trolley and the total cost
of the products on the spot.

Page | 3
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

CHAPTER 3

POWER SUPPLY

The input to the circuit is applied form the regulated power supply. The A.C input i.e
230v from the main supply is step down by the by the transformer to 12v and it is fed to a
rectifier. The output obtained from the rectifier is a pulsating dc voltage.so in order to get pure
dc voltage, the output voltage form the rectifier is fed to the input of filter to remove any A.C
components. Now, this voltage is given to the input of voltage regulator to obtain pure dc
voltage.

3.1 Transformers
Transformers are contraptions which wander down a for the most part higher AC
information Voltage into a lower AC yield voltage. To find the data and yield terminals of a
transformer is outstandingly crude.

Fig 3.1 Transformer

Basically, there are two sides in a transformer where the bend bowing inside the
transformer closes. Both terminations have two wires each. On the transformer, one side will
have three terminals and the other will have two. The one with the three terminals is the
wandered down yield of the transformer, and the one with the two terminals is the place the
data voltage is to be acclimated.

Page | 4
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

3.2 Rectifier
Rectifier is an electronic component which is used to change AC voltage to DC voltage.
It is for the most part separated into Full wave and Half wave rectifiers. At the point when
forward one-sided there will be voltage drop in diodes of around 0.7v. In this manner when two
diodes are combined together for allowance of light of the path there will be a voltage drop of
1.4v since every diode as a voltage drop of 0.7v. However, on account of full wave connect
rectifier there will be a voltage drop of 0.7v as it were. The voltage controller needs 2 volts
more than its yield voltage. For in the event that we are interfacing 12v connector for our
motivation and henceforth we require 14v according to the yield voltage.

Fig 3.2 Rectifier

So, the yield of the diodes (which goes into the voltage controller) will must be more
than or vague to 14 Volts. According to the diode data voltage the diode voltage in the voltage
controller will be 14v. The voltage drop will be 1.4v totally, so the proportionate aggregate
voltage will be 15.4 volts of which 14v in addition to 1.4v. so it is ideal to utilize 18v venture
down transformer from 220v input voltage. In this manner transformer yield voltage will be of
3.4v of rough esteem.

Page | 5
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

3.3 Capacitors
Capacitors are utilized to get the immaculate and smoothest DC voltage in which the
rectifier is utilized to get throbbing DC voltage which is utilized as a part of the light of the
present destiny, from the connector. Capacitors are utilized to get square DC from AC current
experience of the present channels so they are used as a touch of parallel to the yield. Moreover,
if there is a swell in the data or yield, a capacitor changes it by discharging the charge set away
in it.

Fig 3.3 Capacitor

3.4 Voltage Regulators


The 78XX voltage controller is principally overall utilized controller for voltage controllers.
The XX speaks to the voltage of which the voltage controller delivers as the yield to the specific
gadget. 7805 will deliver and control the yield voltage of 5v and 7812 will create the yield
voltage of 12v. The voltage controllers are that they require no under 2 volts more than their
yield voltage as information. For instance, 7805 will require no under 7V, and 7812, no under
14 volts as information sources. This voltage which ought to be given to voltage controllers is
called Dropout Voltage.

Fig 3.4 Voltage Regulator

Page | 6
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

CHAPTER-4
ARDUNIO MICROCONTROLLER
Arduino is an open-source electronics platform based on easy-to-use hardware and
software. Arduino boards are able to read inputs - light on a sensor, a finger on a button, or a
Twitter message - and turn it into an output - activating a motor, turning on an LED, publishing
something online. You can tell your board what to do by sending a set of instructions to the
microcontroller on the board. To do so you use the Arduino programming language (based on
Wiring), and the Arduino Software (IDE), based on Processing. Over the years Arduino has
been the brain of thousands of projects, from everyday objects to complex scientific
instruments

Fig 4.1 Arduino

4.1 Arduino Hardware

The power of the Arduino is not its ability to crunch code, but rather its ability to
interact with the outside world through its input-output (I/O) pins. The Arduino has 14 digital
I/O pins labelled 0 to 13 that can be used to turn motors and lights on and off and read the state
of switches. Each digital pin can sink or source about 40 mA of current. This is more than
adequate for interfacing to most devices, but does mean that interface circuits are needed to

Page | 7
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

control devices other than simple LED's. In other words, you cannot run a motor directly using
the current available from an Arduino pin, but rather must have the pin drive an interface circuit
that in turn drives the motor. To interact with the outside world, the program sets digital pins
to a high or low value using C code instructions, which corresponds to +5 V or 0 V at the pin.
The pin is connected to external interface electronics and then to the device being switched on
and off.

4.2 Atmega328p Features

➢ High Performance, Low Power AVR® 8-Bit Microcontroller


➢ Advanced RISC Architecture

– 131 Powerful Instructions

– Most Single Clock Cycle Execution

– 32 x 8 General Purpose Working Registers

– Fully Static Operation

– Up to 20 MIPS Throughput at 20 MHz

– On-chip 2-cycle Multiplier

➢ High Endurance Non-volatile Memory Segments

– 4/8/16/32K Bytes of In-System Self-Programmable Flash program memory


(ATmega48PA/88PA/168PA/328P)

– 256/512/512/1K Bytes EEPROM (ATmega48PA/88PA/168PA/328P)

– 512/1K/1K/2K Bytes Internal SRAM (ATmega48PA/88PA/168PA/328P)

– Write/Erase Cycles: 10,000 Flash/100,000 EEPROM

– Data retention: 20 years at 85°C/100 years at 25°C

– Optional Boot Code Section with Independent Lock Bits In-System Programming by
On-chip Boot Program True Read-While-Write Operation

– Programming Lock for Software Security

➢ Peripheral Features

Page | 8
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

– Two 8-bit Timer/Counters with Separate Prescaler and Compare Mode

– One 16-bit Timer/Counter with Separate Prescaler, Compare Mode, and Capture
Mode

– Real Time Counter with Separate Oscillator

– Six PWM Channels – 8-channel 10-bit ADC in TQFP and QFN/MLF package
Temperature Measurement – 6-channel 10-bit ADC in PDIP Package Temperature
Measurement

– Programmable Serial USART

– Master/Slave SPI Serial Interface

– Byte-oriented 2-wire Serial Interface (Philips I2 C compatible)

– Programmable Watchdog Timer with Separate On-chip Oscillator

– On-chip Analog Comparator

– Interrupt and Wake-up on Pin Change

➢ Special Microcontroller Features

– Power-on Reset and Programmable Brown-out Detection

– Internal Calibrated Oscillator

– External and Internal Interrupt Sources

– Six Sleep Modes: Idle, ADC Noise Reduction, Power-save, Power-down, Standby,
and Extended Standby

➢ I/O and Packages

– 23 Programmable I/O Lines

– 28-pin PDIP, 32-lead TQFP, 28-pad QFN/MLF and 32-pad QFN/MLF

Page | 9
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

4.3 Pin Configurations

4.4 Pin descriptions

VCC: Digital supply voltage.

GND: Ground.

Port B (PB7:0) XTAL1/XTAL2/TOSC1/TOSC2:

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 both high sink and source
capability. 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. Depending on the clock selection fuse settings, PB6 can be
used as input to the inverting. Oscillator amplifier and input to the internal clock operating
circuit. Depending on the clock selection fuse settings, PB7 can be used as output from the
inverting Oscillator amplifier. If the Internal Calibrated RC Oscillator is used as chip clock
source, PB7.6 is used as TOSC2.1 input for the Asynchronous Timer/Counter2 if the

Page | 10
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

AS2 bit in ASSR is set. The various special features of Port B are elaborated in “Alternate
Functions of Port B” and “System Clock and Clock Options”.

Port C (PC5:0):

Port C is a 7-bit bi-directional I/O port with internal pull-up resistors (selected for each bit).
The PC5.0 output buffers have symmetrical drive characteristics with both high sink and source
capability. 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 becomes active,
even if the clock is not running.

PC6/RESET:

If the RSTDISBL Fuse is programmed, PC6 is used as an I/O pin. Note that the electrical
characteristics of PC6 differ from those of the other pins of Port C. If the RSTDISBL Fuse is
unprogrammed, PC6 is used as a Reset input. A low level on this pin for longer than the
minimum pulse length will generate a Reset, even if the clock is not running.

Port D (PD7:0): 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
both high sink and source capability. 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 becomes active, even if the clock is not running.

AVCC: AVCC is the supply voltage pin for the A/D Converter, PC3:0, and ADC7:6. It should
be externally connected to VCC, even if the ADC is not used. If the ADC is used, it should be
connected to VCC through a low-pass filter. Note that PC6.4 use digital supply voltage, VCC.

AREF: AREF is the analog reference pin for the A/D Converter

ADC7:6 (TQFP and QFN/MLF Package Only): In the TQFP and QFN/MLF package,
ADC7:6 serve as analog inputs to the A/D converter. These pins are powered from the analog
supply and serve as 10-bit ADC channels.

Page | 11
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

4.5 Block Diagram of Atmega328p

4.6 Physical Characteristics

The maximum length and width of the Uno PCB are 2.7 and 2.1 inches
respectively, with the USB connector and power jack extending beyond the former dimension.
Four screw holes allow the board to be attached to a surface or case. Note that the distance
between digital pins 7 and 8 is 160 mil (0.16"), not an even multiple of the 100-mil spacing of
the other pins. 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 becomes
active, even if the clock is not running. The various special features of Port D are elaborated in
“Alternate Functions of Port D”.

Page | 12
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

4.6.1 Register File

➢ 32 8-bit GP registers
➢ Part of SRAM memory space

4.6.2 Stack Pointer Register


➢ Special register in I/O space [3E, 3D]
• Enough bits to address data space
• Initialized to RAMEND (address of highest memory address)
➢ Instructions that use the stack pointer

4.6.3 Program Status Register (PSR)


I T H S V N Z C

I-Global Interrupt Enable


T-Flag Bit
H-Half Carry
S-Sign
V-Over Flow
N-Negative
Z-Zero
C-Carry

Page | 13
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

CHAPTER 5
RFID SYSTEM
RFID is an acronym for “Radio-Frequency Identification” and refers to a technology
whereby digital data encoded in RFID tags or smart labels (defined below) are captured by a
reader via radio waves. RFID is similar to barcoding in that data from a tag or label are
captured by a device that stores the data in a database. RFID has several advantages over
systems that use barcode asset tracking software. The most notable is that RFID tag data can
be read outside the line-of-sight, whereas barcodes must be aligned with an optical scanner.
RID based system has two basic components.
• RFID tags

• RFID reader

5.1 RFID Tags


An RFID tag consists of an integrated circuit and an antenna. This tag carries 12 unique
numbers. The tag is also composed of a protective material that holds the pieces together and
shields them from various environmental conditions. The protective material depends on the
application. For example, employee ID badges containing RFID tags are typically made from
durable plastic, and the tag is embedded between the layers of plastic. RFID tags come in a
variety of shapes and sizes. Tags can be attached to almost anything like Employee ID card,
Student ID, Vehicles, Assets, Shoes etc. There are two types of RFID tags.
• Passive Tags

• Active Tags

5.1.1 Passive Tags


Passive tags are the most widely used, as they are smaller and less expensive to
implement. Passive tags must be “powered up” by the RFID reader before they can transmit
data. Passive tags are comprised of three elements: an integrated circuit or chip, an antenna,
and a substrate. The RFID chip stores data and perform specific tasks. Depending on its
design, the chip may be Read-Only (RO), Write-Once, Read-Many (WORM) or Read-Write
(RW). Typically, RFID chips carry 96 bits of memory (12Bytes).

5.1.2 Active Tags


Unlike passive tags, active RFID tags have an onboard power supply (e.g., a battery),
thereby enabling them to transmit data at all times. Like passive RFID tags, active tags have
both a microchip and an antenna. The chips, however, are usually larger in size and have
greater capabilities than the RFID chips in passive tags.

Page | 14
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

5.2 RFID Reader


It is used to read unique IDs from RFID tags. Whenever RFID tags come in range, the
RFID reader reads its unique ID and transmits it serially to the microcontroller or PC. The
RFID reader has a transceiver and an antenna mounted on it. It is mostly fixed in a stationary
position RFID reader has a transceiver that generates a radio signal and transmits it through
the antenna. This signal itself is in the form of energy which is used to activate and power the
tag. When the RFID tag comes in a range of signals transmitted by the reader, the transponder
in the tag is hit by this signal.
A tag draws power from the electromagnetic field created by the reader. Then the
transponder converts that radio signal into usable power. After getting power, the transponder
sends all the information it has stored in it, such as a unique ID to the RFID reader in the form
of an RF signal. Then, the RFID reader puts this unique ID data in the form of a byte on a
serial Tx (transmit) pin. This data can be used or accessed by PC or microcontroller serially
using UART communication.

5.2.1 EM18 RFID Reader


This module directly connects to any microcontroller UART or through an RS232
converter to a PC. It gives UART/Wiegand26 output. This RFID Reader Module works with
any 125 kHz RFID tags. In our projects and Tutorials, we are going to use this module. RFID
is an upcoming innovation which has as of late pulled in light of a legitimate concern for the
exploration group in view of the uncommon advantages it offers over the other existing
recognizable proof and information detecting advancements. RFID is a specific term utilized
for systems which use radio wave to naturally distinguish things. RFID is a technology that
permit exchange of information amongst labels and reader without the need of viewable
pathway over a separation up to a couple of 10 meters relying upon the sort of label engaged.
For this framework the information is being swapped by radio waves and distinct tags can be
scrutinized or collected normally.
This part is designed to survey the current technology writing and probe the problems
in the existing RFID organization starting from the transformation to yet in its recognition
phase. From past the growth of this revolution from 1900's aside to this expressed reliable
perspectives, thus innovation likewise supports a few affairs or points. A planned motivation
behind part for look at the writing identified with the above-mentioned technology
additionally develops scholarly analysis with giving a deal into a segment of the outstanding
and noteworthy cases hindering the growth of this alteration. It ought to confront these cases
with a specific end goal to give a more prominent perceivability and an enhanced item speed
of the RFID innovation.
From past 1900's the evolution of this innovation aside the expressed affirmative
viewpoints, the innovation additionally carries a few problems. And the anticipated rationale
for part is to have a look at the writing related to Radio frequency Identification further
develops scholastic research and giving a knowledge into a portion of the exceptional and
urgent issues blocking the development of the RFID innovation. There is an emergency need

Page | 15
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

to address these issues with a specific end goal to give a more prominent deceivability and
an enhanced item speed of the RFID innovation. The main utilization of radio waves to
transmit signals goes back to World War II when transponder (labels) was put on plane and
used to recognize drawing a nearer plane. Interrogators dispatched a signal to the system on
the plane and the signal delivered previously could be deployed to identify amicable and
hostile flying machine.

5.2.2 Hardware Specifications


EM-18 RFID reader is one of the commonly used RFID readers to read 125KHz tags.
It features low cost, low power consumption, small form factor and easy to use. The module
radiates 125KHz through its coils and when a 125KHz passive RFID tag is brought into this
field it will get energized from this field.

5.2.3 Pin Configuration

Pin Description

VCC Should be connected to positive of power source.

GND Should be connected to ground.

BUZZ Should be connected to BUZZER

NC No Connection

NC No Connection

SEL SEL=1 then o/p =RS232


SEL=0then o/p=WEIGAND

TX DATA is given out through TX of RS232

DATA1 WEIGAND interface DATA HIGH pin

Page | 16
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

5.3 Specifications

• Operating voltage of EM-18: +4.5V to +5.5V


• Current consumption:50mA
• Can operate on LOW power
• Operating temperature: 0ºC to +80ºC
• Operating frequency:125KHz
• Communication parameter:9600bps
• Reading distance: 10cm, depending on TAG
• Integrated Antenna

5.4 How to Use Em-18 RFID Module


EM-18 is used like any other sensor module. First, we choose the mode of
communication between MODULE and CONTROLLER. Next, we will program the controller
to receive data from module to display. Next power the system. When a tag is brought near the
MODULE it reads the ID and sends the information to controller. The controller receives the
information and performs action programmed by us.
Step1: Establishing a mode of communication. EM-18 can provide output through two
communication interfaces. One is RS232 and another is WEIGAND. The form of
communication is selected by SEL pin. If SEL pin is selected HIGH then form of
communication is RS232 and if SEL pin is pulled LOW then form of communication is
WEIGAND. Usually, the RS232 is selected because it’s popular so SEL pin is pulled HIGH.
Step2: The output of MODULE bit rate is 9600bps (bit per second). The controller should be
programmed to receive information from MODULE at this rate. If bit rate of controller
mismatches then the system will not work correctly.
Now let us consider a simple EM-18 circuit diagram,

Fig 5.1 EM18 RFID module

Page | 17
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

Fig 5.2 Circuit Diagram of RFID Module


In the circuit BUZZER is not compulsory. When a TAG is read the BUZZER turns ON. As
given in circuit, TX is given to CONTROLLER which is to receive DATA.

5.5 Applications
• RFID is used in many applications like an attendance system in which every person will
have their separate RFID tag which will help identify the person and their attendance.

• RFID is used in many companies to provide access to their authorized employees.

• In Material Management.

• Tool Tracking.

• In Hospitals.

• RFID is also helpful to keep track goods and in automated toll collection system on the
highway by having unique tag on them.

Page | 18
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

CHAPTER 6
LIQUID CRYSTAL DISPLAY(LCD)
We always use devices made up of Liquid Crystal Displays (LCDs) like computers,
digital watches and also DVD and CD players. They have become very common and have
taken a giant leap in the screen industry by clearly replacing the use of Cathode Ray Tubes
(CRT). CRT draws more power than LCD and are also bigger and heavier. LCD’s have made
displays thinner than CRT’s. Even while comparing the LCD screen to an LED screen, the
power consumption is lesser as it works on the basic principle of blocking light rather than
dissipating. All of us have seen an LCD, but no one knows the exact working of it. Let us take
a look at the working of an LCD.

We get the definition of LCD from the name “Liquid Crystal” itself. It is actually a
combination of two states of matter – the solid and the liquid. They have both the properties of
solids and liquids and maintain their respective states with respect to another. Solids usually
maintain their state unlike liquids who change their orientation and move everywhere in the
particular liquid. Further studies have showed that liquid crystal materials show more of a liquid
state than that of a solid. It must also be noted that liquid crystals are more heat sensitive than
usual liquids. A little amount of heat can easily turn the liquid crystal into a liquid. This is the
reason why they are also used to make thermometers.

6.1 Basics of LCD Displays


The liquid-crystal display has the distinct advantage of having a low power
consumption than the LED. It is typically of the order of microwatts for the display in
comparison to some order of mill watts for LEDs. Low power consumption requirement has
made it compatible with MOS integrated logic circuit. Its other advantages are its low cost, and
good contrast. The main drawbacks of LCDs is additional requirement of light source, a limited
temperature range of operation (between 0 and 60° C), low reliability, short operating life, poor
visibility in low ambient lighting, slow speed and the need for an ac drive.

6.2 Basic Structure of LCD


A liquid crystal cell consists of a thin layer (about 10 u m) of a liquid crystal
sandwiched between two glass sheets with transparent electrodes deposited on their inside faces.
With both glass sheets transparent, the cell is known as transitive type cell. When one glass is
transparent and the other has a reflective coating, the cell is called reflective type. The LCD
does not produce any illumination of its own. It, in fact, depends entirely on illumination falling
on it from an external source for its visual effect

6.3 Types of Liquid Crystal Displays


Two types of display available are dynamic scattering display and field effect display.
When dynamic scattering display is energized, the molecules of energized area of the display
become turbulent and scatter light in all directions. Consequently, the activated areas take on a
frosted glass appearance resulting in a silver display. Of course, the energized areas remain
translucent.

Page | 19
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

Field effect LCD contains front and back polarizers at right angles to each other.
Without electrical excitation, the light coming through the front polarizer is rotated 90° in the
fluid. Now, let us take a look at the different varieties of liquid crystals that are available for
industrial purposes. The most usable liquid crystal among all the others is the nematic phase
liquid crystals.

6.4 Nematic Phase Lcd


The greatest advantage of a nematic phase liquid crystal substance is that it can bring
about predictable controlled changes according to the electric current passed through them. All
the liquid crystals are according to their reaction on temperature difference and also the nature
of the substance. Twisted Nematic, a particular nematic substance is twisted naturally. When a
known voltage is applied to the substance, it gets untwisted in varying degrees according to our
requirement. This in turn is useful in controlling the passage of light. A nematic phase liquid
crystal can be again classified on the basis in which the molecules orient themselves in respect
to each other. This change in orientation mainly depends on the director, which can be anything
ranging from a magnetic field to a surface with microscopic grooves. Classification includes
Semitic and also cholesteric. Semitic can be again classified as sematic C, in which the
molecules in each layer tilt at an angle from the previous layer. Cholesteric, on the other hand
has molecules that twist slightly from one layer to the next, causing a spiral like design. There
are also combinations of these two called Ferro-electric liquid crystals (FLC), which include
cholesteric molecules in a smectic C type molecule so that the spiral nature of these molecules
allows the microsecond switching response time. This makes FLCs to be of good use in
advanced displays.
Liquid crystal molecules are further classified into thermochroic and lipotropic crystals.
The former changes proportionally with respect to changes in pressure and temperature. They
are further divided into nematic and isotropic. Nematic liquid crystals have a fixed order of
pattern while isotropic liquid crystals are distributed randomly. The lipotropic crystal depends
on the type of solvent they are mixed with. They are therefore useful in making detergents and
soaps.

6.5 Making of LCD


• Though the making of LCD is rather simple there are certain facts that should be noted
while making it.
• The basic structure of an LCD should be controllably changed with respect to the applied
electric current.
• The light that is used on the LCD can be polarized.
• Liquid crystals should be able to both transmit and change polarized light.
• There are transparent substances that can conduct electricity.
To make an LCD, you need to take two polarized glass pieces. The glass which does not
have a polarized film on it must be rubbed with a special polymer which creates microscopic
grooves in the surface. It must also be noted that the grooves are on the same direction as the
polarizing film. Then, all you need to do is to add a coating of nematic liquid crystals to one of
the filters. The grooves will cause the first layer of molecules to align with the filter’s
orientation. At right angle to the first piece, you must then add a second piece of glass along
with the polarizing film. Till the uppermost layer is at a 90-degree angle to the bottom, each

Page | 20
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

successive layer of TN molecules will keep on twisting. The first filter will naturally be
polarized as the light strikes it at the beginning. Thus, the light passes through each layer and is
guided on to the next with the help of molecules. When this happens, the molecules tend to
change the plane of vibration of the light to match their own angle. When the light reaches the
far side of the liquid crystal substance, it vibrates at the same angle as the final layer of
molecules. The light is only allowed an entrance if the second polarized glass filter is same as
the final layer. Take a look at the figure below.

6.6 Working of LCD


The main principle behind liquid crystal molecules is that when an electric current is
applied to them, they tend to untwist. This causes a change in the light angle passing through
them. This causes a change in the angle of the top polarizing filter with respect to it. So little
light is allowed to pass through that particular area of LCD. Thus, that area becomes darker
comparing to others.
For making an LCD screen, a reflective mirror has to be setup in the back. An electrode
plane made of indium-tin oxide is kept on top and a glass with a polarizing film is also added
on the bottom side. The entire area of the LCD has to be covered by a common electrode and
above it should be the liquid crystal substance. Next comes another piece of glass with an
electrode in the shape of the rectangle on the bottom and, on top, another polarizing film. It
must be noted that both of them are kept at right angles. When there is no current, the light
passes through the front of the LCD it will be reflected by the mirror and bounced back. As the
electrode is connected to a temporary battery the current from it will cause the liquid crystals
between the common-plane electrode and the electrode shaped like a rectangle to untwist. Thus,
the light is blocked from passing through. Thus, that particular rectangular area appears blank.

Page | 21
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

6.7 Colour Liquid Crystal Display


Colour LCDs are those that can display pictures in colours. For this to be possible there
must be three sub-pixels with red, green and blue colour filters to create each colour pixel. For
combining these sub-pixels these LCDs should be connected to a large number of transistors.
If any problem occurs to these transistors, it will cause a bad pixel. One of the main
disadvantages of these types of LCDs is the size. Most manufacturers try to reduce the height
than gain it. This is because more transistors and greater pixels will be needed to increase the
length. This will increase the probability of bad pixels. It is very difficult or also impossible to
repair a LCD with bad pixels. This will highly affect the sale of LCDs.16X2 LCD is the most
commonly used LCD Display.16X2 indicates that it can display 32 characters in 2 lines. It has
16 pins. They are shown below.

6.8 Pin Description

Data Pins: Pin7 to Pin14 are data Pins.

Vss: It is the Ground Pin of the module.

Vdd: It is the supply pin of the module.

VEE: Pin3 is used for controlling the brightness of the LCD. Normal setting of this pin is
between 0.4V to 0.9V.A 10 k pot is connected to adjust the brightness of the screen.

Register Select: RS pin is used to select the register. There are two registers in this LCD. They
are data register data instruction register. Data register sends data to the screen while instruction
register sends Commands to LCD’s controller, which controls the instructions.

Logic High (1) – Activates Data register.

Logic Low (0) – Activates Instruction register.

RW selects either read or write mode. In this this pin is connected to ground.

Logic High (1) – Activates Read mode.

Logic Low (0) – Activates Write mode.

Page | 22
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

6.9 Circuit Diagram

Fig 6.1 Connection Diagram of LCD with Arduino

Page | 23
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

CHAPTER 7
I2C BUS PROTOCAL
The I2C or IIC stands for “Inter-Integrated Circuit” is a serial computer bus invented by
Philips semiconductors, today known as NXP semiconductors. This bus system was invented
in 1982. Bus is a group of cables / wires which carry data from one chip to another chip / one
circuit board to another circuit board. The main advantage of I2C bus protocol is that, the
supported microcontroller or sensors or chips can be interlinked with just two wires. The mind-
blowing advantage of this protocol is that, we can interconnect 127 different chips or sensors /
drivers to one master device which usually a microcontroller with just 2 wires. The two wires
are SDA and SCL which are Serial Data and Serial clock respectively. The Serial clock or SCL
is used to sync the data communication over I2C bus. The SDA or Serial Data is the data line in
which the actual data is conveyed from master to slave and vice versa. The master device
controls the Serial clock and decides for which slave device it needs to communicate. No slave
device can initiate a communication first, only master device can do. The Serial data line is
bidirectional and robust, after every set of 8-bit data is sent, the receiving device sends back
an acknowledgement bit.

7.1 HOW FAST I2C PROTOCOL IS?


The original version of I2C protocol developed in 1982 supported 100 Kbps. The next
version was standardized in 1992 which supported 400Kbps (Fast mode) and supported up to
1008 devices. The next version was developed in 1998 with 3.4 Mbps (High speed mode).
Several other I2C versions were developed in the years 2000, 2007, 2012 (with 5Mbps Ultra-
Fast mode) and the recent version of I2C was developed in 2014.Why pull-up resistors in I2C
bus?
The SDA and SCL are “open-drain” which means both the lines can go LOW but it
can’t drive the lines HIGH, so a pull-up resistor is connected on each of the lines. But with most
of the I2C modules such as LCD or RTC has built in pull up resistors, so we no need to connect
one unless it is specified. Pull-up / Pull-down resistor: Pull-up resistor is a resistor connected to
+Ve line of the supply to keep the logic level of a line to HIGH if the line is neither high nor
low. A pull-down resistor is a resistor connected to –Ve line of the supply to keep the logic
level of a line to LOW if the line is neither high nor low. This also prevents noise entering the
lines. There are 16 output pins for LCD display which can be soldered directly to back of the
16 X 2 LCD module. The input pins are +5V, GND, SDA and SCL. The SDA and SCL pins
on Arduino Uno are pins A4 and A5 respectively. For Arduino mega SDA is pin #20 and SCL
is pin #21.

Let us compare how it looks when we wire up the LCD to Arduino without the I2C
adapter and with the adapter.

Page | 24
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

7.2 Without I2C Adapter:

7.2.1 With I2C Adapter:

The Adapter is soldered on the back of the LCD display and as we can see that we saved loads
of GPIO pins for other tasks and also, we can continue add 126 more I2C devices to pins A4
and A5. Please note that the standard Liquid Crystal library won’t work with this I2C LCD
adapter, there is a special library for this, which will be covered soon and we’ll show you how
to use this module with coding example.

Page | 25
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

7.3 HOW TO CONNECT I2C ADAPTER TO 16 X 2 DISPLAY


In the above sections of the article, we learned the basics of I2C protocol and took a
basic overview on I2C LCD adapter module. In this post we are going to learn how to connect
the I2C LCD adapter module to 16 x 2 LCD display and we will see how program with an
example. The major advantage of I2C protocol is that we can wire the supported sensors / input
/ output devices in just two lines and it is helpful with Arduino as it has limited GPIO pins. Now
let’s see how to connect the module to LCD. The module has 16 output pins and 4 input pins.
We can just solder the adapter to the back of the 16 x 2 LCD display. Out of the 4 input pins,
the two are +5V and GND, rest of the two are SDA and SCL. We can see that we saved a lot
of pins at Arduino for other input / output tasks. We can adjust the contrast of the display by
adjusting the potentiometer.
I2C uses only two bidirectional open collector or open drain lines, Serial Data Line
(SDA) and Serial Clock Line (SCL), pulled up with resistors. Typical voltages used are +5 V
or +3.3 V, although systems with other voltages are permitted. The I2C reference design has a
7-bit address space, with a rarely used 10-bit extension.] Common I2C bus speeds are the 100
kbit standard mode and the 400 kbit/s Fast mode. There is also a 10 kbit/s low-speed mode, but
arbitrarily low clock frequencies are also allowed. Later revisions of I2C can host more nodes
and run at faster speeds (400 kbit/s Fast mode, 1 Mbit/s Fast mode plus, 3.4 Mbit High Speed
mode, and 5 Mbit/s Ultra-Fast-mode). These speeds are more widely used on embedded systems
than on PCs. Note the bit rates are quoted for the transfers between master and slave without
clock stretching or other hardware overhead. Protocol overheads include a slave address and
perhaps a register address within the slave device, as well as per-byte ACK/NACK bits. Thus,
the actual transfer rate of user data is lower than those peak bit rates alone would imply. For
example, if each interaction with a slave inefficiently allows only 1 byte of data to be
transferred, the data rate will be less than half the peak bit rate. The number of nodes which can
exist on a given I2C bus is limited by the address space and also by the total bus
capacitance of 400 pF, which restricts practical communication distances to a few meters. The
relatively high impedance and low noise immunity requires a common ground potential, which
again restricts practical use to communication within the same PC board or small system of
boards.

7.4 Transaction Format

An I2C transaction consists of one or more messages. Each message begins with a start
symbol, and the transaction ends with a stop symbol. Start symbols after the first, which begin a
message but not a transaction, are referred to as repeated start symbols. Each message is a read
or a write. A transaction consisting of a single message is called either a read or a write
transaction. A transaction consisting of multiple messages is called a combined transaction.
The most common form of the latter is a write message providing intra-device address
information, followed by a read message.
Many I2C devices do not distinguish between a combined transaction and the same
messages sent as separate transactions, but not all. The device ID protocol requires a single
transaction; slaves are forbidden from responding if they observe a stop symbol. Configuration,
calibration or self-test modes which cause the slave to respond unusually are also often
automatically terminated at the end of a transaction.

Page | 26
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

7.5 Timing Diagram

Fig 7.5 Timing diagram

1. Data transfer is initiated with a start condition (S) signaled by SDA being pulled low
while SCL stays high.
2. SCL is pulled low, and SDA sets the first data bit level while keeping SCL low (during
blue bar time).
3. The data are sampled (received) when SCL rises for the first bit (B1). For a bit to be
valid, SDA must not change between a rising edge of SCL and the subsequent falling
edge (the entire green bar time).
4. This process repeats, SDA transitioning while SCL is low, and the data being read while
SCL is high (B2, Ban).
5. The final bit is followed by a clock pulse, during which SDA is pulled low in preparation
for the stop bit.
6. A stop condition (P) is signaled when SCL rises, followed by SDA rising.
In order to avoid false marker detection, there is a minimum delay between the SCL falling
edge and changing SDA, and between changing SDA and the SCL rising edge. Note that an
I2C message containing N data bits (including acknowledges) contains N+1 clock pulses.

Page | 27
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

CHAPTER 8
ARDUINO IDE

8.1 Introduction

An ARDUINO is a tiny computer that you can program to process inputs and outputs
going to and from the chip. The ARDUINO is what is known as a Physical or Embedded
Computing platform, which means that it is an interactive system that through the use of
hardware and software can interact with its environment. For example, a simple use of the
ARDUINO would be to turn a light on for a set period of time, let’s say 30 seconds, after a button
has been pressed (we will build this very same project later in the book). In this example, the
ARDUINO would have a lamp connected to it as well as a button.
The Arduino would sit patiently waiting for the button to be pressed. When you press
the button, it would then turn the lamp on and start counting. Once it had counted 30 seconds it
would then turn the lamp off and then carry on sitting there waiting for another button press.
You could use this set-up to control a lamp in an under-stair’s cupboard for example. You could
extend this example to sense when the cupboard door was opened and automatically turn
the light on, turning it off after a set period of time.
The Arduino can be used to develop stand-alone interactive objects or it can be
connected to a computer to retrieve or send data to the Arduino and then act on that data (e.g.
Send sensor data out to the internet). The ARDUINO can be connected to LEDʼs. Dot Matrix
displays, LED displays, buttons, switches, motors, temperature sensors, pressure sensors,
distance sensors, webcams, printers, GPS receivers, Ethernet modules,
The ARDUINO board is made of an Atmel AVR Microprocessor, a crystal or oscillator
(basically a crude clock that sends time pulses to the microcontroller to enable it to operate
at the correct.
To program the Arduino (make it do what you want it to) you also use the Arduino IDE
(Integrated Development Environment), which is a piece of free software, that enables you to
program in the language that the Arduino understands. In the case of the Arduino the language
is C. The IDE enables you to write a computer program, which is a set of step-by- step
instructions that you then upload to the Arduino. Then your Arduino will carry out those
instructions and interact with the world outside. In the Arduino world, programs are known as
sketches.

Page | 28
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

The Arduino hardware and software are both Open Source, which means the code, the
schematics, design, etc. are all open for anyone to take freely and do what they like with it.
This means there is nothing stopping anyone from taking the schematics and PCB designs.

The Arduino and making their own and selling them. This is perfectly legal, and indeed the
whole purpose of Open Source, and indeed the Fredonia that comes with the Earthshine
Design Arduino Starter Kit is a perfect example of where someone has taken the Arduino PCB
design, made their own and are selling it under the Fredonia name. You could even make your
own.
The only stipulation that the Arduino development team put on outside developers is
that the Arduino name can only be used exclusively by them on their own products and hence
the clone boards have names such as Fredonia, Boarding, Borodino, etc. As the designs are

open source, any clone board, such as the Fredonia, is 100% compatible with the Arduino and
therefore any software, hardware, shields, etc. will all be 100% compatible.

Page | 29
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

The Arduino can also be extended with the use of shields which circuit boards are
containing other devices (e.g., GPS receivers, LCD Displays, Ethernet connections, etc.) that
you can simply slot into the top of your Arduino to get extra functionality. You don’t have to
use a shield if you don’t want to as you can make the exact same circuitry using a breadboard,
some Vero board or even by making your own PCBʼs.

There are many different variants of the Arduino available. The most common one is
the Diecimila or the Duemilanove. You can also get Mini, Nano and Bluetooth Arduinos. New
to the product line is the new Arduino Mega with increased memory and number of I/O pins.
Probably the most versatile Arduino, and hence the reason it is the most popular, is the
Duemilanove. This is because it uses a standard 28 pin chip, attached to an IC Socket. The
beauty of this systems is that if you make something neat with the Arduino and then want to
turn it into something permanent (e.g., Or under- stairs cupboard light), then instead of using
the relatively expensive Arduino board, you can simply use the Arduino to develop your
device, then pop the chip out of the board and place it into your own circuit board in your
custom device. You would then have made a custom embedded device, which is really cool.
Then, for a couple of quid or bucks you can replace the AVR chip in your Arduino
with a new one. The chip must be pre-programmed with the Arduino Boot loader to enable
it to work with the Arduino IDE, but you can either burn the Boot loader yourself if you
purchase an AVR Programmer, or you can buy these pre- programmed from many suppliers
around the world. Of course, Earthshine Design provide pre- programmed Arduino
chips in it store for a very reasonable price.
If you do a search on the Internet by simply typing Arduino into the search box of
your favorite search engine, you will be amazed at the huge number of websites dedicated to
the Arduino. You can find a mind-boggling amount of information on projects made with the
Arduino and if you have a project in mind, will easily find information that will help you to
get your project up and running easily.
The Arduino is an amazing device and will enable you to make anything from
interactive works of art to robots. With a little enthusiasm to learn how to program the
Arduino and make it interact with other components a well as a bit of imagination, you can
build anything you want. This book and the kit will give you the necessary skills needed to
get started in this exciting and creative hobby. So, now you know what an Arduino is and
what you can do with it, let’s open up the starter kit and dive right in.
Page | 30
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

8.2 Getting Started:


This section will presume you have a PC running Windows or a Mac running OSX
(10.3.9 or later). If you use Linux as your Operating System.

8.3 GET THE ARDUINO AND THE USB CABLE:

Firstly, get your Arduino board and lay it on the table in front of you. Take the
USB cable and plug the B plug (the fatter squarer end) into the USB socket on the
Arduino.

At this stage do NOT connect the Arduino to your PC or Mac yet.


8.4 Download the Arduino IDE
Download the Arduino IDE from the Arduino download page. As of the time of writing
this book, the latest IDE version is 0015. The file is a ZIP file so you will need to
uncompressed it. Once the download has finished, unzip the file, making sure that you
preserve the folder structure as it is and do not make any changes.
If you double-click the folder, you will see a few files and sub-folders inside.

8.5 Installing of USB Drives


If you are using Windows, you will find the drivers in the drivers/FTDI USBDRIVERS
directory of the Arduino distribution. In the next stage (“Connect the Arduino”), you will
Page | 31
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

point Windows Add New Hardware wizard to these drivers.

If you have a Mac these are in the driver’s directory. If you have an older Mac like a
PowerBook, iBook, G4orG5, you should use the PC FTDIUSBSerialDriver_v2_1_9.dmg. If
you have a newer Mac with an Intel chip, you need the Intel drivers:
FTDIUSBSerialDriver_v2_2_9_Intel.dmg. Double-click to mount the disk image and run the
included FTDI USB Serial Driver. pkg.
The latest version of the drivers can be found on the FTDI website.
First, make sure that the little power jumper, between the power and USB sockets, is set to USB
and not External power (not applicable if you have an Arduino board, which has an Auto Power Select
function).

Now, connect the other end of the USB cable into the USB socket on your PC or Mac. You will now
see the small power LED (marked PWR above the RESET switch) light up to show you have power to the
board.
If you have a Mac, this stage of the process is complete and you can move on to the next Chapter.
If you are using Windows, there are a few more steps to complete.

On Windows they Found New Hardware Wizard will now open up as Windows
will have detected that you have connected a new piece of hardware (your Arduino board) to

Page | 32
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

your PC. Tell it NOT to connect to Windows update (Select No, not at this time) and then
click next.
On the next page select “Install from a list or specific location (Advanced)” and click next.

Make sure that “Search for the best driver in these locations” is checked.

Uncheck “Search removable media”. Check “Include this location in the search” and then
click the Browse button. Browse to the location of the USB drivers and then click next.

The wizard will now search for a suitable driver and then tell you that a “USB Serial
Convertor” has been found and that the hardware wizard is now complete. Click Finish.
Now, before we upload the Sketch, we need to tell the IDE what kind of Arduino we are using
and the details of our USB port. Go to the file menu and click Tools, then clock on Board. You
will be presented with a list of all of the different kinds of Arduino board that can be

Page | 33
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

connected to the IDE. Our Freeduino board will either be fitted with an Atmega328 or an
Atmega168 chip so choose “Arduino Duemilanove w/ATmega328” if you have a 328 chip or
“Arduino Diecimila or Duemilanove w/ ATmega328P” if you have a 328 chip.
Now that your Arduino has been connected and the drivers for the USB chip have been
installed, we are now ready to try out the Arduino for the first time and upload your first
Sketch.

We will take a look at the IDE in a little more detail in the next chapter. For now, simply click
File in the file menu and scroll down to Sketchbook. Then scroll down to Examples and click
it. You will be presented with a list of Example sketches that you can use to try out your
Arduino. Now click on Digital and inside there you will find an example Sketch called Blink.
Click on this. T h e B l i n k Sketch will n o w b e loaded into the IDE and

Now you need to tell the IDE the details of your USB port, so now click on Tools again, scroll
down to Serial Port and a list of the available serial ports on your system will be displayed.
You need to choose the one that refers to your USB cable, which is usually listed as something

Page | 34
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

like /dev./tty.usbserial-xxxx ona Mac or something like Com 4 on Windows so click on that.
If not sure, try each one till you find one that works.

You can either click the Upload button, which is the 6th button from the left at the top
with an arrow pointing to the right (hover your mouse pointer over the buttons to see what
they are) or by clicking on File in the file menu and scrolling down to Upload to I/O Board
and clicking on that.

Presuming everything has been set up correctly you will now see the RX and TX
LEDʼs (and also LED 13) on the Freeduino flash on and off very quickly as data is uploaded to
the board. You will see Uploading to I/O Board....
Once the data has been uploaded to the board successfully you will get a done message in the
IDE and the RX/TX LEDʼs will stop flashing.
The Arduino will now reset itself and immediately start to run the Sketch that you have
just uploaded.
Just below the code window too.

The Blink sketch is a very simple sketch that blinks LED 13, which is a tiny green LED
soldered to the board and also connected to Digital Pin 13 from the Microcontroller, and will
make it flash on and off every 1000 milliseconds, or 1 second. If your sketch has uploaded

Page | 35
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

successfully, you will now see this LED happily flashing on and off slowly on your board.
If so, congratulations, you have just successfully installed your Arduino, uploaded and ran your first
sketch.
We will now explain a bit more about the Arduino IDE and how to use it before
moving onto the projects that you can carry out using the hardware supplied with the kit. For
our first project we will carry out this Blink LED sketch again, but this time using an LED that
we will physically connect to one of the digital output pins on the Arduino. We will also
explain the hardware and software involved in this simple project. But first, let’s take a closer
look at the Arduino IDE.

When you open up the Arduino IDE it will look very similar to the image above. If you
are using Windows or Linux there will be some slight differences but the IDE is pretty much
the same no matter what OS you are using.
The IDE is split up into the Toolbar across the top, the code or Sketch Window in the
center and the Serial Output window at the bottom.

The Toolbar consists of 7 buttons, underneath the Toolbar is a tab, or set of tabs, with the
filename of the code within the tab. There is also one further button on the far right hand
side.

Page | 36
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

Along the top is the file menu with drop down menus headed under File, Edit, Sketch,
Tools and Help. The buttons in the Toolbar provide convenient access to the most commonly
used functions within this file menu.

8.6 Serial Monitor

The Toolbar buttons are listed above. The functions of each button are as follows: -

Verify/Co Checks the code for errors

Stop Stops the serial monitor, or un-highlights

New Creates a new blank Sketch

Open Shows a list of Sketches in your

Save Saves the current Sketch

Upload Uploads the current Sketch to the Arduino

Serial Displays serial data being sent from the


.

The Stop button will stop the Serial Monitor from operating. It will also un-highlight
other selected buttons. Whilst the Serial Monitor is operating you may wish to press the Stop
button to obtain a snapshot of the serial data so far to examine it. This is particularly useful if
you are sending data out to the Serial Monitor quicker than you can read tithe New button will
create a completely new and blank Sketch read for you to enter code into. The IDE will ask
you to enter a name and a location for your Sketch (try to use the default location if possible)
and will then give you a blank Sketch ready to be coded. The tab at the top of the Sketch will
now contain the name you have given to your new sketch.
The Open button will present you with a list of Sketches stored within your sketchbook as

Page | 37
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

well as a list of Example sketches you can try out with various peripherals once connected.

The Save button will save the code within the sketch window to your sketch file. Once
complete you will get a done saving message at the bottom of the code window. The Upload
to I/O Board button will upload the code within the current sketch window to your Arduino.
You need to make sure that you have the correct board and port selected (in the Tools menu)
before uploading. It is essential that you Save your sketch before you upload it to your board
in case a strange error causes your system to hang or the IDE to crash. It is also advisable to
Verify/Compile the code before you upload to ensure there are no errors that need to be
debugged first. The Serial Monitor is a very useful tool, especially for debugging your code.
The monitor displays serial data being sent out from your Arduino (USB or Serial board). You
can also send serial data back to the Arduino using the Serial Monitor. If you click the Serial
Monitor button you will be presented with an image like the one above.
On the left hand side you can select the Baud Rate that the serial data is to be sent
to/from the Arduino. The Baud Rate is the rate, per second, that characters (data) is sent
to/from the board. The default setting is 9600 baud, which means that if you were to send a
text novel over the serial communications line (in this case your USB cable) then 9600
letters, or symbols, of the novel, would be sent per second.

To the right of this is a blank text box for you to enter text to send back to the Arduino
and a Send button to send the text within that field. Note that no serial data can be received

Page | 38
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

by the Serial Monitor unless you have set up the code inside your sketch to do so. Similarly,
the Arduino will not receive any data sent unless you have coded it to do so.Finally, the black
area is where your serial data will be displayed. In the image above, the Arduino is running the
ASCII Table sketch that can be found in the Communications examples. This program outputs
ASCII characters, from the Arduino via serial (the USB cable) to the PC where the Serial
monitor then displays them. To start the Serial Monitor press the Serial Monitor button and to
stop it press the Stop button. On a Mac or in Linux, Arduino board will reset itself (rerun the
code from the beginning) when you click the Serial Monitor button. Once you are proficient
at communicating via serial to and from the Arduino you can use other programs such as
Processing, Flash, Max MSP, etc. To communicate between the Arduino and your PC.

We will make use of the Serial Monitor later on in our projects when we read data from
sensors and get the Arduino to send that data to the Serial Monitor, in human readable form,
for us to see. The Serial Monitor window is also were you will see error messages (in red text)
that the IDE will display to you when trying to connect to your board, upload code or verify
code. Below the Serial Monitor at the bottom left you will see a number. This is the current
line that the cursor, within the code window, is at. If you have code in your window and you
move down the lines of code (using the ↓ key on your keyboard) you will see the number
increase as you move down the lines of code. This is useful for finding bugs highlighted by
error messages. Across the top of the IDE window (or across the top of your screen if you are
using a Mac) you will see the various menus that you can click on to access more menu items.

The menu bar across the top of the IDE looks like the image above (and slightly
different in Windows And Linux). I will explain the menus as they are on a Mac, the details
will also apply to the Windows and Linux versions of the IDE.
The next menu is the File menu. In here you get access to options to create a New
sketch, take a look at Sketches stored in your Sketchbook (as well as the Example Sketches),
options to Save your Sketch (or Save As if you want to give it a different name). You also
have the option to upload your sketch to the I/O Board (Arduino) as well as the Print options
for printing out your code.

Page | 39
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

CHAPTER 9
PROTEUS 8 PROFESSNALS

9.1 About Proteus


It is a software suite containing schematic, simulation as well as PCB designing.
• ISIS is the software used to draw schematics and simulate the circuits in real time. The
simulation allows human access during run time, thus providing real time simulation.
• ARES is used for PCB designing. It has the feature of viewing output in 3D view of the
designed PCB along with components.
• The designer can also develop 2D drawings for the product.
9.2 Features
ISIS has wide range of components in its library. It has sources, signal generators,
measurement and analysis tools like oscilloscope, voltmeter, ammeter etc., probes for real time
monitoring of the parameters of the circuit, switches, displays, loads like motors and lamps,
discrete components like resistors, capacitors, inductors, transformers, digital and analog
Integrated circuits, semi-conductor switches, relays, microcontrollers, processors, sensors etc.
ARES offers PCB designing up to 14 inner layers, with surface mount and through whole
packages. It is embedded with the foot prints of different category of components like ICs,
transistors, headers, connectors and other discrete components. It offers Auto routing and
manual routing options to the PCB Designer. The schematic drawn in the ISIS can be directly
transferred ARES.

9.3 Starting New Design


Step 1: Open ISIS software and select New design in File menu

Page | 40
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

Step 2: A dialogue box appears to save the current design. However, we are creating a new
design file so you can click Yes or No depending on the content of the present file. Then a
Pop-Up appears asking to select the template. It is similar to selecting the paper size while
printing. For now select default or according to the layout size of the circuit.

Step 3: An untitled design sheet will be opened, save it according to your wish,it is better to
create a new folder for every layout as it generates other files supporting your design.
However, it is not mandatory.

Page | 41
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

Step 4: To Select components, Click on the component mode button.

Component Mode
Step 5: Click on Pick from Libraries. It shows the categories of components available and a
search option to enter the part name.

Page | 42
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

Step 6: Select the components from categories or type the part name in Keywords text box.

Example shows selection of push button. Select the components accordingly.

Page | 43
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

Step 7: The selected components will appear in the devices list. Select the component and
place it in the design sheet by left-click.

Place all the required components and route the wires i.e, make connections. Either selection
mode above the component mode or component mode allows to connect through wires. Left
click from one terminal to other to make connection. Double right-click on the connected
wire or the component to remove connection or the component respectively.

Page | 44
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

Double click on the component to edit the properties of the components and click on Ok.

Step 8: After connecting the circuit, click on the play button to run the simulation.

In this example simulation, the button is depressed during simulation by clicking on it to


make LED glow.

Page | 45
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

Simulation can be stepped, paused or stopped at any time.

Page | 46
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

CHAPTER 10
WORKING
This innovative project consists of an automated billing system which can be placed
within the shopping trolley. This automated payment system consists of a RFID reader which
is controlled by Arduino. So, whenever the shopper puts any product in trolley it is detected by
the RFID module and is displayed on LCD along with the price of the product. As the shopper
goes on adding products, all products are detected by the module and therefore the price will
increase accordingly customer has to put a product into smart shopping trolley. Each and every
product has product id. The RFID reader can read the product id. Which can have been useful
for customers. All such solutions can be useful for customer. Such solutions save the customer
time and money etc.
A customer goes into a shopping center then she/he first take a trolley. Every last trolley
is joined with a scanner tag per user and a RFID per user. The framework work is the point at
which the customer buys a thing, the customer must be examining the thing first with help of
standardized tag are available in each item utilizing the RFID per user. At that point that
acquired thing can be set into the trolley. While the client is examining the RF tag of the item,
a cost of the buying item is taken and spared in the framework's memory/Arduino. Information
put away in framework's memory is contrasted and the query table. In the event that matches
are discovered at that point cost, name of individual item gets showed on the LCD
Different variables like item cost, item name etc are continuously displayed on LCD
attached to the trolley. Thus we can say that automatic billing of products by using RFID
technique will be a more feasible choice in the upcoming days and thereby operation becomes
more concise and systematic. The developed product is of low cost, amiable to use and does
not require any specific practice.

The ability to take a decision can be done in the cart itself which can be used in the
shopping complexes for effortless and clever way of purchasing items to save vitality, time and
money of the customers. The project is evaluated with different trial cases with distinct items
assessed for all the practical trials. Tags used in this project are of water sensitive so the trolley
is restricted to use water sensitive products. And moreover, tags used in this project have the
capacity of detecting only one side therefore tags are attached to products in circular fashion in
order to avoid non detection. If we can use more powerful tags which are under research, we
can overcome this problem. When the evaluation is done with a single shopping trolley with
distinct items, it gives the 83% accuracy for all the cases.

Page | 47
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

RESULT

Page | 48
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

APPENDIX

SOURCE CODE
#include <Arduino.h>

#include <LiquidCrystal_I2C.h>

#include <Wire.h>

#include <string.h>

LiquidCrystal_I2C lcd(0x27,16,2);

int count = 0;

char input[12];

double total = 0;

int count_prod=0;

void setup() {

Serial.begin(9600);

pinMode(4,OUTPUT);

pinMode(5,OUTPUT);

pinMode(6,OUTPUT);

Serial.begin(9600);

lcd.begin();

lcd.backlight();

lcd.setCursor(0,0);

lcd.print("AUTOMATIC BILL");

delay (2000);

lcd.setCursor(0,1);

lcd.print("SHOPPING CART");

Page | 49
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

delay(2000);

lcd.clear();

lcd.setCursor(0,0);

lcd.print("WELCOME TO");

lcd.setCursor(0,1);

lcd.print("BIG BAZZAR");

void loop() {

if(Serial.available())

count = 0;

while(Serial.available() && count < 12)

input[count] = Serial.read();

count++;

delay(5);

if(input[0] == '0' && input[1] == 'B' && input[2] == '0' && input[3] == '0' &&

input[4] == '2' && input[5] == 'B' && input[6] == '4' && input[7] == '7' &&

input[8] == '1' && input[9] == '2' && input[10] == '7' && input[11] == '6' )

lcd.setCursor(0,0);

lcd.print("BISCUIT ADDED ");

Page | 50
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

lcd.setCursor(0,1);

lcd.print("price(RS):4.00");

digitalWrite(4,HIGH);

digitalWrite(5,HIGH);

delay(1000);

total = total + 4.00;

count_prod++;

digitalWrite(4,LOW);

digitalWrite(5,LOW);

if(input[0] == '0' && input[1] == 'B' && input[2] == '0' && input[3] == '0' &&

input[4] == '2' && input[5] == '4' && input[6] == '3' && input[7] == '2' &&

input[8] == 'A' && input[9] == '1' && input[10] == 'B' && input[11] == 'C' )

lcd.setCursor(0,0);

lcd.print("soap added");

lcd.setCursor(0,1);

lcd.print("Price(Rs):6.00");

digitalWrite(4,HIGH);

digitalWrite(5,HIGH);

delay(1000);

total = total + 6.00;

count_prod++;

digitalWrite(4,LOW);

digitalWrite(5,LOW);

Page | 51
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

if(input[0] == '0' && input[1] == 'B' && input[2] == '0' && input[3] == '0' &&

input[4] == '2' && input[5] == '4' && input[6] == '2' && input[7] == '1' &&

input[8] == '9' && input[9] == '4' && input[10] == '9' && input[11] == 'A' )

lcd.clear();

lcd.setCursor(0,0);

digitalWrite(6,HIGH);

digitalWrite(5,HIGH);

delay(1000);

lcd.print("Total price :-");

digitalWrite(6,LOW);

digitalWrite(5,LOW);

lcd.setCursor(0,1);

lcd.print(total);

delay(5000);

lcd.clear();

lcd.setCursor(0,0);

lcd.print("THANKS FOR");

lcd.setCursor(0,1);

lcd.print("VISITING");

Page | 52
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

ADVANTAGES AND APPLICATIONS

Advantages
It saves customer’s time.
It also reduces the payoff given for workers.
It is possible to rewrite the RFID tags.
It doesn’t need line of sight.

Applications
It Can be utilized in dress showrooms
Grocery store
All wholesale shopping malls
It can be used in super markets
Industrial equipment stores

Page | 53
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

CONCLUSION

The desired objectives were successfully achieved in the prototype model developed.
The developed product is easy to use and economical. Though the project showcases the
proof of concept, there are a few aspects that can be included to make the smart shopping
cart more robust. To begin with, in this project the latency time of the wireless
communication with the server may need to be considered. Secondly, the communication is
not very secure. It is impossible to stick RFID tag to some products. In such cases,
conventional scanning of barcode is more sophisticated. Further, a more sophisticated micro-
controller and larger display system can be used to provide better consumer experience. The
advancement in science and technology is a persistent process. Latest gadgets and latest
technology are being designed and developed. This application is used in shopping malls for
assisting customers by saving a lot of time in buying commodities. In this project RFID is
used as safety access for the item which thereby enhances the surveillance performance. This
implementation initiates for an automated central billing system in shopping malls and
supermarkets. With this, shoppers no longer have to wait near counters for payment of bills
because of their purchased item information getting transferred to central billing unit. By this
billing process speed increases and becomes much simpler. In addition to this capability, the
mechanism also assures recognition of cases of theft induced by fraudulent consumers which
makes the system more reliable and fascinating to both customers as well as sellers. This
will enhance the shopping experience to a new level.
Different variables like item cost, item name etc. are continuously displayed on LCD
attached to the trolley. Thus, we can say that automatic billing of products by using RFID
technique will be a more feasible choice in the upcoming days and thereby operation
becomes more concise and systematic. The developed product is of low cost, amiable to use
and does not require any specific practice. The ability to take a decision can be done in the
cart itself which can be used in the shopping complexes for effortless and clever way of
purchasing items to save vitality, time and money of the customers. The project is evaluated
with different trial cases with distinct items assessed for all the practical trials. Tags used in
this project are of water sensitive so the trolley is restricted to use water sensitive products.
And moreover, tags used in this project have the capacity of detecting only one side therefore
tags are attached to products in rectangular fashion in order to avoid non detection. If we can
use more powerful tags which are under research, we can overcome this problem. When the
evaluation is done with a single shopping trolley with distinct items, it gives the 83%
accuracy for all the cases.

Page | 54
YSREC OF YVU, PDTR
SMART SHOPPING TROLLEY WITH ADVANCED BILLING SYSTEM

REFERENCES

[1] Kriti Bhagat, Saylee Deshmukh, Shraddha Dhonde, Sneha Ghag publications of
International Journal of Science, Engineering and Technology Research (IJSETR),
Volume 5, Issue 2, February 2016.
[2] Subhranil Som, Arjun Shome by publication Subhranil Som Int. Journal of
Engineering Research and Applications, ISSN: 2248-9622, Vol. 4, Issue 6 (Version 3),
June 2014.
[3] M. S. Islam & M. A. Rahman published by Asian Journal of Applied Science and
Engineering, Volume 2, No 2 (2013).
[4] Prananjali Koppad, Vishnu Agarwal published by International Journal of
Engineering Research & Technology (IJERT), ISSN: 2278-0181, IJERTV3IS090023
Vol. 3 Issue 9, September-2014
[5] S. Akash, Bibek Kabi , Mr. S.Karthick published by International Journal of Recent
Trends in Engineering, Vol 2, No. 7, November 2009
. [6] Juing-Huei Su, Chyi-Shyong Lee, Hsin-Hsiung Huang, Sheng-Hsiung Chuang &
Chih-Yuan Lin published by World Transactions on Engineering and Technology
Education 2010 WIETE Vol.8, No.4, 2010 [7] International Journal of Engineering
Trends and Technology (IJETT) – Volume 32 Number 5- February 2016. Subankar Roy
#1, Tashi Rapden Wangchuk#2, Rajesh Bhatt#3

Page | 55
YSREC OF YVU, PDTR

You might also like