mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-20 21:33:47 -07:00
chg: added the append_Crc option
This commit is contained in:
parent
0a1a48df01
commit
2fffe96773
1 changed files with 6 additions and 3 deletions
|
@ -76,7 +76,7 @@ function main(args)
|
||||||
end
|
end
|
||||||
|
|
||||||
local ignore_response = false
|
local ignore_response = false
|
||||||
local appendcrc = false
|
local append_crc = false
|
||||||
local stayconnected = false
|
local stayconnected = false
|
||||||
local payload = nil
|
local payload = nil
|
||||||
local doconnect = true
|
local doconnect = true
|
||||||
|
@ -87,7 +87,7 @@ function main(args)
|
||||||
for o, a in getopt.getopt(args, 'orcpx:dt3') do
|
for o, a in getopt.getopt(args, 'orcpx:dt3') do
|
||||||
if o == "o" then doconnect = false end
|
if o == "o" then doconnect = false end
|
||||||
if o == "r" then ignore_response = true end
|
if o == "r" then ignore_response = true end
|
||||||
if o == "c" then appendcrc = true end
|
if o == "c" then append_crc = true end
|
||||||
if o == "p" then stayconnected = true end
|
if o == "p" then stayconnected = true end
|
||||||
if o == "x" then payload = a end
|
if o == "x" then payload = a end
|
||||||
if o == "d" then DEBUG = true end
|
if o == "d" then DEBUG = true end
|
||||||
|
@ -108,7 +108,7 @@ function main(args)
|
||||||
|
|
||||||
-- The actual raw payload, if any
|
-- The actual raw payload, if any
|
||||||
if payload then
|
if payload then
|
||||||
res,err = sendRaw(payload,{ignore_response = ignore_response, topaz_mode = topaz_mode})
|
res,err = sendRaw(payload,{ignore_response = ignore_response, topaz_mode = topaz_mode, append_crc = append_crc})
|
||||||
if err then return oops(err) end
|
if err then return oops(err) end
|
||||||
|
|
||||||
if not ignoreresponse then
|
if not ignoreresponse then
|
||||||
|
@ -145,6 +145,9 @@ function sendRaw(rawdata, options)
|
||||||
if options.topaz_mode then
|
if options.topaz_mode then
|
||||||
flags = flags + lib14a.ISO14A_COMMAND.ISO14A_TOPAZMODE
|
flags = flags + lib14a.ISO14A_COMMAND.ISO14A_TOPAZMODE
|
||||||
end
|
end
|
||||||
|
if options.append_crc then
|
||||||
|
flags = flags + lib14a.ISO14A_COMMAND.ISO14A_APPEND_CRC
|
||||||
|
end
|
||||||
|
|
||||||
local command = Command:new{cmd = cmds.CMD_READER_ISO_14443a,
|
local command = Command:new{cmd = cmds.CMD_READER_ISO_14443a,
|
||||||
arg1 = flags, -- Send raw
|
arg1 = flags, -- Send raw
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue