-Main Page
   -Tech Bits
   -Case Gallery
   -About Us
   -Droid Hype

   -IWill USA
   -Samsung USA
   -EverGreen Tech
   -Buffalo Tech
   -Zalman Tech
   -Cyber Cooler
   -Vantec USA
   -Lian Li
   -EDGE Memory
   -Eagle Tech

   Online Shops:
   -HighSpeed PC
   -Xoxide Mods
   -Computer Geeks

.: Random Case Gallery User uploads :.
Mahogany USB Drive
Sharing cellphone broadband
Making acrylic fan grills

LapLogic Aerogel Extreme
EDGE DiskGO 160GB Network HDD
GelaSkins for DS and PSP

-- 7-Segment Temp Display+
-- Category: Guide
-- Posted by: Skylined
-- Posted on: 2003-06-09
-- Price: ~ $NA USD
-- Pages: 1 2 3 4 [ 5 ]
Digg this article
Submit to reddit
Add to del.icio.us
Submit to Slashdot
Stumble this article!

Parallel port interfacing

   First off, if you’re not interested on how the software works, you can skip this part.

   Typical PC parallel ports have 25 pins. 8 lines in the data port (pins 2 to 9), 5 lines in the status port (pins 10 to 13 & 15), 4 lines in the control port (pins 1, 14, 16 & 17), and 8 ground lines (pins 18 to 25). To access each line, you need to send the value to the correct base address. The data port’s address 888 decimal or 378 Hex. The status port would be in 889 decimal (base+1), and the control port would be in 890 decimal (base+2). Since we’re only doing output, we’ll only need the output lines. And since the circuit would only need to accept 4-digit binary inputs for each 7-segment, and we have a total of 12 output lines (the 8 data lines plus the 4 control lines, which can also be used as output), we can control 3 full 7-segment displays at the most.

   But in this case, we will be using two output lines to supply power for two 4511 CMOS ICs so that we won’t need to externally power the circuit, like from let’s say, a molex. That would leave us with 2 fully functional 7-segment displays, which is already enough to display temps in Celsius. Now the extra two (or one of the extra outputs) outputs will be used to light up two bands of the third 7-segment display since we only need two to display a “1”. This would help display temps in Fahrenheit or show CPU usage since Fahrenheit temps and CPU usage can reach 100 and/or over.

   To enumerate, we used pins 2 to 5 of the parallel port to control the tens digit, pins 6 to 9 to control the ones digit, pin 1 (and 14) to control the “1” value in the hundreds digit, pin 1 to power the two 4511 ICs.

   Basic parallel port interfacing would show that sending a 1 logic to the data pins will send 5v to that pin (we tested it and it’s just 3v. I never bothered to measure it until now?). Same goes with the control pins but taking note of the inverted ones, which are pins 1, 14 and 17. So in your software, just keep those pins with a logic of 0 to keep them on.

Click above picture to enlarge

   The “Value” row shows the specific value you need to send to the parallel port to set a 1 logic on the corresponding pins. Meaning if you send a value of 1 to port address 888, it will send 5v (or 3v) to pin 2. Send a value of 8 will send 5v to pin 5; a value of 128 will send 5v to pin 9 and so on. To send 5v to two or more pins at one time, just add the values. To send 5v to pins 1 and 2, send a value of 3. To send 5v to pins 2, 5 and 8, send a value of 73, and so on. To set all 8 pins to 0v, just send a value of 0. Now the some of the control lines are inverted. So sending a value of 0 to port address 890 (control line port address) will send 5v to pins 1, 14 and 17. Adding values will also apply to the control lines, but again, take note of the inverted lines (you can use XOR in your software logic if you want).

   To display the correct number value in the 7-segment, we follow the 4511 IC's truth table. For example: to display a “1” digit on the tens 7-segment, the 4511 needs a value of 0001. That’s in DCBA order. So we’ll set the order in binary: 8 4 2 1 (pins 5 4 3 2). That means we would need to send a value of “1” to the data line. To display a “5” digit, the 4511 needs a value of 0101. So we need to set a 1 logic to pins 2 and 4 by sending the data line a value of 5 (4 + 1), and so on and so forth.

   For the ones 7-segment, the same idea applies, but then we would base our values for pins 6-8. To display a “1” (0001), we need to send the data line a value of 16 (turning pin 6 on). To display a “5” we send a value of 80 (16+64), and so on and so forth.
Of course these two values would most probably display values at the same time. Just add up the total values you need to display for both 7-segment displays, since port 888 control all 8 pins. Like to display “24”, you need to send a value of 66 (2 + 64).

   As for the control lines, we just need to have pins 16 and 17 on all the time or else the tens and ones 7-segment would not light up. The use of the hundreds 7-segment would depend on what values are you going to display. If you need to display values of 100 and over, you just need to send 5v to pin1 (and pin14) to light up the b and c band of the 7-segment to display a “1”. So your control line would only have a value of either 4 or 5 (or 7). That would be 0010 or 1010 (or 1110) in pin order 1 14 16 17. Basically, it should be 1111 or 0011 for on and off respectively. But since 1, 14 and 17 are inverted, it becomes 0010 or 1110.

   Values displayed

For the values to be displayed, you can use any info that usually ranges from 0 to a max of 199. Values that come into mind are, first of all, system temperatures. 0-100 for Celsius (getting a temp reading of 100C would cause havoc ? so you don’t actually need three digits for C) and 0-199 for Fahrenheit (you don’t get 200+ degrees F values on your temps right? Right?!). CPU usage and RAM usage would only need 0-100 since it’s only in percentage.

As for how to obtain such values, this will depend on you. In our version, we used Motherboard Monitor to acquire system temps and cpu usage, with the help of MBM’s shared memory. MBM has released the shared memory module for different programming language so you can write your software with the language of your choice. One thing though, the software needs to have MBM running in the background since we can’t get the sys temps and/or cpu usage information without MBM. You can write your own module to acquire these values from your system’s BIOS if you can. But for the meantime, we’ll just use MBM since almost all of us use it.
Another thing to take note. The shared memory module only works with MBM versions below 5.2. Livewiredev updates MBM but not the shared memory modules. So, for you to be able to use the software we have or your own, you have to use MBM 5.1 or lower.

   Software usage

   Our software is pretty much straightforward. But then, MBM has to be running in the background or the SXDisplay won’t run. Just choose the mode you want to display. Then set your refresh interval using either the textbox or the slider. The refresh values are in seconds, so the fastest refresh interval you can use is 1 second. But this refresh value is for the SXDisplay program only. The refresh interval is still dependent on MBM’s refresh interval. So if you set MBM to refresh every 10 seconds, setting the SXDisplay software’s interval to 1 second won’t be of help. Select between Celsius and Fahrenheit using the toggle buttons on the bottom. Minimize to hide and just double click on the tray icon to show.

   If you want to use our software, we have versions for both WIN9X and WINNT based systems. Just read the readme.txt for installation instructions.

   SXDisplay NT version - Downloaded 381 times!

   SXDisplay WIN9X version - Downloaded 308 times!

   Here's a sample video showing X24's circuit and a little digit cycle test: circuitfinal.avi

   This video file has been downloaded 1516 times!

< Previous Discuss this in our Forums! >

Page: 1 2 3 4 [ 5 ]

Bandwidth sponsored by SCHostPro.com

Latest Updates

LapLogic G800/W800 Areogel Extreme
LapLogic G800/W800 Aerogel Extreme

Mahogany USB Drive
Mahogany USB Drive

EDGE Tech DiskGO NAS 160GB
Network HDD

GelaSkins for DS and PSP
DS and PSP

All trademarks used are properties of their respective owners. All rights reserved.
Copyright © 1999 - 2017 by GideonTech.com

Page was generated in 0.036087 seconds

Partner Links: Shorty.org

Our Friends - GideonTech | Metku | AllTheMods | OCModShop | Bona Fide Reviews | Rbmods | ThinkComputers | PCApex | TweakTown