ENCYCLOPEDIA OF RADIO ELECTRONICS AND ELECTRICAL ENGINEERING LPTtest program. Encyclopedia of radio electronics and electrical engineering Encyclopedia of radio electronics and electrical engineering / Microcontrollers The proposed program allows the user to set the desired logical signal level at any output of the computer's printer port and find out the status of any input of this port. It will facilitate the establishment of devices connected to the port. Radio amateurs design devices that work together with a computer and are connected to it via COM, LPT, less often PCI, ISA, USB, etc. There are many examples [1-5]. These are programmers, emulators, analog-to-digital and digital-to-analog converters and more. Although, due to the wide capabilities of the computer, such devices are much simpler than those that work autonomously, they still need to be checked and adjusted after manufacture. Testing a device connected to a computer using its working program is far from the best option. Usually, it does not provide functions for displaying the values of signals on the input lines of the interface and their manual change at the output. In rare cases, a special test program is attached to the device (for example, [4]), which serves to check the passage of signals through its circuits. But for testing other hardware, such a program, as a rule, is not suitable. As a result, the assembled device has to be checked without a computer at all, by applying signals to the interface connector that simulate the operation of a PC, which also cannot be called convenient. To establish devices connected to the computer's COM port, you can use the program TSOM, which makes it possible to control each output signal of the port separately and monitor the levels of all inputs. The description of this program in [6] led the author to the idea of creating a similar one for the parallel port. This is how the LPTtest program appeared, capable of monitoring all signals of the LPT port. The program has been tested under Windows 98 and Windows XP, there are no contraindications to work in other versions of Windows. The program accesses the port registers through the software driver LPTwdmlO [7]. When working under Windows 9x/Me, you will need to install this driver manually: run the Add Hardware Wizard from the Control Panel, select Other Devices in the list that appears and specify the folder where the Iptwdmio.sys and Iptwdmio.inf files are located. After installation is complete, you must restart your computer. And now - a quote from [7]: "When working on Windows 2000/XP, manual installation is also possible in a similar way. But unlike Windows 98/Me, you definitely won't need to reboot during installation, the driver starts immediately. In addition, manual installation There is one advantage: if the client program was run as a non-administrator user, it will still be able to work with ports through the driver." And one more quote: "Automatic installation is performed when creating an object for working with the driver in the user program if the program runs on an NT family platform, i.e. Windows NT4/2000/XP and the driver were not previously installed manually. When this does not require any additional actions on the part of the user, but if the program starts on behalf of a user who does not have administrative rights, automatic installation will not occur and the program will not be able to manage ports." Before running the LPTtest program, be sure to copy the Iptwdmio.sys file to the same folder as the LPTtest.exe file. It should also contain the files LPTpins.jpg (the location of the sockets of the DB-25F socket) and LPThelp.mhtml (help on the LPT interface). The LPTtest program window is shown in fig. 1. It displays the status of five input, four output lines of the port and eight lines of its data bus. The inscriptions Low (low) or High (high) to the right of each button that changes the state of the output line, and to the right of each name of the input line, shows the current logical signal level on the corresponding connector pin. On startup, LPTtest sets all outputs low. The current value of the code in the port data register (DR) displayed in the status line in decimal and hexadecimal number systems is updated by the program at a frequency of 100 Hz. If you bring the mouse pointer to any button or to the name of the input line, a hint pops up with the number of this pin in the standard DB-25F connector for the LPT port. To see a connector image similar to that shown in Fig. 2, it is enough to select the item Pinout of the connector in the Help menu. The LPT Interface... item of the same menu will display the contents of the help file. The Select Port menu offers two options in this version of the program: LPT1 (base address 378h) and LPT2 (base address 278h). The selected port number will be written to the Config.txt file and read from it the next time the program is started. If such a file does not exist, the program will create it in its folder, choosing the LPT1 port by default. The Outputs and Inputs radio buttons change the state of the fifth bit of the Port Control Register (CR), thereby transferring the data bus to output mode (set by default) or input. The bus is able to work on input in most modern computers, parallel interface adapters of outdated models do not provide such an opportunity. When the data bus is configured for input, its lines are connected through the resistors provided in the port controller to a +5 V voltage source. Therefore, the logic level on lines that are not connected to external circuits is perceived as high. When switching the data bus from input to output, the program automatically sets the value to zero in the DR register, as a result of which all lines of the bus will be driven low. The program performs the same operation when changing the port, at startup and at shutdown. LPTtest program and all files necessary for its operation Writer
Author: A. Vakulenko, Tyumen See other articles Section Microcontrollers. Read and write useful comments on this article. Latest news of science and technology, new electronics: Machine for thinning flowers in gardens
02.05.2024 Advanced Infrared Microscope
02.05.2024 Air trap for insects
01.05.2024
Other interesting news: ▪ Alloy with giant barymagnetic effect ▪ The Leader Brain Feature Helps Persuade ▪ The driver is hindered not by a mobile phone in his hands, but by talking on it ▪ Electronic noses for livestock farms ▪ Cause of ringing in the ears News feed of science and technology, new electronics
Interesting materials of the Free Technical Library: ▪ website section LEDs. Article selection ▪ article by James Watson. Biography of a scientist ▪ article What is the Romance group of languages? Detailed answer ▪ Svid's article is silvery. Legends, cultivation, methods of application ▪ article History of metal detectors. Encyclopedia of radio electronics and electrical engineering ▪ article Riddles with weighings and transfusions
Leave your comment on this article: Comments on the article: Tractor driver Why is there no information on the radio magazine server that the authors refer to that is discussed in the article "Program LPTtect ..."? All languages of this page Home page | Library | Articles | Website map | Site Reviews www.diagram.com.ua |