Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /home/freehos1/public_html/projectus/core/open_close_dbase_connection.php on line 0

Deprecated: Function split() is deprecated in /home/freehos1/public_html/projectus/Railway-anticollision-system/index.php(0) : eval()'d code on line 22

Deprecated: Function split() is deprecated in /home/freehos1/public_html/projectus/Railway-anticollision-system/index.php(0) : eval()'d code on line 35

Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /home/freehos1/public_html/projectus/scripts/get_ad_type_position.php on line 0

Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /home/freehos1/public_html/projectus/scripts/load_ads.php on line 0

Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /home/freehos1/public_html/projectus/scripts/sponsor_found.php on line 0

Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /home/freehos1/public_html/projectus/scripts/load_links.php on line 0

Deprecated: Function split() is deprecated in /home/freehos1/public_html/projectus/Railway-anticollision-system/index.php(0) : eval()'d code on line 161

Deprecated: Function split() is deprecated in /home/freehos1/public_html/projectus/Railway-anticollision-system/index.php(0) : eval()'d code on line 164

Deprecated: Function split() is deprecated in /home/freehos1/public_html/projectus/Railway-anticollision-system/index.php(0) : eval()'d code on line 167
designing the software for railway anticollision system
projectus.freehost7.com:UG and PG level projects,mini projects and many more here ...







 

MEMORY MAPPING

We have used one 8-bit microcontroller 8051 and two peripheral devices i.e.8255 for hardware implementation. 8255 is connected to 8051 for interfacing various I/O devices. RD and WR signals are used for reading I/P and writing O/P respectively. CS signal is used for selection of particular chip. The memory map of the designed hardware is shown below.

The base address of first 8255 :

A15 A14 A13 A12 A11 A10 A9 A8 A7 A6 A5 A4 A3 A2 A1 A0

1 X X X X X X X X X X X X X 0 0 =8000H 1PA

1 X X X X X X X X X X X X X 0 1 =8001H 1PB

1 X X X X X X X X X X X X X 1 0 =8002H 1PC

1 X X X X X X X X X X X X X 1 1 =8003H 1CR

Input/output I/O Port RAM location

LCD 8000H 1PA 30H

Switch 8001H 1PB 31H

LCD 8002H 1PC 32H

- 8003H 1CR 33H

 

 

For the first 8255, we have assigned PB, upper half of PC as input ports and PA, lower half of PC as output ports. So the required control word for the first 8255 is -

D7 D6 D5 D4 D3 D2 D1 D0

1 0 0 0 1 0 1 0 = 8AH

The base address of second 8255 :

A15 A14 A13 A12 A11 A10 A9 A8 A7 A6 A5 A4 A3 A2 A1 A0

1 X X X X X 1 X X X X X X X 0 0 =8200H 2PA

1 X X X X X 1 X X X X X X X 0 1 =8201H 2PB

1 X X X X X 1 X X X X X X X 1 0 =8202H 2PC

1 X X X X X 1 X X X X X X X 1 1 =8203H 2CR

Input/output I/O Port RAM location

LED 8200H 2PA 34H

LED 8201H 2PB 35H

LED 8202H 2PC 36H

- 8203H 2CR 37H

For the second 8255, we have assigned PA,PB and PC port as output ports. So the required control word for the second 8255 is-

D7 D6 D5 D4 D3 D2 D1 D0

1 0 0 0 0 0 0 0 = 80H

 

 

The base address of third 8255 :

A15 A14 A13 A12 A11 A10 A9 A8 A7 A6 A5 A4 A3 A2 A1 A0

1 X X X X X X 1 X X X X X X 0 0 =8100H 3PA

1 X X X X X X 1 X X X X X X 0 1 =8101H 3PB

1 X X X X X X 1 X X X X X X 1 0 =8102H 3PC

1 X X X X X X 1 X X X X X X 1 1 =8103H 3CR

Input/Output I/O Port RAM location

DIGITAL INPUT 8101H 3PB 39H

DIGITAL INPUT 8102H 3PC 40H

- 8103H 3CR 41H

 

For the third 8255, we have assigned PA,PB and PC port as input ports. So the required control word for the third 8255 is-

D7 D6 D5 D4 D3 D2 D1 D0

1 0 0 1 1 0 1 1 = 9BH