Four Elevator COntroller
Four Elevator COntroller
Four Elevator COntroller
Submitted to:
Submitted by:
Siddharth
9911102336
Mehul Garg
9911102255
Devyani Gera
9911102210
Abhas Vijayvargiya
9911102153
Table of Contents
1.Abstract
3.Theory
3.1 Dual Elevator Control
4.3 Assumptions
5.3 From the point of view as a System Being acted on by Many users
10
11
12
7.Verilog Code
13
8.Simulation Results
23
9.Conclusion
25
References
Abstract
The elevator control system is one of the important aspects in electronics control module in
automotive application. In this investigation elevator control system is designed with different
control strategies. First the elevator control system is implemented for multi-storage building.
This implementation is based on FPGA based logic controller for intelligent control of elevator
group system. This proposed approach is based on algorithm which is developed to reduce the
amount of computation required by focusing only on relevant rules and ignoring those which
are irrelevant to the condition for better performance of the group of elevator system. Here we
have designed controller for four elevators group.
Mehul Garg
Siddharth
Abhas Vijayvargiya
Theory
Elevator Control & its Working
Devyani Gera
Block Diagram
Verilog Coding for Four Elevator System
Theory
1. Dual Elevator Controller
An elevator or lift is a kind of transport device used to move people between building
floors. Whenever a passenger presses the call button for an elevator, a computer
receives the request and logs it for future reference. There are actually two sets of doors,
which allow passengers safely to exit and enter the lift. One set of doors remains shut
until an elevator car's presence is detected and the elevators computer controls the other
door. Once both doors are open, passengers should leave quickly to allow new
passengers to board and more calls to be answered. Elevator doors also contain motion
detectors and other presence-sensing devices to keep doors from trapping passengers.
Another issue want to be considered is the weight capacity. Overload in elevator will
lead to accident and using the load sensor can control it. In modern life elevators have
become an integral part of any public or commercial complex. It does not only ease the
faster movement between any two floors and provide a way for movement of disabled,
but has also become a status symbol. Elevators work on a gearless traction system in
which the movement of the elevator is controlled by several steel hoist ropes and a
counter-weight. The weight of the car and counterweight provides sufficient traction
between the sheaves and the hoist ropes so that the sheaves can grip the hoist ropes and
move and hold the car without excessive slipping. The machinery to drive the elevator
is located in a machine room usually directly above the elevator hoist way. To feed
electricity to the car and receive electrical signals from it, a multi-wire electrical cable
connects the machine room to the car.
2. Basic Principle
Elevators themselves are simple devices and the basic lifting systems have not changed
much in over 50 years. The control systems however, have changed substantially to
improve safety and speed of operation. Elevators are designed for a specific building
taking into account such factors as the height of the building, the number of people
traveling to each floor and the expected periods of high usage.
Controllers can also be programmed to respond differently at different times of the day.
For example the elevator controller in a busy office building will receive a
preponderance of calls from the ground floor in the morning. When workers are arriving
and need to go to their workplaces on the upper floors, in that case, the controller will
be programmed to send all unassigned cars to the ground floor rather than have them
return to a home floor in their sector. Later in the day a different set of instructions can
be used to send unassigned elevators to different sectors since passengers leaving the
building will be much more evenly distributed among the floors than in the morning.
3. Assumptions
The Dual Elevator System does face some conflict in the operation that which car
should take the request when both are at the same positions. So some assumptions are
implemented in the elevator algorithm. The assumptions considered are:
Default State:
The default position provides quick response to the request coming at any of the
four floors. The default positions of the elevators are specified below
E1 first floor
E2 second floor
E3 third floor
E4 fourth floor
4. Working of Elevator
In this general block diagram there are two main blocks are available. One is controller
and other is door operator. A sensor is connected between these two main blocks so that
if there any sensor signal goes high, the operation on all four elevators will be carried
out.
Every elevator has inside buttons for 1 to 4 floors and outside call button at every floor.
The sensor signal will sense the obstruction and timer, so that the signal from controller
will be send to door operator and hence the door operator will control the elevator
according to the request.
10
4.
The Finite state machine for Elevator System is done below. The state encodings are
mentioned below. The input are 2-bit binary.
State 00: floor 1
State 01: Floor 2
State 10: Floor 3
State 11: Floor 4
11
12
The project does not account for obstacles to sensor or any other interruption to the
movement of the elevator system.
The project does not account for a real life elevator system in the sense that various
functions of the elevator such as the hold door button, fire alarm button, stop etc. have
not been inducted in the code
The project assumes the opening and closing of the door and does not show it their
function in the simulation.
The functions of the lift operator such as scheduling a maintenance etc. have also been
avoided.
Verilog Code
`timescale 1ns /1ps // time scale of 1ns and resolution 0.01 ns
module elevator_demo( input clk, reset, req_1F, req_2F, req_3F, req_4F, req_E1_1,
req_E1_2, req_E1_3, req_E1_4, req_E2_1, req_E2_2, req_E2_3, req_E2_4, req_E3_1,
req_E3_2, req_E3_3, req_E3_4, req_E4_1, req_E4_2, req_E4_3, req_E4_4,output reg [1:0]
E1_pos, E2_pos, E3_pos, E4_pos,output reg [7:0] o1, o2, o3, o4);
reg [1:0] E1_next_pos, E2_next_pos, E3_next_pos, E4_next_pos;
reg dg;
parameter firstfloor= 2'b00, secondfloor = 2'b01, thirdfloor = 2'b10, fourthfloor = 2'b11;
begin
E1_pos <= E1_next_pos;
E2_pos <= E2_next_pos;
E3_pos <= E3_next_pos;
E4_pos <= E4_next_pos;
end
if (E1_pos==firstfloor)
begin
o1=8'b10011111;
13
dg=4'b1110;
end
if (E1_pos==secondfloor)
begin
o1=8'b00100101;
dg=4'b1110;
end
if (E1_pos==thirdfloor)
begin
o1=8'b00001101;
dg=4'b1110;
end
if (E1_pos==fourthfloor)
begin
o1=8'b10011001;
dg=4'b1110;
end
if (E2_pos==firstfloor)
begin
o2=8'b10011111;
dg=4'b1101;
end
if (E2_pos==secondfloor)
begin
o2=8'b00100101;
dg=4'b1101;
end
if (E2_pos==thirdfloor)
begin
o2=8'b00001101;
dg=4'b1101;
end
if (E2_pos==fourthfloor)
begin
o2=8'b10011001;
dg=4'b1101;
end\
14
if (E3_pos==firstfloor)
begin
o3=8'b10011111;
dg=4'b1011;
end
if (E3_pos==secondfloor)
begin
o3=8'b00100101;
dg=4'b1011;
end
if (E3_pos==thirdfloor)
begin
o3=8'b00001101;
dg=4'b1011;
end
if (E3_pos==fourthfloor)
begin
o3=8'b10011001;
dg=4'b1011;
end
if (E4_pos==firstfloor)
begin
o4=8'b10011111;
dg=4'b0111;
end
if (E4_pos==secondfloor)
begin
o4=8'b00100101;
dg=4'b0111;
end
if (E4_pos==thirdfloor)
begin
o4=8'b00001101;
dg=4'b0111;
end
15
if (E4_pos==fourthfloor)
begin o4=8'b10011001;
dg=4'b0111;
end
end
always@(posedge clk, reset, E1_pos, E2_pos, E3_pos, E4_pos, req_1F, req_2F, req_3F,
req_4F, req_E1_1, req_E1_2, req_E1_3, req_E1_4,req_E2_1, req_E2_2, req_E2_3,
req_E2_4, req_E3_1, req_E3_2, req_E3_3, req_E3_4, req_E4_1, req_E4_2, req_E4_3,
req_E4_4)
begin
begin
if (req_1F==1)
begin
E1_next_pos<=firstfloor;
end
if (req_2F==1)
begin
E2_next_pos<=secondfloor;
end
if (req_3F==1)
begin
E3_next_pos<=thirdfloor;
end
if (req_4F==1)
begin
E4_next_pos<=fourthfloor;
end
end
16
begin
if (req_E1_1==1)
E1_next_pos<=firstfloor;
if (req_E1_2==1)
E1_next_pos<=secondfloor;
if (req_E1_3==1)
E1_next_pos<=thirdfloor;
if (req_E1_4==1)
E1_next_pos<=fourthfloor;
end
begin
if (req_E2_1==1)
E2_next_pos<=firstfloor;
if (req_E2_2==1)
E2_next_pos<=secondfloor;
if (req_E2_3==1)
E2_next_pos<=thirdfloor;
if (req_E2_4==1)
E2_next_pos<=fourthfloor;
end
begin
if (req_E3_1==1)
E3_next_pos<=firstfloor;
if (req_E3_2==1)
E3_next_pos<=secondfloor;
17
if (req_E3_3==1)
E3_next_pos<=thirdfloor;
if (req_E3_4==1)
E3_next_pos<=fourthfloor;
end
begin
if (req_E4_1==1)
E4_next_pos<=firstfloor;
if (req_E4_2==1)
E4_next_pos<=secondfloor;
if (req_E4_3==1)
E4_next_pos<=thirdfloor;
if (req_E4_4==1)
E4_next_pos<=fourthfloor;
end
end
endmodule
//TESTBENCH
// Inputs
reg clk; reg reset;
reg req_1F, req_2F, req_3F, req_4F;
reg req_E1_1, req_E1_2, req_E1_3, req_E1_4;
18
//OUTPUTS
wire [1:0] E1_pos;
wire [1:0] E2_pos;
wire [1:0] E3_pos;
wire [1:0] E4_pos;
wire [7:0] o1;
wire [7:0] o2;
wire [7:0] o3;
wire [7:0] o4;
//Instantiate FE_Test
initial begin
// Initialize Inputs
19
clk = 0;
end
always clk=#10 ~clk;
initial
begin
reset = 1;
req_1F = 0;
req_2F = 0;
req_3F = 0;
req_4F = 0;
req_E1_1=0;
req_E1_2=0;
req_E1_3=0;
req_E1_4=0;
req_E2_1=0;
req_E2_2=0;
req_E2_3=0;
req_E2_4=0;
req_E3_1=0;
req_E3_2=0;
req_E3_3=0;
req_E3_4=0;
req_E4_1=0;
req_E4_2=0;
req_E4_3=0;
req_E4_4=0;
#10
20
reset = 1;
req_1F = 0;
req_2F = 0;
req_3F = 0;
req_4F = 0;
req_E1_1=0;
req_E1_2=1;
req_E1_3=0;
req_E1_4=0;
req_E2_1=0;
req_E2_2=0;
req_E2_3=0;
req_E2_4=1;
req_E3_1=1;
req_E3_2=0;
req_E3_3=0;
req_E3_4=0;
req_E4_1=0;
req_E4_2=0;
req_E4_3=1;
req_E4_4=0;
#10
//
reset = 1;
req_1F = 1;
req_2F = 1;
21
req_3F = 1;
req_4F = 1;
req_E1_1=0;
req_E1_2=0;
req_E1_3=0;
req_E1_4=0;
req_E2_1=0;
req_E2_2=0;
req_E2_3=0;
req_E2_4=0;
req_E3_1=0;
req_E3_2=0;
req_E3_3=0;
req_E3_4=0;
req_E4_1=0;
req_E4_2=0;
req_E4_3=0;
req_E4_4=0;
end
endmodule
22
Simulation Results
23
The simulation results corresponds to the above mentioned testbench. The following requests
were made to all the four elevators. Their output can be discerned in the four status values o1,
o2, l3, & o4 which mention the position of the elevators E1, E2, E3 & E4 respectively.
Each floor is decoded in the elevator status using eight bit numbers mentioned below:
Floor 1 10011111 8h9F
Floor 2 00100101 8h25
Floor 3 00001101 8h0D
Floor 4 10011001 8h99
The output Ex_pos gives the floor on which the elevator is located as per the earlier
mentioned values.
The input were given as follows:
E1- 2nd floor
E2- 4th floor
E3- 1st floor
E4- 3rd floor
The output is decided after 1 clock period, after which the values are reflected in the Ox
register.
24
Conclusion
This project has designed a four elevator system for as many floor. The output proves that
each lift gives priority to the internal inputs as compared to the external outputs.
The design can also be altered to suit the need for as many floors as required.
The simulation results have been successful.
25
References
[1] http://www.electrical-knowhow.com/2012/04/elevator-control-system.html
[2] http://image.slidesharecdn.com/fourelevatorcontroller-140216134421-phpapp01/95/fourelevator-controller-3-638.jpg?cb=139255837
[3] http://image.slidesharecdn.com/fourelevatorcontroller-140216134421-phpapp01/95/fourelevator-controller-3-638.jpg?cb=139255837
26