#include <Si5351.hpp>
|
| Si5351 (i2c_inst *i2cPort=i2c0, uint8_t i2cAddr=0x60, const uint8_t cLoad=10) |
|
void | disableInterrupts () |
| Disables the interrupt pin.
|
|
void | disableOEBPin () |
| Disables the OEB pin.
|
|
void | resetPll (const char pll) const |
| Resets PLLA or PLLB.
|
|
void | resetPll () const |
| Resets PLLA and PLLB.
|
|
void | setClkControl (const uint8_t clkIndex, bool powerDown, bool intMode, uint8_t inputSource, bool invert, uint8_t outputSource, uint8_t strength) |
|
void | setMultisynth0to5parameters (const uint8_t multisynth, const uint32_t integer, const uint32_t num, const uint32_t denom, uint8_t outDiv=0) const |
| Configures the multisynth divider 0, 1, 2, 3, 4 or 5.
|
|
void | setOutputDisableState (uint8_t clkIndex, const uint8_t disState) |
| Determins the state of a disabled output.
|
|
void | setOutput (const uint8_t clkIndex, const bool enabled) |
| Enables or disables a single output driver.
|
|
void | setOutputsOff () |
| Disables all output drivers and powers them down.
|
|
void | setPllInputSource (const uint8_t inputDivider, const uint8_t sourceB=0, const uint8_t sourceA=0) |
| Sets the clock input divider.
|
|
void | setPllParameters (const char pll, const uint32_t integer, const uint32_t numerator, const uint32_t denominator) |
| Sets the PLL dividers.
|
|
◆ Si5351()
Si5351::Si5351 |
( |
i2c_inst * | i2cPort = i2c0, |
|
|
uint8_t | i2cAddr = 0x60, |
|
|
const uint8_t | cLoad = 10 ) |
- Parameters
-
i2cPort | is an I2C controller, for example i2c0 . It must have been initialized. |
i2cAddr | is the I2C address. |
cLoad | is the crystal cnternal load capacitance in pF and must bei 6, 8 or 10. Other values are treated as 10. |
◆ disableInterrupts()
void Si5351::disableInterrupts |
( |
| ) |
|
Disables the interrupt pin.
◆ disableOEBPin()
void Si5351::disableOEBPin |
( |
| ) |
|
◆ resetPll() [1/2]
void Si5351::resetPll |
( |
| ) |
const |
◆ resetPll() [2/2]
void Si5351::resetPll |
( |
const char | pll | ) |
const |
Resets PLLA or PLLB.
- Parameters
-
pll | must be 'a' or 'b'. Other values are ignored. |
◆ setClkControl()
void Si5351::setClkControl |
( |
const uint8_t | clkIndex, |
|
|
bool | powerDown, |
|
|
bool | intMode, |
|
|
uint8_t | inputSource, |
|
|
bool | invert, |
|
|
uint8_t | outputSource, |
|
|
uint8_t | strength ) |
- Parameters
-
clkIndex | must be between 0 and 7. Other values are treated like 0. |
powerDown | sets the mode of the output driver. |
intMode | sets the multisynth int mode. |
inputSource | must be 0 (PLLA) or 1 (PLLB on Si5351A/C or VCXO on Si5351B). Other values are treated like 0. |
invert | inverts the output clock if set to true. |
outputSource | must be 0 (XTAL) or 3 (multisynth). Other values are treated like 3. |
strength | must be 2, 4, 6 or 8. Other values are treated like 2. |
◆ setMultisynth0to5parameters()
void Si5351::setMultisynth0to5parameters |
( |
const uint8_t | multisynth, |
|
|
const uint32_t | integer, |
|
|
const uint32_t | num, |
|
|
const uint32_t | denom, |
|
|
uint8_t | outDiv = 0 ) const |
Configures the multisynth divider 0, 1, 2, 3, 4 or 5.
- Parameters
-
multisynth | must be 0, 1, 2, 3, 4 or 5. Other values are ignored. |
integer | is a in (a + b/c). |
num | is b in (a + b/c). |
denom | is c in (a + b/c). |
outDiv | must not be greater than 7. Higher Bits are ignored. The output divider is set to 2^´outDiv´. |
◆ setOutput()
void Si5351::setOutput |
( |
const uint8_t | clkIndex, |
|
|
const bool | enabled ) |
Enables or disables a single output driver.
- Parameters
-
clkIndex | must bei 0, 1, 2, 3, 4, 5, 6 or 7. Other Values are ignored. |
enabled | enables output clkIndex if true is given, otherwise disables it. |
◆ setOutputDisableState()
void Si5351::setOutputDisableState |
( |
uint8_t | clkIndex, |
|
|
const uint8_t | disState ) |
Determins the state of a disabled output.
- Parameters
-
clkIndex | must be between 0 and 7. Other values are treated like 0. |
disState | must be 0 (low), 1 (high), 2 (high Z) or 3 (never disabled). Higher bits are ignored. |
◆ setOutputsOff()
void Si5351::setOutputsOff |
( |
| ) |
|
Disables all output drivers and powers them down.
◆ setPllInputSource()
void Si5351::setPllInputSource |
( |
const uint8_t | inputDivider, |
|
|
const uint8_t | sourceB = 0, |
|
|
const uint8_t | sourceA = 0 ) |
Sets the clock input divider.
- Parameters
-
inputDivider | must be 1, 2, 4 or 8. Other values are treated like 1. |
sourceB | is ignored becauseat the moment only the Si5351A ist fully supported. |
sourcea | is ignored becauseat the moment only the Si5351A ist fully supported. |
◆ setPllParameters()
void Si5351::setPllParameters |
( |
const char | pll, |
|
|
const uint32_t | integer, |
|
|
const uint32_t | numerator, |
|
|
const uint32_t | denominator ) |
Sets the PLL dividers.
- Parameters
-
pll | must be 'a' (PLL A) or 'b' (PLL B). Other values are ignored. |
integer | is a in (a + b/c). |
numerator | is b in (a + b/c). |
denominator | is c in (a + b/c). |
The documentation for this class was generated from the following files: