X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/blobdiff_plain/d352146782cf2a886aff171b459e76324ac35bde..2e78fbaa1d62a89689fd12048db7e0b6be696a5e:/client/scripts/e.lua diff --git a/client/scripts/e.lua b/client/scripts/e.lua index 1d0833b4..a20b8e47 100644 --- a/client/scripts/e.lua +++ b/client/scripts/e.lua @@ -39,7 +39,7 @@ end -- The main entry point function main(args) - local data = '01020304' + local data local width = 0 -- Read the parameters @@ -49,6 +49,8 @@ function main(args) if o == "w" then width = a end end + data = data or '01020304' + print( string.rep('-',60) ) print('Bit width of CRC | '..width) print('Bytes | '..data) @@ -57,9 +59,13 @@ function main(args) print( string.rep('-',60) ) local lists = core.reveng_models(width) for _,i in pairs(lists) do - local one = core.reveng_runmodel(i, data, false, 0) - local two = core.reveng_runmodel(i, data, true, 0) - print( ('%-20s| %-16s| %s'):format(i, one, two) ) + local a1 = core.reveng_runmodel(i, data, false, '0') + local a2 = core.reveng_runmodel(i, data, true, '0') + local a3 = core.reveng_runmodel(i, data, false, 'b') + local a4 = core.reveng_runmodel(i, data, false, 'B') + local a5 = core.reveng_runmodel(i, data, false, 'l') + local a6 = core.reveng_runmodel(i, data, false, 'L') + print( ('%-20s| %-16s| %-16s| %-16s| %-16s| %-16s| %-16s'):format(i, a1:upper(), a2:upper(),a3:upper(),a4:upper(),a5:upper(),a6:upper() ) ) end end