![]() |
PU2CLR Si4735 Arduino Library
1.1.9
Arduino Library for Si47XX Devices - By Ricardo Lima Caratti
|
Functions | |
void | SI4735::setMaxDelaySetFrequency (uint16_t ms) |
Set the Max Delay after Set Frequency. More... | |
void | SI4735::setFrequencyStep (uint16_t step) |
Sets the current step value. More... | |
void | SI4735::setTuneFrequencyAntennaCapacitor (uint16_t capacitor) |
Only FM. Freeze Metrics During Alternate Frequency Jump. More... | |
void | SI4735::setFrequency (uint16_t) |
Set the frequency to the corrent function of the Si4735 (FM, AM or SSB) More... | |
void | SI4735::frequencyUp () |
Increments the current frequency on current band/function by using the current step. More... | |
void | SI4735::frequencyDown () |
Decrements the current frequency on current band/function by using the current step. More... | |
void | SI4735::setAM () |
Sets the radio to AM function. It means: LW MW and SW. More... | |
void | SI4735::setFM () |
Sets the radio to FM function. More... | |
void | SI4735::setAM (uint16_t fromFreq, uint16_t toFreq, uint16_t intialFreq, uint16_t step) |
Sets the radio to AM (LW/MW/SW) function. More... | |
void | SI4735::setFM (uint16_t fromFreq, uint16_t toFreq, uint16_t initialFreq, uint16_t step) |
Sets the radio to FM function. More... | |
bool | SI4735::isCurrentTuneFM () |
Returns true if the current function is FM (FM_TUNE_FREQ). More... | |
bool | SI4735::isCurrentTuneAM () |
Returns true if the current function is AM (AM_TUNE_FREQ). More... | |
bool | SI4735::isCurrentTuneSSB () |
Returns true if the current function is SSB (SSB_TUNE_FREQ). More... | |
|
inline |
Set the Max Delay after Set Frequency.
After the set frequency command, the system need a time to get ready to the next set frequency (default value 30ms).
Why the waitToSend() does not work in this case? No idea for while!
A low value makes the getFrequency command inaccurate.
ms |
|
inline |
Sets the current step value.
This function does not check the limits of the current band. Please, don't take a step bigger than your legs.
Example:
step | if you are using FM, 10 means 100KHz. If you are using AM 10 means 10KHz For AM, 1 (1KHz) to 1000 (1MHz) are valid values. For FM 5 (50KHz), 10 (100KHz) and 100 (1MHz) are valid values. |
void SI4735::setTuneFrequencyAntennaCapacitor | ( | uint16_t | capacitor | ) |
Only FM. Freeze Metrics During Alternate Frequency Jump.
Selects the tuning capacitor value.
On FM mode, The Antenna Tuning Capacitor is valid only when using TXO/LPI pin as the antenna input. This selects the value of the antenna tuning capacitor manually, or automatically if set to zero. The valid range is 0 to 191. Automatic capacitor tuning is recommended. Whentunedmanually,thevaractorisoffsetbyfourcodes. Forexample,if the varactor is set to a value of 5 manually, when read back the value will be 1. The four codes (1pf) delta accounts for the capacitance at the chip.
on AM mode, If the value is set to anything other than 0, the tuning capacitance is manually set as 95 fF x ANTCAP + 7 pF. ANTCAP manual range is 1–6143. Automatic capacitor tuning is recommended. In SW mode, ANTCAPH[15:8] (high byte) needs to be set to 0 and ANTCAPL[7:0] (low byte) needs to be set to 1.
capacitor | If zero, the tuning capacitor value is selected automatically. If the value is set to anything other than 0: AM - the tuning capacitance is manually set as 95 fF x ANTCAP + 7 pF. ANTCAP manual range is 1–6143; FM - the valid range is 0 to 191. According to Silicon Labs, automatic capacitor tuning is recommended (value 0). |
void SI4735::setFrequency | ( | uint16_t | freq | ) |
Set the frequency to the corrent function of the Si4735 (FM, AM or SSB)
You have to call setup or setPowerUp before call setFrequency.
uint16_t | freq is the frequency to change. For example, FM => 10390 = 103.9 MHz; AM => 810 = 810 KHz. |
References SI4735::waitToSend().
void SI4735::frequencyUp | ( | ) |
Increments the current frequency on current band/function by using the current step.
void SI4735::frequencyDown | ( | ) |
Decrements the current frequency on current band/function by using the current step.
void SI4735::setAM | ( | ) |
Sets the radio to AM function. It means: LW MW and SW.
Define the band range you want to use for the AM mode.
References SI4735::powerDown(), and SI4735::radioPowerUp().
Referenced by SI4735::setAM().
void SI4735::setFM | ( | ) |
Sets the radio to FM function.
References SI4735::disableFmDebug(), SI4735::powerDown(), and SI4735::radioPowerUp().
Referenced by SI4735::setFM().
void SI4735::setAM | ( | uint16_t | fromFreq, |
uint16_t | toFreq, | ||
uint16_t | initialFreq, | ||
uint16_t | step | ||
) |
Sets the radio to AM (LW/MW/SW) function.
The example below sets the band from 550KHz to 1750KHz on AM mode. The band will start on 810KHz and step is 10KHz.
fromFreq | minimum frequency for the band |
toFreq | maximum frequency for the band |
initialFreq | initial frequency |
step | step used to go to the next channel |
References SI4735::setAM().
void SI4735::setFM | ( | uint16_t | fromFreq, |
uint16_t | toFreq, | ||
uint16_t | initialFreq, | ||
uint16_t | step | ||
) |
Sets the radio to FM function.
Defines the band range you want to use for the FM mode.
The example below sets the band from 64MHz to 108MHzKHz on FM mode. The band will start on 103.9MHz and step is 100KHz. On FM mode, the step 10 means 100KHz. If you want a 1MHz step, use 100.
fromFreq | minimum frequency for the band |
toFreq | maximum frequency for the band |
initialFreq | initial frequency (default frequency) |
step | step used to go to the next channel |
References SI4735::setFM().
bool SI4735::isCurrentTuneFM | ( | ) |
Returns true if the current function is FM (FM_TUNE_FREQ).
bool SI4735::isCurrentTuneAM | ( | ) |
Returns true if the current function is AM (AM_TUNE_FREQ).
bool SI4735::isCurrentTuneSSB | ( | ) |
Returns true if the current function is SSB (SSB_TUNE_FREQ).