Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nfc_magic: Fix support of 4K fobs #102

Merged
merged 3 commits into from
Jan 2, 2024
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions nfc_magic/lib/magic/protocols/gen4/gen4_poller.c
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ static NfcCommand gen4_poller_write_mf_classic(Gen4Poller* instance) {
instance->config[25] = iso3_data->atqa[1];
instance->config[26] = iso3_data->sak;
instance->config[27] = 0x00;
instance->config[28] = instance->total_blocks;
instance->config[28] = instance->total_blocks - 1;
instance->config[29] = 0x01;

Gen4PollerError error = gen4_poller_set_config(
Expand Down Expand Up @@ -353,7 +353,7 @@ static NfcCommand gen4_poller_write_mf_ultralight(Gen4Poller* instance) {
instance->config[25] = iso3_data->atqa[1];
instance->config[26] = iso3_data->sak;
instance->config[27] = 0x00;
instance->config[28] = instance->total_blocks;
instance->config[28] = instance->total_blocks - 1;
instance->config[29] = 0x01;

Gen4PollerError error = gen4_poller_set_config(
Expand Down