Skip to content

Commit

Permalink
arty: Add numato sd card pmod
Browse files Browse the repository at this point in the history
It has a different layout.

Signed-off-by: Joel Stanley <joel@jms.id.au>
  • Loading branch information
shenki committed Feb 23, 2021
1 parent a90c0bc commit d1189f8
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
18 changes: 18 additions & 0 deletions litex_boards/platforms/arty.py
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,7 @@ def sdcard_pmod_io(pmod):
IOStandard("LVCMOS33"),
),
("sdcard", 0,
# DAT0 DAT1 DAT2 DAT3
Subsignal("data", Pins(f"{pmod}:2 {pmod}:4 {pmod}:5 {pmod}:0"), Misc("PULLUP True")),
Subsignal("cmd", Pins(f"{pmod}:1"), Misc("PULLUP True")),
Subsignal("clk", Pins(f"{pmod}:3")),
Expand All @@ -306,6 +307,23 @@ def sdcard_pmod_io(pmod):
]
_sdcard_pmod_io = sdcard_pmod_io("pmodd") # SDCARD PMOD on JD.

def numato_sdcard_pmod_io(pmod):
return [
# SDCard PMOD:
# https://numato.com/product/micro-sd-expansion-module/
("sdcard", 0,
# DAT0 DAT1 DAT2 DAT3
Subsignal("data", Pins(f"{pmod}:6 {pmod}:2 {pmod}:4 {pmod}:0"), Misc("PULLUP True")),
Subsignal("cmd", Pins(f"{pmod}:5"), Misc("PULLUP True")),
Subsignal("clk", Pins(f"{pmod}:1")),
# Subsignal("cd", Pins(f"{pmod}:3")), # not connected
Misc("SLEW=FAST"),
IOStandard("LVCMOS33"),
),
]
_numato_sdcard_pmod_io = numato_sdcard_pmod_io("pmodd") # SDCARD PMOD on JD.


# Platform -----------------------------------------------------------------------------------------

class Platform(XilinxPlatform):
Expand Down
2 changes: 1 addition & 1 deletion litex_boards/targets/arty.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def main():
ident_version = args.no_ident_version,
**soc_sdram_argdict(args)
)
soc.platform.add_extension(arty._sdcard_pmod_io)
soc.platform.add_extension(arty._numato_sdcard_pmod_io)
if args.with_spi_sdcard:
soc.add_spi_sdcard()
if args.with_sdcard:
Expand Down

0 comments on commit d1189f8

Please sign in to comment.