relay interface, sorta

Status
Not open for further replies.

LaymansPC

New Member
First off let me say hi, I'm new here. This seems to be a really nice resource, I'll likely be spending a great deal of time here. I love electronics but haven't had any formal training. I work on computers and am mostly paid to swap complete boards, I do occasionally get into replacing some capacitors or the likes and really enjoy "something different".

I've been asked to help tie two machines together that aren't really intended to work together. We have one device that can be programmed to beep during different functions. We have another device that performs logging that has 5 input channels for logging different things.

What we are hoping to do is is put together an interface that will count the beeps and create output to the logging device in one of it's 5 input channels. i.e. speaker beeps once, interface sends signal to logging channel 1. speaker beeps twice, interface sends a signal to logging channel 2.

Any help pointing me in the right direction would be great.

Thanks in advance for your time.
 
Last edited:
Hi Layman, welcome to the forum.

looks like a job for microcontrollers. There are ready made PIC main boards which can be programmed, where the beeper wiring output can be detected by the input/output pins.

However, you'll need to learn to program the PIC to do according to your wish, and do some simple interfacing electronics. You can do more research on PICs, and you'll find the most suitable one offered by companies like Digi-Key or Farnell.

A little insight, I hope.
Cheers.
 
Thanks for the fast reply! I'll be sure to stop back with any questions and/or results.

Any other tips or resources anyone can think of would be great as well. I'll go do some reading and see what I can learn about PICs and check back in later.

Thanks again!
 
You have all the fun, layman. The closest I ever got to interesting stuff like this was the occasional brain dead test jig.
What kind of signal are you sending to the logger? A simple digital high/low or a voltage to be measured by the logger's ADC input?
Later.
kenjj
 
I've been known to get into a few interesting projects.

The GPS device doing the logging simply accepts any 8V-32V input. It has up to 5 inputs available.

I was originally planning on using multiple LEDs in the output device to trigger relays that would momentarily switch on a 12V line to the different logging device inputs. We then learned the programmable LEDs were not part of our device and that our only output option was a speaker we can program to do 1, 2, or 3 tones depending on the function. It was then that I started seeking some sort of controller to identify the number of beeps on the output device's speaker and send current to the proper input channel on the logging device. For this, I came here in search of wisdom.
 
personnally if this system is use in industries, i would use a small plc, they are some under 100$ and easily programmed by anyone who knows plc. they are much more versatile than PIC
 
Thanks! This will be used in mobile equipment to send signals into a GPS logging device so the location of certain event may be logged.

Any recommended PLC resources? I'm quite the newb in this sort of thing, but very willing to learn.
 
Last edited:
personnally if this system is use in industries, i would use a small plc, they are some under 100$ and easily programmed by anyone who knows plc. they are much more versatile than PIC

I have to claim ignorance in that I never use a PLC. Why are they more versatile then a PIC? Seems backwards.
 
That's because it is backwards. A PLC by definition can't be more versatile than a bare processor/microcontroller because they are built around around processors/microcontrollers. However, this does make them more capable due to all the extra stuff being built around them, but as soon as you start doing that you start limiting the versatility.

Versatility is a different thing than capability.

Human on foot - has the potential to do many different things, but not very capable (at say...flying at 500km/h)
Human in a plane- very capable at flying 500km/h...but not so much potential to do much else.
 
Last edited:
from wiki on PLCs:
Features
The main difference from other computers is that PLCs are armored for severe conditions (such as dust, moisture, heat, cold) and have the facility for extensive input/output (I/O) arrangements.
Programmable logic controller - Wikipedia, the free encyclopedia

My understanding is that a PLC is a preassembled component that simply needs programmed for it's function and added to the system it will operate within, whereas a PIC is just a chip that must be programmed for it's function and integrated into the component that will then be added to the system it will operate within.

I could be wrong. (likely am)
 
Last edited:
It sounds like you need to use a microphone and amplifier to get a suitable audio signal at TTL levels your processor can handle. You could probably put this signal into a rectification circuit and produce a steady DC signal. If you program your processor to measure the pulse width of this signal (with or without rectification), you need only drive the speaker for preset pulse times that the processor can use against a table of values to determine what's going on and act accordingly.
I dunno. Sound reasonable?
kenjj
 
Last edited:
Thanks dknguyen and LaymansPC.


Either a PIC or a PLC will need programing. The beep can easily be detected electricaly by either.

Given that the purpose is to log beeps/events I do not think a PLC will bring much to the table other then the environmental protection.

There is another option that may work for you.
You could use a 555 as a retriggerable oneshot hooked to the speaker wire. The 555 output would go high when the speaker was on. Use the data logger to log this single stream of info. Then write a simple PC program to take the single data stream and post process the data.
If that does not work you can use either a PIC or PLC (or even a logic circuit) to count the beeps then raise the correct pin connected to the data logger and wait for the next series of beeps.
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…