Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Reform
rkx7-litex-boards
Commits
18582739
Commit
18582739
authored
Sep 30, 2021
by
Florent Kermarrec
Browse files
mnt_rkx7: Add SPI SDCard support.
parent
05f31583
Changes
2
Hide whitespace changes
Inline
Side-by-side
litex_boards/platforms/mnt_rkx7.py
View file @
18582739
...
...
@@ -29,6 +29,14 @@ _io = [
),
# SDCard.
(
"spisdcard"
,
0
,
Subsignal
(
"clk"
,
Pins
(
"C11"
)),
Subsignal
(
"mosi"
,
Pins
(
"A15"
),
Misc
(
"PULLUP True"
)),
Subsignal
(
"cs_n"
,
Pins
(
"B15"
),
Misc
(
"PULLUP True"
)),
Subsignal
(
"miso"
,
Pins
(
"A14"
),
Misc
(
"PULLUP True"
)),
Misc
(
"SLEW=FAST"
),
IOStandard
(
"LVCMOS18"
),
),
(
"sdcard"
,
0
,
Subsignal
(
"data"
,
Pins
(
"A14 B10 A12 B15"
),
Misc
(
"PULLUP True"
)),
Subsignal
(
"cmd"
,
Pins
(
"A15"
),
Misc
(
"PULLUP True"
)),
...
...
litex_boards/targets/mnt_rkx7.py
View file @
18582739
...
...
@@ -90,7 +90,6 @@ class BaseSoC(SoCCore):
if
with_etherbone
:
self
.
add_etherbone
(
phy
=
self
.
ethphy
)
# I2C --------------------------------------------------------------------------------------
self
.
submodules
.
i2c
=
I2CMaster
(
platform
.
request
(
"i2c"
))
...
...
@@ -102,7 +101,9 @@ def main():
parser
.
add_argument
(
"--load"
,
action
=
"store_true"
,
help
=
"Load bitstream"
)
parser
.
add_argument
(
"--sys-clk-freq"
,
default
=
125e6
,
help
=
"System clock frequency (default: 125MHz)"
)
parser
.
add_argument
(
"--with-spi-flash"
,
action
=
"store_true"
,
help
=
"Enable SPI Flash (MMAPed)"
)
parser
.
add_argument
(
"--with-sdcard"
,
action
=
"store_true"
,
help
=
"Enable SDCard support"
)
sdopts
=
parser
.
add_mutually_exclusive_group
()
sdopts
.
add_argument
(
"--with-spi-sdcard"
,
action
=
"store_true"
,
help
=
"Enable SPI-mode SDCard support"
)
sdopts
.
add_argument
(
"--with-sdcard"
,
action
=
"store_true"
,
help
=
"Enable SDCard support"
)
ethopts
=
parser
.
add_mutually_exclusive_group
()
ethopts
.
add_argument
(
"--with-ethernet"
,
action
=
"store_true"
,
help
=
"Enable Ethernet support"
)
ethopts
.
add_argument
(
"--with-etherbone"
,
action
=
"store_true"
,
help
=
"Enable Etherbone support"
)
...
...
@@ -117,6 +118,8 @@ def main():
with_spi_flash
=
args
.
with_spi_flash
,
**
soc_core_argdict
(
args
)
)
if
args
.
with_spi_sdcard
:
soc
.
add_spi_sdcard
()
if
args
.
with_sdcard
:
soc
.
add_sdcard
()
builder
=
Builder
(
soc
,
**
builder_argdict
(
args
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment