Sunday, July 12, 2009

How to to hardware interfacing using language C or C++?

hi , suppose i want to run the home appliances by using my computer , i will require a program in C, then i will require an electronic ckt. that will have a relay , that will finally turn on and off the appliance , but i need the program to send the signal to the serial port where i will be finally connecting my hardware, i am a begineer , and this is my plan what i want to do , so anybody who can help me out with any little information , will be welcomed .

How to to hardware interfacing using language C or C++?
I nice little tutorial with a simple application.


http://www.faqs.org/docs/Linux-mini/IO-P...
Reply:Using the parallel port would be much easier, since you just send a value to the port and the bits stay the same until you send another value.





The serial port however works differently.





The parallel port has 8 output bits, so you could be able to control 8 different appliances.





I have done this in the past, I used only 4 of the 8 bits, and used optocouplers to isolate the parallel port's output from the relays. The parallel port's output isn't enough to turn on a relay, and the isolation prevents you damaging the port.





Good luck, google^H^H^H^H^H^H yahoo is your friend!


No comments:

Post a Comment