Library for TEA5767 FM stereo radio module

Dependents:   TEA5767_RadioFM_Test_Code

Embed: (wiki syntax)

« Back to documentation index

TEA5767 Class Reference

TEA5767 Class Reference

TEA5767 class. More...

#include <TEA5767.h>

Public Member Functions

 TEA5767 (PinName sda, PinName scl, int addr)
 Creates an TEA5767 object connected to the specified I2C object.
 ~TEA5767 ()
 Destroys a TEA5767 object.
void SetBand (char valueBand)
 Set the band FM.
void SetFrequency (double freq, char side= 'h')
 Set the radio frequency.
void SearchUp (float freq)
 Auto search up frequency.
void SearchDown (float freq)
 Auto search down frequency.
float FreqCurrent ()
 Read the current frequancy.
int CheckDevice ()
 Checks if the address exist on an I2C bus.
int SignalLevel ()
 Read the signal level of the band.

Detailed Description

TEA5767 class.

Definition at line 14 of file TEA5767.h.


Constructor & Destructor Documentation

TEA5767 ( PinName  sda,
PinName  scl,
int  addr 
)

Creates an TEA5767 object connected to the specified I2C object.

Parameters:
sdaI2C data port
sclI2C clock port
addrthe I2C address of the TEA5767 device

Definition at line 4 of file TEA5767.cpp.

~TEA5767 (  )

Destroys a TEA5767 object.

Definition at line 11 of file TEA5767.cpp.


Member Function Documentation

int CheckDevice (  )

Checks if the address exist on an I2C bus.

Returns:
0 on success, or non-0 on failure

Definition at line 118 of file TEA5767.cpp.

float FreqCurrent (  )

Read the current frequancy.

Returns:
the current frequency

Definition at line 70 of file TEA5767.cpp.

void SearchDown ( float  freq )

Auto search down frequency.

Parameters:
freqfrequency

Definition at line 64 of file TEA5767.cpp.

void SearchUp ( float  freq )

Auto search up frequency.

Parameters:
freqfrequency

Definition at line 58 of file TEA5767.cpp.

void SetBand ( char  valueBand )

Set the band FM.

Parameters:
valueBandset the band ('e' = EUROPE/US - 'j' = JAPANESE)

Definition at line 28 of file TEA5767.cpp.

void SetFrequency ( double  freq,
char  side = 'h' 
)

Set the radio frequency.

Parameters:
freqfrequency
sideside injection mode ('h' = HIGH - 'l' = LOW)

Definition at line 35 of file TEA5767.cpp.

int SignalLevel (  )

Read the signal level of the band.

Returns:
the signal level

Definition at line 124 of file TEA5767.cpp.