I2S bclk分頻係數計算

2021-07-03 04:17:18 字數 716 閱讀 6636

bclk = 2 * word_select_size * fs;

假如word_select_size = 32; fs = 44100;bclk=2.8224m;

bclk一般從乙個master時鐘分頻下來,假如叫做mclk;

如果mclk由主控的pll或者其他時鐘源提供,那麼mclk由此pll分頻或者倍頻得到;

mclk = pll/4 = 5.6448m;bclk=mclk/2=2.8224m;

mdiv = 4;bdiv = 2;

over_samplerate = 5.6448m/44.1k = 128

mclk:有時為了使系統間能夠更好地同步,還需要另外傳輸乙個訊號mclk,稱為主時鐘,也叫系統時鐘(sys clock),是取樣頻率的128倍,256倍或384倍,也叫過取樣(over_samplerate);

lrck_period的配置:

pcm mode:number of bclks within(

left+right) channel width;

i2s/left-justified/right-justified mode:number of bclks within ech individual channel width(left or right)

n+1:

n=7; 8 bclk width

...n=1023; 1024 bclks width;



i2s和s2i演算法 sstream用法

標頭檔案 include cout本人實戰常用如下模板 void i2s int num,string str 1.2 string to int 下面的例子將輸入到str中的字元通過string stream型別的變數ss轉換為int型別的變數,輸入到num中 stringstream ss st...

I2C驅動(2) 讀寫eeprom

include include include include include include include include include static unsigned short ignore static unsigned short normal addr 位址值是7位 改為0x60的話...

協同過濾I2I的簡單實現

基於物品的協同過濾是目前業界應用最多的演算法。可以通過下面公式定義物品的相似度 w i,j n i n j n i n j w frac wi,j n i n j n i n j 這裡,分母 n i n j n i cap n j n i n j 是同時喜歡物品i和物品j的的使用者數。為了減輕熱門物...