Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations KootK on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Convert Small signal pulse to RS-232 signal levels?

Status
Not open for further replies.

thomaskuhn

Computer
Sep 20, 2010
12
I have a USB monitoring device, that once a certain data pattern is found, triggers out a small 4-5V pulse. The pulse is very small, about 400ns. It seems to be too small to be detected on a RS-232 Clear-To-Send (CTS)input pin. I am using a USB RS-232 dongle (Keyspan USA-19HS) as an input to our computer. This USB dongle is used for other measurements too, and I thought it would be convenient to use the CTS pins as sort of a generic "GPIO" for this particular device.

What circuit would I need to put between the pulse generating device and the RS-232 to ensure I get a CTS signal detected?

here is what the pulse looks like on a scope:
Imgur
gDx0kni.png


Web (In case Imgur is blocked)
pulse.bmp
 
Replies continue below

Recommended for you

I would try a one shot circuit, triggered by your small pulse it will give you a solid, definable pulse that you can use for your CTS. Another alternative would be to use a very small microprocessor like a PIC or one of the really tiny TI processors.
 
Thanks for the great ideas. I ran by radio shack to see if they had any max232 type IC's. no luck BUT i saw the arduino micro, and could not resist. I have been looking for an excuse to get one, and... One thing led to another... And i had to explain to the wife where $35 went and what this little chip thing is...

Good news is that the digital pins on it are good enough to trigger the cts line. It should be able to sense the pulse but i have not gotten that far yet.

What was really amusing was my giddiness in showing the wife the whole setup through to the laptop with a test app flickering hi...low...high..low in a rediculous font. She thinks i am nuts...

 
Good news is that the digital pins on it are good enough to trigger the cts line. It should be able to sense the pulse but i have not gotten that far yet.
Be sure you check the worst case specs, lowest output from micro with highest requirement of the CTS. From experience, I would recommend placing a cheap transistor in the line as a switch. This way the micro can toggle the switch with little to no current draw and you can get a full swing with current drive on the CTS. Also, things that are connected to the outside world tend to be what get blown up in circuits and this could protect your micro from the inevitable hand slip or mis-connection of the RS-232 cable.
 
The good news is that the OP's signal is relatively robust, but it's generally not a good practice to allow such short signals to be propagated through potentially noise inducing or prone cables without pre-processing them to be more noise immune. The typical approaches would be amplification; we've got one system that uses RTL-style outputs running up to 28VDC, on a military system, natch, or by increasing the length of the signal with a one-shot as suggested earlier.

If the signal were increased to 4 microseconds or even 4 ms, would there be a downside? The upside is clearly that there would be little chance of a noise glitch resulting in either an erroneous trigger, or a missed trigger.

TTFN
faq731-376
7ofakss

Need help writing a question or understanding a reply? forum1529
 
but it's generally not a good practice to allow such short signals to be propagated through potentially noise inducing or prone cables without pre-processing them to be more noise immune
This reminds me of something that I encountered in my last major circuit design. The rise and fall time of these signals can be of critical importance. If one is using programmable logic, e.g. an ASIC or FPGA, the rise times of those circuits can be ridiculously fast (1-2ns). At these rates, circuit geometry becomes important. This is one of the reasons that PICs are considered robust, they tend to be slow which prevents a lot of noise issues.
 
Well,

I have done some playing and i have struck out a bit I think. I was having all sorts of issues just trying to recapture the pulse again on an o-scope. There seems to be some reliability issue in generating it. The analog input to the Arduino board has a read resolution of 100 microseconds, so I think it is too slow to even catch this pulse. I agree that this signal can hide in the noise very easily, and I was having that issue too. I think the One shot might be the best approach.

Unfortunately I can not modify the source of the pulse (Mercury T2 USB analyzer). I am not sure why they chose the trigger method they did, but oh well.
 
That a very good point. I guess i was thinking that the level would be too low to be seen on the digital side. Not sure why i thought that. I guess some of the captures were less siquare waves and more "messy waves". The digital ports might work out fine. I will have try it out

 
I just took a closer look at your scope trace, based upon your comment about tying to capture it with a scope. Notice the ring pulses at both edge transitions. This could indicate interference between the pulse and your scope probe, possibly cause by the inductance of the probe (i.e. a snap cap and flying ground). The take away being that your scope may be lying to you. See:
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor