命令nfc的pn532 读写命令格式(NFC pn532 read and write command format)

format命令  时间:2021-03-24  阅读:()

nfc的pn532读写命令格式NFC pn532 read and write commandf ormat

The PN532 command PN532 command (S50)

Note: 1, this article only for pn532 and S50 communication card.2, Pn532 and PC for the serial communication, baud rate 115200,8 data bits, 1 stop bit and parity none

3, unless otherwise stated, all sent to receive information andfollow the general frame format

4, all the operation of the EEPROM must be authenticatedGeneral frame format: (normal send and receive commands anddata to follow this format)

ACK frame format:

NACK frame format:

Extended frame format:

Error: frame format (prompt application layer error,unrecognized command or parameter error)

Command set:

Wake up: 5555000000000000 FF 03 FD 0000000000000000D4 14011700

Explanation: 1, 5555000000000000 and 000000000000 wake-upcommand is special, only this part of the order, on behalf ofwaiting

2, the SAMConfiguration command, where 01 represents aconfiguration for the normal mode

Example: 0000 FF 00 FF 000000 return information FF 02 FE D5

151600

Explain:

1, ACK

2, D5 15 performed correctly and completed

Get UID:00 FF 04 FC 4A 0100 D4 00 E1 00

2, the baud rate value

Example: return data: 0000 FF 00 FF 000000 FF 0C F4 D5 4B010100040804 FB 0E E2 0B D8 00

Identity verification: 0000 FF LEN LCS D4 Addr FF FF FF FF FF400160 FF UID DCS 00

Example: enter the command: 0000 FF 0F F1 D4 FF FF FF FF 40016007FF FF FB 0E E2 0B 9400

Read: 0000 FF 05 FB D4 400130 Addr DCS 00

Explain:

The InDataExchange command, said the 01 target card number 30that read operations, Addr is to read the block addressExample: enter the command: FF 05 FB 0000 D4 40013004 B7 00Interpretation: 04 to read the block address

Return information: 0000 FF 00 FF 000000 FF 13 ED D5 4100 FFFF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FA 00

Explanation: 00 read success behind the data read dataWrite operation: 0000 FF 15 EB D44001 A0 Addr BlockData 4F 00Explain:

Addr to write the address of BlockData to write data.Example: enter the command: FF 15 EB 0000 D4 4001 A0

0401010101010101 0101010101010101 013700

Interpretation: in sector2 block1 write 01

Output: 0000 FF 00 FF 000000 FF 03 FD D5 4100 EA 00

Explanation: 00 successful writing

Enter the command: FF 05 FB 0000 D4 40013004 B7 00

Explanation: read the block data

Output: 0000 FF 00 FF 000000 FF 13 ED 4100010101010101 D50101010101010101 0101 DA 00

Explanation: obviously, the data read write data

Increase of operation: 0000 FF 09 F7 D4 4001 C1 Addr 01000000DCS 00

Reduction operation: 0000 FF 09 F7 D44001 C0 Addr 01000000 DCS

00

Transfer operation: 0000 FF 05 FB D4 4001 B0 Addr DCS 00Store operation: 0000 FF 05 FB D4 4001 C2 Addr DCS 00Turn off the radio frequency: 0000 FF 04 FC D4 320100 F9 00Explanation: the command for RFConfiguration 01, RF field said,the 00 turn off radio frequency

Example: enter the command: FF 04 FC 0000 D4 320100 F9 00Output: 0000 FF 00 FF 000000 FF 02 FE D5 33 F8 00

Explanation: D5 33 is finished, RF Field off

A M1 card, command analysis (No. 1 M1 card)

Key verification: according to the block number to verify the

same sector as long as verification of one piece, can operatewith a sector in the 4 block.

The operation of another sector, but also re verification.1, initialize the PN532 to the normal state

5555000000000000 in: 0000000000000000FF 03 FD 14011700 D4

Out:00 00 FF 00 FF 00

0000 FF 02 FE 151600 D5

2, find the card

In:00 00 FF 04 FC D4 4A 0200 E0 00

Analysi s: 4A / command

02 / / 0--2 card number.

00 / / 106K baud rate

Out:00 00 FF 00 FF 00

0000 FF 0C F4 D5 4B 01010004080402 F5 13 BE 0600

Analysis: 0000 FF 00 FF 00 //ACK

0000 FF 0C F4

D5 //PN532 to MCU

The 4B command / response

01 / 1 target card

01 / / target card number, maximum 0x02, minimum 0

0004 //atq

08 / / 08=1K card capacity

04 bytes of UID //4

02 F5 13 BE //UID

0600 //DCS+POST

3, key authentication

In:00 00 fF 0F F1 D4 FF FF FF FF FF 40016007 FF 02 F5 13 BE 00

C2

Analysis: 40 / / command

01 / 1 card

60 / / key authentication command

07 / /块号

ff ff ff ff ff ff / /密钥

02 f5 13 be / / uidout: 00 00 00 00 ff ff

00 00 ff 03 fd d5 41 00 ea 00

析: 41 00 / /正确状态

4、读卡/ / 07是控制字节in: 00 00 ff / fb d4 40 01 30 07 00 / /读第7块b4

00 00 ff 05 fb d4 40 01 30 06 00 / /读第6块b5

00 00 ff 05 fb d4 40 01 30 08 00 / /读第8块b3

析: 40 / /命令

01 /卡1

30 / /读卡命令

07 / /快号out: 00 00 00 ff ff 00 / / ack

00 00 ff 13 ed d5 4100 00 00 00 00 00 00ff ff ff ff ff 07 80

69 ff ff 01 00 / / 7块

out: 00 00 00 ff ff 00 / / ack

00 00 ff 13 ed d5 4100 00 00 00 00 00 00 00 00 00 00 00 00 00

00 00 00 00 / / 6块ea

析: 41 00 / /正确err: 00 00 00 00 ff ff

00 00 ff 03 fd d5 d7 00 41 13

析: 41 03 / /错误

5、写卡in: 00 00 ff 15 eb d4 40 01 a0 06 00 01 02 03 04 05 06 07 0809 0a 0b 0c 0d 0e 0f cd 00

析: 40 / /命令

01 /卡1a0 / /写卡命令

06 / /块号

00 01 02 03 04 05 06 07 08 09 0a 0b 0c 0d 0e 0f / / 16字节数据out: 00 00 00 00 00 ff ff

00 00 ff 03 fd d5 41 00 ea 00

附件:ff ff 00 00 00 00

00 00 ff 0f f1 d5 4b 01 01

00 44 / / 44代表什么呢?

00 / /不遵循iso14443 - 4标准

07

04 8f d7 5a cf 20 80

60 00

二、 p2p应用

1、初始化pn532到normal状态in: 55 5500 00 00 00 00 00 00 00 00 00 00 00 00 00ff 03 fdd4 14 01 17 00out: 00 00 00 00 ff ff

02 00 00 ff fe d5 15 16 00

/ * * * * * * * * * * * * nfc initial * * * * * * * * * * * *

* * * * /

10gbiz($2.36/月),香港/洛杉矶CN2 GIA线路VPS,香港/日本独立服务器

10gbiz发布了9月优惠方案,针对VPS、独立服务器、站群服务器、高防服务器等均提供了一系列优惠方面,其中香港/洛杉矶CN2 GIA线路VPS主机4折优惠继续,优惠后最低每月仅2.36美元起;日本/香港独立服务器提供特价款首月1.5折27.43美元起;站群/G口服务器首月半价,高防服务器永久8.5折等。这是一家成立于2020年的主机商,提供包括独立服务器租用和VPS主机等产品,数据中心包括美国洛...

RackNerd:便宜vps补货/1核/768M内存/12G SSD/2T流量/1G带宽,可选机房圣何塞/芝加哥/达拉斯/亚特拉大/荷兰/$9.49/年

RackNerd今天补货了3款便宜vps,最便宜的仅$9.49/年, 硬盘是SSD RAID-10 Storage,共享G口带宽,最低配给的流量也有2T,注意,这3款补货的便宜vps是intel平台。官方网站便宜VPS套餐机型均为KVM虚拟,SolusVM Control Panel ,硬盘是SSD RAID-10 Storage,共享G口带宽,大流量。CPU:1核心内存:768 MB硬盘:12 ...

rfchost:洛杉矶vps/双向CN2 GIA,1核/1G/10G SSD/500G流量/100Mbps/季付$23.9

rfchost怎么样?rfchost是一家开办了近六年的国人主机商,一般能挺过三年的国人商家,还是值得入手的,商家主要销售VPS,机房有美国洛杉矶/堪萨斯、中国香港,三年前本站分享过他家堪萨斯机房的套餐。目前rfchost商家的洛杉矶机房还是非常不错的,采用CN2优化线路,电信双程CN2 GIA,联通去程CN2 GIA,回程AS4837,移动走自己的直连线路,目前季付套餐还是比较划算的,有需要的可...

format命令为你推荐
操作httpflashwind谁能教我怎么在360里下载个flashwind?重庆电信断网电信光纤一直掉线,打电话问说是机房出了问题 要排查,已经一个星期了还没弄好,大概需要多久才能弄好?企业信息查询系统官网怎么在网上查询企业营业执照是否存在?dell服务器bios设置dell R410服务器 bios设置参数如何恢复出厂设置?文档下载怎么下载百度文档颁发的拼音大致的致的拼音12306.com如何登录1230635互联在中国哪家服务商提供的企业邮箱好呢?300051三五互联请问300051三五互联还会继续盘升吗?
香港虚拟主机 万网域名查询 域名备案批量查询 申请免费域名 vmsnap3 流媒体服务器 轻量 150邮箱 100x100头像 php空间申请 天互数据 国外免费全能空间 服务器维护方案 天翼云盘 上海联通宽带测速 360云服务 shuang12 美国盐湖城 广州虚拟主机 主机返佣 更多