当前位置:网站首页>Matlab uses audiorecorder and recordblocking to record sound, play to play sound, and audiobook to save sound
Matlab uses audiorecorder and recordblocking to record sound, play to play sound, and audiobook to save sound
2022-07-02 01:29:00 【Hu Gang 2016】
Because I use now matlab yes 2018a, So you can't use abandoned wavreord and wavplay, Only use audiorecorder.
Fs=44800;% Microphone sampling rate
nBits=16;% Quantization Bits
nChannel=1;% Number of recording channels , You can set 1 perhaps 2
time=5;% Time of recording audio , The unit is seconds
recObj = audiorecorder(Fs, nBits, nChannel);
disp('Start speaking.')
% Start recording sound
recordblocking(recObj, time);
disp('End of Recording.');
% Playback recorded data
play(recObj);
% Get recording data
myRecording = getaudiodata(recObj);
% Draw recording data waveform
plot(myRecording);
% Store voice signals
filename = 'audiorecorder_data_1.wav';
audiowrite(filename, myRecording, Fs);


You can see that the size of the file generated by the recording is 438KB
It's calculated by :Fs * nBits / 8 * time * nChannel / 1024
namely :44800 * 16 / 8 * 5 * 1 / 1024 = 437.5KB
No matter how many words you say when recording , Even if you don't say a word , The size of the generated files is so large .
边栏推荐
- Develop a simple login logic based on SSM
- Game thinking 15: thinking about the whole region and sub region Services
- [WesternCTF2018]shrine writeup
- KS006基于SSM实现学生成绩管理系统
- [IVX junior engineer training course 10 papers] 04 canvas and a group photo of IVX and me
- Self drawing of menu items and CListBox items
- Appium inspector can directly locate the WebView page. Does anyone know the principle
- 【图像增强】基于Frangi滤波器实现血管图像增强附matlab代码
- [Floyd] post disaster reconstruction
- CTF daily question day45 sensor
猜你喜欢

Single chip microcomputer -- hlk-w801 transplant NES simulator (III)

企业应该选择无服务器计算吗?
![[WesternCTF2018]shrine writeup](/img/26/1700095c9b38b9b74a1b1136e5d5de.jpg)
[WesternCTF2018]shrine writeup

遷移雲計算工作負載的四個基本策略

Edge extraction edges based on Halcon learning_ image. Hdev routine

LeetCode、3无重复最长子序列

迁移云计算工作负载的四个基本策略

学习笔记2--高精度地图定义及价值

Quatre stratégies de base pour migrer la charge de travail de l'informatique en nuage

We should make clear the branch prediction
随机推荐
Android high frequency network interview topic must know and be able to compare Android development environment
现货黄金分析的技巧有什么呢?
We should make clear the branch prediction
uTools
SQL injection for Web Security (2)
[WesternCTF2018]shrine writeup
[IVX junior engineer training course 10 papers to get certificates] 01 learn about IVX and complete the New Year greeting card
Datawhale 社区黑板报(第1期)
matlab 实现语音信号重采样和归一化,并播放比对效果
MySQL application day02
error: . repo/manifests/: contains uncommitted changes
The pain of Xiao Sha
[image enhancement] vascular image enhancement based on frangi filter with matlab code
SAP ui5 beginner tutorial 20 - explanation of expression binding usage of SAP ui5
[IVX junior engineer training course 10 papers] 02 numerical binding and adaptive website production
三分钟学会基础k线图知识
6-2漏洞利用-ftp不可避免的问题
Have you stepped on the nine common pits in the e-commerce system?
Daily work and study notes
微信小程序中使用tabBar