#######################################
# Syntax Coloring Map SFE_TPA2016D2
#######################################

#######################################
# Datatypes (KEYWORD1)
#######################################
WM8960	KEYWORD1


#######################################
# Methods and Functions (KEYWORD2)
#######################################
begin	KEYWORD2
isConnected	KEYWORD2
enableVREF	KEYWORD2
disableVREF	KEYWORD2
enableAINL	KEYWORD2
disableAINL	KEYWORD2
enableAINR	KEYWORD2
disableAINR	KEYWORD2
enableLMIC	KEYWORD2
disableLMIC	KEYWORD2
enableRMIC	KEYWORD2
disableRMIC	KEYWORD2
enableLMICBOOST	KEYWORD2
disableLMICBOOST	KEYWORD2
enableRMICBOOST	KEYWORD2
disableRMICBOOST	KEYWORD2
pgaLeftNonInvSignalSelect	KEYWORD2
pgaRightNonInvSignalSelect	KEYWORD2
connectLMN1	KEYWORD2 
disconnectLMN1	KEYWORD2 	
connectRMN1	KEYWORD2 	
disconnectRMN1	KEYWORD2 	
connectLMIC2B	KEYWORD2 
disconnectLMIC2B	KEYWORD2	
connectRMIC2B	KEYWORD2 
disconnectRMIC2B	KEYWORD2	
setLINVOL	KEYWORD2
setRINVOL	KEYWORD2
setLINVOLDB	KEYWORD2
setRINVOLDB	KEYWORD2
enablePgaZeroCross	KEYWORD2
disablePgaZeroCross	KEYWORD2
enableLINMUTE	KEYWORD2
disableLINMUTE	KEYWORD2
enableRINMUTE	KEYWORD2
disableRINMUTE	KEYWORD2
pgaLeftIPVUSet	KEYWORD2
pgaRightIPVUSet	KEYWORD2
setLMICBOOST	KEYWORD2
setRMICBOOST	KEYWORD2
setLIN3BOOST	KEYWORD2
setLIN2BOOST	KEYWORD2
setRIN3BOOST	KEYWORD2
setRIN2BOOST	KEYWORD2
enableMicBias	KEYWORD2
disableMicBias	KEYWORD2
setMicBiasVoltage	KEYWORD2
enableAdcLeft	KEYWORD2
disableAdcLeft	KEYWORD2
enableAdcRight	KEYWORD2
disableAdcRight	KEYWORD2
setAdcLeftDigitalVolume	KEYWORD2 
setAdcRightDigitalVolume	KEYWORD2
setAdcLeftDigitalVolumeDB	KEYWORD2 
setAdcRightDigitalVolumeDB	KEYWORD2
enableAlc	KEYWORD2
disableAlc	KEYWORD2
setAlcTarget	KEYWORD2
setAlcDecay	KEYWORD2
setAlcAttack	KEYWORD2
setAlcMaxGain	KEYWORD2
setAlcMinGain	KEYWORD2
setAlcHold	KEYWORD2
enablePeakLimiter	KEYWORD2
disablePeakLimiter	KEYWORD2
enableNoiseGate	KEYWORD2
disableNoiseGate	KEYWORD2
setNoiseGateThreshold	KEYWORD2
enableDacLeft	KEYWORD2
disableDacLeft	KEYWORD2
enableDacRight	KEYWORD2
disableDacRight	KEYWORD2
setDacLeftDigitalVolume	KEYWORD2 
setDacRightDigitalVolume	KEYWORD2	
setDacLeftDigitalVolumeDB	KEYWORD2 
setDacRightDigitalVolumeDB	KEYWORD2	
enableDacMute	KEYWORD2
disableDacMute	KEYWORD2
enable3d	KEYWORD2
disable3d	KEYWORD2
set3dDepth	KEYWORD2
enableDac6dbAttenuation	KEYWORD2
disableDac6dbAttentuation	KEYWORD2
enableLOMIX	KEYWORD2
disableLOMIX	KEYWORD2
enableROMIX	KEYWORD2
disableROMIX	KEYWORD2
enableOUT3MIX	KEYWORD2
disableOUT3MIX	KEYWORD2
enableLI2LO	KEYWORD2
disableLI2LO	KEYWORD2
setLI2LOVOL	KEYWORD2
enableLB2LO	KEYWORD2
disableLB2LO	KEYWORD2
setLB2LOVOL	KEYWORD2
enableLD2LO	KEYWORD2
disableLD2LO	KEYWORD2
enableRI2RO	KEYWORD2
disableRI2RO	KEYWORD2
setRI2ROVOL	KEYWORD2
enableRB2RO	KEYWORD2
disableRB2RO	KEYWORD2
setRB2ROVOL	KEYWORD2
enableRD2RO	KEYWORD2
disableRD2RO	KEYWORD2
enableLI2MO	KEYWORD2
disableLI2MO	KEYWORD2
enableRI2MO	KEYWORD2
disableRI2MO	KEYWORD2
enableOUT3asVMID	KEYWORD2
enableVMID	KEYWORD2
disableVMID	KEYWORD2
enableHeadphones	KEYWORD2
disableHeadphones	KEYWORD2
enableRightHeadphone	KEYWORD2
disableRightHeadphone	KEYWORD2
enableLeftHeadphone	KEYWORD2
disableLeftHeadphone	KEYWORD2
enableHeadphoneStandby	KEYWORD2
disableHeadphoneStandby	KEYWORD2
setHeadphoneVolume	KEYWORD2
setHeadphoneVolumeDB	KEYWORD2
enableHeadphoneZeroCross	KEYWORD2
disableHeadphoneZeroCross	KEYWORD2	
enableSpeakers	KEYWORD2
disableSpeakers	KEYWORD2
enableRightSpeaker	KEYWORD2
disableRightSpeaker	KEYWORD2
enableLeftSpeaker	KEYWORD2
disableLeftSpeaker	KEYWORD2
setSpeakerVolume	KEYWORD2
setSpeakerVolumeDB	KEYWORD2
enableSpeakerZeroCross	KEYWORD2
disableSpeakerZeroCross	KEYWORD2
setSpeakerDcGain	KEYWORD2
setSpeakerAcGain	KEYWORD2
enableLoopBack	KEYWORD2
disableLoopBack	KEYWORD2
enablePLL	KEYWORD2
disablePLL	KEYWORD2
setPLLPRESCALE	KEYWORD2
setPLLN	KEYWORD2
setPLLK	KEYWORD2
setSMD	KEYWORD2
setCLKSEL	KEYWORD2
setSYSCLKDIV	KEYWORD2
setADCDIV	KEYWORD2
setDACDIV	KEYWORD2
setBCLKDIV	KEYWORD2
setDCLKDIV	KEYWORD2
setALRCGPIO	KEYWORD2
enableMasterMode	KEYWORD2
enablePeripheralMode	KEYWORD2
setWL	KEYWORD2
setLRP	KEYWORD2
setALRSWAP	KEYWORD2
writeRegister	KEYWORD2

#######################################
# Constants (LITERAL1)
#######################################

## WM8960 register addresses
WM8960_REG_LEFT_INPUT_VOLUME 	LITERAL1
WM8960_REG_RIGHT_INPUT_VOLUME 	LITERAL1
WM8960_REG_LOUT1_VOLUME 	LITERAL1
WM8960_REG_ROUT1_VOLUME 	LITERAL1
WM8960_REG_CLOCKING_1 	LITERAL1
WM8960_REG_ADC_DAC_CTRL_1 	LITERAL1
WM8960_REG_ADC_DAC_CTRL_2 	LITERAL1
WM8960_REG_AUDIO_INTERFACE_1 	LITERAL1
WM8960_REG_CLOCKING_2 	LITERAL1
WM8960_REG_AUDIO_INTERFACE_2 	LITERAL1
WM8960_REG_LEFT_DAC_VOLUME 	LITERAL1
WM8960_REG_RIGHT_DAC_VOLUME 	LITERAL1
WM8960_REG_RESET 	LITERAL1
WM8960_REG_3D_CONTROL 	LITERAL1
WM8960_REG_ALC1 	LITERAL1
WM8960_REG_ALC2 	LITERAL1
WM8960_REG_ALC3 	LITERAL1
WM8960_REG_NOISE_GATE 	LITERAL1
WM8960_REG_LEFT_ADC_VOLUME 	LITERAL1
WM8960_REG_RIGHT_ADC_VOLUME 	LITERAL1
WM8960_REG_ADDITIONAL_CONTROL_1 	LITERAL1
WM8960_REG_ADDITIONAL_CONTROL_2 	LITERAL1
WM8960_REG_PWR_MGMT_1 	LITERAL1
WM8960_REG_PWR_MGMT_2 	LITERAL1
WM8960_REG_ADDITIONAL_CONTROL_3 	LITERAL1
WM8960_REG_ANTI_POP_1 	LITERAL1
WM8960_REG_ANTI_POP_2 	LITERAL1
WM8960_REG_ADCL_SIGNAL_PATH 	LITERAL1
WM8960_REG_ADCR_SIGNAL_PATH 	LITERAL1
WM8960_REG_LEFT_OUT_MIX_1 	LITERAL1
WM8960_REG_RIGHT_OUT_MIX_2 	LITERAL1
WM8960_REG_MONO_OUT_MIX_1 	LITERAL1
WM8960_REG_MONO_OUT_MIX_2 	LITERAL1
WM8960_REG_LOUT2_VOLUME 	LITERAL1
WM8960_REG_ROUT2_VOLUME 	LITERAL1
WM8960_REG_MONO_OUT_VOLUME 	LITERAL1
WM8960_REG_INPUT_BOOST_MIXER_1 	LITERAL1
WM8960_REG_INPUT_BOOST_MIXER_2 	LITERAL1
WM8960_REG_BYPASS_1 	LITERAL1
WM8960_REG_BYPASS_2 	LITERAL1
WM8960_REG_PWR_MGMT_3 	LITERAL1
WM8960_REG_ADDITIONAL_CONTROL_4 	LITERAL1
WM8960_REG_CLASS_D_CONTROL_1 	LITERAL1
WM8960_REG_CLASS_D_CONTROL_3 	LITERAL1
WM8960_REG_PLL_N 	LITERAL1
WM8960_REG_PLL_K_1 	LITERAL1
WM8960_REG_PLL_K_2 	LITERAL1
WM8960_REG_PLL_K_3 	LITERAL1

## PGA input selections
WM8960_PGAL_LINPUT2	LITERAL1
WM8960_PGAL_LINPUT3	LITERAL1
WM8960_PGAL_VMID	LITERAL1
WM8960_PGAR_RINPUT2	LITERAL1
WM8960_PGAR_RINPUT3	LITERAL1
WM8960_PGAR_VMID	LITERAL1

## Mic (aka PGA) BOOST gain options
WM8960_MIC_BOOST_GAIN_0DB	LITERAL1
WM8960_MIC_BOOST_GAIN_13DB	LITERAL1
WM8960_MIC_BOOST_GAIN_20DB	LITERAL1
WM8960_MIC_BOOST_GAIN_29DB	LITERAL1

## Mixer 1 and 2 boost gain options
WM8960_BOOST_MIXER_GAIN_MUTE	LITERAL1
WM8960_BOOST_MIXER_GAIN_NEG_12DB	LITERAL1
WM8960_BOOST_MIXER_GAIN_NEG_9DB	LITERAL1
WM8960_BOOST_MIXER_GAIN_NEG_6DB	LITERAL1
WM8960_BOOST_MIXER_GAIN_NEG_3DB	LITERAL1
WM8960_BOOST_MIXER_GAIN_0DB	LITERAL1
WM8960_BOOST_MIXER_GAIN_3DB	LITERAL1
WM8960_BOOST_MIXER_GAIN_6DB	LITERAL1

## Output Mixer gain options
WM8960_OUTPUT_MIXER_GAIN_0DB	LITERAL1
WM8960_OUTPUT_MIXER_GAIN_NEG_3DB	LITERAL1
WM8960_OUTPUT_MIXER_GAIN_NEG_6DB	LITERAL1
WM8960_OUTPUT_MIXER_GAIN_NEG_9DB	LITERAL1
WM8960_OUTPUT_MIXER_GAIN_NEG_12DB	LITERAL1
WM8960_OUTPUT_MIXER_GAIN_NEG_15DB	LITERAL1
WM8960_OUTPUT_MIXER_GAIN_NEG_18DB	LITERAL1
WM8960_OUTPUT_MIXER_GAIN_NEG_21DB	LITERAL1

## Mic Bias voltage options
WM8960_MIC_BIAS_VOLTAGE_0_9_AVDD	LITERAL1
WM8960_MIC_BIAS_VOLTAGE_0_65_AVDD	LITERAL1

## Automatic Level Control Modes
WM8960_ALC_MODE_OFF	LITERAL1
WM8960_ALC_MODE_RIGHT_ONLY	LITERAL1
WM8960_ALC_MODE_LEFT_ONLY	LITERAL1
WM8960_ALC_MODE_STEREO	LITERAL1

## SYSCLK divide
WM8960_SYSCLK_DIV_BY_1	LITERAL1
WM8960_SYSCLK_DIV_BY_2	LITERAL1
WM8960_CLKSEL_MCLK	LITERAL1
WM8960_CLKSEL_PLL	LITERAL1
WM8960_PLL_MODE_INTEGER	LITERAL1
WM8960_PLL_MODE_FRACTIONAL	LITERAL1
WM8960_PLLPRESCALE_DIV_1	LITERAL1
WM8960_PLLPRESCALE_DIV_2	LITERAL1

## class d clock divide
WM8960_DCLKDIV_16	LITERAL1

## word length settings (aka bits per sample)
## Audio Data Word Length
WM8960_WL_16BIT	LITERAL1
WM8960_WL_20BIT	LITERAL1
WM8960_WL_24BIT	LITERAL1
WM8960_WL_32BIT	LITERAL1

WM8960_LR_POLARITY_NORMAL	LITERAL1
WM8960_LR_POLARITY_INVERT	LITERAL1
WM8960_ALRSWAP_NORMAL	LITERAL1
WM8960_ALRSWAP_SWAP	LITERAL1

WM8960_ALC_TARGET_LEVEL_NEG_22_5DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_21DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_19_5DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_18DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_16_5DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_15DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_13_5DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_12DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_10_5DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_9DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_7_5DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_6DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_4_5DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_3DB	LITERAL1
WM8960_ALC_TARGET_LEVEL_NEG_1_5DB	LITERAL1

WM8960_ALC_MAX_GAIN_LEVEL_NEG_12DB	LITERAL1
WM8960_ALC_MAX_GAIN_LEVEL_NEG_6DB	LITERAL1
WM8960_ALC_MAX_GAIN_LEVEL_0DB	LITERAL1
WM8960_ALC_MAX_GAIN_LEVEL_6DB	LITERAL1
WM8960_ALC_MAX_GAIN_LEVEL_12DB	LITERAL1
WM8960_ALC_MAX_GAIN_LEVEL_18DB	LITERAL1
WM8960_ALC_MAX_GAIN_LEVEL_24DB	LITERAL1
WM8960_ALC_MAX_GAIN_LEVEL_30DB	LITERAL1

WM8960_ALC_MIN_GAIN_LEVEL_NEG_17_25DB	LITERAL1
WM8960_ALC_MIN_GAIN_LEVEL_NEG_11_25DB	LITERAL1
WM8960_ALC_MIN_GAIN_LEVEL_NEG_5_25DB	LITERAL1
WM8960_ALC_MIN_GAIN_LEVEL_0_75DB	LITERAL1
WM8960_ALC_MIN_GAIN_LEVEL_6_75DB	LITERAL1
WM8960_ALC_MIN_GAIN_LEVEL_12_75DB	LITERAL1
WM8960_ALC_MIN_GAIN_LEVEL_18_75DB	LITERAL1
WM8960_ALC_MIN_GAIN_LEVEL_24_75DB	LITERAL1

WM8960_ALC_HOLD_TIME_0MS	LITERAL1
WM8960_ALC_HOLD_TIME_3MS	LITERAL1
WM8960_ALC_HOLD_TIME_5MS	LITERAL1
WM8960_ALC_HOLD_TIME_11MS	LITERAL1
WM8960_ALC_HOLD_TIME_21MS	LITERAL1
WM8960_ALC_HOLD_TIME_43MS	LITERAL1
WM8960_ALC_HOLD_TIME_85MS	LITERAL1
WM8960_ALC_HOLD_TIME_170MS	LITERAL1
WM8960_ALC_HOLD_TIME_341MS	LITERAL1
WM8960_ALC_HOLD_TIME_682MS	LITERAL1
WM8960_ALC_HOLD_TIME_1365MS	LITERAL1
WM8960_ALC_HOLD_TIME_3SEC	LITERAL1
WM8960_ALC_HOLD_TIME_5SEC	LITERAL1
WM8960_ALC_HOLD_TIME_10SEC	LITERAL1
WM8960_ALC_HOLD_TIME_23SEC	LITERAL1
WM8960_ALC_HOLD_TIME_44SEC	LITERAL1

WM8960_ALC_DECAY_TIME_24MS	LITERAL1
WM8960_ALC_DECAY_TIME_48MS	LITERAL1
WM8960_ALC_DECAY_TIME_96MS	LITERAL1
WM8960_ALC_DECAY_TIME_192MS	LITERAL1
WM8960_ALC_DECAY_TIME_384MS	LITERAL1
WM8960_ALC_DECAY_TIME_768MS	LITERAL1
WM8960_ALC_DECAY_TIME_1536MS	LITERAL1
WM8960_ALC_DECAY_TIME_3SEC	LITERAL1
WM8960_ALC_DECAY_TIME_6SEC	LITERAL1
WM8960_ALC_DECAY_TIME_12SEC	LITERAL1
WM8960_ALC_DECAY_TIME_24SEC	LITERAL1

WM8960_ALC_ATTACK_TIME_6MS	LITERAL1
WM8960_ALC_ATTACK_TIME_12MS	LITERAL1
WM8960_ALC_ATTACK_TIME_24MS	LITERAL1
WM8960_ALC_ATTACK_TIME_482MS	LITERAL1
WM8960_ALC_ATTACK_TIME_964MS	LITERAL1
WM8960_ALC_ATTACK_TIME_1928MS	LITERAL1
WM8960_ALC_ATTACK_TIME_3846MS	LITERAL1
WM8960_ALC_ATTACK_TIME_768MS	LITERAL1
WM8960_ALC_ATTACK_TIME_1536MS	LITERAL1
WM8960_ALC_ATTACK_TIME_3SEC	LITERAL1
WM8960_ALC_ATTACK_TIME_6SEC	LITERAL1

#######################################
# Instances (KEYWORD3)
#######################################

