mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-19 21:03:48 -07:00
fix: FPGA config for ICOPYX
This commit is contained in:
parent
cad92c4a05
commit
9dd5b66c0a
3 changed files with 4 additions and 10 deletions
|
@ -39,7 +39,7 @@ typedef struct {
|
||||||
typedef lz4_stream_t *lz4_streamp_t;
|
typedef lz4_stream_t *lz4_streamp_t;
|
||||||
|
|
||||||
// remember which version of the bitstream we have already downloaded to the FPGA
|
// remember which version of the bitstream we have already downloaded to the FPGA
|
||||||
static int downloaded_bitstream = 0;
|
static int downloaded_bitstream = FPGA_BITSTREAM_UNKNOWN;
|
||||||
|
|
||||||
// this is where the bitstreams are located in memory:
|
// this is where the bitstreams are located in memory:
|
||||||
extern uint32_t _binary_obj_fpga_all_bit_z_start[], _binary_obj_fpga_all_bit_z_end[];
|
extern uint32_t _binary_obj_fpga_all_bit_z_start[], _binary_obj_fpga_all_bit_z_end[];
|
||||||
|
@ -464,7 +464,7 @@ static bool FpgaConfCurrentMode(int bitstream_target) {
|
||||||
// fpga "XC3S100E" image merge
|
// fpga "XC3S100E" image merge
|
||||||
// If fpga image is no init
|
// If fpga image is no init
|
||||||
// We need load hf_lf_allinone.bit
|
// We need load hf_lf_allinone.bit
|
||||||
if (downloaded_bitstream != 0) {
|
if (downloaded_bitstream != FPGA_BITSTREAM_UNKNOWN) {
|
||||||
// test start
|
// test start
|
||||||
// PIO controls the following pins
|
// PIO controls the following pins
|
||||||
AT91C_BASE_PIOA->PIO_PER = GPIO_FPGA_SWITCH;
|
AT91C_BASE_PIOA->PIO_PER = GPIO_FPGA_SWITCH;
|
||||||
|
|
|
@ -148,8 +148,8 @@ else ifeq ($(PLATFORM),PM3GENERIC)
|
||||||
PLATFORM_DEFS = -DLED_ORDER_PM3EASY
|
PLATFORM_DEFS = -DLED_ORDER_PM3EASY
|
||||||
endif
|
endif
|
||||||
else ifeq ($(PLATFORM),PM3ICOPYX)
|
else ifeq ($(PLATFORM),PM3ICOPYX)
|
||||||
# FPGA bitstream files, the order doesn't matter anymore - only hf has a bitstream, the other 3 files are 0 bytes
|
# FPGA bitstream files, the order doesn't matter anymore - only hf has a bitstream
|
||||||
FPGA_BITSTREAMS = fpga_icopyx_lf.bit fpga_icopyx_hf.bit fpga_icopyx_felica.bit fpga_icopyx_hf_15.bit
|
FPGA_BITSTREAMS = fpga_icopyx_hf.bit
|
||||||
PLATFORM_DEFS = -DWITH_FLASH -DICOPYX -DXC3
|
PLATFORM_DEFS = -DWITH_FLASH -DICOPYX -DXC3
|
||||||
PLTNAME = iCopy-X with XC3S100E
|
PLTNAME = iCopy-X with XC3S100E
|
||||||
PLATFORM_FPGA = xc3s100e
|
PLATFORM_FPGA = xc3s100e
|
||||||
|
|
|
@ -182,12 +182,6 @@ work:
|
||||||
$(Q)$(XILINX_TOOLS_PREFIX)par $(VERBOSITY) -w $< $@
|
$(Q)$(XILINX_TOOLS_PREFIX)par $(VERBOSITY) -w $< $@
|
||||||
|
|
||||||
%.bit: %.ncd
|
%.bit: %.ncd
|
||||||
# Hacky hack, make empty files for icopyx
|
|
||||||
if echo "$@" | grep -qi "icopyx"; then \
|
|
||||||
truncate -s0 ../fpga_icopyx_lf.bit; \
|
|
||||||
truncate -s0 ../fpga_icopyx_hf_15.bit; \
|
|
||||||
truncate -s0 ../fpga_icopyx_felica.bit; \
|
|
||||||
fi
|
|
||||||
$(Q)$(RM) $@ $*.drc $*.rbt
|
$(Q)$(RM) $@ $*.drc $*.rbt
|
||||||
$(info [=] BITGEN $@)
|
$(info [=] BITGEN $@)
|
||||||
$(Q)$(XILINX_TOOLS_PREFIX)bitgen $(VERBOSITY) -w $* $@
|
$(Q)$(XILINX_TOOLS_PREFIX)bitgen $(VERBOSITY) -w $* $@
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue