DSPRelated.com
Forums

Sharp DSP notch filter

Started by Eeyore May 20, 2009
Eeyore <rabbitsfriendsandrelations@hotmail.com> wrote:

> > >Jan Panteltje wrote: > >> < snip> >> I clearly remember the first C class we had, and after that meeting was over, I went >> over to the instructor and asked him: >> "Where is the input and output in C?". >> He answered: "There is no such thing in C'." >> So I replied: "But then I cannot do anything with it, in embedded I need to do I/O". >> He then said: "But you can use in line asm to make your own out and in routines".... >> Now that was a relief :-) > >Hence inc stdio.h presumably ?
He was probably working on an Intelish platform with seperate memory and I/O spaces. -- Failure does not prove something is impossible, failure simply indicates you are not using the right tools... "If it doesn't fit, use a bigger hammer!" --------------------------------------------------------------
Eeyore <rabbitsfriendsandrelations@hotmail.com> wrote:

> > >Nils wrote: > >> After reading the discussion I wonder: >> >> Couldn't you simply connect a transformer to the mains, add a resistor >> divider at the output to get the signal down and record the glitches? > >My front end will do all of that to get the levels right etc. The thing is, >you don't seem to be able to see the glitches for the mains, we've already >been looking. They must be quite small, or it's getting in via another
Get a proper digital scope. Many scopes lower their samplerates so you don't see short glitches. Lecroy is bad when it comes to this kind of behaviour. What you need it peak detect. -- Failure does not prove something is impossible, failure simply indicates you are not using the right tools... "If it doesn't fit, use a bigger hammer!" --------------------------------------------------------------

Eeyore wrote:

> Nils wrote: > > > After reading the discussion I wonder: > > > > Couldn't you simply connect a transformer to the mains, add a resistor > > divider at the output to get the signal down and record the glitches? > > My front end will do all of that to get the levels right etc. The thing is, > you don't seem to be able to see the glitches for the mains
I should add to that, just looking on a scope trace or even using a HEME power quality analyser which seems to be targeted at other problems like longer term dips and surges. Graham

Nico Coesel wrote:

> Eeyore wrote: > >Nils wrote: > > > >> After reading the discussion I wonder: > >> > >> Couldn't you simply connect a transformer to the mains, add a resistor > >> divider at the output to get the signal down and record the glitches? > > > >My front end will do all of that to get the levels right etc. The thing is, > >you don't seem to be able to see the glitches for the mains, we've already > >been looking. They must be quite small, or it's getting in via another > > Get a proper digital scope. Many scopes lower their samplerates so you > don't see short glitches. Lecroy is bad when it comes to this kind of > behaviour. What you need it peak detect.
I agree but it's beyond our budget for this alone. By making dedicated kit of our own, designed specifically for this kind of job alone we can avoid that problem. Graham

"miso@sushi.com" wrote:

> Eeyore <rabbitsfriendsandrelati...@hotmail.com> wrote: > > Nils wrote: > > > After reading the discussion I wonder: > > > > > Couldn't you simply connect a transformer to the mains, add a resistor > > > divider at the output to get the signal down and record the glitches? > > > > My front end will do all of that to get the levels right etc. The thing is, > > you don't seem to be able to see the glitches for the mains, we've already > > been looking. They must be quite small, or it's getting in via another > > route. If we knew the route it would be easy but this is the task, to find > > what the susceptibility is in a 35 year old product. > > > > If we had unrestricted access we could try one idea at a time but it won't > > be like that so we need to be prepared for various eventualities. > > > > > That way we could take a look at the data and see what happends on the > > > mains. > > > > > You're at a recording studio after all. Recording something shouldn't be > > > much of a problem. :-) > > > > They might object to losing their hard disk rack. We can record it on a > > laptop of course but real time would keep the client happier. > > Have you researched Dranetz gear? > http://www.dranetz-bmi.com/
I know their kind of stuff and Schaffner EMC too but this work won't pay for that. Graham

Nico Coesel wrote:

> Eeyore <rabbitsfriendsandrelations@hotmail.com> wrote: > >Jan Panteltje wrote: > > > >> < snip> > >> I clearly remember the first C class we had, and after that meeting was over, I went > >> over to the instructor and asked him: > >> "Where is the input and output in C?". > >> He answered: "There is no such thing in C'." > >> So I replied: "But then I cannot do anything with it, in embedded I need to do I/O". > >> He then said: "But you can use in line asm to make your own out and in routines".... > >> Now that was a relief :-) > > > >Hence inc stdio.h presumably ? > > He was probably working on an Intelish platform with seperate memory > and I/O spaces.
That's what I like about PL/M. It automatically points to the right space according to the command and register etc definition file. Graham

Nico Coesel wrote:

> Eeyore <rabbitsfriendsandrelations@hotmail.com> wrote: > >"miso@sushi.com" wrote: > >> Eeyore <rabbitsfriendsandrelati...@hotmail.com> wrote: > >> > Nils wrote: > >> > > After reading the discussion I wonder: > >> > > >> > > Couldn't you simply connect a transformer to the mains, add a resistor > >> > > divider at the output to get the signal down and record the glitches? > >> > > >> > My front end will do all of that to get the levels right etc. The thing is, > >> > you don't seem to be able to see the glitches for the mains, we've already > >> > been looking. They must be quite small, or it's getting in via another > >> > route. If we knew the route it would be easy but this is the task, to find > >> > what the susceptibility is in a 35 year old product. > >> > > >> > If we had unrestricted access we could try one idea at a time but it won't > >> > be like that so we need to be prepared for various eventualities. > >> > > >> > > That way we could take a look at the data and see what happends on the > >> > > mains. > >> > > >> > > You're at a recording studio after all. Recording something shouldn't be > >> > > much of a problem. :-) > >> > > >> > They might object to losing their hard disk rack. We can record it on a > >> > laptop of course but real time would keep the client happier. > >> > >> Have you researched Dranetz gear? > >> http://www.dranetz-bmi.com/ > > > >I know their kind of stuff and Schaffner EMC too but this work won't pay for > >that. > > I get a feeling you have a lot of time for this project, but not a > large budget to work with?
Pretty much. I'm helping out a colleague who hasn't the funds for the expensive gear and can't design 'clever' electronics himself. The potential bonus for me is that if we get it right we could be experts in the field. Ever lower noise levels mean more and more of this is surfacing.
> I would get a high quality USB audio interface.
I think he has something similar using firewire but there was something odd about it, would have to ask him again.
> Put a front end together for measuring line voltages and > have it record for a few days at the highest resolution/sampling > frequency. Cooledit is a very good program for analyzing the data. > > I think this route is faster than try to get going with DSP > algorithms.
Could be done but I was very interested in the DSP route because of that real time processing advantage. Jan's idea interested me for example. http://panteltje.com/panteltje/xpequ/humfilter-0.1.tgz http://abelian.org/humfilt/ Aside from not having a Linux box to run it on right now. Graham

Tim Wescott wrote:

> This sounds like an adventure into audiophoolery, which isn't what I'd > expect of you. > > What, exactly, are you planning on filtering
We expect some treatment of the mains supply ( maybe audio 'in band filtering' or an isolation transformer ) , possibly re-wiring mains and signal cabling to avoid large loops and zero-crossing certain loads.
> and what are you planning on filtering it against?
What appear to be audio in band transients superimposed on the mains or entering the audio chain by inductive coupling. Unlikely to be capacitive coupling into the audio directly.
> I suppose that you could filter your power supply rail with a supply that > has infinite rejection at all the power line harmonics --
Or maybe just a very low pass filter. Incidentally, from our findings here we may be able to sell products into the 'audiophool' market that REALLY WORK ! They had an 'audiophool filter' on the premises from the grand fools Russ Andrews and their &#4294967295;800 'mains conditioner' connects the live and neutral in directly to the outlet sockets with some largish capacitors in parallel ! Some 'conditioner'. http://www.russandrews.com/product.asp?lookup=1&region=UK&currency=GBP&pf_id=1101&customer_id=PAA2306051009397CVMURDTGYWSUBNOB I note you're left-pondian btw, so a visit to S london would be a little excessive. :~) Graham

Nico Coesel wrote:

> However I have to go along with Tim. Filtering 50Hz harmonics is not > going to help. The plops and clicks you mention are not a multiples of > 50Hz. These are just random spikes on the mains. If these spikes end > up in your audio circuitry, then you most likely have a ground loop or > another ground related problem somewhere. It means that the current > from the spike shares a return path with your audio signal.
Ah, I think you misundestood that I intended to filter the wanted audio. Not at all. What I want to find is the mode of propagation of the mains borne transients into the equipment by eliminating the power line frequency and harmonics from tests we can run on the supplies and even the free-field. Which just gave me an idea. Graham

Jon Kirwan wrote:

> Eeyore <rabbitsfriendsandrelations@hotmail.com> wrote: > > >I am proposing to engage on a project regarding mains voltage 'purity' > >(and absence of ) with regard to audible clicks and pops in high-end > >professional and hi-fi audio equipment. > ><snip> > > Hi, Graham. A thought crossed my mind and it leads to some questions. > > (1) I think you mention elsewhere "to find what the susceptibility is > in a 35 year old product." Is this something that has started more > recently, then? Or has it been going on for a long time and they are > only now noticing or otherwise deciding to deal with it?
They may be being a little coy about this. I found evidence of obvious previous attempts to clean up the mains using 'audiophool grade' components such as .... http://www.russandrews.com/product.asp?lookup=1&region=UK&currency=GBP&pf_id=1101&customer_id=PAA2306051009397CVMURDTGYWSUBNOB It always pays to sniff about. My colleague was there primarily though to remove the effect of inrush current from the a/c which dimmed the lighting momentarily. By re-connecting the mains more suitably to to 2 separate supplies he got rid of that problem but the studio operators said he'd introduced this new one. Maybe he made it more susceptible but the existence of the above 'conditioner' makes me suspect there was always something there. Incidentally, in the end they took his advice and installed a new low-inrush aircon unit ! Duh ! And we also found the supposed 'balanced' 25-0-25 AC supply to the console wasn't balanced. It was 66-106-156 as a result of a suitable named 'Tinkertek' replacement AC supply. So people have been fiddling before. I managed to rewire it to make it properly 25-0-25 and that did seem to help a bit. The original 'PSU' used a CVT to provide the balanced AC which would have provided high transient isolation but due to age was no longer regulating properly and the output voltage was low causing regulator drop-out so couldn't be re-evaluated. Recall that the console takes AC and DC is derived in each channel cassette. We don't know if the transformers in these cassettes have an ES screen.
> (2) Who else (or what other activities) occupy the building?
Nothing other than domestic.
> (3) On what time scale do these events occur?
For example when lights are switched. So the frequency of occurence could be anything.
> I had a situation, years ago, where a dental office moved into the > building on a different floor. Turns out, they had an x-ray machine > and they used it, on occasion. When they did, I'd get nice, narrow kV > spikes back on the AC line that fed us. There was another weird one > where a nearby research facility (150' away) would turn on some of > their equipment and we'd see our ground (relative to theirs) jump 7kV. > The copper communications line was a mess during that transition. > > In other words, have you also checked out what's new, who else is > doing what, nearby?
Good tip but it's in a residential area and the source of the transients is internal to the building and its wiring.. Graham