You are on page 1of 28

Restaurant Automation

Dept Of ECE,VJCET 1
Chapter 1
INTRODUCTION

The 'embedded system' is a combination of hardware,software and additional
mechanical parts designed to do a specific function.it is intended to perform a particular task
with or without human intervention.software is developed as per user requirements to
perform desired functions. the project ' restaurant automation ' is based on embedded
techonology that uses ATMEL'S microcontroller AT89s52.this device has wide capabilityin
communication purposes.the program as per user's requirement ,is coded in assembly
language,keil is used to stimulate and assemble written code.





Restaurant Automation

Dept Of ECE,VJCET 2
Chapter 2
CIRCUIT DIAGRAM


Figure 2.1 Circuit diagram of receiver and customer section
Restaurant Automation

Dept Of ECE,VJCET 3
Chapter 3
INTRODUCTION TO MICROCONTROLLER AT89S52 ATMEL


Fig 3.1 AT8s52
The AT89S52 is a low-power, high-performance CMOS 8-bit microcontroller with4K
bytes of in-system programmable Flash memory. The device is manufactured using Atmels
high-density nonvolatile memory technology and is compatible with the industry standard
80C52 instruction set and pinout. The on-chip Flash allows the program memory to be
reprogrammed in-system or by a conventional nonvolatile memory programmer. By
combining a versatile 8-bit CPU with in-system programmable Flash on a monolithic chip,
the Atmel AT89S52 is a powerful microcontroller which provides a highly-flexible and cost-
effective solution to many embedded control applications
The AT89S52 provides the following standard features: 4K bytes of Flash, 128 bytes
of RAM, 32 I/O lines, Watchdog timer, two data pointers, two 16-bit timer/counters, a
fivevector two-level interrupt architecture, a full duplex serial port, on-chip oscillator, and
clock circuitry. In addition, the AT89S52 is designed with static logic for operation down to
zero frequency and supports two software selectable power saving modes. The Idle Mode
stops the CPU while allowing the RAM, timer/counters, serial port, and interrupt system to
Restaurant Automation

Dept Of ECE,VJCET 4
continue functioning. The Power-down mode saves the RAM contents but freezes the
oscillator, disabling all other chip functions until the next external interrupt or hardware reset.

3.1 FEATURES
4K Bytes of In-System Programmable (ISP) Flash Memory Endurance: 1000
Write/Erase cycles
4.0V to 5.5V Operating Range
Fully Static Operation: 0 Hz to 33 MHz
Three-level Program Memory Lock
128 x 8-bit Internal RAM
32 Programmable I/O Lines
Two 16-bit Timer/Counters
Six Interrupt Sources
Full Duplex UART Serial Channel
Low-power Idle and Power-down Modes
Interrupt Recovery from Power-down Mode
Watchdog Timer
Dual Data Pointer
Power-off Flag
Fast Programming Time
Flexible ISP Programming (Byte and Page Mode)

3.2 PORTS
Port 0 Port 0 is an 8-bit open drain bidirectional I/O port. As an output port, each pin can
sink eight TTL inputs. When 1s are written to port 0 pins, the pins can be used as high
impedance inputs. Port 0 can also be configured to be the multiplexed low-order address/data
bus during accesses to external program and data memory. In this mode, P0 has internal pull-
ups. Port 0 also receives the code bytes during Flash programming and outputs the code bytes
during program verification. External pull-ups are required during program verification.

Port 1 Port 1 is an 8-bit bidirectional I/O port with internal pull-ups. The Port 1 output
buffers can sink/source four TTL inputs. When 1s are written to Port 1 pins, they are pulled
Restaurant Automation

Dept Of ECE,VJCET 5
high by the internal pull-ups and can be used as inputs. As inputs, Port 1 pins that are
externally being pulled low will source current (IIL) because of the internal pull-ups.
Port 1 also receives the low-order address bytes during Flash programming and verification.
Table 3.1 port 1 pin functions

Port 2 Port 2 is an 8-bit bidirectional I/O port with internal pull-ups. The Port 2 output
buffers can sink/source four TTL inputs. When 1s are written to Port 2 pins, they are pulled
high by the internal pull-ups and can be used as inputs. As inputs, Port 2 pins that are
externally being pulled low will source current (IIL) because of the internal pull-ups.
Port 2 emits the high-order address byte during fetches from external program memory and
during accesses to external data memory that use 16-bit addresses (MOVX @ DPTR). In this
application, Port 2 uses strong internal pull-ups when emitting 1s. During accesses to external
data memory that use 8-bit addresses (MOVX @ RI), Port 2 emits the contents of the P2
Special Function Register.
Port 2 also receives the high-order address bits and some control signals during Flash
programming and verification.
Port 3 Port 3 is an 8-bit bidirectional I/O port with internal pull-ups. The Port 3 output
buffers can sink/source four TTL inputs. When 1s are written to Port 3 pins, they are pulled
high by the internal pull-ups and can be used as inputs. As inputs, Port 3 pins that are
externally being pulled low will source current (IIL) because of the pull-ups.
Port 3 receives some control signals for Flash programming and verification.
Port 3 also serves the functions of various special features of the AT89S51, as shown in the
following table.








Restaurant Automation

Dept Of ECE,VJCET 6
Table 3.2 port 3 pin functions



3.3 PIN CONFIGURATION

Fig 3.2 Pin Configuration
3.4 PIN DESCRIPTION

VCC Supply voltage.
GND Ground.

Restaurant Automation

Dept Of ECE,VJCET 7
RST Reset input. A high on this pin for two machine cycles while the oscillator is running
resets the
device. This pin drives High for 98 oscillator periods after the Watchdog times out. The
DISRTO bit in SFR AUXR (address 8EH) can be used to disable this feature. In the
default state of bit DISRTO, the RESET HIGH out feature is enabled.

ALE/PROG Address Latch Enable (ALE) is an output pulse for latching the low byte of
the address during accesses to external memory. This pin is also the program pulse input
(PROG) during Flash
programming. In normal operation, ALE is emitted at a constant rate of 1/6 the oscillator
frequency and may be used for external timing or clocking purposes. Note, however, that
one ALE pulse is
skipped during each access to external data memory. If desired, ALE operation can be
disabled by setting bit 0 of SFR location 8EH. With the bit set, ALE is active only during
a MOVX or MOVC instruction. Otherwise, the pin is weakly pulled high. Setting the
ALE-disable bit has no effect if the microcontroller is in external execution mode.

PSEN Program Store Enable (PSEN) is the read strobe to external program memory.
When the AT89S51 is executing code from external program memory, PSEN is activated
twice each machine cycle, except that two PSEN activations are skipped during each
access to external data memory.

EA/VPP External Access Enable. EA must be strapped to GND in order to enable the
device to fetch code from external program memory locations starting at 0000H up to
FFFFH. Note, however,
that if lock bit 1 is programmed, EA will be internally latched on reset. EA should be
strapped to VCC for internal program executions. This pin also receives the 12-volt
programming enable voltage (VPP) during Flash programming.

XTAL1 Input to the inverting oscillator amplifier and input to the internal clock operating
circuit.

XTAL2 Output from the inverting oscillator amplifier

Restaurant Automation

Dept Of ECE,VJCET 8
3.5 BLOCK DIAGRAM

Fig 3.3 block diagram of at89s52







Restaurant Automation

Dept Of ECE,VJCET 9

Chapter 4
INTRODUCTION TO XBEE


Fig 4.1 XBEE module
XBEE is a specification for a suite of high level communication protocols used to
create personal area networks built from small, low-power digital radios. XBEE is based on
an IEEE 802.15 standard. Though low-powered, XBEE devices can transmit data over long
distances by passing data through intermediate devices to reach more distant ones, creating a
mesh network; i.e., a network with no centralized control or high-power transmitter/receiver
able to reach all of the networked devices. The decentralized nature of such wireless ad hoc
networks make them suitable for applications where a central node can't be relied upon.
XBEE is used in applications that require only a low data rate, long battery life, and
secure networking. XBEE has a defined rate of 250 kbit/s, best suited for periodic or
intermittent data or a single signal transmission from a sensor or input device. Applications
include wireless light switches, electrical meters with in-home-displays, traffic management
systems, and other consumer and industrial equipment that requires short-range wireless
Restaurant Automation

Dept Of ECE,VJCET 10
transfer of data at relatively low rates. The technology defined by the XBEE specification is
intended to be simpler and less expensive than other WPANs, such as Bluetooth or Wi-Fi.
XBEE networks are secured by 128 bit symmetric encryption keys. In home
automation applications, transmission distances range from 10 to 100 meters line-of-sight,
depending on power output and environmental characteristics.
[1]


4.1 Features
DSSS transceiver
250kbps data rate, 2 MChip/s chip rate
O-QPSK with half sine pulse shaping modulation
Very low current consumption
RX (receiving frame, -50 dBm): 18.5 mA
RX (waiting for frame): 22.3 mA
TX (+5 dBm output power): 33.6 mA
TX (0 dBm output power): 25.8 mA
Three flexible power modes for reduced power consumption
Low power fully static CMOS design
Very good sensitivity (-98dBm)
High adjacent channel rejection (49 dB)
High alternate channel rejection (54 dB)
On chip VCO, LNA, PA and filters.
Low supply voltage (1.8 - 3.8 V)
Programmable output power up to +5 dBm
I/Q direct conversion transceiver







Restaurant Automation

Dept Of ECE,VJCET 11









Table 4.1 Pin Assignments for the XBeePRO Modules








Restaurant Automation

Dept Of ECE,VJCET 12

4.2 BLOCK DIAGRAM

Fig 4.2 blockdiagram of XBEE module





Restaurant Automation

Dept Of ECE,VJCET 13

4.4 INTERFACING XBEE WITH 8051

We want to interface the XBEE module with 8051 Primer Board for accessing the
mobiles without wires through UART0. The data communication is done in internet by using
the XBEE module through MAX232 into the SBUF register of 8051 microcontroller (refer
serial interfacing with 8051). The serial data from the XBEE receiver is taken by using the
Serial Interrupt of the controller. +5V and ground is connected to provide power to the
module. While TX and RX pin is connected for communication.

Circuit diagram

Fig 4.3 interfacing XBEE with 8052

Restaurant Automation

Dept Of ECE,VJCET 14
Chapter 5
LCD MODULE


Fig 5.1 Lcd module
LCD (Liquid Crystal Display) screen is an electronic display module and find a wide
range of applications. A 16x2 LCD display is very basic module and is very commonly used
in various devices and circuits. These modules are preferred over seven segments and other
multi segment LEDs. The reasons being: LCDs are economical; easily programmable; have
no limitation of displaying special & even custom characters (unlike in seven segments),
animations and so on.
A 16x2 LCD means it can display 16 characters per line and there are 2 such lines. In
this LCD each character is displayed in 5x7 pixel matrix. This LCD has two registers,
namely, Command and Data.
The command register stores the command instructions given to the LCD. A
command is an instruction given to LCD to do a predefined task like initializing it, clearing
its screen, setting the cursor position, controlling display etc. The data register stores the data
to be displayed on the LCD. The data is the ASCII value of the character to be displayed on
the LCD.




Restaurant Automation

Dept Of ECE,VJCET 15


5.1 PIN DESCRIPTION
Table 5.1 lcd pin description
PIN
NO
NAME

FUNCTION

1 VSS Ground pin
2 VCC Power supply pin of 5V
3 VEE Used for adjusting the contrast commonly attached to the potentiometer.
4 RS
RS is the register select pin used to write display data to the LCD (characters), this
pin has to be high when writing the data to the LCD. During the initializing
sequence and other commands this pin should low.
5 R/W
Reading and writing data to the LCD for reading the data R/W pin should be high
(R/W=1) to write the data to LCD R/W pin should be low (R/W=0)
6 E
Enable pin is for starting or enabling the module. A high to low pulse of about
450ns pulse is given to this pin.
7 DB0

8 DB1

9 DB2

10 DB3

11 DB4
DB0-DB7 Data pins for giving data(normal data like numbers characters or
command data) which is meant to be displayed
12 DB5

13 DB6

14 DB7

15 LED+ Back light of the LCD which should be connected to Vcc
16 LED- Back light of LCD which should be connected to ground.


5.2 COMMANDS
There are some preset commands which will do a specific task in the LCD. These
commands are very important for displaying data in LCD. The list of commands given
below:
Command Function
0F For switching on LCD, blinking the cursor.
1 Clearing the screen
2 Return home.
4 Decrement cursor
6 Increment cursor
E Display on and also cursor on
Restaurant Automation

Dept Of ECE,VJCET 16
Command Function
80 Force cursor to beginning of the first line
C0 Force cursor to beginning of second line
38 Use two lines and 5x7 matrix
83 Cursor line 1 position 3
3C Activate second line
0C3 Jump to second line position 3
0C1 Jump to second line position1

Restaurant Automation

Dept Of ECE,VJCET 17
Chapter 6
MATRIX KEY PAD

Fig 6.1 keypad
Matrix Keypads are commonly used in calculators, telephones etc where a number of
input switches are required. We know that matrix keypad is made by arranging push button
switches in row and columns. In the straight forward way to connect a 44 keypad (16
switches) to a microcontroller we need 16 inputs pins. But by connecting switches in the
following way we can read the status of each switch using 8 pins of the microcontroller.

Fig 6.2 keypad connection diagram
Restaurant Automation

Dept Of ECE,VJCET 18
The status of each keys can be determined by a process called Scanning. For the sake
of explanation lets assume that all the column pins (Col1 Col4) are connected to the inputs
pins and all the row pins are connected to the output pins of the microcontroller. In the
normal case all the column pins are pulled up (HIGH state) by internal or external pull up
resistors. Now we can read the status of each switch through scanning.
1. A logic LOW is given to Row1 and others (Row2 Row-4) HIGH
2. Now each Column is scanned. If any switch belongs to 1
st
row is pressed
corresponding column will pulled down (logic LOW) and we can detect the pressed
key.
3. This process is repeated for all rows.
If you need to save more pins of your microcontroller then you can interface keypad
using the ADC module of your microcontroller.


Restaurant Automation

Dept Of ECE,VJCET 19
Chapter 7
VOLTAGE REGULATOR IC



Fig 7.1 7805
The AT80s51 ic and most of its components need 5v dc supply. Here we use 7805 ic
for the conversion of 9v battery voltage to 5v supply. 7805 is a voltage regulator integrated
circuit. It is a member of 78xx series of fixed linear voltage regulator ICs. The voltage source
in a circuit may have fluctuations and would not give the fixed voltage output. The voltage
regulator IC maintains the output voltage at a constant value. The xx in 78xx indicates the
fixed output voltage it is designed to provide. 7805 provides +5V regulated power supply.
Capacitors of suitable values can be connected at input and output pins depending upon the
respective voltage levels.

7.1 Pin Description
Table 7.1 7805 pin description


Restaurant Automation

Dept Of ECE,VJCET 20
Chapter 8
RESTAURANT AUTOMATION

8.1 INTRODUCTION

Usually when we go to any restaurant for dinner waitstaff/server provides us
with the menu book, take our orders serve us in the best way they can. But most of the time
item is listed in the menu by names only. They dont have brief or detailed description so
fearing how would they test, what would be the ingredients, whether we will like it or not
& several other thoughts, we end up eating/ordering regular items (familiar foods) even
though we are willing to experiment different cuisines.Citing these problems we have
come up with the idea of having a digital ordering system. This is a microcontroller
based system having a keypad. The concept is we can browse the menus/sub-menus by
jus fingertip. The items would be well defined & descripted . We can select the items
from the various categories like- starter, veg., non-veg, drinks, ice-creams, desserts etc.
& place the order by just a finger touch and the desired order will be served over a
conveyer belt to the particular customer table without any serving staff interference.

8.2 BLOCK DIAGRAM

The block diagram of keypad based restaurant ordering system is shown below


Restaurant Automation

Dept Of ECE,VJCET 21
Fig8.1 block diagram of transmitter section

Fig 8.2 block diagram of receivers section

8.3 WORKING
This project presents with a solution to the hotel management for providing the
fastest services to the customers. Since then we have two major problems. Firstly we
have to increase range so we use XBEE technology for the transmission purpose.
Second is reducing the service time. This paper aims to show that managing queuing
strategy that can solve this problem. This paper can help in making a restaurant fully
automated. The waiter will take the orders from the customers table and ask for the
confirmation of the order when the order is confirmed the order will be send to the
concerned chef automatically through the wireless transmission by using XBEE module.
On the advancement this paper can became more reliable by using digital touchable
screens given to the waiter or hardware is embedded over the table on which customer
is sitting for giving the orders to the chef. The whole of the ordering, billing information can
be send to the microcontroller on the chef receiver side. This will help the higher
management to get noticed about billing and each dish ordered.This will really help them
Restaurant Automation

Dept Of ECE,VJCET 22
during their auditing, and knowing there strength and weaknesses and also improvising on
it.
This project is a whole automated system designed to get orders from the customers,
make them ready and the delivered to them. The project has a system that is given to
every waiter to take the orders. As the person takes the order and finalizes the dishes, the
order number with dish codes are sent to the main chef automatically in the form of
packets using a XBEE wireless technology. The chef makes the dishes according to the
order. When the dish will be ready the chef sends a ready command back to the waiter.
There will be MCU (microcontroller unit) section to perform all the controlling oftaking
orders, sending it and receiving back the ready command. Order will be taken by
using a matrix pad or by using digital touchable screen. Transmission is done by using
XBEE transceiver.

8.4 FLOWCHART
Receiver section

Restaurant Automation

Dept Of ECE,VJCET 23
Customer side

Restaurant Automation

Dept Of ECE,VJCET 24

8.5 PCB LAYOUT
































Fig 8.3 Pcb Layout
Restaurant Automation

Dept Of ECE,VJCET 25
Chapter 9

RESULTS

In our project we are basically focused on the time delay which
occurs during manual ordering of foods in restaurant.Our project helps the customers to alert
the chef their dishes directly and there by avoiding the time lag occurring during the original
existing system.in this modern era where time is money this project emerges out as best to
save unnecessary time lag in restaurants.

Restaurant Automation

Dept Of ECE,VJCET 26
Chapter 10
CONCLUSION AND FUTURE EXPANSION

After completing this project, the objectives of this project were successfully
accomplished on time. With this project, hopefully it can provide many benefits and
gains to consumers where they can save time to users and ease of use and greatly helpful in
the hotels. In conclusion, Zigbee based chef alerting system clearly shows improvements
in the use and effectiveness as it is more systematic and effective than the existing manual
ordering system. The middle man (waiter) is now removed by this project. User can give
orders directly to the chef simply by using this project.
In future this technology can be extended to the LAN connections by which the
order information and calculation of bills can be send to the distance places to the owners of
the hotels. The billing system can also be improved by using an ATM Swapping machine
along with this project. The programming should be done in such manner that order
can only be transfer to the chef if and only if the bill has been given.Another
expansion to be done is using gprs technology to pre order foods from outside the restaurant
using a mobile application.


Restaurant Automation

Dept Of ECE,VJCET 27
BIBLIOGRAPHY

[1] Microcontrollers and Embedded System by Ali Mazidi
[2] 8051 Microcontroller: An Application Based
Introduction by David Calcutt, Frederrick Cowan, and
Hassan Parchizadeh
[3] Keil website.[online].Available:www.keil.com/dd/
docs/datasheet Atmel AT89S52 microcontroller
datasheet
[4] S. Vijaya kumar, M.A. Shahid assisted Menu
Recommender to Enhance Customer Service and
Improve Restaurant (IJERT) Vol. 2 Issue 9, September -2013
[5] Interfacing www.pantechsolutions.net/accessoryboards/zigbee-interfacing-with-8051
[6] ZigBee/IEEE 802.15.4 Summary Sinem Coleri Ergen
email:csinem@eecs.berkeley.edu September 10, 2004
Restaurant Automation

Dept Of ECE,VJCET 28

You might also like