parallel port interfacing using assembly language
TRANSCRIPT
![Page 1: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/1.jpg)
Parallel Port Interfacing using Assembly
Language
Parallel Port Interfacing using Assembly
Language
![Page 2: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/2.jpg)
Computer port (hardware)
• A 'port' serves as an interface between the computer and other computers or peripheral devices.• A port is a specialized outlet on a
piece of equipment to which a plug or cable connects.
![Page 3: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/3.jpg)
Example ports
USB
![Page 4: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/4.jpg)
Example ports
FireWire
![Page 5: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/5.jpg)
Example ports
Ethernet port
![Page 6: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/6.jpg)
Example ports
Serial Port
![Page 7: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/7.jpg)
Example ports
Parallel Port
![Page 8: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/8.jpg)
Example ports
PS/2 Connector
![Page 9: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/9.jpg)
Example ports
VGA Connector
![Page 10: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/10.jpg)
Electrical signal transfer
Electronically, hardware ports can almost always be divided into two groups based on the signal transfer:•Serial ports send and receive one bit at a time via a single wire pair (Ground and +/-).•Parallel ports send multiple bits at the same time over several sets of wires.
![Page 11: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/11.jpg)
Electrical signal transfer
![Page 12: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/12.jpg)
Parallel PortParallel Port
• a type of interface found on computers for connecting various for connecting various peripheralsperipherals. . • is a parallel communicationparallel communication physical
interface.• is also known as a printer portprinter port
![Page 13: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/13.jpg)
Parallel Port AddressesParallel Port Addresses
PORT Name PORT AddressLPT1 0x3BC (956)LPT2 0x378 (888)LPT3 0x278 (632)
When the computer is first turned on, BIOS (Basic Input/Output System) will determine the number of ports you have and assign device labels LPT1, LPT2 & LPT3 to them. Usually the address for LPT1 is 378h.
![Page 14: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/14.jpg)
Parallel Port AddressesParallel Port Addresses
To know your Parallel Port address, do the following:Go to Start > Control Panel > System > ‘Hardware’ Tab > Click on Device Manager > Look for ‘Ports’ in the device list > Double click on LPT1 > Click on the ‘Resources’ Tab. In that you can see the starting address of I/O Range.
![Page 15: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/15.jpg)
Parallel Port PinsParallel Port Pins
![Page 16: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/16.jpg)
Circuit DiagramCircuit Diagram
![Page 17: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/17.jpg)
CPU ModesCPU Modes
Kernel ModeIn Kernel mode, the executing code has complete and unrestricted access to the underlying hardware.User ModeIn User mode, the executing code has no ability to directly access hardware or reference memory.
![Page 18: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/18.jpg)
User Port DriverUser Port Driver
• is a kernel mode driver for Windows NT/2000/XP/Vista/Win7 that gives usermode programs access to I/O ports.
• from Tomas Franzon.
Download Site:http://hem.passagen.se/tomasf/
UserPort/UserPort.zip
![Page 19: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/19.jpg)
UserPort InstallationUserPort Installation
• Copy UserPort.SYS to %WINDIR%\SYSTEM32\DRIVERS
• Start UserPort.EXE• add the addresses you want and remove
the others• click on start
![Page 20: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/20.jpg)
ProgrammingProgramming
.model tiny
.codemain: mov al, 00000001b mov dx, 378h out dx, al mov ax, 4c00h int 21hend main
![Page 21: Parallel Port Interfacing using Assembly Language](https://reader035.vdocuments.site/reader035/viewer/2022081418/563e0abf5503464e708b4d75/html5/thumbnails/21.jpg)