• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ BRCM_READ_REG函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中BRCM_READ_REG函数的典型用法代码示例。如果您正苦于以下问题:C++ BRCM_READ_REG函数的具体用法?C++ BRCM_READ_REG怎么用?C++ BRCM_READ_REG使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了BRCM_READ_REG函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: chal_audio_earpath_clear_isolation_ctrl

/*============================================================================
*
* Function Name: cVoid chal_audio_earpath_clear_isolation_ctrl(
* CHAL_HANDLE handle, cUInt16 sr_ctrl)
*
* Description:  Clear AudioTx isolation Controls
*
* Parameters:   handle - audio chal handle.
*                      sr_ctrl - isolation controls.
* Should be one of the combinations of CHAL_AUDIO_AUDIOTX_ISO_XXXX
*
* Return:       None.
*
*============================================================================*/
cVoid chal_audio_earpath_clear_isolation_ctrl(CHAL_HANDLE handle,
					      cUInt16 iso_ctrl)
{
	cUInt32 base = ((ChalAudioCtrlBlk_t *) handle)->audioh_base;
	cUInt32 reg_value;

	/* Get the current setting  */
	reg_value = BRCM_READ_REG(base, AUDIOH_AUDIOTX_ISO);

	reg_value &= ~(iso_ctrl & CHAL_AUDIO_AUXIOTX_ISO_CTRL_MASK);

	/* Set the required setting */
	BRCM_WRITE_REG(base, AUDIOH_AUDIOTX_ISO, reg_value);

	return;
}
开发者ID:faizauthar12,项目名称:Hyper_kernel,代码行数:30,代码来源:chal_caph_audioh_vout.c


示例2: chal_audio_stpath_clr_fifo

cVoid chal_audio_stpath_clr_fifo(CHAL_HANDLE handle)
{
	cUInt32 reg_val;
	cUInt32 base = ((ChalAudioCtrlBlk_t *) handle)->sdt_base;

	reg_val = BRCM_READ_REG(base, SDT_SDT_CTRL_3);
	reg_val |= SDT_SDT_CTRL_3_FIFO_RESET_MASK;
	/* Set the required setting */
	BRCM_WRITE_REG(base, SDT_SDT_CTRL_3, reg_val);

	reg_val &= ~SDT_SDT_CTRL_3_FIFO_RESET_MASK;
	/* Set the required setting */
	BRCM_WRITE_REG(base, SDT_SDT_CTRL_3, reg_val);

	return;
}
开发者ID:faizauthar12,项目名称:Hyper_kernel,代码行数:16,代码来源:chal_caph_audioh_sidetone.c


示例3: chal_audio_mic_pga

 /* function name changed from chal_audio_mic_pga_set_gain */
void chal_audio_mic_pga(CHAL_HANDLE handle, cUInt32 gain_regval)
{
	cUInt32 base = ((ChalAudioCtrlBlk_t *)handle)->audioh_base;
	cUInt32 reg_val;

	reg_val = BRCM_READ_REG(base, AUDIOH_AUDIORX_VRX1);
	reg_val &= ~AUDIOH_AUDIORX_VRX1_AUDIORX_VRX_GAINCTRL_MASK;

	if (gain_regval > 0x3f)
		gain_regval = 0x3f;

	reg_val |= (gain_regval
		<< AUDIOH_AUDIORX_VRX1_AUDIORX_VRX_GAINCTRL_SHIFT);

	BRCM_WRITE_REG(base, AUDIOH_AUDIORX_VRX1, reg_val);
}
开发者ID:TheNikiz,项目名称:android_kernel_samsung_hawaii,代码行数:17,代码来源:chal_analogmic.c


示例4: chal_audio_mic_mute

/*============================================================================
*
* Function Name: chal_audio_mic_mute(CHAL_HANDLE handle,  Boolean mute_ctrl)
*
* Description:  Mute the ANALOG MIC and AUX MIC signals on the DATA line
*
* Parameters:   handle      : the voice input path handle.
*               mute_ctrl   : mute control
*
* Return:       None.
*
*============================================================================*/
cVoid chal_audio_mic_mute(CHAL_HANDLE handle, Boolean mute_ctrl)
{
	cUInt32 base = ((ChalAudioCtrlBlk_t *) handle)->audioh_base;
	cUInt32 reg_val;

	reg_val = BRCM_READ_REG(base, AUDIOH_AUDIORX_VRX1);
	reg_val &= ~(AUDIOH_AUDIORX_VRX1_AUDIORX_VRX_ADCRST_MASK);

	if (mute_ctrl == TRUE)
		reg_val |= AUDIOH_AUDIORX_VRX1_AUDIORX_VRX_ADCRST_MASK;
	else
		reg_val &= ~(AUDIOH_AUDIORX_VRX1_AUDIORX_VRX_ADCRST_MASK);

	BRCM_WRITE_REG(base, AUDIOH_AUDIORX_VRX1, reg_val);

}
开发者ID:ASAZING,项目名称:Android-Kernel-Gt-s7390l,代码行数:28,代码来源:chal_caph_audioh_analogmic.c


示例5: chal_audio_ihfpath_eanc_in

cVoid chal_audio_ihfpath_eanc_in(CHAL_HANDLE handle, cUInt16 enable )
{
    cUInt32 base =    ((ChalAudioCtrlBlk_t*)handle)->audioh_base;
    cUInt32     eanc_ctrl;

    // Set the required settings
    eanc_ctrl = BRCM_READ_REG(base, AUDIOH_EANC_CTL);
    eanc_ctrl &= (~AUDIOH_EANC_CTL_IHF_EANC_ENABLE_MASK);
    if(enable == CHAL_AUDIO_ENABLE)
    {
        eanc_ctrl |= AUDIOH_EANC_CTL_IHF_EANC_ENABLE_MASK;
    }
    BRCM_WRITE_REG(base, AUDIOH_EANC_CTL, eanc_ctrl);

   return;
}
开发者ID:Astinj,项目名称:Kernel_GT-S5830C,代码行数:16,代码来源:chal_ihf.c


示例6: chal_audio_vinpath_clr_fifo

void chal_audio_vinpath_clr_fifo(CHAL_HANDLE handle)
{
    cUInt32     reg_val;
    cUInt32 base =    ((ChalAudioCtrlBlk_t*)handle)->audioh_base;

    reg_val = BRCM_READ_REG(base, AUDIOH_VIN_FIFO_CTRL);
    reg_val |= AUDIOH_VIN_FIFO_CTRL_VIN_FIFO_CLEAR_MASK;
    /* Set the required setting */
    BRCM_WRITE_REG(base,  AUDIOH_VIN_FIFO_CTRL, reg_val);

    reg_val &= ~AUDIOH_VIN_FIFO_CTRL_VIN_FIFO_CLEAR_MASK;
    /* Set the required setting */
    BRCM_WRITE_REG(base,  AUDIOH_VIN_FIFO_CTRL, reg_val);

    return;
}
开发者ID:ASAZING,项目名称:Android-Kernel-Gt-s7390l,代码行数:16,代码来源:chal_vin.c


示例7: chal_audio_hspath_sdm_is_dither_enabled

/*
 * ============================================================================
 *
 *	Function Name:
 *	chal_audio_hspath_sdm_is_dither_enabled(CHAL_HANDLE handle)
 *
 *	Description:  Check if dither to sigma delta module on headset path
 *	enabled
 *
 *	Parameters:   handle - audio chal handle.
 *
 *	 Return:
 *		enable : bit 1 for right channel enable/disable
 *		enable : bit 0 for left channel enable/disable
 *
 * ============================================================================
 */
cUInt16 chal_audio_hspath_sdm_is_dither_enabled(CHAL_HANDLE handle)
{
    cUInt32 reg_val;
    cUInt32 base = ((ChalAudioCtrlBlk_t *)handle)->audioh_base;
    cUInt16 ret = 0;

    reg_val = BRCM_READ_REG(base, AUDIOH_SDM_DITHER_CTL);

    if (reg_val & AUDIOH_SDM_DITHER_CTL_STEREO_DITHER_EN_L_MASK)
        ret |= AUDIOH_SDM_DITHER_CTL_STEREO_DITHER_EN_L_MASK;

    if (reg_val & AUDIOH_SDM_DITHER_CTL_STEREO_DITHER_EN_R_MASK)
        ret |= AUDIOH_SDM_DITHER_CTL_STEREO_DITHER_EN_R_MASK;

    return ret;
}
开发者ID:TheNikiz,项目名称:android_kernel_samsung_hawaii,代码行数:33,代码来源:chal_hs.c


示例8: chal_audio_earpath_sidetone_in

cVoid chal_audio_earpath_sidetone_in(CHAL_HANDLE handle, cUInt16 enable )
{

    cUInt32 base =    ((ChalAudioCtrlBlk_t*)handle)->audioh_base;
    cUInt32     reg_val = 0;

    reg_val = BRCM_READ_REG(base, AUDIOH_DAC_CTL);
    reg_val &= (~AUDIOH_DAC_CTL_VOUT_SIDETONE_EN_MASK);
    if(enable == CHAL_AUDIO_ENABLE)
    {
        reg_val |= AUDIOH_DAC_CTL_VOUT_SIDETONE_EN_MASK;
    }
    BRCM_WRITE_REG(base, AUDIOH_DAC_CTL, reg_val);

    return;
}
开发者ID:Ashutos97,项目名称:GT-S5360-opensource-Update-2,代码行数:16,代码来源:chal_vout.c


示例9: chal_audio_hspath_set_filter

/*============================================================================
*
* Function Name: cVoid chal_audio_hspath_set_filter(CHAL_HANDLE handle,
* cUInt16 filter)
*
* Description:  set Filter type for the heaset  path
*
* Parameters:   handle    - audio chal handle.
*                 filter    -  0: Linear Phase, 1 Minimum Phase
* Return:       None.
*
*============================================================================*/
cVoid chal_audio_hspath_set_filter(CHAL_HANDLE handle, cUInt16 filter)
{
	cUInt32 base = ((ChalAudioCtrlBlk_t *) handle)->audioh_base;
	cUInt32 reg_val;

	reg_val = BRCM_READ_REG(base, AUDIOH_MIN_PHASE);
	reg_val &= ~(AUDIOH_MIN_PHASE_HS_MIN_PHASE_MASK);

	if (filter & CHAL_AUDIO_MINIMUM_PHASE_FILTER)
		reg_val |= AUDIOH_MIN_PHASE_HS_MIN_PHASE_MASK;

	/* Set the required setting */
	BRCM_WRITE_REG(base, AUDIOH_MIN_PHASE, reg_val);

	return;
}
开发者ID:ASAZING,项目名称:Android-Kernel-Gt-s7390l,代码行数:28,代码来源:chal_caph_audioh_hs.c


示例10: chal_audio_earpath_set_gain

cVoid chal_audio_earpath_set_gain(CHAL_HANDLE handle, cUInt32 gain)
{
    cUInt32     reg_val;
    cUInt32     base =    ((ChalAudioCtrlBlk_t*)handle)->audioh_base;

    reg_val = BRCM_READ_REG(base, AUDIOH_EP_DAC_CTRL);

    /* Mask the gain bits */
    reg_val &= 0xFE7FFFFF;
    reg_val |= ((gain&0x03) << 23);

    /* Set the required setting */
    BRCM_WRITE_REG(base,  AUDIOH_EP_DAC_CTRL, reg_val);

    return;
}
开发者ID:Ashutos97,项目名称:GT-S5360-opensource-Update-2,代码行数:16,代码来源:chal_vout.c


示例11: chal_audio_ihfpath_set_fifo_thres

cVoid chal_audio_ihfpath_set_fifo_thres(CHAL_HANDLE handle, cUInt16 thres, cUInt16 thres_2)
{
    cUInt32     reg_val;
    cUInt32 base =    ((ChalAudioCtrlBlk_t*)handle)->audioh_base;

    reg_val = BRCM_READ_REG(base, AUDIOH_IHF_FIFO_CTRL);
    reg_val &= ~(0x7F);
    reg_val &= ~(0xF0);
    reg_val |= thres;
    reg_val |= thres_2 << 8;

    /* Set the required setting */
    BRCM_WRITE_REG(base,  AUDIOH_IHF_FIFO_CTRL, reg_val);

    return;
}
开发者ID:Astinj,项目名称:Kernel_GT-S5830C,代码行数:16,代码来源:chal_ihf.c


示例12: chal_audio_nvinpath_set_fifo_thres

void chal_audio_nvinpath_set_fifo_thres(CHAL_HANDLE handle, cUInt16 thres, cUInt16 thres_2 )
{
    cUInt32     reg_val;
    cUInt32 base =    ((ChalAudioCtrlBlk_t*)handle)->audioh_base;

    reg_val = BRCM_READ_REG(base, AUDIOH_NVIN_FIFO_CTRL);
    reg_val &= ~(AUDIOH_NVIN_FIFO_CTRL_NVIN_FIFO_THRES_MASK);
    reg_val &= ~(AUDIOH_NVIN_FIFO_CTRL_NVIN_FIFO_THRES2_MASK);
    reg_val |= thres;
    reg_val |= thres_2 << AUDIOH_NVIN_FIFO_CTRL_NVIN_FIFO_THRES2_SHIFT;

    /* Set the required setting */
    BRCM_WRITE_REG(base,  AUDIOH_NVIN_FIFO_CTRL, reg_val);

    return;
}
开发者ID:ASAZING,项目名称:Android-Kernel-Gt-s7390l,代码行数:16,代码来源:chal_nvin.c


示例13: chal_audio_hspath_set_bits_per_sample

cVoid chal_audio_hspath_set_bits_per_sample(CHAL_HANDLE handle, cUInt16 bits)
{
	cUInt32 reg_val;
	cUInt32 base = ((ChalAudioCtrlBlk_t *) handle)->audioh_base;

	reg_val = BRCM_READ_REG(base, AUDIOH_STEREO_FIFO_CTRL);

	if (bits >= 24)
		reg_val |= AUDIOH_STEREO_FIFO_CTRL_STEREO_FIFO_24BIT_MASK;
	else
		reg_val &= ~AUDIOH_STEREO_FIFO_CTRL_STEREO_FIFO_24BIT_MASK;

	/* Set the required setting */
	BRCM_WRITE_REG(base, AUDIOH_STEREO_FIFO_CTRL, reg_val);

	return;
}
开发者ID:ASAZING,项目名称:Android-Kernel-Gt-s7390l,代码行数:17,代码来源:chal_caph_audioh_hs.c


示例14: chal_audio_hspath_dma_enable

/*============================================================================
*
* Function Name: cVoid chal_audio_hspath_dma_enable(CHAL_HANDLE handle,
* cUInt16 dma_enable)
*
* Description:  Enable or Disable DMA on headset path
*
* Parameters:   handle     - audio chal handle.
*                 dma_enable - true: enable DMA, false : disable DMA.
* Return:       None.
*
*============================================================================*/
cVoid chal_audio_hspath_dma_enable(CHAL_HANDLE handle, Boolean dma_enable)
{
	cUInt32 base = ((ChalAudioCtrlBlk_t *) handle)->audioh_base;
	cUInt32 reg_val;

	reg_val = BRCM_READ_REG(base, AUDIOH_DMA_CTL);

	if (dma_enable)
		reg_val |= AUDIOH_DMA_CTL_STEREO_DMA_EN_MASK;
	else
		reg_val &= ~AUDIOH_DMA_CTL_STEREO_DMA_EN_MASK;

	/* Set the required setting */
	BRCM_WRITE_REG(base, AUDIOH_DMA_CTL, reg_val);

	return;
}
开发者ID:ASAZING,项目名称:Android-Kernel-Gt-s7390l,代码行数:29,代码来源:chal_caph_audioh_hs.c


示例15: chal_audio_eancpath_set_mode

void chal_audio_eancpath_set_mode(CHAL_HANDLE handle, _Bool mode)
{
    cUInt32 base =    ((ChalAudioCtrlBlk_t*)handle)->audioh_base;
    cUInt32     eanc_ctrl;

    eanc_ctrl = BRCM_READ_REG(base, AUDIOH_EANC_CTL);

    eanc_ctrl &= (~AUDIOH_EANC_CTL_EANC_MODE96K_MASK);

    if(mode == CHAL_AUDIO_ENABLE)
    {
        eanc_ctrl |= (AUDIOH_EANC_CTL_EANC_MODE96K_MASK);
    }
    BRCM_WRITE_REG(base, AUDIOH_EANC_CTL, eanc_ctrl);

    return;
}
开发者ID:ASAZING,项目名称:Android-Kernel-Gt-s7390l,代码行数:17,代码来源:chal_eanc.c


示例16: chal_audio_hspath_set_pack

cVoid chal_audio_hspath_set_pack(CHAL_HANDLE handle, Boolean pack)
{
	cUInt32 reg_val;
	cUInt32 base = ((ChalAudioCtrlBlk_t *) handle)->audioh_base;

	reg_val = BRCM_READ_REG(base, AUDIOH_STEREO_FIFO_CTRL);

	if (pack == CHAL_AUDIO_ENABLE)
		reg_val |= AUDIOH_STEREO_FIFO_CTRL_STEREO_FIFO_PACK_MASK;
	else
		reg_val &= ~AUDIOH_STEREO_FIFO_CTRL_STEREO_FIFO_PACK_MASK;

	/* Set the required setting */
	BRCM_WRITE_REG(base, AUDIOH_STEREO_FIFO_CTRL, reg_val);

	return;
}
开发者ID:ASAZING,项目名称:Android-Kernel-Gt-s7390l,代码行数:17,代码来源:chal_caph_audioh_hs.c


示例17: chal_audio_enable_adc_paths

void chal_audio_enable_adc_paths(CHAL_HANDLE handle, cUInt32 adc_mask, cUInt16 enable)
{
    cUInt32     reg_val;
    cUInt32     reg_adc_mask = 0;
    cUInt32 base =    ((ChalAudioCtrlBlk_t*)handle)->audioh_base;


    if((adc_mask&CHAL_AUDIO_PATH_AMIC1) || (adc_mask&CHAL_AUDIO_PATH_AMIC2))
    {
        reg_adc_mask |= AUDIOH_ADC_CTL_AMIC_EN_MASK;
    }

    if(adc_mask& CHAL_AUDIO_PATH_DMIC1)
    {
        reg_adc_mask |= AUDIOH_ADC_CTL_DMIC1_EN_MASK;
    }

    if(adc_mask& CHAL_AUDIO_PATH_DMIC2)
    {
        reg_adc_mask |= AUDIOH_ADC_CTL_DMIC2_EN_MASK;
    }

    if(adc_mask&CHAL_AUDIO_PATH_DMIC3)
    {
        reg_adc_mask |= AUDIOH_ADC_CTL_DMIC3_EN_MASK;
    }

    if(adc_mask&CHAL_AUDIO_PATH_DMIC4)
    {
        reg_adc_mask |= AUDIOH_ADC_CTL_DMIC4_EN_MASK;
    }

    /*
     *  Enable/Disable the DAC Paths.
     * It is necessary to enable all the paths at the same time
     */
    reg_val = BRCM_READ_REG(base, AUDIOH_ADC_CTL);
    reg_val &= (~reg_adc_mask);
    if(enable == CHAL_AUDIO_ENABLE)
    {
        reg_val |= reg_adc_mask;
    }
    BRCM_WRITE_REG(base, AUDIOH_ADC_CTL, reg_val);

    return;
}
开发者ID:emreharbutoglu,项目名称:i9105Sammy,代码行数:46,代码来源:chal_analogtest.c


示例18: chal_audio_hspath_mute

cVoid chal_audio_hspath_mute(CHAL_HANDLE handle, Boolean mute)
{
	cUInt32 reg_val;
	cUInt32 base = ((ChalAudioCtrlBlk_t *) handle)->audioh_base;

	reg_val = BRCM_READ_REG(base, AUDIOH_DAC_CTL);

	if (mute == CHAL_AUDIO_ENABLE)
		reg_val |= AUDIOH_DAC_CTL_STEREO_MUTE_MASK;
	else
		reg_val &= ~AUDIOH_DAC_CTL_STEREO_MUTE_MASK;

	/* Set the required setting */
	BRCM_WRITE_REG(base, AUDIOH_DAC_CTL, reg_val);

	return;
}
开发者ID:ASAZING,项目名称:Android-Kernel-Gt-s7390l,代码行数:17,代码来源:chal_caph_audioh_hs.c


示例19: chal_audio_hspath_set_mono_stereo

void chal_audio_hspath_set_mono_stereo(CHAL_HANDLE handle, _Bool mode)
{
    cUInt32     reg_val;
    cUInt32 base = ((ChalAudioCtrlBlk_t *)handle)->audioh_base;

    reg_val = BRCM_READ_REG(base, AUDIOH_STEREO_FIFO_CTRL);

    if (mode == CHAL_AUDIO_ENABLE)
        reg_val |= AUDIOH_STEREO_FIFO_CTRL_STEREO_FIFO_MONO_MASK;
    else /* stereo */
        reg_val &= ~AUDIOH_STEREO_FIFO_CTRL_STEREO_FIFO_MONO_MASK;

    /* Set the required setting */
    BRCM_WRITE_REG(base,  AUDIOH_STEREO_FIFO_CTRL, reg_val);

    return;
}
开发者ID:TheNikiz,项目名称:android_kernel_samsung_hawaii,代码行数:17,代码来源:chal_hs.c


示例20: chal_audio_stpath_set_fifo_thres

cVoid chal_audio_stpath_set_fifo_thres(CHAL_HANDLE handle, cUInt16 thres,
				       cUInt16 thres_2)
{
	cUInt32 reg_val;
	cUInt32 base = ((ChalAudioCtrlBlk_t *) handle)->sdt_base;

	reg_val = BRCM_READ_REG(base, SDT_SDT_CTRL_3);
	reg_val &= ~(SDT_SDT_CTRL_3_THRES_MASK);
	reg_val &= ~(SDT_SDT_CTRL_3_THRES2_MASK);
	reg_val |= thres << SDT_SDT_CTRL_3_THRES_SHIFT;
	reg_val |= thres_2 << SDT_SDT_CTRL_3_THRES2_SHIFT;

	/* Set the required setting */
	BRCM_WRITE_REG(base, SDT_SDT_CTRL_3, reg_val);

	return;
}
开发者ID:faizauthar12,项目名称:Hyper_kernel,代码行数:17,代码来源:chal_caph_audioh_sidetone.c



注:本文中的BRCM_READ_REG函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ BRCM_WRITE_REG函数代码示例发布时间:2022-05-30
下一篇:
C++ BRANCH函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap