2965
- 收藏
- 点赞
- 分享
- 举报
hi3531a 增大音量问题
我在使用hi3531a的时候,录出的音频特别小,查看海思手册,好像我的开发板使用的并不是海思内置的audio codec引擎,我所用的开发板使用了tlv320aic31的audio codec引擎,我尝试过
(1) 使用ioctl(s32Acodec_Fd, ACODEC_SET_INPUT_VOL, &iVol 发现我的sdk工程中并没有ACODEC_SET_INPUT_VOL这个定义
(2) 使用HI_MPI_AI_SetVqeVolume() 报错没有配置vqe 不知道vqe是否可以增大音量,有没有必要配置vqe?
(3 )调节tlv320的ioctl
#if 0//20180302
audio_ctrl.if_mute_route = 0;
audio_ctrl.input_level = 0;
#else
audio_ctrl.if_mute_route = 1;
audio_ctrl.input_level = 100;
printf("mute route = 1!\n");
printf("%d set input level =%d\n",__LINE__,audio_ctrl.input_level);
#endif
ioctl(s_fdTlv,LEFT_DAC_VOL_CTRL,&audio_ctrl);
ioctl(s_fdTlv,RIGHT_DAC_VOL_CTRL,&audio_ctrl);
/*Right/Left DAC Datapath Control */
audio_ctrl.if_powerup = 1;/*Left/Right DAC datapath plays left/right channel input data*/
ioctl(s_fdTlv,LEFT_DAC_POWER_SETUP,&audio_ctrl);
if ((AIO_MODE_I2S_MASTER != enWorkmode) && (AIO_MODE_I2S_SLAVE != enWorkmode))
{
audio_ctrl.if_powerup = 0;
}
ioctl(s_fdTlv,RIGHT_DAC_POWER_SETUP,&audio_ctrl);
/* */
if ((AIO_MODE_PCM_MASTER_STD == enWorkmode)||(AIO_MODE_PCM_SLAVE_STD == enWorkmode))
{
bPCMStd = HI_TRUE;
audio_ctrl.data_offset = bPCMStd;
ioctl(s_fdTlv,SET_SERIAL_DATA_OFFSET,&audio_ctrl);
}
else if ((AIO_MODE_PCM_MASTER_NSTD == enWorkmode)||(AIO_MODE_PCM_SLAVE_NSTD == enWorkmode))
{
bPCMStd = HI_FALSE;
audio_ctrl.data_offset = bPCMStd;
ioctl(s_fdTlv,SET_SERIAL_DATA_OFFSET,&audio_ctrl);
}
else
{;}
/* data bit width (0:16bit 1:20bit 2:24bit 3:32bit) */
audio_ctrl.data_length = 0;
ioctl(s_fdTlv,SET_DATA_LENGTH,&audio_ctrl);
/*DACL1 TO LEFT_LOP/RIGHT_LOP VOLUME CONTROL 82 92*/
#if 1// 20180302
audio_ctrl.if_mute_route = 1;/* route*/
#else
audio_ctrl.if_mute_route = 1;/* route*/
#endif
audio_ctrl.input_level = vol; /*level control*/
printf("%d set input level =%d \n",__LINE__,vol);
ioctl(s_fdTlv,DACL1_2_LEFT_LOP_VOL_CTRL,&audio_ctrl);
ioctl(s_fdTlv,DACR1_2_RIGHT_LOP_VOL_CTRL,&audio_ctrl);
/* LEFT_LOP/RIGHT_LOP OUTPUT LEVEL CONTROL 86 93*/
audio_ctrl.if_powerup = 1;
#if 0//20180302
audio_ctrl.input_level = 0;
audio_ctrl.if_mute_route = 1;
#else
audio_ctrl.input_level = 100;
audio_ctrl.if_mute_route = 1;
printf("%d set input level =%d \n",__LINE__,audio_ctrl.input_level);
#endif
ioctl(s_fdTlv,LEFT_LOP_OUTPUT_LEVEL_CTRL,&audio_ctrl);
ioctl(s_fdTlv,RIGHT_LOP_OUTPUT_LEVEL_CTRL,&audio_ctrl);
/*config AD*/
/* LEFT/RIGHT ADC PGA GAIN CONTROL 15 16*/
#if 0//20180302
audio_ctrl.input_level = 0;
audio_ctrl.if_mute_route =0;
#else
audio_ctrl.input_level = 9;
audio_ctrl.if_mute_route =1;
printf("%d set input level =9\n",__LINE__);
#endif
ioctl(s_fdTlv,LEFT_ADC_PGA_CTRL,&audio_ctrl);
ioctl(s_fdTlv,RIGHT_ADC_PGA_CTRL,&audio_ctrl);
/*INT2L TO LEFT/RIGTH ADCCONTROL 17 18*/
#if 0//20180302
audio_ctrl.input_level = 0;
#else
audio_ctrl.input_level = 100;
printf("%d set input level =100\n",__LINE__);
#endif
ioctl(s_fdTlv,IN2LR_2_LEFT_ADC_CTRL,&audio_ctrl);
ioctl(s_fdTlv,IN2LR_2_RIGTH_ADC_CTRL,&audio_ctrl);
尝试将level从0 增加到100,还是没有放大
请问:如果放大音频输入,我需要将录制的音频流发送出去,但是现在声音太小。
(1) 使用ioctl(s32Acodec_Fd, ACODEC_SET_INPUT_VOL, &iVol 发现我的sdk工程中并没有ACODEC_SET_INPUT_VOL这个定义
(2) 使用HI_MPI_AI_SetVqeVolume() 报错没有配置vqe 不知道vqe是否可以增大音量,有没有必要配置vqe?
(3 )调节tlv320的ioctl
#if 0//20180302
audio_ctrl.if_mute_route = 0;
audio_ctrl.input_level = 0;
#else
audio_ctrl.if_mute_route = 1;
audio_ctrl.input_level = 100;
printf("mute route = 1!\n");
printf("%d set input level =%d\n",__LINE__,audio_ctrl.input_level);
#endif
ioctl(s_fdTlv,LEFT_DAC_VOL_CTRL,&audio_ctrl);
ioctl(s_fdTlv,RIGHT_DAC_VOL_CTRL,&audio_ctrl);
/*Right/Left DAC Datapath Control */
audio_ctrl.if_powerup = 1;/*Left/Right DAC datapath plays left/right channel input data*/
ioctl(s_fdTlv,LEFT_DAC_POWER_SETUP,&audio_ctrl);
if ((AIO_MODE_I2S_MASTER != enWorkmode) && (AIO_MODE_I2S_SLAVE != enWorkmode))
{
audio_ctrl.if_powerup = 0;
}
ioctl(s_fdTlv,RIGHT_DAC_POWER_SETUP,&audio_ctrl);
/* */
if ((AIO_MODE_PCM_MASTER_STD == enWorkmode)||(AIO_MODE_PCM_SLAVE_STD == enWorkmode))
{
bPCMStd = HI_TRUE;
audio_ctrl.data_offset = bPCMStd;
ioctl(s_fdTlv,SET_SERIAL_DATA_OFFSET,&audio_ctrl);
}
else if ((AIO_MODE_PCM_MASTER_NSTD == enWorkmode)||(AIO_MODE_PCM_SLAVE_NSTD == enWorkmode))
{
bPCMStd = HI_FALSE;
audio_ctrl.data_offset = bPCMStd;
ioctl(s_fdTlv,SET_SERIAL_DATA_OFFSET,&audio_ctrl);
}
else
{;}
/* data bit width (0:16bit 1:20bit 2:24bit 3:32bit) */
audio_ctrl.data_length = 0;
ioctl(s_fdTlv,SET_DATA_LENGTH,&audio_ctrl);
/*DACL1 TO LEFT_LOP/RIGHT_LOP VOLUME CONTROL 82 92*/
#if 1// 20180302
audio_ctrl.if_mute_route = 1;/* route*/
#else
audio_ctrl.if_mute_route = 1;/* route*/
#endif
audio_ctrl.input_level = vol; /*level control*/
printf("%d set input level =%d \n",__LINE__,vol);
ioctl(s_fdTlv,DACL1_2_LEFT_LOP_VOL_CTRL,&audio_ctrl);
ioctl(s_fdTlv,DACR1_2_RIGHT_LOP_VOL_CTRL,&audio_ctrl);
/* LEFT_LOP/RIGHT_LOP OUTPUT LEVEL CONTROL 86 93*/
audio_ctrl.if_powerup = 1;
#if 0//20180302
audio_ctrl.input_level = 0;
audio_ctrl.if_mute_route = 1;
#else
audio_ctrl.input_level = 100;
audio_ctrl.if_mute_route = 1;
printf("%d set input level =%d \n",__LINE__,audio_ctrl.input_level);
#endif
ioctl(s_fdTlv,LEFT_LOP_OUTPUT_LEVEL_CTRL,&audio_ctrl);
ioctl(s_fdTlv,RIGHT_LOP_OUTPUT_LEVEL_CTRL,&audio_ctrl);
/*config AD*/
/* LEFT/RIGHT ADC PGA GAIN CONTROL 15 16*/
#if 0//20180302
audio_ctrl.input_level = 0;
audio_ctrl.if_mute_route =0;
#else
audio_ctrl.input_level = 9;
audio_ctrl.if_mute_route =1;
printf("%d set input level =9\n",__LINE__);
#endif
ioctl(s_fdTlv,LEFT_ADC_PGA_CTRL,&audio_ctrl);
ioctl(s_fdTlv,RIGHT_ADC_PGA_CTRL,&audio_ctrl);
/*INT2L TO LEFT/RIGTH ADCCONTROL 17 18*/
#if 0//20180302
audio_ctrl.input_level = 0;
#else
audio_ctrl.input_level = 100;
printf("%d set input level =100\n",__LINE__);
#endif
ioctl(s_fdTlv,IN2LR_2_LEFT_ADC_CTRL,&audio_ctrl);
ioctl(s_fdTlv,IN2LR_2_RIGTH_ADC_CTRL,&audio_ctrl);
尝试将level从0 增加到100,还是没有放大
请问:如果放大音频输入,我需要将录制的音频流发送出去,但是现在声音太小。
我来回答
回答7个
时间排序
认可量排序
认可0
认可0
认可0
认可0
认可0
认可0
认可0
或将文件直接拖到这里
悬赏:
E币
网盘
* 网盘链接:
* 提取码:
悬赏:
E币
Markdown 语法
- 加粗**内容**
- 斜体*内容*
- 删除线~~内容~~
- 引用> 引用内容
- 代码`代码`
- 代码块```编程语言↵代码```
- 链接[链接标题](url)
- 无序列表- 内容
- 有序列表1. 内容
- 缩进内容
- 图片![alt](url)
相关问答
-
2018-08-15 18:45:57
-
2016-08-30 15:17:42
-
2017-11-30 09:33:31
-
2017-04-07 13:27:30
-
2019-06-24 17:40:37
-
2018-03-30 16:22:08
-
2017-04-07 13:43:32
-
2016-07-29 11:54:40
-
2017-04-18 14:29:25
-
2019-08-26 09:42:41
-
2019-12-10 14:45:18
-
2016-07-15 14:51:17
-
02017-12-06 11:42:55
-
32017-03-02 19:52:35
-
2017-04-15 15:40:34
-
2016-08-05 10:32:55
-
2016-07-28 23:37:06
-
2016-09-23 15:11:28
-
102016-10-10 16:10:19
无更多相似问答 去提问
点击登录
-- 积分
-- E币
提问
—
收益
—
被采纳
—
我要提问
切换马甲
上一页
下一页
悬赏问答
-
5SS928的emmc有32GB,bootargs设置使用16GB,但是为啥能用的只有rootfs的大小
-
33SS928怎样烧写ubuntu系统
-
10ToolPlatform下载rootfs提示网络失败
-
10谁有GK7205V500的SDK
-
5Hi3516CV610 烧录不进去
-
10Hi3559AV100 芯片硬解码h265编码格式的视频时出现视频播放错误,解码错误信息 s32PackErr:码流有错
-
5海思SS928 / SD3403的sample_venc.c摄像头编码Demo中,采集到的摄像头的YUV数据在哪个相关的函数中?
-
5海鸥派openEuler无法启动网卡,连接WIFI存在问题
-
66有没有ISP相关的巨佬帮忙看看SS928对接IMX347的图像问题
-
50求助hi3559与FPGA通过SLVS-EC接口对接问题
举报反馈
举报类型
- 内容涉黄/赌/毒
- 内容侵权/抄袭
- 政治相关
- 涉嫌广告
- 侮辱谩骂
- 其他
详细说明
提醒
你的问题还没有最佳答案,是否结题,结题后将扣除20%的悬赏金
取消
确认
提醒
你的问题还没有最佳答案,是否结题,结题后将根据回答情况扣除相应悬赏金(1回答=1E币)
取消
确认