Functions | |
cy_en_ble_eco_status_t | Cy_BLE_EcoConfigure (cy_en_ble_eco_freq_t freq, cy_en_ble_eco_sys_clk_div_t sysClkDiv, uint32_t cLoad, uint32_t xtalStartUpTime, cy_en_ble_eco_voltage_reg_t voltageReg) |
This API configures and enables the BLE ECO clock. More... | |
void | Cy_BLE_EcoReset (void) |
This API resets and disables the BLE ECO clock. More... | |
__STATIC_INLINE bool | Cy_BLE_EcoIsEnabled (void) |
Reports the Enabled/Disabled BLE ECO status. More... | |
cy_en_ble_eco_status_t Cy_BLE_EcoConfigure | ( | cy_en_ble_eco_freq_t | freq, |
cy_en_ble_eco_sys_clk_div_t | sysClkDiv, | ||
uint32_t | cLoad, | ||
uint32_t | xtalStartUpTime, | ||
cy_en_ble_eco_voltage_reg_t | voltageReg | ||
) |
This API configures and enables the BLE ECO clock.
If Cy_BLE_Enable() API is called by the application, the stack enables the BLE ECO clock automatically with the following default parameters:
Parameter | Value |
---|---|
ECO Frequency | CY_BLE_DEFAULT_ECO_FREQ |
Divider | CY_BLE_DEFAULT_ECO_DIV |
Startup time | CY_BLE_DEFAULT_OSC_STARTUP_DELAY_LF |
Load cap | CY_BLE_DEFAULT_CAP_TRIM_VALUE |
If there is a need to start the BLE ECO with non-default parameters, call the Cy_BLE_EcoConfigure() function with the custom configuration each time before calling the Cy_BLE_Enable() function.
This clock is stopped in Deep Sleep and Hibernate power modes.
freq | - Operating frequency of the crystal, type of cy_en_ble_eco_freq_t. |
sysClkDiv | - System divider for ECO clock, type of cy_en_ble_eco_sys_clk_div_t. |
cLoad | - ECO crystal load capacitance in multiple of 0.075pF (pF_from_user valid range: 7.5...26.625pF) cLoad = ((pF_from_user - 7.5)/0.075) |
xtalStartUpTime | - ECO crystal startup time in multiple of 31.25us (startup_time_from_user valid range: 400...4593.75us) xtalStartUpTime = startup_time_from_user/31.25 |
voltageReg | - BLE Voltage regulator, type of cy_en_ble_eco_voltage_reg_t. |
Error Codes | Description |
---|---|
CY_BLE_ECO_SUCCESS | The function completed successfully. |
CY_BLE_ECO_BAD_PARAM | The wrong input parameter. |
CY_BLE_ECO_RCB_CONTROL_LL | The RCB Control is with BLE Link Layer. |
CY_BLE_ECO_ALREADY_STARTED | The BLE ECO clock is already started. |
CY_BLE_ECO_HARDWARE_ERROR | The RCB or BLE ECO operation failed. |
For the PSoC 64 devices, there are possible situations when the function returns the PRA error status code. This is because for PSoC 64 devices, the function uses the PRA driver to change the frequency value on the protected side. Refer to cy_en_pra_status_t for more details.
void Cy_BLE_EcoReset | ( | void | ) |
This API resets and disables the BLE ECO clock.
__STATIC_INLINE bool Cy_BLE_EcoIsEnabled | ( | void | ) |
Reports the Enabled/Disabled BLE ECO status.