
DC EMU Old SD Driver init (OzOnE)
By: a guest on
Jul 22nd, 2012 | syntax:
VeriLog | size: 0.59 KB | hits: 46 | expires: Never
if (CCS) // This should be HIGH if SD Card is SDHC.
Host_Command_Arg <= gd_start_sector * 4; // SDHC cards use 512-byte SECTOR addressing - Need to multiply the GD sector offset by 4.
else
Host_Command_Arg <= gd_start_sector * 2048; // Low-density SD Cards use BYTE addressing - Need to multiply the GD sector offset by 2048.
Host_Command_Type <= CMD_Multiple_Block_Read;
trig_Host_Command <= 1'b1;
state <= 10'd3;
end
3: begin
trig_Host_Command <= 1'b0; // Remember to only strobe "trig_Host_command" for ONE clock!!
state <= 10'd4;
end