33 lines
821 B
Plaintext
33 lines
821 B
Plaintext
RS485 bus protocol
|
|
|
|
Byte 1 : Message start = 0x7E
|
|
Byte 2 : Command is RPPduId
|
|
Byte 3 : Address 0x00 reserved for de busmaster
|
|
byte 4+ : Message
|
|
byte last - 1 : Checksum off preveiuis bytes
|
|
byte last : end of message = 0x7F
|
|
|
|
|
|
|
|
Commands
|
|
PDU_ID_0_RESERVED = 0x00,
|
|
POLL_REQUEST = 0x01,
|
|
STATUS_RESPONSE = 0x02,
|
|
CREDENTIAL_NOTIFICATION = 0x03,
|
|
INDICATION_REQUEST = 0x04,
|
|
SET_MIFARE_KEYS = 0x05,
|
|
SET_PARAMETER = 0x06,
|
|
GET_PARAMETER = 0x07,
|
|
GET_PARAMETER_RESPONSE = 0x08,
|
|
RESTART = 0x09,
|
|
|
|
|
|
PollRequest example
|
|
0x7E, 0x01, 0x00, 0x01, 0x6C, 0x07F => reader 1
|
|
0x7E, 0x01, 0x00, 0x02, 0x65, 0x07F => reader 2
|
|
|
|
Status response example
|
|
0x7E, 0x02, 0x01, 0x00, 0x01, 0x40, 0x07F => from reader 1
|
|
0x7E, 0x02, 0x02, 0x00, 0x01, 0xFD, 0x07F => from reader 2
|
|
|