amfm 2.0.0.0
amfm.h File Reference

This file contains API for AMFM Click driver. More...

#include "drv_digital_out.h"
#include "drv_digital_in.h"
#include "drv_i2c_master.h"

Go to the source code of this file.

Data Structures

struct  amfm_t
 Click ctx object definition. More...
 
struct  amfm_cfg_t
 Click configuration structure definition. More...
 

Macros

#define AMFM_MAP_MIKROBUS(cfg, mikrobus)
 
#define AMFM_OK   0
 
#define AMFM_ERROR   -1
 
#define AMFM_DEVICE_ADDRESS   0x11
 
#define AMFM_CMD_PWRUP   0x01
 
#define AMFM_CMD_GETREV   0x10
 
#define AMFM_CMD_PWRDOWN   0x11
 
#define AMFM_CMD_SETPROP   0x12
 
#define AMFM_CMD_GETPROP   0x13
 
#define AMFM_CMD_GETINTSTATUS   0x14
 
#define AMFM_CMD_PATCHARGS   0x15
 
#define AMFM_CMD_PATCHDATA   0x16
 
#define AMFM_CMD_GPIOCTL   0x80
 
#define AMFM_CMD_GPIOSET   0x81
 
#define AMFM_CMD_AMTUNEFREQ   0x40
 
#define AMFM_CMD_AMSEEKSTART   0x41
 
#define AMFM_CMD_AMTUNESTATUS   0x42
 
#define AMFM_CMD_AMRSQSTATUS   0x43
 
#define AMFM_CMD_AMAGCSTATUS   0x47
 
#define AMFM_CMD_AMAGCOVERRIDE   0x48
 
#define AMFM_CMD_FMTUNEFREQ   0x20
 
#define AMFM_CMD_FMSEEKSTART   0x21
 
#define AMFM_CMD_FMTUNESTATUS   0x22
 
#define AMFM_CMD_FMRSQSTATUS   0x23
 
#define AMFM_CMD_FMRDSSTATUS   0x24
 
#define AMFM_CMD_FMAGCSTATUS   0x27
 
#define AMFM_CMD_FMAGCOVERRIDE   0x28
 
#define AMFM_PWRUP_ARG1_CTSIEN   0x80
 
#define AMFM_PWRUP_ARG1_GPO2OEN   0x40
 
#define AMFM_PWRUP_ARG1_PATCH   0x20
 
#define AMFM_PWRUP_ARG1_XOSCEN   0x10
 
#define AMFM_PWRUP_ARG1_FUNC_FMRECEIVE   0x00
 
#define AMFM_PWRUP_ARG1_FUNC_QUERYLIBID   0x0F
 
#define AMFM_PWRUP_ARG2_OPMODE_ANALOGOUT   0x05
 
#define AMFM_PWRUP_ARG2_OPMODE_DIGITALOUT   0x0B
 
#define AMFM_PWRUP_ARG2_OPMODE_DIGITALOUTS   0xB0
 
#define AMFM_PWRUP_ARG2_OPMODE_ANALOGDIGITALOUTS   0xB5
 
#define AMFM_FMTUNEFREQ_ARG1_FREEZE   0x02
 
#define AMFM_FMTUNEFREQ_ARG1_FAST   0x01
 
#define AMFM_FMSEEKSTART_ARG1_SEEKUP   0x08
 
#define AMFM_FMSEEKSTART_ARG1_WRAP   0x04
 
#define AMFM_FMTUNESTATUS_ARG1_CANCEL   0x02
 
#define AMFM_FMTUNESTATUS_ARG1_INTACK   0x01
 
#define AMFM_FMRSQSTATUS_ARG1_INTACK   0x01
 
#define AMFM_FMRDSSTATUS_ARG1_STATUSONLY   0x04
 
#define AMFM_FMRDSSTATUS_ARG1_MTFIFO   0x02
 
#define AMFM_FMRDSSTATUS_ARG1_INTACK   0x01
 
#define AMFM_FMAGCOVERRIDE_ARG1_RFAGCDIS   0x01
 
#define AMFM_GPIOCTL_ARG1_GPO3OEN   0x08
 
#define AMFM_GPIOCTL_ARG1_GPO2OEN   0x04
 
#define AMFM_GPIOCTL_ARG1_GPO1OEN   0x02
 
#define AMFM_GPIOSET_ARG1_GPO3LEVEL   0x08
 
#define AMFM_GPIOSET_ARG1_GPO2LEVEL   0x04
 
#define AMFM_GPIOSET_ARG1_GPO1LEVEL   0x02
 
#define AMFM_PROP_GPOIEN_H   0x00
 
#define AMFM_PROP_GPOIEN_L   0x01
 
#define AMFM_PROP_DIGITALOUTFORMAT_H   0x01
 
#define AMFM_PROP_DIGITALOUTFORMAT_L   0x02
 
#define AMFM_PROP_DIGITALOUTSAMPLERATE_H   0x01
 
#define AMFM_PROP_DIGITALOUTSAMPLERATE_L   0x04
 
#define AMFM_PROP_REFCLKFREQ_H   0x02
 
#define AMFM_PROP_REFCLKFREQ_L   0x01
 
#define AMFM_PROP_REFCLKPRESCALE_H   0x02
 
#define AMFM_PROP_REFCLKPRESCALE_L   0x02
 
#define AMFM_PROP_RXVOLUME_H   0x40
 
#define AMFM_PROP_RXVOLUME_L   0x00
 
#define AMFM_PROP_RXHMUTE_H   0x40
 
#define AMFM_PROP_RXHMUTE_L   0x01
 
#define AMFM_PROP_FMDEEMPHASIS_H   0x11
 
#define AMFM_PROP_FMDEEMPHASIS_L   0x00
 
#define AMFM_PROP_AMDEEMPHASIS_H   0x31
 
#define AMFM_PROP_AMDEEMPHASIS_L   0x00
 
#define AMFM_PROP_FMCHANFILTER_H   0x11
 
#define AMFM_PROP_FMCHANFILTER_L   0x02
 
#define AMFM_PROP_AMCHANFILTER_H   0x31
 
#define AMFM_PROP_AMCHANFILTER_L   0x02
 
#define AMFM_PROP_AMAUTOVOLCTRLMAXGAIN_H   0x31
 
#define AMFM_PROP_AMAUTOVOLCTRLMAXGAIN_L   0x03
 
#define AMFM_PROP_AMMODEAFCSWPULLINRANGE_H   0x31
 
#define AMFM_PROP_AMMODEAFCSWPULLINRANGE_L   0x04
 
#define AMFM_PROP_AMMODEAFCSWLOCKINRANGE_H   0x31
 
#define AMFM_PROP_AMMODEAFCSWLOCKINRANGE_L   0x05
 
#define AMFM_PROP_AMRSQINTS_H   0x32
 
#define AMFM_PROP_AMRSQINTS_L   0x00
 
#define AMFM_PROP_AMRSQSNRHITHS_H   0x32
 
#define AMFM_PROP_AMRSQSNRHITHS_L   0x01
 
#define AMFM_PROP_AMRSQSNRLOTHS_H   0x32
 
#define AMFM_PROP_AMRSQSNRLOTHS_L   0x02
 
#define AMFM_PROP_AMRSQRSSIHITHS_H   0x32
 
#define AMFM_PROP_AMRSQRSSIHITHS_L   0x03
 
#define AMFM_PROP_AMRSQRSSILOTHS_H   0x32
 
#define AMFM_PROP_AMRSQRSSILOTHS_L   0x04
 
#define AMFM_PROP_AMSMUTERATE_H   0x33
 
#define AMFM_PROP_AMSMUTERATE_L   0x00
 
#define AMFM_PROP_AMSMUTESLOPE_H   0x33
 
#define AMFM_PROP_AMSMUTESLOPE_L   0x01
 
#define AMFM_PROP_AMSMUTEMAXATTENUATION_H   0x33
 
#define AMFM_PROP_AMSMUTEMAXATTENUATION_L   0x02
 
#define AMFM_PROP_AMSMUTESNRTHS_H   0x33
 
#define AMFM_PROP_AMSMUTESNRTHS_L   0x03
 
#define AMFM_PROP_AMSMUTERELEASERATE_H   0x33
 
#define AMFM_PROP_AMSMUTERELEASERATE_L   0x04
 
#define AMFM_PROP_AMSMUTEATTACKRATE_H   0x33
 
#define AMFM_PROP_AMSMUTEATTACKRATE_L   0x05
 
#define AMFM_PROP_AMSEEKBANDBOT_H   0x34
 
#define AMFM_PROP_AMSEEKBANDBOT_L   0x00
 
#define AMFM_PROP_AMSEEKBANDTOP_H   0x34
 
#define AMFM_PROP_AMSEEKBANDTOP_L   0x01
 
#define AMFM_PROP_AMSEEKFREQSPACING_H   0x34
 
#define AMFM_PROP_AMSEEKFREQSPACING_L   0x02
 
#define AMFM_PROP_AMSEEKTUNESNRTHS_H   0x34
 
#define AMFM_PROP_AMSEEKTUNESNRTHS_L   0x03
 
#define AMFM_PROP_AMSEEKTUNERSSITHS_H   0x34
 
#define AMFM_PROP_AMSEEKTUNERSSITHS_L   0x04
 
#define AMFM_PROP_AMAGCATTACKRATE_H   0x37
 
#define AMFM_PROP_AMAGCATTACKRATE_L   0x02
 
#define AMFM_PROP_AMAGCRELEASERATE_H   0x37
 
#define AMFM_PROP_AMAGCRELEASERATE_L   0x03
 
#define AMFM_PROP_AMFRONTENDAGCCTRL_H   0x37
 
#define AMFM_PROP_AMFRONTENDAGCCTRL_L   0x05
 
#define AMFM_PROP_AMNBDETECTTHS_H   0x39
 
#define AMFM_PROP_AMNBDETECTTHS_L   0x00
 
#define AMFM_PROP_AMNBINTERVAL_H   0x39
 
#define AMFM_PROP_AMNBINTERVAL_L   0x01
 
#define AMFM_PROP_AMNBRATE_H   0x39
 
#define AMFM_PROP_AMNBRATE_L   0x02
 
#define AMFM_PROP_AMNBIIRFILTER_H   0x39
 
#define AMFM_PROP_AMNBIIRFILTER_L   0x03
 
#define AMFM_PROP_AMNBDELAY_H   0x39
 
#define AMFM_PROP_AMNBDELAY_L   0x04
 
#define AMFM_PROP_FMBLENDSTEREOTHS_H   0x11
 
#define AMFM_PROP_FMBLENDSTEREOTHS_L   0x05
 
#define AMFM_PROP_FMBLENDMONOTHS_H   0x11
 
#define AMFM_PROP_FMBLENDMONOTHS_L   0x06
 
#define AMFM_PROP_FMANTENNAIN_H   0x11
 
#define AMFM_PROP_FMANTENNAIN_L   0x07
 
#define AMFM_PROP_FMMAXTUNEERR_H   0x11
 
#define AMFM_PROP_FMMAXTUNEERR_L   0x08
 
#define AMFM_PROP_FMRSQINTSRC_H   0x12
 
#define AMFM_PROP_FMRSQINTSRC_L   0x00
 
#define AMFM_PROP_FMRSQSNRHITHS_H   0x12
 
#define AMFM_PROP_FMRSQSNRHITHS_L   0x01
 
#define AMFM_PROP_FMRSQSNRLOTHS_H   0x12
 
#define AMFM_PROP_FMRSQSNRLOTHS_L   0x02
 
#define AMFM_PROP_FMRSQRSSIHITHS_H   0x12
 
#define AMFM_PROP_FMRSQRSSIHITHS_L   0x03
 
#define AMFM_PROP_FMRSQRSSILOTHS_H   0x12
 
#define AMFM_PROP_FMRSQRSSILOTHS_L   0x04
 
#define AMFM_PROP_FMRSQMULTIPATHHITHS_H   0x12
 
#define AMFM_PROP_FMRSQMULTIPATHHITHS_L   0x05
 
#define AMFM_PROP_FMRSQMULTIPATHLOTHS_H   0x12
 
#define AMFM_PROP_FMRSQMULTIPATHLOTHS_L   0x06
 
#define AMFM_PROP_FMRSQBLENDTHS_H   0x12
 
#define AMFM_PROP_FMRSQBLENDTHS_L   0x07
 
#define AMFM_PROP_FMSMUTERATE_H   0x13
 
#define AMFM_PROP_FMSMUTERATE_L   0x00
 
#define AMFM_PROP_FMSMUTESLOPE_H   0x13
 
#define AMFM_PROP_FMSMUTESLOPE_L   0x01
 
#define AMFM_PROP_FMSMUTEMAXATTENUATION_H   0x13
 
#define AMFM_PROP_FMSMUTEMAXATTENUATION_L   0x02
 
#define AMFM_PROP_FMSMUTESNRTHS_H   0x13
 
#define AMFM_PROP_FMSMUTESNRTHS_L   0x03
 
#define AMFM_PROP_FMSMUTERELEASERATE_H   0x13
 
#define AMFM_PROP_FMSMUTERELEASERATE_L   0x04
 
#define AMFM_PROP_FMSMUTEATTACKRATE_H   0x13
 
#define AMFM_PROP_FMSMUTEATTACKRATE_L   0x05
 
#define AMFM_PROP_FMSEEKBANDBOT_H   0x14
 
#define AMFM_PROP_FMSEEKBANDBOT_L   0x00
 
#define AMFM_PROP_FMSEEKBANDTOP_H   0x14
 
#define AMFM_PROP_FMSEEKBANDTOP_L   0x01
 
#define AMFM_PROP_FMSEEKFREQSPACING_H   0x14
 
#define AMFM_PROP_FMSEEKFREQSPACING_L   0x02
 
#define AMFM_PROP_FMSEEKTUNESNRTHS_H   0x14
 
#define AMFM_PROP_FMSEEKTUNESNRTHS_L   0x03
 
#define AMFM_PROP_FMSEEKTUNERSSITHS_H   0x14
 
#define AMFM_PROP_FMSEEKTUNERSSITHS_L   0x04
 
#define AMFM_PROP_FMRDSINTSRC_H   0x15
 
#define AMFM_PROP_FMRDSINTSRC_L   0x00
 
#define AMFM_PROP_FMRDSINTFIFOCOUNT_H   0x15
 
#define AMFM_PROP_FMRDSINTFIFOCOUNT_L   0x01
 
#define AMFM_PROP_FMRDSCFG_H   0x15
 
#define AMFM_PROP_FMRDSCFG_L   0x02
 
#define AMFM_PROP_FMRDSCONFIDENCE_H   0x15
 
#define AMFM_PROP_FMRDSCONFIDENCE_L   0x03
 
#define AMFM_PROP_FMAGCATTACKRATE_H   0x17
 
#define AMFM_PROP_FMAGCATTACKRATE_L   0x00
 
#define AMFM_PROP_FMAGCRELEASERATE_H   0x17
 
#define AMFM_PROP_FMAGCRELEASERATE_L   0x01
 
#define AMFM_PROP_FMBLENDRSSISTEREOTHS_H   0x18
 
#define AMFM_PROP_FMBLENDRSSISTEREOTHS_L   0x00
 
#define AMFM_PROP_FMBLENDRSSIMONOTHS_H   0x18
 
#define AMFM_PROP_FMBLENDRSSIMONOTHS_L   0x01
 
#define AMFM_PROP_FMBLENDRSSIATTACKRATE_H   0x18
 
#define AMFM_PROP_FMBLENDRSSIATTACKRATE_L   0x02
 
#define AMFM_PROP_FMBLENDRSSIRELEASERATE_H   0x18
 
#define AMFM_PROP_FMBLENDRSSIRELEASERATE_L   0x03
 
#define AMFM_PROP_FMBLENDSNRSTEREOTHS_H   0x18
 
#define AMFM_PROP_FMBLENDSNRSTEREOTHS_L   0x04
 
#define AMFM_PROP_FMBLENDSNRMONOTHS_H   0x18
 
#define AMFM_PROP_FMBLENDSNRMONOTHS_L   0x05
 
#define AMFM_PROP_FMBLENDSNRATTACKRATE_H   0x18
 
#define AMFM_PROP_FMBLENDSNRATTACKRATE_L   0x06
 
#define AMFM_PROP_FMBLENDSNRRELEASERATE_H   0x18
 
#define AMFM_PROP_FMBLENDSNRRELEASERATE_L   0x07
 
#define AMFM_PROP_FMBLENDMULTIPATHSTEREOTHS_H   0x18
 
#define AMFM_PROP_FMBLENDMULTIPATHSTEREOTHS_L   0x08
 
#define AMFM_PROP_FMBLENDMULTIPATHMONOTHS_H   0x18
 
#define AMFM_PROP_FMBLENDMULTIPATHMONOTHS_L   0x09
 
#define AMFM_PROP_FMBLENDMULTIPATHATTACKRATE_H   0x18
 
#define AMFM_PROP_FMBLENDMULTIPATHATTACKRATE_L   0x0A
 
#define AMFM_PROP_FMBLENDMULTIPATHRELEASERATE_H   0x18
 
#define AMFM_PROP_FMBLENDMULTIPATHRELEASERATE_L   0x0B
 
#define AMFM_PROP_FMBLENDMAXSTEREOSEPARATION_H   0x18
 
#define AMFM_PROP_FMBLENDMAXSTEREOSEPARATION_L   0x0C
 
#define AMFM_PROP_FMNBDETECTTHS_H   0x19
 
#define AMFM_PROP_FMNBDETECTTHS_L   0x00
 
#define AMFM_PROP_FMNBINTERVAL_H   0x19
 
#define AMFM_PROP_FMNBINTERVAL_L   0x01
 
#define AMFM_PROP_FMNBRATE_H   0x19
 
#define AMFM_PROP_FMNBRATE_L   0x02
 
#define AMFM_PROP_FMNBIIRFILTER_H   0x19
 
#define AMFM_PROP_FMNBIIRFILTER_L   0x03
 
#define AMFM_PROP_FMNBDELAY_H   0x19
 
#define AMFM_PROP_FMNBDELAY_L   0x04
 
#define AMFM_PROP_FMHICUTSNRHITHS_H   0x1A
 
#define AMFM_PROP_FMHICUTSNRHITHS_L   0x00
 
#define AMFM_PROP_FMHICUTSNRLOTHS_H   0x1A
 
#define AMFM_PROP_FMHICUTSNRLOTHS_L   0x01
 
#define AMFM_PROP_FMHICUTATTACKRATE_H   0x1A
 
#define AMFM_PROP_FMHICUTATTACKRATE_L   0x02
 
#define AMFM_PROP_FMHICUTRELEASERATE_H   0x1A
 
#define AMFM_PROP_FMHICUTRELEASERATE_L   0x03
 
#define AMFM_PROP_FMHICUTMULTIPATHTRIGGERTHRESHOLD_H   0x1A
 
#define AMFM_PROP_FMHICUTMULTIPATHTRIGGERTHRESHOLD_L   0x04
 
#define AMFM_PROP_FMHICUTMULTIPATHENDTHS_H   0x1A
 
#define AMFM_PROP_FMHICUTMULTIPATHENDTHS_L   0x05
 
#define AMFM_PROP_FMHICUTCUTOFFFREQ_H   0x1A
 
#define AMFM_PROP_FMHICUTCUTOFFFREQ_L   0x06
 
#define AMFM_PROPVALH_RSQREP   0x08
 
#define AMFM_PROPVALH_RDSREP   0x04
 
#define AMFM_PROPVALH_STCREP   0x01
 
#define AMFM_PROPVALL_CTSIEN   0x80
 
#define AMFM_PROPVALL_ERRIEN   0x40
 
#define AMFM_PROPVALL_RSQIEN   0x08
 
#define AMFM_PROPVALL_RDSIEN   0x04
 
#define AMFM_PROPVALL_STCIEN   0x01
 
#define AMFM_PROPVALL_OFALL   0x80
 
#define AMFM_PROPVALL_OMODE_I2S   0x00
 
#define AMFM_PROPVALL_OMODE_LEFTJUST   0x30
 
#define AMFM_PROPVALL_OMODE_MSBATSECONDDCLK   0x40
 
#define AMFM_PROPVALL_OMODE_MSBATFIRSTDCLK   0x60
 
#define AMFM_PROPVALL_OMONO   0x04
 
#define AMFM_PROPVALL_OSIZE_16b   0x00
 
#define AMFM_PROPVALL_OSIZE_20b   0x01
 
#define AMFM_PROPVALL_OSIZE_24b   0x02
 
#define AMFM_PROPVALL_OSIZE_08b   0x03
 
#define AMFM_PROPVALL_DEEMPH_75uS   0x02
 
#define AMFM_PROPVALL_DEEMPH_50uS   0x01
 
#define AMFM_PROPVALL_AUTO   0x00
 
#define AMFM_PROPVALL_WIDE   0x01
 
#define AMFM_PROPVALL_NARROW   0x02
 
#define AMFM_PROPVALL_NARROWER   0x03
 
#define AMFM_PROPVALL_NARROWEST   0x04
 
#define AMFM_PROPVALL_FMTXO   0x01
 
#define AMFM_PROPVALL_BLENDIEN   0x80
 
#define AMFM_PROPVALL_MULTHIEN   0x20
 
#define AMFM_PROPVALL_MULTLIEN   0x10
 
#define AMFM_PROPVALL_SNRHIEN   0x08
 
#define AMFM_PROPVALL_SNRLIEN   0x04
 
#define AMFM_PROPVALL_RSSIHIEN   0x02
 
#define AMFM_PROPVALL_RSSILIEN   0x01
 
#define AMFM_PROPVALL_RDSNEWBLOCKB   0x20
 
#define AMFM_PROPVALL_RDSNEWBLOCKA   0x10
 
#define AMFM_PROPVALL_RDSSYNCFOUND   0x04
 
#define AMFM_PROPVALL_RDSSYNCLOST   0x02
 
#define AMFM_PROPVALL_RDSRECV   0x01
 
#define AMFM_PROPVALH_BLETHA_NOERRORS   0x00
 
#define AMFM_PROPVALH_BLETHA_1TO2ERRORS   0x40
 
#define AMFM_PROPVALH_BLETHA_3TO5ERRORS   0x80
 
#define AMFM_PROPVALH_BLETHA_UNCORRECTABLE   0xC0
 
#define AMFM_PROPVALH_BLETHB_NOERRORS   0x00
 
#define AMFM_PROPVALH_BLETHB_1TO2ERRORS   0x10
 
#define AMFM_PROPVALH_BLETHB_3TO5ERRORS   0x20
 
#define AMFM_PROPVALH_BLETHB_UNCORRECTABLE   0x30
 
#define AMFM_PROPVALH_BLETHC_NOERRORS   0x00
 
#define AMFM_PROPVALH_BLETHC_1TO2ERRORS   0x04
 
#define AMFM_PROPVALH_BLETHC_3TO5ERRORS   0x08
 
#define AMFM_PROPVALH_BLETHC_UNCORRECTABLE   0x0C
 
#define AMFM_PROPVALH_BLETHD_NOERRORS   0x00
 
#define AMFM_PROPVALH_BLETHD_1TO2ERRORS   0x01
 
#define AMFM_PROPVALH_BLETHD_3TO5ERRORS   0x02
 
#define AMFM_PROPVALH_BLETHD_UNCORRECTABLE   0x03
 
#define AMFM_PROPVALL_RDSEN   0x01
 
#define AMFM_PROPVALL_MAXAUDIOFREQ_MAX   0x00
 
#define AMFM_PROPVALL_MAXAUDIOFREQ_2   0x10
 
#define AMFM_PROPVALL_MAXAUDIOFREQ_3   0x20
 
#define AMFM_PROPVALL_MAXAUDIOFREQ_4   0x30
 
#define AMFM_PROPVALL_MAXAUDIOFREQ_5   0x40
 
#define AMFM_PROPVALL_MAXAUDIOFREQ_6   0x50
 
#define AMFM_PROPVALL_MAXAUDIOFREQ_8   0x60
 
#define AMFM_PROPVALL_MAXAUDIOFREQ_11   0x70
 
#define AMFM_PROPVALL_HICUTTRANSFREQ_DISABLED   0x00
 
#define AMFM_PROPVALL_HICUTTRANSFREQ_2   0x01
 
#define AMFM_PROPVALL_HICUTTRANSFREQ_3   0x02
 
#define AMFM_PROPVALL_HICUTTRANSFREQ_4   0x03
 
#define AMFM_PROPVALL_HICUTTRANSFREQ_5   0x04
 
#define AMFM_PROPVALL_HICUTTRANSFREQ_6   0x05
 
#define AMFM_PROPVALL_HICUTTRANSFREQ_8   0x06
 
#define AMFM_PROPVALL_HICUTTRANSFREQ_11   0x07
 
#define AMFM_PROPVALL_LMUTE   0x02
 
#define AMFM_PROPVALL_RMUTE   0x01
 

Functions

void amfm_cfg_setup (amfm_cfg_t *cfg)
 Config Object Initialization function.
 
err_t amfm_init (amfm_t *ctx, amfm_cfg_t *cfg)
 Initialization function.
 
void amfm_default_cfg (amfm_t *ctx)
 Click Default Configuration function.
 
void amfm_generic_write (amfm_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len)
 Generic write function.
 
void amfm_generic_read (amfm_t *ctx, uint8_t reg, uint8_t *data_buf, uint8_t len)
 Generic read function.
 
uint8_t amfm_an_get (amfm_t *ctx)
 Function for checking AN pin state.
 
uint8_t amfm_int_get (amfm_t *ctx)
 Function for checking INT pin state.
 
void amfm_rst_set (amfm_t *ctx, uint8_t pin_state)
 Function for setting RST pin state.
 
void amfm_cs_set (amfm_t *ctx, uint8_t pin_state)
 Function for setting CS pin state.
 
uint8_t amfm_send_command (amfm_t *ctx, uint8_t *cmd_and_args_buf)
 Function for sending command and command arguments to device.
 
uint8_t amfm_get_cts (amfm_t *ctx)
 Function for checking CTS bit.
 
uint8_t amfm_get_stc (amfm_t *ctx)
 Function for checking STC bit.
 
uint8_t amfm_get_rsq (amfm_t *ctx)
 Function for checking RSQ bit.
 
uint8_t amfm_get_rds (amfm_t *ctx)
 Function for checking RDS bit.
 
uint8_t amfm_get_response (amfm_t *ctx, uint8_t *resp_buf, uint8_t n_bytes)
 Function for getting device response.
 
uint8_t amfm_init_device (amfm_t *ctx)
 Device initialization.
 
uint8_t amfm_seek (amfm_t *ctx)
 Function for seeking next station.
 
uint8_t amfm_set_volume (amfm_t *ctx, uint8_t volume)
 Function for setting volume level.
 
uint8_t amfm_mute (amfm_t *ctx)
 Function for muting device.
 
uint8_t amfm_unmute (amfm_t *ctx)
 Function for unmuting device.
 
uint8_t amfm_tune_up (amfm_t *ctx)
 Function for tune up current frequency.
 
uint8_t amfm_tune_down (amfm_t *ctx)
 Function for tune down current frequency.
 
uint8_t amfm_tune_frequency (amfm_t *ctx, uint16_t frequency)
 Function for tuning frequency.
 
uint16_t amfm_get_channel (amfm_t *ctx)
 Function for getting current channel value.
 

Detailed Description

This file contains API for AMFM Click driver.