Table of Contents
µFR Nano Online Reader protocols structure #
This section will describe how to use the µFR Nano Online reader.
Master mode POST request
- In master mode, if the card is detected, the device sends an HTTP POST request to the host.
- HTTP response must be “OK” or “FAILED” for firmware version 1.5.4 and below.
- If the response is “OK”, the device will beep once and turn on the green LED.
- If the response is “FAILED”, the device will beep twice and turn on the red LED.
- If the server doesn’t respond, the device will beep three times and turn on the red LED.
- For firmware version 1.6.0 and above see Master mode POST response protocol section.
Master mode HTTP POST request structure #
* | Form parameters | ||||||
Linear read disabled | SN | UID | CTRLINFO | ONLINE | |||
Linear read enabled | SN | UID | CTRLINFO | ONLINE | DATA | ||
Reader Serial | Control | Number 1 or | Linear read | ||||
Description | Card UID | number from | 2 depends | data as HEX | |||
number | |||||||
0 to 255 | of reader | string |
The master mode POST response
- When the server receives a POST request, µFR Nano Online is waiting for an HTTP response
- The response contains HEX String commands from the µFR COM protocol
- The response has to contain 3 rows delimited by the newline character (\n), one for each UART
- CMD-EXT must be sent in one string preceded by CMD, without any delimiter
- Sending multiple commands can be done by splitting multiple strings with a whitespace delimiter.
Master mode HTTP POST response structure #
Command sent to | \n | Command sent to | \n | Command sent to Transparent |
UART2 | UART1 | UART |
- PHP Server API for handling Master mode request with example is available at https//code.d-logic.com/nfc-rfid-reader-sdk/µFR_online-examples-php-master_mode
Master mode UDP broadcast #
- In master mode, if the card is detected and UDP broadcast is enabled, the device sends UDP broadcast
- If an HTTP POST request is enabled, the indication is the same as described above
- If the HTTP POST request is disabled, the device will beep once and turn on the green LED.
Master mode UDP broadcast structure #
80/ReaderSerialNumber/CardUID/0
UDP discovery server #
- UDP discovery server is used for finding µFR readers in local networks
- Send any UDP packet to µFR reader port 8880 and wait for a response.
UDP discovery server response example #
* | UART 1 PORT | UART 2 PORT | |||||||||||||||||
* | IP address | Port | CP | Baud rate | Port | CP | Baud rate | ||||||||||||
DEC | 192 | 168 | 1 | 5 | 8881 | ‘T’ | 115200 | 8882 | ‘U’ | 250000 | |||||||||
HEX | C0 | A8 | 01 | 05 | B1 | 22 | 54 | 00 | C2 | 01 | 00 | B2 | 22 | 55 | 90 | D0 | 03 | 00 |
*CP is a network communication protocol. ‘T’ stands for TCP and ‘U’ for UDP.
µFR Nano Online only COM protocol commands #
- These commands are µFR Nano Online only
- Commands are sent in ASCII mode
- Commands are used in Transparent, BLE Serial, and BLE Low Energy mode.
Command | Description |
!TURN_MST_MODE_ON! | Toggle the device to WiFi master mode. |
!TURN_SLV_MODE_ON! | Toggle the device to WiFi slave mode. |
!TURN_BLE_MODE_ON! | Toggle the device to BLE Low Energy mode. |
!TURN_SPP_MODE_ON! | Toggle the device to BLE Serial mode. |
!TURN_HID_MODE_ON! | Toggle device to BLE HID mode. |
!TURN_AP0_MODE_ON! | Turn off Access Point when BLE is using. |
!TURN_AP1_MODE_ON! | Turn on Access Point when BLE is on. |
!TURN_LD0_MODE_ON! | Turn off the LED indication when BLE is on. |
!TURN_LD1_MODE_ON! | Turn on the LED indication when BLE is using. |