<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);" class="elementToProof">
Okay.  The way I did something similar to this (in 1982) was to use what's called a Schroeder chirp.  This contains far more energy than a step function and could be generated on the console, then analysed with an FFT.  Then it's trivial to convert the FFT
 output coefficients into an FIR filter.<br>
</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Didrik Madheden <nitro2k01@gmail.com><br>
<b>Sent:</b> 11 December 2022 15:31<br>
<b>To:</b> Mike Bryant <mbryant@futurehorizons.com><br>
<b>Cc:</b> SDIY List <synth-diy@synth-diy.org><br>
<b>Subject:</b> Re: [sdiy] Removing the effect of a DC blocking filter through DSP</font>
<div> </div>
</div>
<div>
<div dir="auto">Thanks. But this is not audio from a microphone at all. It's audio generated from an 8-bit game console, which I need to analyze for hardware research about quirks in its audio generation circuit. Hence why I alluded that I can easily generate
 a step function for reference. Ie, I'd write a program for the console that changes a DC offset.</div>
<br>
<div class="x_gmail_quote">
<div dir="ltr" class="x_gmail_attr">On Sun, 11 Dec 2022, 16:18 Mike Bryant, <<a href="mailto:mbryant@futurehorizons.com">mbryant@futurehorizons.com</a>> wrote:<br>
</div>
<blockquote class="x_gmail_quote" style="margin:0 0 0 .8ex; border-left:1px #ccc solid; padding-left:1ex">
<div dir="ltr">
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0); background-color:rgb(255,255,255)">
This tends to imply you have an A-D convertor in the chain.  This will affect the step impulse you want to use for calibration possibly more than the capacitors.  You will also need to roll off your correction filter before you get to DC - there's a lot of
 crap around at <10Hz which if this is music/voice you won't want.   <br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0); background-color:rgb(255,255,255)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0); background-color:rgb(255,255,255)">
Conversely if it's geological audio or something like that, I'd suggest a different mic system that is dc coupled :-)<br>
</div>
<div id="x_m_-2031428299160381907appendonsend"></div>
<hr style="display:inline-block; width:98%">
<div id="x_m_-2031428299160381907divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>From:</b> Synth-diy <<a href="mailto:synth-diy-bounces@synth-diy.org" target="_blank" rel="noreferrer">synth-diy-bounces@synth-diy.org</a>>
 on behalf of Didrik Madheden via Synth-diy <<a href="mailto:synth-diy@synth-diy.org" target="_blank" rel="noreferrer">synth-diy@synth-diy.org</a>><br>
<b>Sent:</b> 11 December 2022 14:49<br>
<b>To:</b> SDIY List <<a href="mailto:synth-diy@synth-diy.org" target="_blank" rel="noreferrer">synth-diy@synth-diy.org</a>><br>
<b>Subject:</b> [sdiy] Removing the effect of a DC blocking filter through DSP</font>
<div> </div>
</div>
<div><font size="2"><span style="font-size:11pt">
<div>Today the thing I'm tasked with is that I have some audio recorded<br>
through a setup containing one or more DC blocking caps, and would<br>
like to recover the unaffected audio. In principle, this could<br>
potentially be fairly simple depending on the circuit: model a 1 pole<br>
HP filter and run it backwards. Of course, the issue is that you would<br>
be integrating over a fairly long period of time (in my case I'd need<br>
to do it over multiple seconds) and the output is likely to diverge<br>
easily. I'm able to produce a step function from this system as a<br>
reference.<br>
<br>
Before I roll up my sleeves and try to code something myself, is there<br>
any project or code examples that does exactly this, in particular<br>
automating or visualizing the trimming of the parameters needed to<br>
avoid divergence? In the ideal case, such a software might have a<br>
waveform view where I can select part of the reference waveform that's<br>
silent, for extracting a corrective DC offset, and the pulse of my<br>
reference step function, for extracting the filter parameters, and out<br>
comes the parameters I need.<br>
<br>
-- <br>
/Didrik<br>
_______________________________________________<br>
Synth-diy mailing list<br>
<a href="mailto:Synth-diy@synth-diy.org" target="_blank" rel="noreferrer">Synth-diy@synth-diy.org</a><br>
<a href="http://synth-diy.org/mailman/listinfo/synth-diy" target="_blank" rel="noreferrer">http://synth-diy.org/mailman/listinfo/synth-diy</a><br>
Selling or trading? Use <a href="mailto:marketplace@synth-diy.org" target="_blank" rel="noreferrer">
marketplace@synth-diy.org</a><br>
</div>
</span></font></div>
</div>
</blockquote>
</div>
</div>
</body>
</html>