mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-21 13:53:55 -07:00
compact address assignment
This commit is contained in:
parent
4c95c16e54
commit
18326934d6
1 changed files with 1 additions and 3 deletions
|
@ -607,9 +607,7 @@ int CmdEM4x50Read(const char *Cmd) {
|
||||||
case 'b': {
|
case 'b': {
|
||||||
param_getdec(Cmd, cmdp + 1, &address);
|
param_getdec(Cmd, cmdp + 1, &address);
|
||||||
// lsb: byte 1 = fwr, byte 2 = lwr, byte 3 = 0x0, byte 4 = 0x0
|
// lsb: byte 1 = fwr, byte 2 = lwr, byte 3 = 0x0, byte 4 = 0x0
|
||||||
etd.addresses = address; // lwr
|
etd.addresses = (address << 8) | address;
|
||||||
etd.addresses <<= 8;
|
|
||||||
etd.addresses |= address; // fwr
|
|
||||||
|
|
||||||
// validation
|
// validation
|
||||||
if (address <= 0 || address >= EM4X50_NO_WORDS) {
|
if (address <= 0 || address >= EM4X50_NO_WORDS) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue