+
+ CLIParserInit("hf iclass snoop", "\nSnoop a communication between an iClass Reader and an iClass Tag.", NULL);
+ void* argtable[] = {
+ arg_param_begin,
+ arg_lit0("j", "jam", "Jam (prevent) e-purse Updates"),
+ arg_param_end
+ };
+ if (CLIParserParseString(Cmd, argtable, arg_getsize(argtable), true)){
+ CLIParserFree();
+ return 0;
+ }
+
+ bool jam_epurse_update = arg_get_lit(1);
+
+ const uint8_t update_epurse_sequence[2] = {0x87, 0x02};
+
+ UsbCommand c = {CMD_SNOOP_ICLASS, {0}};
+ if (jam_epurse_update) {
+ c.arg[0] = sizeof(update_epurse_sequence);
+ memcpy(c.d.asBytes, update_epurse_sequence, sizeof(update_epurse_sequence));
+ }