News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

PC Interfacing kit + book

Started by fifo_thekid, November 05, 2008, 03:20:05 PM

Previous topic - Next topic

fifo_thekid

Hi everybody
I'm a computer engineering undergraduate
I've a very good knowledge in x86 assembler language, C++, VB, and many other languages
I've done very little amateur hardware interfacing, using QBasic, a parallel port cable, and LEDs
Now, I want to start simple industrial interfacing (e.g. connecting a machine to a computer so that u can turn it on an off from the computer..)
My worst side is the hardware side, since I'm so scared about making short circuits and loose connections

What I want, is book + code + hardware kit that I can use for learning on Windows XP platform
Preferably, they should contain relays and a non-hobbyist hardware interfacing card...

Help is appreciated :bg

Mark Jones

Hello, it is a little unclear exactly what you are looking to do. But here are two official "starter kit" products from reputable microncontroller manufacturers:

http://www.microchip.com/stellent/idcplg?IdcService=SS_GET_PAGE&nodeId=81  and
http://www.atmel.com/dyn/products/tools.asp?family_id=607#1443

These do NOT come with step-by-step instruction manuals, however the vendors do supply comprehensive datasheets and application notes. If considering one of these, I would strongly advise to start with the smallest 8-bit chips possible due to their complexity. I take it that the computer engineering degree includes some electronics training? That will definitely be needed, but for the most part the "kits" are self-contained. But if you really want to interface the PC to something intelligent, then this may be a way to go. Some chips have built-in USB capability, and many include application notes describing how to interface them to serial and parallel ports.

Take a look around, is that what you are after?
"To deny our impulses... foolish; to revel in them, chaos." MCJ 2003.08

fifo_thekid

I'm so grateful for your reply  :lol
I asked this question on many forums, but I didn't get any help!
What I'm trying to do, for now only, is to connect a panel for a machine, with all its LEDs and buttons, to the computer
I think that I have sufficient software tools & knowledge for designing the hardware driver
Still, if you have any software kits that make hardware interfacing easier, please give me a clue
The second thing, connecting buttons to the computer means that I need relays, but I really lack knowledge in this field, so, do you know about "Using relays for hardware interfacing For Dummies"!!!  :U

Mark Jones

Connecting a "relay" to a PC is not as simple as it sounds, unfortunately. The full details are outside the scope of a forum discussion. Still, if you learn well on your own, this could teach you enough to accompish the task:

http://www.ibiblio.org/kuphaldt/electricCircuits/
"To deny our impulses... foolish; to revel in them, chaos." MCJ 2003.08

Rainstorm

fifo_thekid, interesting stuff!
I'm interested in this stuff to some extent but know nothing about it or electronics.
If someone who knows about this could briefly comment on the basic logic & the way to go about it, would be greatly appreciated. - Like how to go about hooking up other devices with the computer, having them interface with the comp & then building a software interface from which to direct their working.

thanks

Mark Jones

"To deny our impulses... foolish; to revel in them, chaos." MCJ 2003.08

vanjast

As you want to interface to relays, I take it that your control system will be fairly slow.

Probably the best bet would be to get a USB to RS232 or RS485 (industry standard) converter - These usually come with a driver and a small SDK. This can connect your PC to the relay card. Google is your friend - shop around a bit  :bg

Your relay (interface card) should be isolated from the USB line and have it's own power supply, as USB can only supply a max of 500mA per channel.
Relays are noisy buggers and must be kept away from the USB lines. The USB/comms link - Relay card controller isolation can be implemented via RS232/485 opto-isolators.

If you want to do your own drivers and hardware, microchip, atmel, and a few others have USB on a chip with all the firmware already established.
For the PC, have a look at www.USB.org for the specs and Windoze must have an SDK somewhere.
Don't forget to keep your relays and interface drivers on their own PSU and isolated from the PC..  AND put small fuses on the USB power line cos if there's a blow-out you do not want to take your pc out as well :8)

fifo_thekid

Quote from: vanjast on November 09, 2008, 06:03:16 PM
As you want to interface to relays, I take it that your control system will be fairly slow.

Probably the best bet would be to get a USB to RS232 or RS485 (industry standard) converter - These usually come with a driver and a small SDK. This can connect your PC to the relay card. Google is your friend - shop around a bit  :bg

Your relay (interface card) should be isolated from the USB line and have it's own power supply, as USB can only supply a max of 500mA per channel.
Relays are noisy buggers and must be kept away from the USB lines. The USB/comms link - Relay card controller isolation can be implemented via RS232/485 opto-isolators.

If you want to do your own drivers and hardware, microchip, atmel, and a few others have USB on a chip with all the firmware already established.
For the PC, have a look at www.USB.org for the specs and Windoze must have an SDK somewhere.
Don't forget to keep your relays and interface drivers on their own PSU and isolated from the PC..  AND put small fuses on the USB power line cos if there's a blow-out you do not want to take your pc out as well :8)
This reply was amazing  :dazzled:
Now, let's start step by step..
Now I'm supposed to have a:
1- USB  to RS232 or RS485 converter (Why don't I use USB directly?)
2- A relay card (Are there ready made relay cards?)
3- A microchip (Which kit is recommended for starters?)

Now, is there an online tutorial,video and or book for a project similar to mine?

(Special thanks to Mark Jones for his links...)

rags

God made Man, but the monkey applied the glue -DEVO

fifo_thekid

Thanks rags
That was really helpful
I really liked that parallel port relay board

One last question, since I live in United Arab Emirates (UAE), the delivery of those materials will be really late, so, do you know which is the best supplier for those stuff from a nearby country like Turkey or China?

rags

That, unfortunately I cannot help you with..sorry :(
God made Man, but the monkey applied the glue -DEVO

vanjast

Quote from: fifo_thekid on November 15, 2008, 10:42:38 AM
One last question, since I live in United Arab Emirates (UAE), the delivery of those materials will be really late, so, do you know which is the best supplier for those stuff from a nearby country like Turkey or China?

If you're buying over the internet or via an agent, one can usually check on the company's website for any local agents (or the nearest agent) that can get the product to you. If that fails, ask the supplier to courier it direct to you - cost more, but at least you'll receive it. You'll have to find which local couriers are operating in your area.

Quote
1- USB  to RS232 or RS485 converter (Why don't I use USB directly?)
2- A relay card (Are there ready made relay cards?)
3- A microchip (Which kit is recommended for starters?)

1. - Not a problem - just that USB cable length spec is about 3 metres maximum, which can be a problem, depending on how you impliment the project. You'd also want to isolate the PC from the rest of the system - protection of sorts.
3.- I find www.microchip.com very user friendly, Free IDE's.. the works.

Good luck with your project.
:bg

GregL

I always thought the Parallax stuff looked interesting, never actually used any of it.