This detailed guide for programmers, developers, and computer enthusiasts shows how to get the most from parallel port in any application or project. The Visual-Basic code and circuit designs include examples that use the new enhanced (EPP) and expanded (EPC) modes.
"synopsis" may belong to another edition of this title.
Jan Axelson writes about computer programming and electronic technology. Jan's books include USB Embedded Hosts, USB Complete, Serial Port Complete, and USB Mass Storage. Jan's articles have appeared in Circuit Cellar, EDN, Embedded Systems Programming, and Nuts & Volts.
From Chapter 11, Modes for Data Transfer:
Detecting an ECP
In testing a port, you might think that the first step would be to test for an SPP, and work your way up from there. But if the port is an ECP, and it happens to be in its internal SPP mode, the port will fail the PS/2 (bidirectional) test. For this reason, the TestPort routine in Listing 4-4 begins by testing for an ECP.
An ECP has several additional registers. One of these, the extended control register (ECR) at base address + 402h, is useful in detecting an ECP.
Microsoft's ECP document recommends a test for detecting an ECP. First, read the port's ECR at and verify that bit 0 (FIFO empty) =1 and bit 1 (FIFO full) =0. These bits should be distinct from bits 0 and 1 in the port's Control register (at base address + 2). You can verify this by toggling one of the bits in the Control register, and verifying that the corresponding bit in the ECR doesn't change. A further test is to write 34h to the ECR and read it back. Bits 0 and 1 in the ECR are read-only, so if you read 35h, you almost certainly have an ECP.
If an ECP exists, you can read and set the port's internal ECP mode in bits 5, 6, and 7 of the ECR. In Listing 4-4, a combo box enables users to select an ECP mode when a port is ECP. Chapter 15 has more on reading, setting, and using the ECP's modes.
From Chapter 7, Output Applications:
Solid-state Relays
Another way to switch power to a load is to use a solid-state relay, which offers an easy-to-use, optoisolated switch in a single package. Figure 7-7A shows an example.
In a typical solid-state DC relay, applying a voltage across the control inputs causes current to flow in an LED enclosed in the package. The LED switches on a photodiode, which applies a control voltage to a MOSFET's gate, switching the MOSFET on. The result is a low resistance across the switch terminals, which effectively closes the switch and allows current to flow. Removing the control voltage turns off the LED and opens the switch.
Solid-state relays are rated for use with a variety of load voltages and currents. Because the switch is optoisolated, there need be no electrical connection at all between the control signal and the circuits being switched.
Solid-state relays have an on resistance of anywhere from a few ohms to several hundred ohms. Types rated for higher voltages tend to have higher on resistances. Solid-state relays also have small leakage currents, typically a microampere or so, that flow through the switch even when off. This leakage current isn't a problem in most applications.
There are solid-state relays for switching AC loads as well. These provide a simple and safe way to use a logic signal to switch line voltage to a load. Inside the relay, the switch itself is usually an SCR or TRIAC. Zero-voltage switches minimize noise by switching only when the AC voltage is near zero.
"About this title" may belong to another edition of this title.
Shipping:
FREE
Within U.S.A.
Seller: Gulf Coast Books, Memphis, TN, U.S.A.
paperback. Condition: Fair. Seller Inventory # 0965081915-4-32751179
Quantity: 1 available
Seller: BooksRun, Philadelphia, PA, U.S.A.
Paperback. Condition: Good. New edition. Ship within 24hrs. Satisfaction 100% guaranteed. APO/FPO addresses supported. Seller Inventory # 0965081915-11-1
Quantity: 1 available
Seller: SecondSale, Montgomery, IL, U.S.A.
Condition: Good. Item in good condition. Textbooks may not include supplemental items i.e. CDs, access codes etc. Seller Inventory # 00083847665
Quantity: 1 available
Seller: ThriftBooks-Atlanta, AUSTELL, GA, U.S.A.
Paperback. Condition: Very Good. No Jacket. May have limited writing in cover pages. Pages are unmarked. ~ ThriftBooks: Read More, Spend Less 1.45. Seller Inventory # G0965081915I4N00
Quantity: 1 available
Seller: Bay State Book Company, North Smithfield, RI, U.S.A.
Condition: acceptable. The book is complete and readable, with all pages and cover intact. Dust jacket, shrink wrap, or boxed set case may be missing. Pages may have light notes, highlighting, or minor water exposure, but nothing that affects readability. May be an ex-library copy and could include library markings or stickers. Seller Inventory # BSM.JGSX
Quantity: 1 available
Seller: Better World Books: West, Reno, NV, U.S.A.
Condition: Good. Used book that is in clean, average condition without any missing pages. Seller Inventory # 5192679-6
Quantity: 1 available
Seller: TextbookRush, Grandview Heights, OH, U.S.A.
Condition: Good. Expedited orders RECEIVED in 1-5 business days within the United States. Orders ship SAME or NEXT business day. We proudly ship to APO/FPO addresses. 100% Satisfaction Guaranteed! Seller Inventory # 44549488
Quantity: 1 available
Seller: Grumpys Fine Books, Tijeras, NM, U.S.A.
Paperback. Condition: very good. little wear and tear. Seller Inventory # Grumpy0965081915
Quantity: 1 available
Seller: Grumpys Fine Books, Tijeras, NM, U.S.A.
Paperback. Condition: new. Prompt service guaranteed. Seller Inventory # Clean0965081915
Quantity: 1 available
Seller: BennettBooksLtd, North Las Vegas, NV, U.S.A.
Paperback. Condition: New. In shrink wrap. Looks like an interesting title! Seller Inventory # Q-0965081915
Quantity: 1 available