Hardware access layer for managing the QSPI peripheral. More...
Data Structures | |
struct | nrf_qspi_pins_t |
Pin configuration. More... | |
struct | nrf_qspi_cinstr_conf_t |
Custom instruction configuration. More... | |
struct | nrf_qspi_addrconfig_conf_t |
Addressing mode register configuration. See nrf_qspi_addrconfig_set. More... | |
struct | nrf_qspi_prot_conf_t |
Structure with QSPI protocol interface configuration. More... | |
struct | nrf_qspi_phy_conf_t |
QSPI physical interface configuration. More... | |
struct | nrf_qspi_encryption_t |
QSPI encryption settings for XIP and DMA transfers. More... | |
Macros | |
#define | NRF_QSPI_HAS_XIPEN 1 |
Symbol indicating whether XIP can be explicitly enabled or disabled via XIPEN register. | |
#define | NRF_QSPI_HAS_XIP_ENC 1 |
Symbol indicating whether encryption for XIP is present. | |
#define | NRF_QSPI_HAS_DMA_ENC 1 |
Symbol indicating whether encryption for EasyDMA is present. | |
#define | NRF_QSPI_HAS_MODE_1 1 |
Symbol indicating whether support for QSPI mode 1 is present. | |
#define | NRF_QSPI_BASE_CLOCK_FREQ 96000000uL |
Value representing QSPI base clock frequency. | |
#define | NRF_QSPI_PIN_NOT_CONNECTED 0xFF |
This value can be used as a parameter for the nrf_qspi_pins_set function to specify that a given QSPI signal (SCK, CSN, IO0, IO1, IO2, or IO3) will not be connected to a physical pin. | |
#define | NRF_QSPI_PIN_VAL(pin) (pin) == NRF_QSPI_PIN_NOT_CONNECTED ? 0xFFFFFFFF : (pin) |
Macro for setting proper values to pin registers. | |
Enumerations | |
enum | nrf_qspi_task_t { NRF_QSPI_TASK_ACTIVATE = offsetof(NRF_QSPI_Type, TASKS_ACTIVATE), NRF_QSPI_TASK_READSTART = offsetof(NRF_QSPI_Type, TASKS_READSTART), NRF_QSPI_TASK_WRITESTART = offsetof(NRF_QSPI_Type, TASKS_WRITESTART), NRF_QSPI_TASK_ERASESTART = offsetof(NRF_QSPI_Type, TASKS_ERASESTART), NRF_QSPI_TASK_DEACTIVATE = offsetof(NRF_QSPI_Type, TASKS_DEACTIVATE) } |
QSPI tasks. More... | |
enum | nrf_qspi_event_t { NRF_QSPI_EVENT_READY = offsetof(NRF_QSPI_Type, EVENTS_READY) } |
QSPI events. More... | |
enum | nrf_qspi_int_mask_t { NRF_QSPI_INT_READY_MASK = QSPI_INTENSET_READY_Msk } |
QSPI interrupts. More... | |
enum | nrf_qspi_frequency_t { NRF_QSPI_FREQ_DIV1, NRF_QSPI_FREQ_DIV2, NRF_QSPI_FREQ_DIV3, NRF_QSPI_FREQ_DIV4, NRF_QSPI_FREQ_DIV5, NRF_QSPI_FREQ_DIV6, NRF_QSPI_FREQ_DIV7, NRF_QSPI_FREQ_DIV8, NRF_QSPI_FREQ_DIV9, NRF_QSPI_FREQ_DIV10, NRF_QSPI_FREQ_DIV11, NRF_QSPI_FREQ_DIV12, NRF_QSPI_FREQ_DIV13, NRF_QSPI_FREQ_DIV14, NRF_QSPI_FREQ_DIV15, NRF_QSPI_FREQ_DIV16 } |
QSPI base clock frequency divider values. More... | |
enum | nrf_qspi_readoc_t { NRF_QSPI_READOC_FASTREAD = QSPI_IFCONFIG0_READOC_FASTREAD, NRF_QSPI_READOC_READ2O = QSPI_IFCONFIG0_READOC_READ2O, NRF_QSPI_READOC_READ2IO = QSPI_IFCONFIG0_READOC_READ2IO, NRF_QSPI_READOC_READ4O = QSPI_IFCONFIG0_READOC_READ4O, NRF_QSPI_READOC_READ4IO = QSPI_IFCONFIG0_READOC_READ4IO } |
Interface configuration for a read operation. More... | |
enum | nrf_qspi_writeoc_t { NRF_QSPI_WRITEOC_PP = QSPI_IFCONFIG0_WRITEOC_PP, NRF_QSPI_WRITEOC_PP2O = QSPI_IFCONFIG0_WRITEOC_PP2O, NRF_QSPI_WRITEOC_PP4O = QSPI_IFCONFIG0_WRITEOC_PP4O, NRF_QSPI_WRITEOC_PP4IO = QSPI_IFCONFIG0_WRITEOC_PP4IO } |
Interface configuration for a write operation. More... | |
enum | nrf_qspi_addrmode_t { NRF_QSPI_ADDRMODE_24BIT = QSPI_IFCONFIG0_ADDRMODE_24BIT, NRF_QSPI_ADDRMODE_32BIT = QSPI_IFCONFIG0_ADDRMODE_32BIT } |
Interface configuration for addressing mode. More... | |
enum | nrf_qspi_spi_mode_t { NRF_QSPI_MODE_0 = QSPI_IFCONFIG1_SPIMODE_MODE0, NRF_QSPI_MODE_1 = QSPI_IFCONFIG1_SPIMODE_MODE3 } |
QSPI SPI mode. Polarization and phase configuration. More... | |
enum | nrf_qspi_addrconfig_mode_t { NRF_QSPI_ADDRCONF_MODE_NOINSTR = QSPI_ADDRCONF_MODE_NoInstr, NRF_QSPI_ADDRCONF_MODE_OPCODE = QSPI_ADDRCONF_MODE_Opcode, NRF_QSPI_ADDRCONF_MODE_OPBYTE0 = QSPI_ADDRCONF_MODE_OpByte0, NRF_QSPI_ADDRCONF_MODE_ALL = QSPI_ADDRCONF_MODE_All } |
Addressing configuration mode. More... | |
enum | nrf_qspi_erase_len_t { NRF_QSPI_ERASE_LEN_4KB = QSPI_ERASE_LEN_LEN_4KB, NRF_QSPI_ERASE_LEN_64KB = QSPI_ERASE_LEN_LEN_64KB, NRF_QSPI_ERASE_LEN_ALL = QSPI_ERASE_LEN_LEN_All } |
Erasing data length. More... | |
enum | nrf_qspi_cinstr_len_t { NRF_QSPI_CINSTR_LEN_1B = QSPI_CINSTRCONF_LENGTH_1B, NRF_QSPI_CINSTR_LEN_2B = QSPI_CINSTRCONF_LENGTH_2B, NRF_QSPI_CINSTR_LEN_3B = QSPI_CINSTRCONF_LENGTH_3B, NRF_QSPI_CINSTR_LEN_4B = QSPI_CINSTRCONF_LENGTH_4B, NRF_QSPI_CINSTR_LEN_5B = QSPI_CINSTRCONF_LENGTH_5B, NRF_QSPI_CINSTR_LEN_6B = QSPI_CINSTRCONF_LENGTH_6B, NRF_QSPI_CINSTR_LEN_7B = QSPI_CINSTRCONF_LENGTH_7B, NRF_QSPI_CINSTR_LEN_8B = QSPI_CINSTRCONF_LENGTH_8B, NRF_QSPI_CINSTR_LEN_9B = QSPI_CINSTRCONF_LENGTH_9B } |
Custom instruction length. More... | |
Functions | |
NRF_STATIC_INLINE void | nrf_qspi_task_trigger (NRF_QSPI_Type *p_reg, nrf_qspi_task_t task) |
Function for activating the specified QSPI task. More... | |
NRF_STATIC_INLINE uint32_t | nrf_qspi_task_address_get (NRF_QSPI_Type const *p_reg, nrf_qspi_task_t task) |
Function for getting the address of the specified QSPI task register. More... | |
NRF_STATIC_INLINE void | nrf_qspi_event_clear (NRF_QSPI_Type *p_reg, nrf_qspi_event_t event) |
Function for clearing the specified QSPI event. More... | |
NRF_STATIC_INLINE bool | nrf_qspi_event_check (NRF_QSPI_Type const *p_reg, nrf_qspi_event_t event) |
Function for retrieving the state of the QSPI event. More... | |
NRF_STATIC_INLINE uint32_t | nrf_qspi_event_address_get (NRF_QSPI_Type const *p_reg, nrf_qspi_event_t event) |
Function for getting the address of the specified QSPI event register. More... | |
NRF_STATIC_INLINE void | nrf_qspi_int_enable (NRF_QSPI_Type *p_reg, uint32_t mask) |
Function for enabling specified interrupts. More... | |
NRF_STATIC_INLINE void | nrf_qspi_int_disable (NRF_QSPI_Type *p_reg, uint32_t mask) |
Function for disabling specified interrupts. More... | |
NRF_STATIC_INLINE uint32_t | nrf_qspi_int_enable_check (NRF_QSPI_Type const *p_reg, uint32_t mask) |
Function for checking if the specified interrupts are enabled. More... | |
NRF_STATIC_INLINE void | nrf_qspi_enable (NRF_QSPI_Type *p_reg) |
Function for enabling the QSPI peripheral. More... | |
NRF_STATIC_INLINE void | nrf_qspi_disable (NRF_QSPI_Type *p_reg) |
Function for disabling the QSPI peripheral. More... | |
NRF_STATIC_INLINE void | nrf_qspi_pins_set (NRF_QSPI_Type *p_reg, nrf_qspi_pins_t const *p_pins) |
Function for configuring QSPI pins. More... | |
NRF_STATIC_INLINE void | nrf_qspi_pins_get (NRF_QSPI_Type const *p_reg, nrf_qspi_pins_t *p_pins) |
Function for getting the currently configured QSPI pins. More... | |
NRF_STATIC_INLINE void | nrf_qspi_xip_offset_set (NRF_QSPI_Type *p_reg, uint32_t xip_offset) |
Function for setting the QSPI XIPOFFSET register. More... | |
NRF_STATIC_INLINE void | nrf_qspi_ifconfig0_set (NRF_QSPI_Type *p_reg, nrf_qspi_prot_conf_t const *p_config) |
Function for setting the QSPI IFCONFIG0 register. More... | |
NRF_STATIC_INLINE void | nrf_qspi_ifconfig0_raw_set (NRF_QSPI_Type *p_reg, uint32_t regval) |
Function for setting the explicit value of the QSPI IFCONFIG0 register. More... | |
NRF_STATIC_INLINE uint32_t | nrf_qspi_ifconfig0_raw_get (NRF_QSPI_Type const *p_reg) |
Function for getting the explicit value of the QSPI IFCONFIG0 register. More... | |
NRF_STATIC_INLINE void | nrf_qspi_ifconfig1_set (NRF_QSPI_Type *p_reg, nrf_qspi_phy_conf_t const *p_config) |
Function for setting the QSPI IFCONFIG1 register. More... | |
NRF_STATIC_INLINE void | nrf_qspi_addrconfig_set (NRF_QSPI_Type *p_reg, nrf_qspi_addrconfig_conf_t const *p_config) |
Function for setting the QSPI ADDRCONF register. More... | |
NRF_STATIC_INLINE void | nrf_qspi_write_buffer_set (NRF_QSPI_Type *p_reg, void const *p_buffer, uint32_t length, uint32_t dest_addr) |
Function for setting write data into the peripheral register (without starting the process). More... | |
NRF_STATIC_INLINE void | nrf_qspi_read_buffer_set (NRF_QSPI_Type *p_reg, void *p_buffer, uint32_t length, uint32_t src_addr) |
Function for setting read data into the peripheral register (without starting the process). More... | |
NRF_STATIC_INLINE void | nrf_qspi_erase_ptr_set (NRF_QSPI_Type *p_reg, uint32_t erase_addr, nrf_qspi_erase_len_t len) |
Function for setting erase data into the peripheral register (without starting the process). More... | |
NRF_STATIC_INLINE uint32_t | nrf_qspi_erase_ptr_get (NRF_QSPI_Type const *p_reg) |
Function for getting the currently configured erase pointer. More... | |
NRF_STATIC_INLINE nrf_qspi_erase_len_t | nrf_qspi_erase_len_get (NRF_QSPI_Type const *p_reg) |
Function for getting the currently configured erase length. More... | |
NRF_STATIC_INLINE uint32_t | nrf_qspi_status_reg_get (NRF_QSPI_Type const *p_reg) |
Function for getting the peripheral status register. More... | |
NRF_STATIC_INLINE uint8_t | nrf_qspi_sreg_get (NRF_QSPI_Type const *p_reg) |
Function for getting the device status register stored in the peripheral status register. More... | |
NRF_STATIC_INLINE bool | nrf_qspi_busy_check (NRF_QSPI_Type const *p_reg) |
Function for checking if the peripheral is busy or not. More... | |
NRF_STATIC_INLINE void | nrf_qspi_cinstrdata_set (NRF_QSPI_Type *p_reg, nrf_qspi_cinstr_len_t length, void const *p_tx_data) |
Function for setting registers sending with custom instruction transmission. More... | |
NRF_STATIC_INLINE void | nrf_qspi_cinstrdata_get (NRF_QSPI_Type const *p_reg, nrf_qspi_cinstr_len_t length, void *p_rx_data) |
Function for getting data from register after custom instruction transmission. More... | |
NRF_STATIC_INLINE void | nrf_qspi_cinstr_transfer_start (NRF_QSPI_Type *p_reg, nrf_qspi_cinstr_conf_t const *p_config) |
Function for sending custom instruction to external memory. More... | |
NRF_STATIC_INLINE void | nrf_qspi_cinstr_long_transfer_start (NRF_QSPI_Type *p_reg, nrf_qspi_cinstr_conf_t const *p_config) |
Function for starting a custom instruction long transfer. More... | |
NRF_STATIC_INLINE bool | nrf_qspi_cinstr_long_transfer_is_ongoing (NRF_QSPI_Type const *p_reg) |
Function for checking whether a custom instruction long transfer is ongoing. More... | |
NRF_STATIC_INLINE void | nrf_qspi_cinstr_long_transfer_continue (NRF_QSPI_Type *p_reg, nrf_qspi_cinstr_len_t length, bool finalize) |
Function for continuing a custom instruction long transfer. More... | |
NRF_STATIC_INLINE void | nrf_qspi_xip_set (NRF_QSPI_Type *p_reg, bool enable) |
Function for enabling or disabling Execute in Place (XIP) operation. More... | |
NRF_STATIC_INLINE void | nrf_qspi_xip_encryption_configure (NRF_QSPI_Type *p_reg, nrf_qspi_encryption_t const *p_cfg) |
Function for configuring the XIP encryption. More... | |
NRF_STATIC_INLINE void | nrf_qspi_xip_encryption_set (NRF_QSPI_Type *p_reg, bool enable) |
Function for enabling or disabling the XIP encryption. More... | |
NRF_STATIC_INLINE void | nrf_qspi_dma_encryption_configure (NRF_QSPI_Type *p_reg, nrf_qspi_encryption_t const *p_cfg) |
Function for configuring the EasyDMA encryption. More... | |
NRF_STATIC_INLINE void | nrf_qspi_dma_encryption_set (NRF_QSPI_Type *p_reg, bool enable) |
Function for enabling or disabling the EasyDMA encryption. More... | |
NRF_STATIC_INLINE void | nrf_qspi_iftiming_set (NRF_QSPI_Type *p_reg, uint8_t rxdelay) |
Function for setting the timing related to sampling of the input serial data. More... | |
Hardware access layer for managing the QSPI peripheral.
enum nrf_qspi_addrmode_t |
Custom instruction length.
enum nrf_qspi_erase_len_t |
enum nrf_qspi_event_t |
enum nrf_qspi_frequency_t |
QSPI base clock frequency divider values.
enum nrf_qspi_int_mask_t |
enum nrf_qspi_readoc_t |
Interface configuration for a read operation.
enum nrf_qspi_spi_mode_t |
enum nrf_qspi_task_t |
QSPI tasks.
enum nrf_qspi_writeoc_t |
Interface configuration for a write operation.
NRF_STATIC_INLINE void nrf_qspi_addrconfig_set | ( | NRF_QSPI_Type * | p_reg, |
nrf_qspi_addrconfig_conf_t const * | p_config | ||
) |
Function for setting the QSPI ADDRCONF register.
This function must be executed before sending task NRF_QSPI_TASK_ACTIVATE. Data stored in the structure is sent during the start of the peripheral. Remember that the reset instruction can set addressing mode to default in the memory device. If memory reset is necessary before configuring the addressing mode, use custom instruction feature instead of this function. Case with reset: Enable the peripheral without setting ADDRCONF register, send reset instructions using a custom instruction feature (reset enable and then reset), set proper addressing mode using the custom instruction feature.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | p_config | Pointer to the addressing mode configuration structure. See nrf_qspi_addrconfig_conf_t. |
NRF_STATIC_INLINE bool nrf_qspi_busy_check | ( | NRF_QSPI_Type const * | p_reg | ) |
Function for checking if the peripheral is busy or not.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
true | The QSPI is busy. |
false | The QSPI is ready. |
NRF_STATIC_INLINE void nrf_qspi_cinstr_long_transfer_continue | ( | NRF_QSPI_Type * | p_reg, |
nrf_qspi_cinstr_len_t | length, | ||
bool | finalize | ||
) |
Function for continuing a custom instruction long transfer.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | length | Length of the custom instruction data. |
[in] | finalize | True if the custom instruction long transfer is to be finalized. False if the custom instruction long transfer is to be continued. |
NRF_STATIC_INLINE bool nrf_qspi_cinstr_long_transfer_is_ongoing | ( | NRF_QSPI_Type const * | p_reg | ) |
Function for checking whether a custom instruction long transfer is ongoing.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
true | Custom instruction long transfer is ongoing. |
false | Custom instruction long transfer is not ongoing. |
NRF_STATIC_INLINE void nrf_qspi_cinstr_long_transfer_start | ( | NRF_QSPI_Type * | p_reg, |
nrf_qspi_cinstr_conf_t const * | p_config | ||
) |
Function for starting a custom instruction long transfer.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | p_config | Pointer to the custom instruction configuration structure. See nrf_qspi_cinstr_conf_t. |
NRF_STATIC_INLINE void nrf_qspi_cinstr_transfer_start | ( | NRF_QSPI_Type * | p_reg, |
nrf_qspi_cinstr_conf_t const * | p_config | ||
) |
Function for sending custom instruction to external memory.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | p_config | Pointer to the custom instruction configuration structure. See nrf_qspi_cinstr_conf_t. |
NRF_STATIC_INLINE void nrf_qspi_cinstrdata_get | ( | NRF_QSPI_Type const * | p_reg, |
nrf_qspi_cinstr_len_t | length, | ||
void * | p_rx_data | ||
) |
Function for getting data from register after custom instruction transmission.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | length | Length of the custom instruction data. |
[in] | p_rx_data | Pointer to the reading buffer. |
NRF_STATIC_INLINE void nrf_qspi_cinstrdata_set | ( | NRF_QSPI_Type * | p_reg, |
nrf_qspi_cinstr_len_t | length, | ||
void const * | p_tx_data | ||
) |
Function for setting registers sending with custom instruction transmission.
This function can be ommited when using NRF_QSPI_CINSTR_LEN_1B as the length argument (sending only opcode without data).
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | length | Length of the custom instruction data. |
[in] | p_tx_data | Pointer to the data to send with the custom instruction. |
NRF_STATIC_INLINE void nrf_qspi_disable | ( | NRF_QSPI_Type * | p_reg | ) |
Function for disabling the QSPI peripheral.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
NRF_STATIC_INLINE void nrf_qspi_dma_encryption_configure | ( | NRF_QSPI_Type * | p_reg, |
nrf_qspi_encryption_t const * | p_cfg | ||
) |
Function for configuring the EasyDMA encryption.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | p_cfg | Pointer to encryption configuration structure. |
NRF_STATIC_INLINE void nrf_qspi_dma_encryption_set | ( | NRF_QSPI_Type * | p_reg, |
bool | enable | ||
) |
Function for enabling or disabling the EasyDMA encryption.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | enable | True if EasyDMA encryption is to be enabled, false otherwise. |
NRF_STATIC_INLINE void nrf_qspi_enable | ( | NRF_QSPI_Type * | p_reg | ) |
Function for enabling the QSPI peripheral.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
NRF_STATIC_INLINE nrf_qspi_erase_len_t nrf_qspi_erase_len_get | ( | NRF_QSPI_Type const * | p_reg | ) |
Function for getting the currently configured erase length.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
NRF_STATIC_INLINE uint32_t nrf_qspi_erase_ptr_get | ( | NRF_QSPI_Type const * | p_reg | ) |
Function for getting the currently configured erase pointer.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
NRF_STATIC_INLINE void nrf_qspi_erase_ptr_set | ( | NRF_QSPI_Type * | p_reg, |
uint32_t | erase_addr, | ||
nrf_qspi_erase_len_t | len | ||
) |
Function for setting erase data into the peripheral register (without starting the process).
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | erase_addr | Start address to erase. Address must have padding set to 4 bytes. |
[in] | len | Size of erasing area. |
NRF_STATIC_INLINE uint32_t nrf_qspi_event_address_get | ( | NRF_QSPI_Type const * | p_reg, |
nrf_qspi_event_t | event | ||
) |
Function for getting the address of the specified QSPI event register.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | event | The specified event. |
NRF_STATIC_INLINE bool nrf_qspi_event_check | ( | NRF_QSPI_Type const * | p_reg, |
nrf_qspi_event_t | event | ||
) |
Function for retrieving the state of the QSPI event.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | event | Event to be checked. |
true | The event has been generated. |
false | The event has not been generated. |
NRF_STATIC_INLINE void nrf_qspi_event_clear | ( | NRF_QSPI_Type * | p_reg, |
nrf_qspi_event_t | event | ||
) |
Function for clearing the specified QSPI event.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | event | Event to be cleared. |
NRF_STATIC_INLINE uint32_t nrf_qspi_ifconfig0_raw_get | ( | NRF_QSPI_Type const * | p_reg | ) |
Function for getting the explicit value of the QSPI IFCONFIG0 register.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
NRF_STATIC_INLINE void nrf_qspi_ifconfig0_raw_set | ( | NRF_QSPI_Type * | p_reg, |
uint32_t | regval | ||
) |
Function for setting the explicit value of the QSPI IFCONFIG0 register.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | regval | Register value to be set. |
NRF_STATIC_INLINE void nrf_qspi_ifconfig0_set | ( | NRF_QSPI_Type * | p_reg, |
nrf_qspi_prot_conf_t const * | p_config | ||
) |
Function for setting the QSPI IFCONFIG0 register.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | p_config | Pointer to the QSPI protocol interface configuration structure. See nrf_qspi_prot_conf_t. |
NRF_STATIC_INLINE void nrf_qspi_ifconfig1_set | ( | NRF_QSPI_Type * | p_reg, |
nrf_qspi_phy_conf_t const * | p_config | ||
) |
Function for setting the QSPI IFCONFIG1 register.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | p_config | Pointer to the QSPI physical interface configuration structure. See nrf_qspi_phy_conf_t. |
NRF_STATIC_INLINE void nrf_qspi_iftiming_set | ( | NRF_QSPI_Type * | p_reg, |
uint8_t | rxdelay | ||
) |
Function for setting the timing related to sampling of the input serial data.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | rxdelay | Number of 64 MHz cycles (15.625 ns) delay from the the rising edge of the clock until the input serial data is sampled. |
NRF_STATIC_INLINE void nrf_qspi_int_disable | ( | NRF_QSPI_Type * | p_reg, |
uint32_t | mask | ||
) |
Function for disabling specified interrupts.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | mask | Mask of interrupts to be disabled. |
NRF_STATIC_INLINE void nrf_qspi_int_enable | ( | NRF_QSPI_Type * | p_reg, |
uint32_t | mask | ||
) |
Function for enabling specified interrupts.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | mask | Mask of interrupts to be enabled. |
NRF_STATIC_INLINE uint32_t nrf_qspi_int_enable_check | ( | NRF_QSPI_Type const * | p_reg, |
uint32_t | mask | ||
) |
Function for checking if the specified interrupts are enabled.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | mask | Mask of interrupts to be checked. |
NRF_STATIC_INLINE void nrf_qspi_pins_get | ( | NRF_QSPI_Type const * | p_reg, |
nrf_qspi_pins_t * | p_pins | ||
) |
Function for getting the currently configured QSPI pins.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[out] | p_pins | Pointer to the pins configuration structure to be filled with QSPI pins. |
NRF_STATIC_INLINE void nrf_qspi_pins_set | ( | NRF_QSPI_Type * | p_reg, |
nrf_qspi_pins_t const * | p_pins | ||
) |
Function for configuring QSPI pins.
If a given signal is not needed, pass the NRF_QSPI_PIN_NOT_CONNECTED value instead of its pin number.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | p_pins | Pointer to the pins configuration structure. See nrf_qspi_pins_t. |
NRF_STATIC_INLINE void nrf_qspi_read_buffer_set | ( | NRF_QSPI_Type * | p_reg, |
void * | p_buffer, | ||
uint32_t | length, | ||
uint32_t | src_addr | ||
) |
Function for setting read data into the peripheral register (without starting the process).
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[out] | p_buffer | Pointer to the reading buffer. |
[in] | length | Length of the read data. |
[in] | src_addr | Address in memory to read from. |
NRF_STATIC_INLINE uint8_t nrf_qspi_sreg_get | ( | NRF_QSPI_Type const * | p_reg | ) |
Function for getting the device status register stored in the peripheral status register.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
NRF_STATIC_INLINE uint32_t nrf_qspi_status_reg_get | ( | NRF_QSPI_Type const * | p_reg | ) |
Function for getting the peripheral status register.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
NRF_STATIC_INLINE uint32_t nrf_qspi_task_address_get | ( | NRF_QSPI_Type const * | p_reg, |
nrf_qspi_task_t | task | ||
) |
Function for getting the address of the specified QSPI task register.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | task | QSPI task. |
NRF_STATIC_INLINE void nrf_qspi_task_trigger | ( | NRF_QSPI_Type * | p_reg, |
nrf_qspi_task_t | task | ||
) |
Function for activating the specified QSPI task.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | task | Task to be activated. |
NRF_STATIC_INLINE void nrf_qspi_write_buffer_set | ( | NRF_QSPI_Type * | p_reg, |
void const * | p_buffer, | ||
uint32_t | length, | ||
uint32_t | dest_addr | ||
) |
Function for setting write data into the peripheral register (without starting the process).
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | p_buffer | Pointer to the writing buffer. |
[in] | length | Lenght of the writing data. |
[in] | dest_addr | Address in memory to write to. |
NRF_STATIC_INLINE void nrf_qspi_xip_encryption_configure | ( | NRF_QSPI_Type * | p_reg, |
nrf_qspi_encryption_t const * | p_cfg | ||
) |
Function for configuring the XIP encryption.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | p_cfg | Pointer to encryption configuration structure. |
NRF_STATIC_INLINE void nrf_qspi_xip_encryption_set | ( | NRF_QSPI_Type * | p_reg, |
bool | enable | ||
) |
Function for enabling or disabling the XIP encryption.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | enable | True if XIP encryption is to be enabled, false otherwise. |
NRF_STATIC_INLINE void nrf_qspi_xip_offset_set | ( | NRF_QSPI_Type * | p_reg, |
uint32_t | xip_offset | ||
) |
Function for setting the QSPI XIPOFFSET register.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | xip_offset | Address offset in the external memory for Execute in Place operation. |
NRF_STATIC_INLINE void nrf_qspi_xip_set | ( | NRF_QSPI_Type * | p_reg, |
bool | enable | ||
) |
Function for enabling or disabling Execute in Place (XIP) operation.
[in] | p_reg | Pointer to the structure of registers of the peripheral. |
[in] | enable | True if XIP is to be enabled, false otherwise. |