Skip to content

Files

Latest commit

 

History

History

NfcCxSample

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
page_type description languages products
sample
Sample code for creating a NFC driver using the NFC Class Extension.
cpp
windows
windows-wdk

NFC CX client driver sample

A template for creating an NFC functional driver using the NFC Class Extension (CX) driver.

This is a complete version of the code created in the NFC CX quick start guide.

Prerequisites

To use the NFC CX, your NFC Controller must implement NFC Forum's NFC Controller Interface (NCI) protocol.

In addition, the NFC CX requires the driver to use the UMDF 2 framework.

Universal windows driver compliant

This sample builds a Universal Windows Driver. It uses only APIs and DDIs that are included in OneCoreUAP.

File manifest

WDK

  • NfcCx.h - The NFC CX's client driver API. This file is included in the WDK.

Project

  • Driver.cpp

    • DriverEntry - Driver initialization.
  • Device.cpp

    • DeviceContext::AddDevice - Device initialization, including initializing the NFC CX driver.
    • DeviceContext::WriteNciPacket - The implementation of the EvtNfcCxWriteNciPacket callback function.
    • DeviceContext::ReadNciPacket - Demonstrates calling NfcCxNciReadNotification.
  • Device.h

    • DeviceContext - The class that stores the device instance's state.