Skip to content

Commit

Permalink
subsys/nfc : NFC subsystem + nRF NFCT drivers + nt3h2 driver + sample…
Browse files Browse the repository at this point in the history
… code

Signed-off-by: Hessel van der Molen <[email protected]>
  • Loading branch information
HesselM committed Oct 19, 2023
1 parent 0ec9675 commit d72d6e8
Show file tree
Hide file tree
Showing 145 changed files with 20,322 additions and 0 deletions.
1 change: 1 addition & 0 deletions drivers/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ add_subdirectory_ifdef(CONFIG_MODEM modem)
add_subdirectory_ifdef(CONFIG_NET_DRIVERS net)
add_subdirectory_ifdef(CONFIG_NET_L2_ETHERNET ethernet)
add_subdirectory_ifdef(CONFIG_NEURAL_NET_ACCEL neural_net)
add_subdirectory_ifdef(CONFIG_NFC nfc)
add_subdirectory_ifdef(CONFIG_PECI peci)
add_subdirectory_ifdef(CONFIG_PINCTRL pinctrl)
add_subdirectory_ifdef(CONFIG_PM_CPU_OPS pm_cpu_ops)
Expand Down
1 change: 1 addition & 0 deletions drivers/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ source "drivers/mm/Kconfig"
source "drivers/modem/Kconfig"
source "drivers/net/Kconfig"
source "drivers/neural_net/Kconfig"
source "drivers/nfc/Kconfig"
source "drivers/pcie/Kconfig"
source "drivers/peci/Kconfig"
source "drivers/pinctrl/Kconfig"
Expand Down
14 changes: 14 additions & 0 deletions drivers/nfc/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#
# Copyright (c) 2023 Sendrato
#
# SPDX-License-Identifier: Apache-2.0
#

if (CONFIG_NT3H2X11)
zephyr_sources(nt3h2x11.c)
endif()

if (CONFIG_NRFXNFC)
zephyr_sources(nrfxnfc.c)
add_subdirectory(nrfxnfc)
endif()
8 changes: 8 additions & 0 deletions drivers/nfc/Kconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#
# Copyright (c) 2023 Sendrato
#
# SPDX-License-Identifier: Apache-2.0
#

rsource "Kconfig.nt3h2x11"
rsource "Kconfig.nrfxnfc"
41 changes: 41 additions & 0 deletions drivers/nfc/Kconfig.nrfxnfc
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
#
# Copyright (c) 2023 Sendrato
#
# SPDX-License-Identifier: Apache-2.0
#

config NRFXNFC
bool "nRFx-NFC driver"
default n
help
Enable nRFx NFC driver.

if NRFXNFC

config NRFXNFC_DRV_NAME
string "Device Tree name of nRFx-NFC driver"
default "nRFxNFC"
help
Device Tree name of nRFx-NFC driver.

config NRFXNFC_T2T
bool "Enable NFC Type 2 Tag library"
default n
select NFC_T2T_NRFXLIB

config NRFXNFC_T4T
bool "Enable NFC Type 4 Tag library"
default n
select NFC_T4T_NRFXLIB

config NRFXNFC_INIT_PRIORITY
int "NRFXNFC NFC driver init priority"
default 75

config NRFXNFC_MAX_PAYLOAD_SIZE
int "Max payload in bytes"
default 988

rsource "nrfxnfc/Kconfig"

endif # NRFXNFC
36 changes: 36 additions & 0 deletions drivers/nfc/Kconfig.nt3h2x11
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
#
# Copyright (c) 2023 Sendrato
#
# SPDX-License-Identifier: Apache-2.0
#

config NT3H2X11
bool "NT3H2X11 NFC driver"
default n
depends on I2C
help
Enable I2C-based driver for NT3H2X11 led driver.

if NT3H2X11

config NT3H2X11_2K
bool "Use 2k memory map instead of 1k"
default n
help
Use 2k memory map instead of 1k

config NT3H2X11_MAX_WRITE_DELAY
int "delay in ms"
default 10
help
Max I2C write delay in ms for when writing EEPROM

config NT3H2X11_INIT_PRIORITY
int "NT3H2X11 NFC driver init priority"
default 75

module = NT3H2X11
module-str = nt3h2x11
source "${ZEPHYR_BASE}/subsys/logging/Kconfig.template.log_config"

endif # NT3H2X11
Loading

0 comments on commit d72d6e8

Please sign in to comment.