2016年11月11日金曜日

3V動作 トランスレス型 3 BJT トランジスタ 低周波パワー・アンプの設計


乾電池3Vで動作できるポータブルラジオ用にスピーカを鳴らせる3石トランジスタ使用低周波ミニ・パワーアンプを設計した。

1. 前段LPF無しの増幅動作



















図1 過渡解析結果





















図2 AC解析結果


過渡解析結果からは、高調波歪みは多少あるが、実用範囲にあると思われる。
約20dBもの電圧利得が得られた。

しかしトランジスタの高周波特性が良すぎるため、中間周波数455KHzでも相当の利得がでてしまう。


2. 高周波ゲインを下げる改良

上記1.の周波数特性を、高周波領域で十分下がるように初段に 10KΩと0.01uFによるLPFをつけた。

その結果、総合利得はぼぼ同一で、中間周波数455KHz以上で十分に利得が下がる効果が得られた。





















図3 過渡解析結果
























図4 AC解析結果



ブログ記事目次へ戻る















2016年11月5日土曜日

Synchronized AM demodulator by using “IQ demodulator” and calculations of square-multiplying and square root 

Synchronized AM demodulator by using “IQ demodulator” and calculations of square-multiplying and square root (Preliminary)
IQ(直交)復調器と、自乗、加算、平方根計算を使った数値演算式AM同期検波方式理論
(C) Noboru, Ji1NZL, Nov. 2, 2016


[Abstract] 
AM receivers can cancel the change of the phase on the received signal by using an IQ demodulator and the math operation Vout = √(I(t)^2+q(t)^2). 
The IQ demodulator here may configured by analog circuit and that the math operation Vout = √(I(t)^2+q(t)^2) can be calculated by some MPU or DSP. This AM detector can get good quality of sound with very low distortion.

 Fig.1 An architecture of AM synchronized detector

1. How the AM synchronized demodulator works

AM RF signal received on the radio expressed as the equation (1). 
Here, I assume that Vam changes the phase θ(t)[rad] on the propagation path of the AM RF/ ( E/M ) wave. 

Vam= ( Vdc+x(t) )*Vc*sin(ωc*t+θ(t)) …(1)  

Vdc : DC voltage at AM modulator. Unit is [V].
x(t) : Baseband signal function for AM modulator. Unit is [V].
Vc  : Carrier peak voltage that AM receiver receives. Unit is [V].
ωc : Angular frequency of the AM modulator. Unit is [rad・Hz].
fc  : Frequency of the carrier ωc. Unit is [Hz].

There is a problem that the signal strength of decoded tone changed by this phase change. For example, when the receiver used the oscillator frequency = π/2 [rad] shifted for the equation (1), the decoded signal becomes 0. It means there is no tone. Or we feel it as “fading” phenomenon as time goes on.

The AM decoder here synchronized with the phase of the carrier, fix this problem.
Assume the baseband signal is a sine wave voltage of single audio frequency defined as (2) here.

x(t)=Vs*sin(ωs*t) …(2)  

Vs  :  Peak voltage of (2). Unit is [V].
ωs : Angular frequency of a sine baseband signal. Unit is [rad・Hz].
ωs = 2πfs …(3)
fs : Frequency of baseband sine wave. Unit is [Hz].

The voltage of the oscillator Vosc is expressed as

Vosc = Vo*sin(ωc*t) …(4)

Vo : Peak voltage of (4). Unit is [V].

At the equation (1), 

sin(ωc*t+θ(t)) = sin(ωc*t)*cos(θ(t))+cos(ωc*t)*sin(θ(t))  … (5)

Then (1) becomes


Vam= Vc*{Vdc+ Vs*sin(ωs*t)}* { sin(ωc*t)*cos(θ(t))+cos(ωc*t)*sin(θ(t)) } …(6)
      = Vc{ Vdc*sin(ωc*t)*cos(θ(t))+Vdc*(cos(ωc*t)*sin(θ(t))) )
              +Vs*sin(ωs*t)*sin(ωc*t)*cos(θ(t))+Vs*sin(ωs*t)*cos(ωc*t)*sin(θ(t)) } …(7)

Since V3 = Vam*Vosc , then (7)x(4) becomes V3,

V3 = Vc{ Vdc*sin(ωc*t)*cos(θ(t))+Vdc*(cos(ωc*t)*sin(θ(t))) )
              +Vs*sin(ωs*t)*sin(ωc*t)*cos(θ(t))+Vs*sin(ωs*t)*cos(ωc*t)*sin(θ(t)) } * Vo*sin(ωc*t)

=Vc*Vo{ Vdc*(sin(ωc*t))^2*cos(θ(t))+Vdc*(sin(ωc*t)*cos(ωc*t)*sin(θ(t))) )
            +Vs*(sin(ωs*t)*sin(ωc*t))^2*cos(θ(t))+Vs*sin(ωs*t)*sin(ωc*t)*cos(ωc*t)*sin(θ(t)) }

=Vc*Vo{ (sin(ωc*t))^2* {Vdc*cos(θ(t)) + Vs*sin(ωs*t)*cos(θ(t))}
            + (sin(ωc*t)*cos(ωc*t)*{ Vdc*sin(θ(t)) + Vs*sin(ωs*t)*sin(θ(t)) } }

=Vc*Vo{ (sin(ωc*t))^2* (Vdc + Vs*sin(ωs*t))*cos(θ(t))
          + (sin(ωc*t)*cos(ωc*t)) *(Vdc + Vs*sin(ωs*t))*sin(θ(t)) }  …(8)


Here,
(sin(ωc*t))^2 = (1/2)*(cos(2*ωc*t)-cos(ωc-ωc)) = (1/2)*{cos(2*ωc*t)-1}  …(9) 
sin(ωc*t)*cos(ωc*t) =(1/2)*sin(2*ωc*t) …(10)

Replace (sin(ωc*t))^2 and sin(ωc*t)*cos(ωc*t) in (8) by (9) and (10)
Then

V3 = Vc*Vo{  (1/2)*{cos(2*ωc*t)-1} * (Vdc+Vs*sin(ωs*t))*cos(θ(t)) + (1/2)*sin(2*ωc*t) *(Vdc+Vs)*sin(θ(t)) } 
    = Vc*Vo{ (1/2)*cos(2*ωc*t)*(Vdc+Vs)*cos(θ(t)) -(1/2)* (Vdc+Vs)*cos(θ(t)) + (1/2)*sin(2*ωc*t) *(Vdc+Vs*sin(ωs*t))*sin(θ(t)) }  …(10)

Very high RF frequency voltage cos(2*ωc*t) and cos(2*ωc*t) can be remove from (10) by LPF,

Then
V-i = Vc*Vo{ -(1/2)* (Vdc+Vs*sin(ωs*t))*cos(θ(t)) }  
    = -(1/2)*Vc*Vo{ (Vdc+Vs*sin(ωs*t)) *cos(θ(t)) } …(11)

V2 is -π/2[rad] shifted signal of the oscillator (4),

V2= Vo*sin(ωc*t-π/2) = -Vo*cos(ωc*t) …(12)

Here the equations (4) and (12) configures as so-called an “orthogonal oscillator”. 
They may generate orthogonal sine waves or square (pulse) waves that they are shifted -π/2 [rad] each other.

When the orthogonal oscillator generates sine waves, the mixer devices must be used as analog multipliers.

When the orthogonal oscillator generates square (pulse) waves, analog switches can be used as the mixer devices. 

Get V4 = Vam * V2, 
V4 = Vc{ Vdc*sin(ωc*t)*cos(θ(t))+Vdc*(cos(ωc*t)*sin(θ(t))) )
            +Vs*sin(ωs*t)*sin(ωc*t)*cos(θ(t))+Vs*sin(ωs*t)*cos(ωc*t)*sin(θ(t)) } * (-Vo*cos(ωc*t)) }
    = -Vc*Vo{ Vdc*sin(ωc*t)*cos(ωc*t)*cos(θ(t))+Vdc*((cos(ωc*t)^2)*sin(θ(t))) )
                    +Vs*sin(ωs*t)*sin(ωc*t)*cos(ωc*t)*cos(θ(t))+Vs*sin(ωs*t)*(cos(ωc*t))^2*sin(θ(t)) }
    =  -Vc*Vo{ sin(ωc*t)*cos(ωc*t){Vdc*cos(θ(t)) +Vs*sin(ωs*t)*cos(θ(t))}
                    +((cos(ωc*t)^2) {Vdc*sin(θ(t))+ Vs*sin(ωs*t)*sin(θ(t))}  }
  =  -Vc*Vo{ sin(ωc*t)*cos(ωc*t){Vdc +Vs*sin(ωs*t)}*cos(θ(t))
                  +((cos(ωc*t)^2) {Vdc+ Vs*sin(ωs*t)}*sin(θ(t))) } …(13)

Here,
(cos(ωc*t))^2 = (1/2)*(cos(2*ωc*t)+cos(ωc-ωc)) = (1/2)*{cos(2*ωc*t)+1}  …(14) 

sin(ωc*t)*cos(ωc*t) =(1/2)*sin(2*ωc*t) …(10)

V4 = -Vc*Vo{  (1/2)*sin(2*ωc*t) *{Vdc +Vs*sin(ωs*t)}*cos(θ(t))
                  +((1/2)*{cos(2*ωc*t)+1}) {Vdc+ Vs*sin(ωs*t)}*sin(θ(t))) }
    = -Vc*Vo{  (1/2)*sin(2*ωc*t) *{Vdc +Vs*sin(ωs*t)}*cos(θ(t))
                  +((1/2*Vdc)*{cos(2*ωc*t)) + (1/2){Vdc + Vs*sin(ωs*t)}*sin(θ(t))} ) } …(15)

Very high RF frequency voltage sin(2*ωc*t) and cos(2*ωc*t) can be remove from (15) by LPF,

Then
V-q= -Vc*Vo{ (1/2){Vdc + Vs*sin(ωs*t)}*sin(θ(t))} ) } 
= -(1/2)*Vc*Vo*{Vdc + Vs*sin(ωs*t)} *sin(θ(t)) } …(16)

Here, define K(t) is as
K(t) ≡ -(1/2)*Vc*Vo*{Vdc + Vs*sin(ωs*t)} …(17)

Then (16) can be written as
V-q = K(t)*sin(θ(t)) …(18)

and (11) can be written as
V-i = K(t)*cos(θ(t))  …(19)

By using (18) and (19),

V-i^2 + v-q^2 = {K(t)*cos(θ(t)) }^2 + {K(t)*sin(θ(t))}^2
                    = K(t)^2*{cos(θ(t))}^2 + K(t)^2*{sin(θ(t))}^2 
                    = K(t)^2*{ {cos(θ(t))}^2 + {sin(θ(t))}^2 }  … (∵ {cos(θ(t))}^2 + {sin(θ(t))}^2 =1 )
                    = K(t)^2

∴ √(V-i^2 + v-q^2) = K(t)
                            = -(1/2)*Vc*Vo*{Vdc + Vs*sin(ωs*t)} …(20)

The equation (20) is the same as AM decoded voltage Vout on the Fig.1.
∴ Vout = -(1/2)*Vc*Vo*{Vdc + Vs*sin(ωs*t)} 
            = -(1/2)*Vc*Vo*Vdc  - (1/2)*Vc*Vo*Vs*sin(ωs*t) …(21) 

The equation (21) does not have the variable θ(t) in these parameters.
And Vo and Vdc are constant value. 
The DC voltage -(1/2)*Vc*Vo*Vdc [V] can be removed by some condenser such as 1uF.
Vc (signal strength) can change according to the time goes. 
However it can be nearly constant by using AGC (Automatic Gain Control) in the receiver.

This means output signal voltage Vout is extracted the baseband signal Vs*sin(ωs*t) as the output “Vout” from Vam, 
it is independent of change value of the phase θ(t),
and the AM Synchronized reception is possible by using the architecture of Fig.1.

I draw the Fig.1 by referencing the schematic[1] and changed the delay function to configure an orthogonal OSC(oscillator). that generates a 1MHz sine or square (pulse) wave and a π/2 [rad] shifted one.

If voltages V-i and V-q are sampled by A/D convertors, MPU or DSP can calculate Vout by the equation (21). 


Fig.2 is an example of simulation result of the transient analysis by LTspice iV developed by (C) Linear Technology inc. 
The quality of the detector is pretty better than the traditional diode detector.


Fig.2 Simulation result of the transient analysis by LTspice iV 

 
                        Fig.3  An example of actual work of demodulation by "IQ demodulator" 


      Fig.4  An example of assembling of "IQ memodulator" RF front end PB

2. Subjects

(1) Frequency stability of the orthogonal oscillator and error of demodulated tone

    The orthogonal signal oscillator have to have good frequency stability such as a few Herz.
    But old type of PLL that sets the frequency such as 100Hz every steps is used, 100Hz low beat can occur.
    Frequency error for the orthogonal oscillator can affect the tone difference. Especially, when listening music or songs. 
    It seems that human’s ears are very sensitive for 8Hz frequency drift.
    Accuracy and stability of frequency for the orthogonal oscillator is very important.  
    Latest DDS can satisfy this accuracy.

(2) Sampling noise of ADC (AD converter)
    The sampling noise of ADC (AD convertor) may affect the RF input of the receiver. It must be minimized.

(3) Switching noise of Analog switches
    When analog switches are used as the orthogonal mixer, they generates some noise. However, it can removed by LPF.
    In the actual experiments, they are practical enough.

(4) Wide dynamic range of AM demodulator
    The traditional diode AM detector so called “Peak detector” or “Envelope detector” generates harmonics tone such as 2KHz, 3KHz, …. if the baseband frequency is 1KHz used. This is derived from the electric characteristics of exponential function on the diodes current.  { The current on diode is expressed as  “ i = Is*(exp(K*v)-1) “. }
This demodulator can have much wider dynamic range for the baseband signal swings then the diode detector. 
Because the demodulator by analog multipliers or analog switch can have wide dynamic range without tone distortion such as the traditional diode detector.

(5) Programmable LPF/BPF
The LPF/BPF at I/Q output sides can be defined by the software on the DSP or MPU. Eg. FIR filter, IIR filter.
These LPF/BPF also can be configured by the analog circuit such as CR filter, LC filter, or other filter used with OP amps.  

References:
[1] The schematics of “AM synchronous detector” by the author Mr. “Kaikyou no Kaze” / “The wind from the sea” 
(Copyright of the schematics is reserved and is respected as nice knowledge of the author.)

Return to INDEX

2016年11月3日木曜日

コイルを使わないGIC同調回路とそれを使ったダイオード検波AMラジオ

コイルを使わないGIC同調回路とそれを使ったダイオード検波AMラジオを構成してみました。
目標は、IC(集積回路)にコイルを使わずに同調回路やマッチング・フィルタを組み込むことを視野に入れています。
























図1 GIC同調回路を使ったダイオード検波AMラジオの過渡解析結果










図2 GIC同調回路を使った同調回路の周波数・位相特性解析結果
(長波〜中波〜短波)


































図3 従来式 LC同調回路を使った同調回路の周波数・位相特性解析結果
(長波〜中波〜短波)


参考資料:
[1]アナログ回路 培風館 "オペアンプによるGIC回路"
(内容が古いので現代に適応する改訂が望まれます。)


ブログ記事目次へ戻る


2016年10月30日日曜日

アナログスイッチによるAM復調回路とダイオード検波の性能比較・見積もり(暫定版)

アナログスイッチ (74VHC4066 等)を使用したAM復調回路(検波回路)と、ショットキー・ダイオード使用したAM復調回路(検波回路)について、

(1) IQ信号AM復調回路
(2)プロダクト検波回路
(3)ダイオード検波回路(旧名称:ピーク・ディテクタ)

をLTspiceにより、設計段階での、性能見積もり・比較を行いました。




















図1:過渡解析シミュレーション結果



結果:
(1) アナログスイッチを使ったプロダクト検波方式は、計算上、従来のダイオード検波回路と同等以上の復調感度が得られる。

(2)アナログスイッチを使ったプロダクト検波方式は、計算上、従来のダイオード検波回路に見られる高調波歪みが無くなりより良い音質が得ることが期待できる。

(3)IQ信号AM復調回路は、I信号、Q信号、それぞれ直交関数の関係にある復調信号を、加算合成した信号を得られる。

課題:
(1)ここでアナログスイッチを使った単独または片側だけのプロダクト検波方式では、受信したAM変調波のキャリア信号と同期させる同期検波機能を持たせていないが、同期機能をもたせれば、位相ずれの歪みをキャンセルできる

図1中のI信号電圧、Q信号電圧をそれぞれ2乗して、平方根をとると、その値は、計算上、受信AM電波の位相が時間的に変化しても、その変化をキャンセルできるようです。

この位相同期処理にはDSPやCPUでの信号処理が必要ですが、音質が改善し、伝播経路上の位相変化フェーディングをキャンセルする効果が期待できそうです。(近日公開予定)

また、I信号電圧、Q信号電圧は、時間に関する直交関数の関係にあるので、別の「直交電波の加算現象」に書いた原理に従うと、加算することで、周波数が同じで、振幅が重ねあわせで大きくなり、位相が一定だけずれた信号が得られる可能性があります。(現在検討中)

(2)IQ信号AM復調回路、プロダクト検波回路ともに、局部発振周波数のドリフト、または、送信機側のキャリア周波数のドリフトにより、音調がずれ、音楽の音調がずれて変なふうに聞こえる現象発生が予想される

この課題を解決するには、送信機側のキャリア周波数のドリフト、及び、受信機側局部発振器側の周波数ドリフトを可能な限り0に近づける必要がある。

(3)IQ信号AM復調回路は、アナログ回路またはDSP信号処理で、平方根演算で実現できるが、場合によっては、I信号またはQ信号の片側だけの復調された低周波ベースバンド信号を低周波アンプで増幅したほうが、回路が簡素になり、ノイズレベルも下がる可能性がある。


参考資料:
[1]「海峡の風」さんサイト記事「同期検波」(Copyright by 海峡の風さん)



ブログ記事目次へ戻る


2016年10月23日日曜日

直交(電波)信号の加算現象


引用動画[1]を参考にして、周波数10.7MHzの位相が90度ずれた(直交する)2波の正弦波電波がアンテナに受信されると、周波数が同じで、振幅が大きくなり、位相がずれた正弦波電波に合成される現象が起こることをグラフ上で見える化してみました。




上記グラフは動画[1]の計算説明通りに、式(1)により一般化できることがわかりました。

...(1)



アンテナで、同時に受信された複数の電波電圧は、加算で表現できるという基礎理論は、資料[2]を参考にしました。


実験による検証方法:

方法(1) ダイポールアンテナを適切な高さに設置し、受信機に接続。
  
送信地点1:
適当な周波数(例50MHz)の周波数でキャリア信号(正弦波)電波を送信する。

送信地点2:
送信地点2で、送信地点1と同一周波数でキャリア信号(正弦波)電波を送信する。

受信地点〜送信地点1の距離と、受信地点〜送信地点2の距離の差が、位相差90度になるように位置を調整する。

送信地点1、送信地点2で、時刻を精密に合わせ、同一時刻で送信を開始する。

受信地点で、式(1)で計算された計算値と、受信波電圧の実測値を比較し、一致するか否かを確認する。

方法(2) spiceで、直交関数信号となる正弦波を、オペアンプによる加算回路に入力し、出力値を計算。計算結果が、式(1)と一致するか否かを確認する。


Reference:
[1]Amplitude Phase form 1,2,3
https://www.youtube.com/watch?v=fNuxiNGjDpY
(Copyright by DaveAcademy and Mr. Youtube)

[2]MIT OCW 6.003 Signals and Systems,  "Modulation 1"
(Copyright by Prof. Dennis Freeman, MIT)


ブログ記事目次へ戻る



2016年10月2日日曜日

適応型フィルタを使ったノイズ・キャンセル実験の紹介

Windows95発売の翌年に実験した適応型フィルタのノイズ・キャンセル実験の写真です。


上の写真が、FMラジオのザーという雑音に埋もれたサイン波と、雑音をフィルタで除いた後に出力されたサイン波です。

入力信号:
(1) FMラジオのザーという雑音に埋もれたサイン波
(2) FMラジオのザーという雑音

出力信号:
(3)適応型フィルタを通過した信号=サイン波

下の写真は、一番下が、時々刻々と特性を変化させる適応フィルタの利得:周波数特性です。
ここでは一種の自動学習機能がDSP上で動き、フィルタがどのような特性になるかは全く予測できない不思議な動きをしました。

この当時から脳神経細胞の動きを真似しようとする話が進んでいました。
この時はDSPはアセンブラはあってもC言語コンパイラが無く、アセンブルした機械語のDSPサブルーチンをCallしました。
その後すぐDSP用最適化Cコンパイラが出てきました。

通信機に実装されているノイズリダクション処理(NR処理)は、NMSアルゴリズムという、かなり歴史あるものが使われているようです。
UK/EU/USがこの方面はずっと進んでいて、自分の遅れを痛感・反省し、追いつきたいと思います。

参考文献:
[1]マルチレート信号処理 貴家仁志著 (株)昭晃堂 出版 ISBN4-7856-2012-9


目次へ戻る(Return to index)

2016年10月1日土曜日

LC Tuning frequency calculation by Javascript (Test version: Worked OK)



Calcurate tuning frequency of LC circuit f = 1/2π√LC





Tuning Frequency Calculation f = 1/2π√LC

L (indectance)[H] example. 0.1e-6 when 0.1[uH]

C (capacity)[F] example. 20e-12 when 20[pF]