mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-01-01 13:14:30 +08:00
Add HF simulator modulation mode for 212kHz subcarrier
This commit is contained in:
parent
789d706a7d
commit
ecf53cb215
3 changed files with 5 additions and 1 deletions
|
@ -56,6 +56,7 @@ void SetAdcMuxFor(DWORD whichGpio);
|
|||
// Options for the HF simulated tag, how to modulate
|
||||
#define FPGA_HF_SIMULATOR_NO_MODULATION (0<<0)
|
||||
#define FPGA_HF_SIMULATOR_MODULATE_BPSK (1<<0)
|
||||
#define FPGA_HF_SIMULATOR_MODULATE_212K (2<<0)
|
||||
// Options for ISO14443A
|
||||
#define FPGA_HF_ISO14443A_SNIFFER (0<<0)
|
||||
#define FPGA_HF_ISO14443A_TAGSIM_LISTEN (1<<0)
|
||||
|
|
BIN
fpga/fpga.bit
BIN
fpga/fpga.bit
Binary file not shown.
|
@ -51,7 +51,8 @@ begin
|
|||
end
|
||||
|
||||
// Divide 13.56 MHz by 32 to produce the SSP_CLK
|
||||
reg [4:0] ssp_clk_divider;
|
||||
// The register is bigger to allow higher division factors of up to /128
|
||||
reg [6:0] ssp_clk_divider;
|
||||
always @(posedge adc_clk)
|
||||
ssp_clk_divider <= (ssp_clk_divider + 1);
|
||||
assign ssp_clk = ssp_clk_divider[4];
|
||||
|
@ -87,6 +88,8 @@ always @(mod_type or ssp_clk or ssp_dout)
|
|||
modulating_carrier <= 1'b0; // no modulation
|
||||
else if(mod_type == 3'b001)
|
||||
modulating_carrier <= ssp_dout ^ ssp_clk_divider[3]; // XOR means BPSK
|
||||
else if(mod_type == 3'b010)
|
||||
modulating_carrier <= ssp_dout & ssp_clk_divider[5]; // switch 212kHz subcarrier on/off
|
||||
else
|
||||
modulating_carrier <= 1'b0; // yet unused
|
||||
|
||||
|
|
Loading…
Reference in a new issue