私は、Matlab を使用して ADC を作成し、理解しようとしています。波形からビット数を変更できるこの小さなプログラムを作成しました (2^8、8 はビット数で、1 から 64 まで可能です)。しかし、パソコンで音を鳴らすと、何かが音を止めたかのように聞こえます。周波数を変更することは可能ですが、問題は解決しません。私は何を間違えたのだろうか?
clf %clr screen
t = 0:1:1600
fs = 1000
senial = sin((2*pi*t)/fs)
quant=max(senial)/(2^8) % R/L = size of sep
y=round(senial/quant) % Quantizationto 2^N bit
signe=uint8((sign(y)'+1)/2) % transforms it to int 8 bit
out=[signe] % The first bit represents the sign of the number
sound(y,fs)
plot(y,'b');