Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

more than 8 PC controlled relays... including light dimmer?

Status
Not open for further replies.

brent.xi

New Member
G'day all,

ive been trying to work out how i could control more than 8 external appliances using my parallel port...

i figured that an 8 bit signal could be read by a certain circuit and then control up to 256 relays but i have no idea how?!

im (obvously) a rooky in the ways of electronics beyond the simple circuit concepts but im looking forward to breaking this initial barrier and would like to control multiple circuits, have multiple inputs and also...

i would like to control objects such as lights with a dimmer and once again i have no idea how to.

i would like to have input that is not just 0 or 1 but a certain range per channel. e.g. i want to read a temperature from a room

i have enough programming knowledge to work my way around VB and C# confidently so that side wont be an issue.

btw, this setup doesent have to use the parallel port but maybe serial? or usb? whatever works :)

any help would be greatly appreciated!

thanks people :)
 
Last edited:
How long are you looking to spend? Because going from your current level of knowledge (essentially non-existent) to being able to practically build those kinds of circuits is gonna take you months of research and practice, and cost you a decent amount of money on the stuff you need. X10 would definitly be a smarter way to go if what you want is results rather than to actually learn about electronics.
 
hey, thanks for the replies.

i was hoping to steer clear of the more mainstream X10 system and get this project done completely by myself.

i was thinking to do this project in stages. first to just control outputs with on or off status. then go the inputs with 0 or 1 status. then take it further from there.

the reason i haven't just asked questions relating to each individual step is so i can complete the project on a "top-down" style and get it right from the start.

but this may not be the right path...

maybe i should start with; how could i control more than 8 relays from my PC using either parallel or serial port?
 
how could i control more than 8 relays from my PC using either parallel
Use shift-registers and latches, then you can have as many outputs as you want.
 
You're going to spend more money and time learning than you would on a commercial sollution. Just a warning. A LOT of people have the same idea you do, every one of them has been wrong =>
 
kchriste said:
Use shift-registers and latches, then you can have as many outputs as you want.

Thanks kchriste, i will definately look them up. :)


Sceadwian said:
You're going to spend more money and time learning than you would on a commercial sollution. Just a warning. A LOT of people have the same idea you do, every one of them has been wrong =>

:eek: well thanks for the confidence mate!! :eek:

thankyou [kindly] for your opinion but the basis for this project is not to find the easiest solution... if it was i guess i could just pay someone to sort it out.

i do want to learn how to do this. i want to have a complete understanding of it so next time im faced with a problem i can face it with the same eagerness and have the satisfaction once ive accomplished it. not just to go the "easy-out" and buy the commercial product. but once again, thanks for your opinion.
 
Search the web for parallel port circuits, there are many. Multiplex and demultiplex chips can spread 8 bits to 256 and back. Analog to digital (ADC) chips convert sensor voltages to digital. DACs do the opposite.
I have heard that newer computers can be set up to read the data lines as well as right. If you find out how to do that, let me know. Otherwise you have to read 4 bits at a time on the status register.
The easiest way to use LPT1 with Windows is with inpout32.DLL.

You can find inpout32.DLL with code examples at:
**broken link removed**
**broken link removed**
All of these have to be in Project\ Settings\ link\ object/library modules:
kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib
shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib inpout32.lib
 
As your requirement includes dimming, I would suggest you use the serial port (rather than the parallel port), and use slave PIC's at each device. There used to be a website for pic programs called PICNET which did pretty well most of what you want, using either serial or USB, but it seemed to disappear!.
 
Take a look at this site:
**broken link removed**

In the "How To" box on the left side of the page find the sections for "Olsen 595" and "Dimming the Olsen 595". There is also links to a PIC derivative system titled "Renard" hosted on another site.

Cheap, fast and relatively easy to do exactly what you want using parallel port and bit banging it. Since you are skilled in the programming end, should be a piece of cake, but they also have software links for sequencing the light displays to music files.

Quote:
have heard that newer computers can be set up to read the data lines as well as right. If you find out how to do that, let me know. Otherwise you have to read 4 bits at a time on the status register.

Easiest way to do this is in EPP mode. You can read/write all 8 data bits, with simple programming , using only hardware based instruction decoding, and do it quite fast.
 
Last edited:
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top