nrfx 2.5
Data Structures | Enumerations | Functions
UARTE HAL

Hardware access layer for managing the UARTE peripheral. More...

Data Structures

struct  nrf_uarte_config_t
 Structure for UARTE transmission configuration. More...
 

Enumerations

enum  nrf_uarte_task_t {
  NRF_UARTE_TASK_STARTRX = offsetof(NRF_UARTE_Type, TASKS_STARTRX),
  NRF_UARTE_TASK_STOPRX = offsetof(NRF_UARTE_Type, TASKS_STOPRX),
  NRF_UARTE_TASK_STARTTX = offsetof(NRF_UARTE_Type, TASKS_STARTTX),
  NRF_UARTE_TASK_STOPTX = offsetof(NRF_UARTE_Type, TASKS_STOPTX),
  NRF_UARTE_TASK_FLUSHRX = offsetof(NRF_UARTE_Type, TASKS_FLUSHRX)
}
 UARTE tasks. More...
 
enum  nrf_uarte_event_t {
  NRF_UARTE_EVENT_CTS = offsetof(NRF_UARTE_Type, EVENTS_CTS),
  NRF_UARTE_EVENT_NCTS = offsetof(NRF_UARTE_Type, EVENTS_NCTS),
  NRF_UARTE_EVENT_RXDRDY = offsetof(NRF_UARTE_Type, EVENTS_RXDRDY),
  NRF_UARTE_EVENT_ENDRX = offsetof(NRF_UARTE_Type, EVENTS_ENDRX),
  NRF_UARTE_EVENT_TXDRDY = offsetof(NRF_UARTE_Type, EVENTS_TXDRDY),
  NRF_UARTE_EVENT_ENDTX = offsetof(NRF_UARTE_Type, EVENTS_ENDTX),
  NRF_UARTE_EVENT_ERROR = offsetof(NRF_UARTE_Type, EVENTS_ERROR),
  NRF_UARTE_EVENT_RXTO = offsetof(NRF_UARTE_Type, EVENTS_RXTO),
  NRF_UARTE_EVENT_RXSTARTED = offsetof(NRF_UARTE_Type, EVENTS_RXSTARTED),
  NRF_UARTE_EVENT_TXSTARTED = offsetof(NRF_UARTE_Type, EVENTS_TXSTARTED),
  NRF_UARTE_EVENT_TXSTOPPED = offsetof(NRF_UARTE_Type, EVENTS_TXSTOPPED)
}
 UARTE events. More...
 
enum  nrf_uarte_short_t {
  NRF_UARTE_SHORT_ENDRX_STARTRX = UARTE_SHORTS_ENDRX_STARTRX_Msk,
  NRF_UARTE_SHORT_ENDRX_STOPRX = UARTE_SHORTS_ENDRX_STOPRX_Msk
}
 Types of UARTE shortcuts. More...
 
enum  nrf_uarte_int_mask_t {
  NRF_UARTE_INT_CTS_MASK = UARTE_INTENSET_CTS_Msk,
  NRF_UARTE_INT_NCTS_MASK = UARTE_INTENSET_NCTS_Msk,
  NRF_UARTE_INT_RXDRDY_MASK = UARTE_INTENSET_RXDRDY_Msk,
  NRF_UARTE_INT_ENDRX_MASK = UARTE_INTENSET_ENDRX_Msk,
  NRF_UARTE_INT_TXDRDY_MASK = UARTE_INTENSET_TXDRDY_Msk,
  NRF_UARTE_INT_ENDTX_MASK = UARTE_INTENSET_ENDTX_Msk,
  NRF_UARTE_INT_ERROR_MASK = UARTE_INTENSET_ERROR_Msk,
  NRF_UARTE_INT_RXTO_MASK = UARTE_INTENSET_RXTO_Msk,
  NRF_UARTE_INT_RXSTARTED_MASK = UARTE_INTENSET_RXSTARTED_Msk,
  NRF_UARTE_INT_TXSTARTED_MASK = UARTE_INTENSET_TXSTARTED_Msk,
  NRF_UARTE_INT_TXSTOPPED_MASK = UARTE_INTENSET_TXSTOPPED_Msk
}
 UARTE interrupts. More...
 
enum  nrf_uarte_baudrate_t {
  NRF_UARTE_BAUDRATE_1200 = UARTE_BAUDRATE_BAUDRATE_Baud1200,
  NRF_UARTE_BAUDRATE_2400 = UARTE_BAUDRATE_BAUDRATE_Baud2400,
  NRF_UARTE_BAUDRATE_4800 = UARTE_BAUDRATE_BAUDRATE_Baud4800,
  NRF_UARTE_BAUDRATE_9600 = UARTE_BAUDRATE_BAUDRATE_Baud9600,
  NRF_UARTE_BAUDRATE_14400 = UARTE_BAUDRATE_BAUDRATE_Baud14400,
  NRF_UARTE_BAUDRATE_19200 = UARTE_BAUDRATE_BAUDRATE_Baud19200,
  NRF_UARTE_BAUDRATE_28800 = UARTE_BAUDRATE_BAUDRATE_Baud28800,
  NRF_UARTE_BAUDRATE_31250 = UARTE_BAUDRATE_BAUDRATE_Baud31250,
  NRF_UARTE_BAUDRATE_38400 = UARTE_BAUDRATE_BAUDRATE_Baud38400,
  NRF_UARTE_BAUDRATE_56000 = UARTE_BAUDRATE_BAUDRATE_Baud56000,
  NRF_UARTE_BAUDRATE_57600 = UARTE_BAUDRATE_BAUDRATE_Baud57600,
  NRF_UARTE_BAUDRATE_76800 = UARTE_BAUDRATE_BAUDRATE_Baud76800,
  NRF_UARTE_BAUDRATE_115200 = UARTE_BAUDRATE_BAUDRATE_Baud115200,
  NRF_UARTE_BAUDRATE_230400 = UARTE_BAUDRATE_BAUDRATE_Baud230400,
  NRF_UARTE_BAUDRATE_250000 = UARTE_BAUDRATE_BAUDRATE_Baud250000,
  NRF_UARTE_BAUDRATE_460800 = UARTE_BAUDRATE_BAUDRATE_Baud460800,
  NRF_UARTE_BAUDRATE_921600 = UARTE_BAUDRATE_BAUDRATE_Baud921600,
  NRF_UARTE_BAUDRATE_1000000 = UARTE_BAUDRATE_BAUDRATE_Baud1M
}
 Baudrates supported by UARTE. More...
 
enum  nrf_uarte_error_mask_t {
  NRF_UARTE_ERROR_OVERRUN_MASK = UARTE_ERRORSRC_OVERRUN_Msk,
  NRF_UARTE_ERROR_PARITY_MASK = UARTE_ERRORSRC_PARITY_Msk,
  NRF_UARTE_ERROR_FRAMING_MASK = UARTE_ERRORSRC_FRAMING_Msk,
  NRF_UARTE_ERROR_BREAK_MASK = UARTE_ERRORSRC_BREAK_Msk
}
 Types of UARTE error masks. More...
 
enum  nrf_uarte_parity_t {
  NRF_UARTE_PARITY_EXCLUDED = UARTE_CONFIG_PARITY_Excluded << UARTE_CONFIG_PARITY_Pos,
  NRF_UARTE_PARITY_INCLUDED = UARTE_CONFIG_PARITY_Included << UARTE_CONFIG_PARITY_Pos
}
 Types of UARTE parity modes. More...
 
enum  nrf_uarte_hwfc_t {
  NRF_UARTE_HWFC_DISABLED = UARTE_CONFIG_HWFC_Disabled << UARTE_CONFIG_HWFC_Pos,
  NRF_UARTE_HWFC_ENABLED = UARTE_CONFIG_HWFC_Enabled << UARTE_CONFIG_HWFC_Pos
}
 Types of UARTE flow control modes. More...
 
enum  nrf_uarte_stop_t {
  NRF_UARTE_STOP_ONE = UARTE_CONFIG_STOP_One << UARTE_CONFIG_STOP_Pos,
  NRF_UARTE_STOP_TWO = UARTE_CONFIG_STOP_Two << UARTE_CONFIG_STOP_Pos
}
 Types of UARTE stop bit modes. More...
 
enum  nrf_uarte_paritytype_t {
  NRF_UARTE_PARITYTYPE_EVEN = UARTE_CONFIG_PARITYTYPE_Even << UARTE_CONFIG_PARITYTYPE_Pos,
  NRF_UARTE_PARITYTYPE_ODD = UARTE_CONFIG_PARITYTYPE_Odd << UARTE_CONFIG_PARITYTYPE_Pos
}
 Types of UARTE parity types. More...
 

Functions

NRF_STATIC_INLINE void nrf_uarte_event_clear (NRF_UARTE_Type *p_reg, nrf_uarte_event_t event)
 Function for clearing a specific UARTE event. More...
 
NRF_STATIC_INLINE bool nrf_uarte_event_check (NRF_UARTE_Type const *p_reg, nrf_uarte_event_t event)
 Function for retrieving the state of the UARTE event. More...
 
NRF_STATIC_INLINE uint32_t nrf_uarte_event_address_get (NRF_UARTE_Type const *p_reg, nrf_uarte_event_t event)
 Function for returning the address of the specified UARTE event register. More...
 
NRF_STATIC_INLINE void nrf_uarte_shorts_enable (NRF_UARTE_Type *p_reg, uint32_t mask)
 Function for enabling UARTE shortcuts. More...
 
NRF_STATIC_INLINE void nrf_uarte_shorts_disable (NRF_UARTE_Type *p_reg, uint32_t mask)
 Function for disabling UARTE shortcuts. More...
 
NRF_STATIC_INLINE void nrf_uarte_int_enable (NRF_UARTE_Type *p_reg, uint32_t mask)
 Function for enabling UARTE interrupts. More...
 
NRF_STATIC_INLINE uint32_t nrf_uarte_int_enable_check (NRF_UARTE_Type const *p_reg, uint32_t mask)
 Function for checking if the specified interrupts are enabled. More...
 
NRF_STATIC_INLINE void nrf_uarte_int_disable (NRF_UARTE_Type *p_reg, uint32_t mask)
 Function for disabling the specified interrupts. More...
 
NRF_STATIC_INLINE void nrf_uarte_subscribe_set (NRF_UARTE_Type *p_reg, nrf_uarte_task_t task, uint8_t channel)
 Function for setting the subscribe configuration for a given UARTE task. More...
 
NRF_STATIC_INLINE void nrf_uarte_subscribe_clear (NRF_UARTE_Type *p_reg, nrf_uarte_task_t task)
 Function for clearing the subscribe configuration for a given UARTE task. More...
 
NRF_STATIC_INLINE void nrf_uarte_publish_set (NRF_UARTE_Type *p_reg, nrf_uarte_event_t event, uint8_t channel)
 Function for setting the publish configuration for a given UARTE event. More...
 
NRF_STATIC_INLINE void nrf_uarte_publish_clear (NRF_UARTE_Type *p_reg, nrf_uarte_event_t event)
 Function for clearing the publish configuration for a given UARTE event. More...
 
NRF_STATIC_INLINE uint32_t nrf_uarte_errorsrc_get_and_clear (NRF_UARTE_Type *p_reg)
 Function for getting error source mask. Function is clearing error source flags after reading. More...
 
NRF_STATIC_INLINE void nrf_uarte_enable (NRF_UARTE_Type *p_reg)
 Function for enabling UARTE. More...
 
NRF_STATIC_INLINE void nrf_uarte_disable (NRF_UARTE_Type *p_reg)
 Function for disabling UARTE. More...
 
NRF_STATIC_INLINE void nrf_uarte_txrx_pins_set (NRF_UARTE_Type *p_reg, uint32_t pseltxd, uint32_t pselrxd)
 Function for configuring TX/RX pins. More...
 
NRF_STATIC_INLINE void nrf_uarte_txrx_pins_disconnect (NRF_UARTE_Type *p_reg)
 Function for disconnecting TX/RX pins. More...
 
NRF_STATIC_INLINE uint32_t nrf_uarte_tx_pin_get (NRF_UARTE_Type const *p_reg)
 Function for getting TX pin selection. More...
 
NRF_STATIC_INLINE uint32_t nrf_uarte_rx_pin_get (NRF_UARTE_Type const *p_reg)
 Function for getting RX pin selection. More...
 
NRF_STATIC_INLINE uint32_t nrf_uarte_rts_pin_get (NRF_UARTE_Type const *p_reg)
 Function for getting RTS pin selection. More...
 
NRF_STATIC_INLINE uint32_t nrf_uarte_cts_pin_get (NRF_UARTE_Type const *p_reg)
 Function for getting CTS pin selection. More...
 
NRF_STATIC_INLINE void nrf_uarte_hwfc_pins_set (NRF_UARTE_Type *p_reg, uint32_t pselrts, uint32_t pselcts)
 Function for configuring flow control pins. More...
 
NRF_STATIC_INLINE void nrf_uarte_hwfc_pins_disconnect (NRF_UARTE_Type *p_reg)
 Function for disconnecting flow control pins. More...
 
NRF_STATIC_INLINE void nrf_uarte_task_trigger (NRF_UARTE_Type *p_reg, nrf_uarte_task_t task)
 Function for starting an UARTE task. More...
 
NRF_STATIC_INLINE uint32_t nrf_uarte_task_address_get (NRF_UARTE_Type const *p_reg, nrf_uarte_task_t task)
 Function for returning the address of the specified task register. More...
 
NRF_STATIC_INLINE void nrf_uarte_configure (NRF_UARTE_Type *p_reg, nrf_uarte_config_t const *p_cfg)
 Function for configuring UARTE. More...
 
NRF_STATIC_INLINE void nrf_uarte_baudrate_set (NRF_UARTE_Type *p_reg, nrf_uarte_baudrate_t baudrate)
 Function for setting UARTE baud rate. More...
 
NRF_STATIC_INLINE void nrf_uarte_tx_buffer_set (NRF_UARTE_Type *p_reg, uint8_t const *p_buffer, size_t length)
 Function for setting the transmit buffer. More...
 
NRF_STATIC_INLINE uint32_t nrf_uarte_tx_amount_get (NRF_UARTE_Type const *p_reg)
 Function for getting number of bytes transmitted in the last transaction. More...
 
NRF_STATIC_INLINE void nrf_uarte_rx_buffer_set (NRF_UARTE_Type *p_reg, uint8_t *p_buffer, size_t length)
 Function for setting the receive buffer. More...
 
NRF_STATIC_INLINE uint32_t nrf_uarte_rx_amount_get (NRF_UARTE_Type const *p_reg)
 Function for getting number of bytes received in the last transaction. More...
 

Detailed Description

Hardware access layer for managing the UARTE peripheral.

Enumeration Type Documentation

◆ nrf_uarte_baudrate_t

Baudrates supported by UARTE.

Enumerator
NRF_UARTE_BAUDRATE_1200 

1200 baud.

NRF_UARTE_BAUDRATE_2400 

2400 baud.

NRF_UARTE_BAUDRATE_4800 

4800 baud.

NRF_UARTE_BAUDRATE_9600 

9600 baud.

NRF_UARTE_BAUDRATE_14400 

14400 baud.

NRF_UARTE_BAUDRATE_19200 

19200 baud.

NRF_UARTE_BAUDRATE_28800 

28800 baud.

NRF_UARTE_BAUDRATE_31250 

31250 baud.

NRF_UARTE_BAUDRATE_38400 

38400 baud.

NRF_UARTE_BAUDRATE_56000 

56000 baud.

NRF_UARTE_BAUDRATE_57600 

57600 baud.

NRF_UARTE_BAUDRATE_76800 

76800 baud.

NRF_UARTE_BAUDRATE_115200 

115200 baud.

NRF_UARTE_BAUDRATE_230400 

230400 baud.

NRF_UARTE_BAUDRATE_250000 

250000 baud.

NRF_UARTE_BAUDRATE_460800 

460800 baud.

NRF_UARTE_BAUDRATE_921600 

921600 baud.

NRF_UARTE_BAUDRATE_1000000 

1000000 baud.

◆ nrf_uarte_error_mask_t

Types of UARTE error masks.

Enumerator
NRF_UARTE_ERROR_OVERRUN_MASK 

Overrun error.

NRF_UARTE_ERROR_PARITY_MASK 

Parity error.

NRF_UARTE_ERROR_FRAMING_MASK 

Framing error.

NRF_UARTE_ERROR_BREAK_MASK 

Break error.

◆ nrf_uarte_event_t

UARTE events.

Enumerator
NRF_UARTE_EVENT_CTS 

CTS is activated.

NRF_UARTE_EVENT_NCTS 

CTS is deactivated.

NRF_UARTE_EVENT_RXDRDY 

Data received in RXD (but potentially not yet transferred to Data RAM).

NRF_UARTE_EVENT_ENDRX 

Receive buffer is filled up.

NRF_UARTE_EVENT_TXDRDY 

Data sent from TXD.

NRF_UARTE_EVENT_ENDTX 

Last TX byte transmitted.

NRF_UARTE_EVENT_ERROR 

Error detected.

NRF_UARTE_EVENT_RXTO 

Receiver timeout.

NRF_UARTE_EVENT_RXSTARTED 

Receiver has started.

NRF_UARTE_EVENT_TXSTARTED 

Transmitter has started.

NRF_UARTE_EVENT_TXSTOPPED 

Transmitted stopped.

◆ nrf_uarte_hwfc_t

Types of UARTE flow control modes.

Enumerator
NRF_UARTE_HWFC_DISABLED 

Hardware flow control disabled.

NRF_UARTE_HWFC_ENABLED 

Hardware flow control enabled.

◆ nrf_uarte_int_mask_t

UARTE interrupts.

Enumerator
NRF_UARTE_INT_CTS_MASK 

Interrupt on CTS event.

NRF_UARTE_INT_NCTS_MASK 

Interrupt on NCTS event.

NRF_UARTE_INT_RXDRDY_MASK 

Interrupt on RXDRDY event.

NRF_UARTE_INT_ENDRX_MASK 

Interrupt on ENDRX event.

NRF_UARTE_INT_TXDRDY_MASK 

Interrupt on TXDRDY event.

NRF_UARTE_INT_ENDTX_MASK 

Interrupt on ENDTX event.

NRF_UARTE_INT_ERROR_MASK 

Interrupt on ERROR event.

NRF_UARTE_INT_RXTO_MASK 

Interrupt on RXTO event.

NRF_UARTE_INT_RXSTARTED_MASK 

Interrupt on RXSTARTED event.

NRF_UARTE_INT_TXSTARTED_MASK 

Interrupt on TXSTARTED event.

NRF_UARTE_INT_TXSTOPPED_MASK 

Interrupt on TXSTOPPED event.

◆ nrf_uarte_parity_t

Types of UARTE parity modes.

Enumerator
NRF_UARTE_PARITY_EXCLUDED 

Parity excluded.

NRF_UARTE_PARITY_INCLUDED 

Parity included.

◆ nrf_uarte_paritytype_t

Types of UARTE parity types.

Enumerator
NRF_UARTE_PARITYTYPE_EVEN 

Parity even.

NRF_UARTE_PARITYTYPE_ODD 

Parity odd.

◆ nrf_uarte_short_t

Types of UARTE shortcuts.

Enumerator
NRF_UARTE_SHORT_ENDRX_STARTRX 

Shortcut between ENDRX event and STARTRX task.

NRF_UARTE_SHORT_ENDRX_STOPRX 

Shortcut between ENDRX event and STOPRX task.

◆ nrf_uarte_stop_t

Types of UARTE stop bit modes.

Enumerator
NRF_UARTE_STOP_ONE 

One stop bit.

NRF_UARTE_STOP_TWO 

Two stop bits.

◆ nrf_uarte_task_t

UARTE tasks.

Enumerator
NRF_UARTE_TASK_STARTRX 

Start UART receiver.

NRF_UARTE_TASK_STOPRX 

Stop UART receiver.

NRF_UARTE_TASK_STARTTX 

Start UART transmitter.

NRF_UARTE_TASK_STOPTX 

Stop UART transmitter.

NRF_UARTE_TASK_FLUSHRX 

Flush RX FIFO in RX buffer.

Function Documentation

◆ nrf_uarte_baudrate_set()

NRF_STATIC_INLINE void nrf_uarte_baudrate_set ( NRF_UARTE_Type *  p_reg,
nrf_uarte_baudrate_t  baudrate 
)

Function for setting UARTE baud rate.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]baudrateBaud rate.

◆ nrf_uarte_configure()

NRF_STATIC_INLINE void nrf_uarte_configure ( NRF_UARTE_Type *  p_reg,
nrf_uarte_config_t const *  p_cfg 
)

Function for configuring UARTE.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]p_cfgPointer to UARTE settings structure.

◆ nrf_uarte_cts_pin_get()

NRF_STATIC_INLINE uint32_t nrf_uarte_cts_pin_get ( NRF_UARTE_Type const *  p_reg)

Function for getting CTS pin selection.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
Returns
CTS pin selection.

◆ nrf_uarte_disable()

NRF_STATIC_INLINE void nrf_uarte_disable ( NRF_UARTE_Type *  p_reg)

Function for disabling UARTE.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.

◆ nrf_uarte_enable()

NRF_STATIC_INLINE void nrf_uarte_enable ( NRF_UARTE_Type *  p_reg)

Function for enabling UARTE.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.

◆ nrf_uarte_errorsrc_get_and_clear()

NRF_STATIC_INLINE uint32_t nrf_uarte_errorsrc_get_and_clear ( NRF_UARTE_Type *  p_reg)

Function for getting error source mask. Function is clearing error source flags after reading.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
Returns
Mask with error source flags.

◆ nrf_uarte_event_address_get()

NRF_STATIC_INLINE uint32_t nrf_uarte_event_address_get ( NRF_UARTE_Type const *  p_reg,
nrf_uarte_event_t  event 
)

Function for returning the address of the specified UARTE event register.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]eventThe specified event.
Returns
Address of specified event register.

◆ nrf_uarte_event_check()

NRF_STATIC_INLINE bool nrf_uarte_event_check ( NRF_UARTE_Type const *  p_reg,
nrf_uarte_event_t  event 
)

Function for retrieving the state of the UARTE event.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]eventEvent to be checked.
Return values
trueThe event has been generated.
falseThe event has not been generated.

◆ nrf_uarte_event_clear()

NRF_STATIC_INLINE void nrf_uarte_event_clear ( NRF_UARTE_Type *  p_reg,
nrf_uarte_event_t  event 
)

Function for clearing a specific UARTE event.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]eventEvent to clear.

◆ nrf_uarte_hwfc_pins_disconnect()

NRF_STATIC_INLINE void nrf_uarte_hwfc_pins_disconnect ( NRF_UARTE_Type *  p_reg)

Function for disconnecting flow control pins.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.

◆ nrf_uarte_hwfc_pins_set()

NRF_STATIC_INLINE void nrf_uarte_hwfc_pins_set ( NRF_UARTE_Type *  p_reg,
uint32_t  pselrts,
uint32_t  pselcts 
)

Function for configuring flow control pins.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]pselrtsRTS pin number.
[in]pselctsCTS pin number.

◆ nrf_uarte_int_disable()

NRF_STATIC_INLINE void nrf_uarte_int_disable ( NRF_UARTE_Type *  p_reg,
uint32_t  mask 
)

Function for disabling the specified interrupts.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]maskMask of interrupts to be disabled.

◆ nrf_uarte_int_enable()

NRF_STATIC_INLINE void nrf_uarte_int_enable ( NRF_UARTE_Type *  p_reg,
uint32_t  mask 
)

Function for enabling UARTE interrupts.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]maskMask of interrupts to be enabled.

◆ nrf_uarte_int_enable_check()

NRF_STATIC_INLINE uint32_t nrf_uarte_int_enable_check ( NRF_UARTE_Type const *  p_reg,
uint32_t  mask 
)

Function for checking if the specified interrupts are enabled.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]maskMask of interrupts to be checked.
Returns
Mask of enabled interrupts.

◆ nrf_uarte_publish_clear()

NRF_STATIC_INLINE void nrf_uarte_publish_clear ( NRF_UARTE_Type *  p_reg,
nrf_uarte_event_t  event 
)

Function for clearing the publish configuration for a given UARTE event.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]eventEvent for which to clear the configuration.

◆ nrf_uarte_publish_set()

NRF_STATIC_INLINE void nrf_uarte_publish_set ( NRF_UARTE_Type *  p_reg,
nrf_uarte_event_t  event,
uint8_t  channel 
)

Function for setting the publish configuration for a given UARTE event.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]eventEvent for which to set the configuration.
[in]channelChannel through which to publish the event.

◆ nrf_uarte_rts_pin_get()

NRF_STATIC_INLINE uint32_t nrf_uarte_rts_pin_get ( NRF_UARTE_Type const *  p_reg)

Function for getting RTS pin selection.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
Returns
RTS pin selection.

◆ nrf_uarte_rx_amount_get()

NRF_STATIC_INLINE uint32_t nrf_uarte_rx_amount_get ( NRF_UARTE_Type const *  p_reg)

Function for getting number of bytes received in the last transaction.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
Return values
Amountof bytes received.

◆ nrf_uarte_rx_buffer_set()

NRF_STATIC_INLINE void nrf_uarte_rx_buffer_set ( NRF_UARTE_Type *  p_reg,
uint8_t *  p_buffer,
size_t  length 
)

Function for setting the receive buffer.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]p_bufferPointer to the buffer for received data.
[in]lengthMaximum number of data bytes to receive.

◆ nrf_uarte_rx_pin_get()

NRF_STATIC_INLINE uint32_t nrf_uarte_rx_pin_get ( NRF_UARTE_Type const *  p_reg)

Function for getting RX pin selection.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
Returns
RX pin selection.

◆ nrf_uarte_shorts_disable()

NRF_STATIC_INLINE void nrf_uarte_shorts_disable ( NRF_UARTE_Type *  p_reg,
uint32_t  mask 
)

Function for disabling UARTE shortcuts.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]maskShortcuts to be disabled.

◆ nrf_uarte_shorts_enable()

NRF_STATIC_INLINE void nrf_uarte_shorts_enable ( NRF_UARTE_Type *  p_reg,
uint32_t  mask 
)

Function for enabling UARTE shortcuts.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]maskShortcuts to be enabled.

◆ nrf_uarte_subscribe_clear()

NRF_STATIC_INLINE void nrf_uarte_subscribe_clear ( NRF_UARTE_Type *  p_reg,
nrf_uarte_task_t  task 
)

Function for clearing the subscribe configuration for a given UARTE task.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]taskTask for which to clear the configuration.

◆ nrf_uarte_subscribe_set()

NRF_STATIC_INLINE void nrf_uarte_subscribe_set ( NRF_UARTE_Type *  p_reg,
nrf_uarte_task_t  task,
uint8_t  channel 
)

Function for setting the subscribe configuration for a given UARTE task.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]taskTask for which to set the configuration.
[in]channelChannel through which to subscribe events.

◆ nrf_uarte_task_address_get()

NRF_STATIC_INLINE uint32_t nrf_uarte_task_address_get ( NRF_UARTE_Type const *  p_reg,
nrf_uarte_task_t  task 
)

Function for returning the address of the specified task register.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]taskTask.
Returns
Task address.

◆ nrf_uarte_task_trigger()

NRF_STATIC_INLINE void nrf_uarte_task_trigger ( NRF_UARTE_Type *  p_reg,
nrf_uarte_task_t  task 
)

Function for starting an UARTE task.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]taskTask.

◆ nrf_uarte_tx_amount_get()

NRF_STATIC_INLINE uint32_t nrf_uarte_tx_amount_get ( NRF_UARTE_Type const *  p_reg)

Function for getting number of bytes transmitted in the last transaction.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
Return values
Amountof bytes transmitted.

◆ nrf_uarte_tx_buffer_set()

NRF_STATIC_INLINE void nrf_uarte_tx_buffer_set ( NRF_UARTE_Type *  p_reg,
uint8_t const *  p_buffer,
size_t  length 
)

Function for setting the transmit buffer.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]p_bufferPointer to the buffer with data to send.
[in]lengthMaximum number of data bytes to transmit.

◆ nrf_uarte_tx_pin_get()

NRF_STATIC_INLINE uint32_t nrf_uarte_tx_pin_get ( NRF_UARTE_Type const *  p_reg)

Function for getting TX pin selection.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
Returns
TX pin selection.

◆ nrf_uarte_txrx_pins_disconnect()

NRF_STATIC_INLINE void nrf_uarte_txrx_pins_disconnect ( NRF_UARTE_Type *  p_reg)

Function for disconnecting TX/RX pins.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.

◆ nrf_uarte_txrx_pins_set()

NRF_STATIC_INLINE void nrf_uarte_txrx_pins_set ( NRF_UARTE_Type *  p_reg,
uint32_t  pseltxd,
uint32_t  pselrxd 
)

Function for configuring TX/RX pins.

Parameters
[in]p_regPointer to the structure of registers of the peripheral.
[in]pseltxdTXD pin number.
[in]pselrxdRXD pin number.

Documentation feedback | Developer Zone | Subscribe | Updated