🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

How to communicate with a hardware? NOOB here.

Started by
54 comments, last by macmoy 15 years, 6 months ago
serial controller? you mean, ICs?
what are parallel? will it also use rs232? or different socket?

huhuhuhu. Why cant you just connect the wire from the rs232 to the switch? i have nothing else to do. just turn on the switch and send a "1" and turn it off and send a "2".
that's all.then after i made it for atleast 3 switches, il make it 8 switches..

huhuhu, how will i make it?
Advertisement
How would you send "1" and "2" if you didn't have a logic circuit to do that?

Niko Suni

ahh!! i have read something. correct me if im wrong..

you mean, when an input pin of the PC(rs232) is linked with its output, "1" is sent to the PC??
The serial port works at certain frequency (clock rate). For each clock cycle, the receiving hardware reads one bit by comparing the voltage of the incoming data pin with a reference value (whether it is above or below reference determines whether it is 1 or 0). When it has received certain amount of bits (usually 8) and/or a stop bit, it gives those bits to the host device (which can then read them from the port) and repeats the process again.

The above is an extremely simple description of how incoming serial data works (there are a lot of additional quirks) but it should help you see why things do not work if you just solder one leg of your switch to the RxD pin of the RS232 connector.

Niko Suni

so if i solder one output to the switch and 1 input. then if i turn the switch on, there would be an electric current? which in other words, the device is sending "1" to the PC?? is that right?

is the image above correct?
will it send "1" to the PC if the switch is turned on?
The port does not work in that way.

You will have to heed my earlier advice and read (+understand) some theory of digital electronics before you will be able to proceed with the project.

This is not the most difficult application of the field, but it is impossible to build it without actually knowing what you're doing. If you have promised to build the device soon, you have promised way too much in way too short time.

I remember playing with extremely simple stuff like LED flashers for approximately two years (some 20 years ago) before things "clicked" and I had a revelation of how digital electronics actually work. After that, I've found that nothing is impossible to build; however, the more complex a system is, the more time it takes, and time is by far not a limitless resource for most of us.

Niko Suni

i have read the links. but its always telling me about the pins. i already somehow know the pins.
i thought when the output(DTR) is connected to any input(e.g. Carrier Detect), there will be a current flowing right?

i have read an article.
http://www.swen.uwaterloo.ca/~drayside/altinput/

by the way, can i ask the port if any input(e.g. CarrierDetect) is active?

so that by switching on, there will be connection between DTR and CD. then i ask the port if Cd is active/meaning,theres an electricity flowing, then i play the music, is that posible?


by the way:
i saw in the device manager
*Comm port
*printer port

which is 25 pins and 9 pins?

can i attach my device on the 9 pin? BUT i think its the videocard built-in. my monitor is connected on a videocard(not built in).
still can i connect my device?

how about the 25 pins? is it for printer only?

please help, coz il buy tomorrow the socket. i dont know which(25/9pins)
Buy a book about digital electronic first. I'm serious, and I don't mean to be rude.

If you just solder the port pins randomly, you can (and will, eventually) fry your motherboard. That will cost more than the book.

Niko Suni

im sorry but, im from philippines. its very seldom to find a decent book about this. and the fact that its too expensive.

This topic is closed to new replies.

Advertisement