diff options
| author | James McKenzie <root@ka-ata-killa.panaceas.james.local> | 2025-08-30 14:28:02 +0100 |
|---|---|---|
| committer | James McKenzie <root@ka-ata-killa.panaceas.james.local> | 2025-08-30 14:28:02 +0100 |
| commit | f14f2b812ca595db90990fc642d9d294dab1c612 (patch) | |
| tree | 0115a37278e1c781818ce6a57f0f49fc04d401c6 /volume_pot | |
| parent | 7dc398b51af492e2d863c5a3e8cd3e02d9ee8000 (diff) | |
| download | victoria-001-f14f2b812ca595db90990fc642d9d294dab1c612.tar.gz victoria-001-f14f2b812ca595db90990fc642d9d294dab1c612.tar.bz2 victoria-001-f14f2b812ca595db90990fc642d9d294dab1c612.zip | |
update
Diffstat (limited to 'volume_pot')
| -rwxr-xr-x | volume_pot/volume.pl | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/volume_pot/volume.pl b/volume_pot/volume.pl index 3dc0cd3..ad1e41c 100755 --- a/volume_pot/volume.pl +++ b/volume_pot/volume.pl @@ -75,14 +75,23 @@ sub calc_gain($$) { my $erac = $erad + $rdc; my $erdc = $erac - $erad; - print "Effective total HF resistance: $erae + $ered + $erdc = $erac\n"; + my $etot = $erac; + + # input filter + $etot += 150000.; # 150k + $etot += ( ( 1. / 15. ) * $cnf ); # 15nF + #balance control + $etot += par( 1100., ( 1. / 120. ) * $cnf ); # 1.1k in parallel with 120nF + + print "Effective total impedance $erae + $ered + $erdc = $erac\n"; # compute the potentials for a 1V input - my $pe = $erae / $erac; - my $pd = $erad / $erac; + my $pe = $erae / $etot; + my $pd = $erad / $etot; + my $pa = $erac / $etot; my $ped = $pd - $pe; - my $pda = 1 - $pd; + my $pda = $pa - $pd; my $v = $k / 10.; my $hf; |
