Online Store

µFR Nano Online Reader Implementation Basics

µFR Nano Online Reader implementation basics #

This section will describe how to use the µFR Nano Online reader.

UDP/TCP communication #

  • All bytes sent to UDP/TCP port 1 will be forwarded to UART1 and vice versa
  • All bytes sent to UDP/TCP port 2 will be forwarded to UART2 and vice versa
  • µFR Series libraries have support for UDP/TCP communication
  • UDP/TCP mode works in parallel with Transparent and HTTP mode.

UDP/TCP communication – Reader opening example #

/*

Opening reader on IP address 192.168.1.112 and port 8881 for UDP communication. */

ReaderOpenEx(0, “192.168.1.112:8881”, ‘U’, 0);

/*

Opening the reader on IP address 192.168.1.112 and port 8881 for TCP communication. */

ReaderOpenEx(0, “192.168.1.112:8881”, ‘T’, 0);

Bluetooth serial mode communication #

  • All bytes sent to the Bluetooth serial port will be forwarded to UART1 or UART2 and vice versa.
  • Bluetooth mode doesn’t work in parallel with UDP/TCP and HTTP mode.

Bluetooth serial mode communication – Reader opening example #

/*

Opening reader in Bluetooth serial mode on virtual port COM34. Must disable reset on opening. */

ReaderOpenEx(2, “COM34”, 0, “UNIT_OPEN_RESET_DISABLE”);

Bluetooth serial mode communication #

  • All bytes sent to the USB serial port will be forwarded to UART1 or UART2 and vice versa.
  • The transparent mode works in parallel with UDP/TCP and HTTP mode.

Transparent mode communication – Reader opening example #

/*

Opening the reader in Transparent mode. Must disable reset on opening.

*/

ReaderOpenEx(2, 0, 0, “UNIT_OPEN_RESET_DISABLE”);

HTTP mode communication #

  • All HEX string bytes sent in POST body will be forwarded to UART1 or UART2 and vice versa.
  • HTTP mode works in parallel with UDP/TCP and Transparent mode.

HTTP mode communication – GetCardIdEx example #

/*

Getting Card ID in HTTP mode using an HTTP POST request.

*/

HTTP POST Request body sent to µFR Reader /uart1 or /uart2 > 557caa00aaccec

HTTP POST Response body sent from µFR Reader > de7ced0b08044f52dad995000000000000cb

Scroll Up