Simulation Device... Keyed Peak Detector

May 28, 2008 19 Replies

I want to build an ideal device for use in PSpice simulations, a Keyed Peak Detector...



Finds the maximum peak value of an input voltage while it's enabled ("keyed"), and "dumps"/outputs zero when not enabled.



Any ideas?



(Ideal elements)



...Jim Thompson



-- | James E.Thompson, P.E. | mens | | Analog Innovations, Inc. | et | | Analog/Mixed-Signal ASIC's and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at

formatting link
| 1962 | America: Land of the Free, Because of the Brave


Ask someone at IPCC. They'll find every peak even if it ain't there :-)

SCNR.

Aside from math, can't you use a buffer with (near) zero Zout, an ideal diode, a wee cap? Then when it's keyed off use a FET with 1 femto-ohm Rdson to short out the cap.

Regards, Joerg http://www.analogconsultants.com/ "gmail" domain blocked because of excessive spam. Use another domain or send PM.

Except that ideal diodes tend not to converge. I'm looking for some mathematical method that is "smooth" ;-)

...Jim Thompson

| James E.Thompson, P.E. | mens | | Analog Innovations, Inc. | et | | Analog/Mixed-Signal ASIC\'s and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at http://www.analog-innovations.com | 1962 | America: Land of the Free, Because of the Brave

Maybe you can start with this scenario:

formatting link

Regards, Joerg http://www.analogconsultants.com/ "gmail" domain blocked because of excessive spam. Use another domain or send PM.

That sounds like the old 'Keyed AGC' on TVs. A pulse from the flyback set a reference once each line, then the detected signal level was used to set the RF & IF gain.

http://improve-usenet.org/index.html If you have broadband, your ISP may have a NNTP news server included in your account: http://www.usenettools.net/ISP.htm Sporadic E is the Earth\'s aluminum foil beanie for the \'global warming\' sheep.

It's the other way around, like the fast-attack/slow-release AGC in single sideband receivers. Except that Jim wants to reset it when keyed off.

I rarely have to use that in SPICE but stuff like this I mostly fudge out of real parts with the important values at the extremes, where the computer doesn't beep and the results are still reasonably accurate.

Regards, Joerg http://www.analogconsultants.com/ "gmail" domain blocked because of excessive spam. Use another domain or send PM.

The concept was the same though. You had a fixed reference level to compare the signal to, and used the recovered peak as needed.

http://improve-usenet.org/index.html If you have broadband, your ISP may have a NNTP news server included in your account: http://www.usenettools.net/ISP.htm Sporadic E is the Earth\'s aluminum foil beanie for the \'global warming\' sheep.

Jim Thompson a écrit :

A limited high gain VCVS used as "comparator", a smooth tanh switch and a zero soakage cap?

Don't know if the two first exist in PSPICE.

Thanks, Fred.

In SPICE one can simulate a deliciuous meal that has almost zero calories, no fat and will not add one gram of weight to your body. Then when you actually cook and eat it the cholesterol shoots way up.

Regards, Joerg http://www.analogconsultants.com/ "gmail" domain blocked because of excessive spam. Use another domain or send PM.

Great minds think alike ;-)

I'm working along the lines of a VCCS with the current that is offset TANH, for good convergence.

...Jim Thompson

| James E.Thompson, P.E. | mens | | Analog Innovations, Inc. | et | | Analog/Mixed-Signal ASIC\'s and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at http://www.analog-innovations.com | 1962 | America: Land of the Free, Because of the Brave

Newsgroups: alt.binaries.schematics.electronic Subject: TANH Rectifier (From SED) - TANH-Rectifier.pdf Message-ID:

...Jim Thompson

| James E.Thompson, P.E. | mens | | Analog Innovations, Inc. | et | | Analog/Mixed-Signal ASIC\'s and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at http://www.analog-innovations.com | 1962 | America: Land of the Free, Because of the Brave

Why not fudge a regular diode to be almost ideal, and put a gain of a million in front?

LT Spice doesn't seem to have an ideal diode.

Hey, why not make an ideal diode from a voltage-controlled switch?

John

Well, that is the usual way that one makes an "ideal" diode in the real world... put a real diode in the feedback path of an opamp and let the negative feedback take care of the details.

-Chuck

"John Larkin" schrieb im Newsbeitrag news: snipped-for-privacy@4ax.com...

Hello John,

try this one in LTspice.

.model DID D(Vfwd=0 Ron=1m Roff=1G)

Best regards, Helmut

!@#$%&*

Right under my nose... built-in macros ENVMAX and ENVMIN :-(

...Jim Thompson

| James E.Thompson, P.E. | mens | | Analog Innovations, Inc. | et | | Analog/Mixed-Signal ASIC\'s and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at http://www.analog-innovations.com | 1962 | America: Land of the Free, Because of the Brave

That may or may not be PSpice specific. I thought about it some. Start with a "standard" track and hold, add a fast comparator to convert to a peak and hold (two if you want both peaks). Add some enable circuitry to handle any ADC converter setup and hold times and data transfer as needed.. Did something like this about 20 years ago for what was then Hughes EDSG. Location of the analog / digital boundary is engineer choice.

I created an ideal diode with a TANH smoothness _ before_ I stumbled onto the macro... produces the same results, but slower in simulation.

...Jim Thompson

| James E.Thompson, P.E. | mens | | Analog Innovations, Inc. | et | | Analog/Mixed-Signal ASIC\'s and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at http://www.analog-innovations.com | 1962 | America: Land of the Free, Because of the Brave

Maybe you could post example circuits on your website. Preferably LTSpice circuits as well.

I believe Mikey said that LTspice can read in PSpice schematics??

I'll post it later.

...Jim Thompson

| James E.Thompson, P.E. | mens | | Analog Innovations, Inc. | et | | Analog/Mixed-Signal ASIC\'s and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at http://www.analog-innovations.com | 1962 | America: Land of the Free, Because of the Brave

Posted at...

Newsgroups: alt.binaries.schematics.electronic Subject: For sci.electronics.cad Question - PeakDetAndDump.pdf Message-ID:

Took awhile. We had one of those "events" last night. Wife got an enormous nosebleed. Finally convinced her we needed to take her to an Urgent Care provider. Cauterization didn't work, so they inserted a balloon-like inflatable device (they called it a "rocket" :-) up her nose, and we went back 3.5 hours later and they removed it... bleeding stopped.

...Jim Thompson

| James E.Thompson, P.E. | mens | | Analog Innovations, Inc. | et | | Analog/Mixed-Signal ASIC\'s and Discrete Systems | manus | | Phoenix, Arizona 85048 Skype: Contacts Only | | | Voice:(480)460-2350 Fax: Available upon request | Brass Rat | | E-mail Icon at http://www.analog-innovations.com | 1962 | America: Land of the Free, Because of the Brave

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required