TWIS peripheral driver configuration

nRF5 SDK v12.2.0

Macros

#define TWIS_ENABLED
Set to 1 to activate. More...
#define TWIS_DEFAULT_CONFIG_ADDR0
Address0. More...
#define TWIS_DEFAULT_CONFIG_ADDR1
Address1. More...
#define TWIS_DEFAULT_CONFIG_SCL_PULL
SCL pin pull configuration. More...
#define TWIS_DEFAULT_CONFIG_SDA_PULL
SDA pin pull configuration. More...
#define TWIS_DEFAULT_CONFIG_IRQ_PRIORITY
Interrupt priority. More...
#define TWIS0_ENABLED
Enable TWIS0 instance. More...
#define TWIS1_ENABLED
Enable TWIS1 instance. More...
#define TWIS_ASSUME_INIT_AFTER_RESET_ONLY
Assume that any instance would be initialized only once. More...
#define TWIS_NO_SYNC_MODE
Remove support for synchronous mode. More...
#define TWIS_CONFIG_LOG_ENABLED
Enables logging in the module. More...
#define TWIS_CONFIG_LOG_LEVEL
Default Severity level. More...
#define TWIS_CONFIG_INFO_COLOR
ANSI escape code prefix. More...
#define TWIS_CONFIG_DEBUG_COLOR
ANSI escape code prefix. More...

Detailed Description

Macro Definition Documentation

#define TWIS0_ENABLED

Enable TWIS0 instance.

Set to 1 to activate.

Note
This is an NRF_CONFIG macro.
#define TWIS1_ENABLED

Enable TWIS1 instance.

Set to 1 to activate.

Note
This is an NRF_CONFIG macro.
#define TWIS_ASSUME_INIT_AFTER_RESET_ONLY

Assume that any instance would be initialized only once.

Optimization flag. Registers used by TWIS are shared by other peripherals. Normally, during initialization driver tries to clear all registers to known state before doing the initialization itself. This gives initialization safe procedure, no matter when it would be called. If you activate TWIS only once and do never uninitialize it - set this flag to 1 what gives more optimal code.

Set to 1 to activate.

Note
This is an NRF_CONFIG macro.
#define TWIS_CONFIG_DEBUG_COLOR

ANSI escape code prefix.

Following options are available:

  • 0 - Default
  • 1 - Black
  • 2 - Red
  • 3 - Green
  • 4 - Yellow
  • 5 - Blue
  • 6 - Magenta
  • 7 - Cyan
  • 8 - White
Note
This is an NRF_CONFIG macro.
#define TWIS_CONFIG_INFO_COLOR

ANSI escape code prefix.

Following options are available:

  • 0 - Default
  • 1 - Black
  • 2 - Red
  • 3 - Green
  • 4 - Yellow
  • 5 - Blue
  • 6 - Magenta
  • 7 - Cyan
  • 8 - White
Note
This is an NRF_CONFIG macro.
#define TWIS_CONFIG_LOG_ENABLED

Enables logging in the module.

Set to 1 to activate.

Note
This is an NRF_CONFIG macro.
#define TWIS_CONFIG_LOG_LEVEL

Default Severity level.

Following options are available:

  • 0 - Off
  • 1 - Error
  • 2 - Warning
  • 3 - Info
  • 4 - Debug
Note
This is an NRF_CONFIG macro.
#define TWIS_DEFAULT_CONFIG_ADDR0

Address0.

Note
This is an NRF_CONFIG macro.
#define TWIS_DEFAULT_CONFIG_ADDR1

Address1.

Note
This is an NRF_CONFIG macro.
#define TWIS_DEFAULT_CONFIG_IRQ_PRIORITY

Interrupt priority.

Priorities 0,2 (nRF51) and 0,1,4,5 (nRF52) are reserved for SoftDevice

Following options are available:

  • 0 - 0 (highest)
  • 1 - 1
  • 2 - 2
  • 3 - 3
  • 4 - 4 (except nRF51 family)
  • 5 - 5 (except nRF51 family)
  • 6 - 6 (except nRF51 family)
  • 7 - 7 (except nRF51 family)
Note
This is an NRF_CONFIG macro.
#define TWIS_DEFAULT_CONFIG_SCL_PULL

SCL pin pull configuration.

Following options are available:

  • 0 - Disabled
  • 1 - Pull down
  • 3 - Pull up
Note
This is an NRF_CONFIG macro.
#define TWIS_DEFAULT_CONFIG_SDA_PULL

SDA pin pull configuration.

Following options are available:

  • 0 - Disabled
  • 1 - Pull down
  • 3 - Pull up
Note
This is an NRF_CONFIG macro.
#define TWIS_ENABLED

Set to 1 to activate.

Note
This is an NRF_CONFIG macro.
#define TWIS_NO_SYNC_MODE

Remove support for synchronous mode.

Synchronous mode would be used in specific situations. And it uses some additional code and data memory to safely process state machine by polling it in status functions. If this functionality is not required it may be disabled to free some resources.

Set to 1 to activate.

Note
This is an NRF_CONFIG macro.