概述
工模调节
▪进入EM模式
(*
#
*
#3646633#
*
#
*
),您将看到不同模式(听筒、耳机、外放、耳机同时外放)下的音频参数。
audio_ver1_volume_custom_default.h
(alps/mediatek/custom/common/cgen/inc/audio/[project])
#ifndef AUDIO_VER1_VOLUME_CUSTOM_DEFAULT_H
#define AUDIO_VER1_VOLUME_CUSTOM_DEFAULT_H
#define VER1_AUD_VOLUME_RING
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0,
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0,
104,128,152,176,200,224,248,0,0,0,0,0,0,0,0,
104,128,152,176,200,224,248,0,0,0,0,0,0,0,0
#define VER1_AUD_VOLUME_SIP
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0,
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0,
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0,
0,43,85,128,171,213,255,0,0,0,0,0,0,0,0
#define VER1_AUD_VOLUME_MIC
64,112,192,164,192,192,184,184,184,184,184,0,0,0,0,
255,192,192,176,192,192,196,184,184,184,184,0,0,0,0,
255,208,208,164,255,208,196,0,0,0,0,0,0,0,0,
255,208,208,164,255,208,172,0,0,0,0,0,0,0,0
#ifdef FM_DIGITAL_INPUT
#define VER1_AUD_VOLUME_FM
16,80,112,144,176,208,240,0,0,0,0,0,0,0,0,
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0,
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0,
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0
#else
#define VER1_AUD_VOLUME_FM
16,80,112,144,176,208,240,0,0,0,0,0,0,0,0,
16,80,112,144,176,208,240,0,0,0,0,0,0,0,0,
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0,
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0
#endif
#define VER1_AUD_VOLUME_SPH
80,88,100,116,124,132,140,0,0,0,0,0,0,0,0,
84,96,112,124,132,140,148,0,0,0,0,0,0,0,0,
80,88,100,116,124,132,140,0,0,0,0,0,0,0,0,
40,52,64,76,88,100,112,0,0,0,0,0,0,0,0
#define VER1_AUD_VOLUME_SID
0,0,16,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,32,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
#define VER1_AUD_VOLUME_MEDIA
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0,
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0,
104,128,152,176,200,224,248,0,0,0,0,0,0,0,0,
104,128,152,176,200,224,248,0,0,0,0,0,0,0,0
#define VER1_AUD_VOLUME_MATV
0,32,64,92,128,160,192,0,0,0,0,0,0,0,0,
0,32,64,92,128,160,192,0,0,0,0,0,0,0,0,
112,136,160,184,208,232,255,0,0,0,0,0,0,0,0,
0,43,85,128,171,213,255,0,0,0,0,0,0,0,0
#define VER1_AUD_NORMAL_VOLUME_DEFAULT
128,128,128,128,128,128
#define VER1_AUD_HEADSER_VOLUME_DEFAULT
148,148,148,148,148,148
#define VER1_AUD_SPEAKER_VOLUME_DEFAULT
120,120,120,120,120,120
#define VER1_AUD_HEADSETSPEAKER_VOLUME_DEFAULT
132,120,132,132,132,132,132,132
#define VER1_AUD_EXTAMP_VOLUME_DEFAULT
132,132,132,132,132,132
#define VER1_AUD_VOLUME_LEVEL_DEFAULT
7,7,7,7,7,7,7,7,7
#endif
nSpeech Volumecustomize
Ø当AudioSystem处于
MODE_IN_CALL
模式 .
Ø输出设备有三种Normal, Headset , Hands-free mode
Ø调节的是模拟增益
开关机音量调整
▪如果想改变开关机音量,有两种方式
–第一是把AudioMtkPolicyManager.cpp
•(alps/mediatek/platform/common/hardware/audio/)
•#define
BOOT_ANIMATION_VOLUME(0.25) 修改此值,最大为1
–第二是修改代码
•BootAnimation.cpp (alps/frameworks/base/cmds/bootanimation)
•在bool BootAnimation::threadLoop()里mediastatus = mediaplayer->start()前面 增加下面这行代码
•
mediaplayer
->
setVolume
(
leftVolume,rightVolume
);//适当调节音量值,参数范围0-1,默认是1
–第三种
•更换开关机资源文件
拨号键盘音量
(
DTMF
)
▪方法一,DialpadFragment.java
–Alps/packages/apps/contacts/src/com/android/contacts/dialpad/
–private static final int
TONE_RELATIVE_VOLUME = 80; 最大可到100,最小是0
▪方法二,在代码中AudioMTKPolicyManager.cpp
–Alps/mediatek/platform/common/hardware/audio
–Static unsigned char audiovolume_dtmf[][]
详细文件参考
http://download.csdn.net/detail/wds1181977/8227493
最后
以上就是害羞小虾米为你收集整理的MTK修改听筒音量,拨号键盘音量,开关机音量调整的全部内容,希望文章能够帮你解决MTK修改听筒音量,拨号键盘音量,开关机音量调整所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复