From 7573205a935cbe84e573b4cee3664bb344e3eddf Mon Sep 17 00:00:00 2001 From: iceman1001 Date: Tue, 10 May 2022 07:34:17 +0200 Subject: [PATCH] fix iclass simulation --- armsrc/appmain.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/armsrc/appmain.c b/armsrc/appmain.c index e329b2e23..e0dabebd0 100644 --- a/armsrc/appmain.c +++ b/armsrc/appmain.c @@ -1712,8 +1712,12 @@ static void PacketReceived(PacketCommandNG *packet) { break; } case CMD_HF_ICLASS_EML_MEMSET: { - //iceman, should call FPGADOWNLOAD before, since it corrupts BigBuf - FpgaDownloadAndGo(FPGA_BITSTREAM_HF); + //----------------------------------------------------------------------------- + // Note: we call FpgaDownloadAndGo(FPGA_BITSTREAM_HF_15) here although FPGA is not + // involved in dealing with emulator memory. But if it is called later, it might + // destroy the Emulator Memory. + //----------------------------------------------------------------------------- + FpgaDownloadAndGo(FPGA_BITSTREAM_HF_15); struct p { uint16_t offset; uint16_t len;