mirror of
https://github.com/saymrwulf/litex-boards.git
synced 2026-11-18 09:41:45 +00:00
pr243: Make led_chaser optional.
This commit is contained in:
parent
9835bd5f93
commit
0ca203487b
3 changed files with 17 additions and 14 deletions
|
|
@ -115,7 +115,8 @@ def addAsyncSram(soc, platform, name, origin, size):
|
||||||
class BaseSoC(SoCCore):
|
class BaseSoC(SoCCore):
|
||||||
def __init__(self, variant="a7-35",
|
def __init__(self, variant="a7-35",
|
||||||
toolchain="vivado",
|
toolchain="vivado",
|
||||||
sys_clk_freq=int(100e6),
|
sys_clk_freq=int(100e6),
|
||||||
|
with_led_chaser=True,
|
||||||
ident_version=True,
|
ident_version=True,
|
||||||
with_jtagbone=True,
|
with_jtagbone=True,
|
||||||
with_mapped_flash=False,
|
with_mapped_flash=False,
|
||||||
|
|
@ -136,9 +137,10 @@ class BaseSoC(SoCCore):
|
||||||
addAsyncSram(self,platform,"main_ram",0x40000000,512*1024)
|
addAsyncSram(self,platform,"main_ram",0x40000000,512*1024)
|
||||||
|
|
||||||
# Leds -------------------------------------------------------------------------------------
|
# Leds -------------------------------------------------------------------------------------
|
||||||
self.submodules.leds = LedChaser(
|
if with_led_chaser:
|
||||||
pads = platform.request_all("user_led"),
|
self.submodules.leds = LedChaser(
|
||||||
sys_clk_freq = sys_clk_freq)
|
pads = platform.request_all("user_led"),
|
||||||
|
sys_clk_freq = sys_clk_freq)
|
||||||
|
|
||||||
# Build --------------------------------------------------------------------------------------------
|
# Build --------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -168,7 +168,7 @@ def addCellularRAM(soc, platform, name, origin):
|
||||||
# BaseSoC ------------------------------------------------------------------------------------------
|
# BaseSoC ------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
class BaseSoC(SoCCore):
|
class BaseSoC(SoCCore):
|
||||||
def __init__(self, sys_clk_freq=int(75e6), with_ethernet=False, with_etherbone=False, with_video_terminal=False, with_video_framebuffer=False, **kwargs):
|
def __init__(self, sys_clk_freq=int(75e6), with_led_chaser=True, with_ethernet=False, with_etherbone=False, with_video_terminal=False, with_video_framebuffer=False, **kwargs):
|
||||||
platform = digilent_nexys4.Platform()
|
platform = digilent_nexys4.Platform()
|
||||||
|
|
||||||
# SoCCore ----------------------------------_-----------------------------------------------
|
# SoCCore ----------------------------------_-----------------------------------------------
|
||||||
|
|
@ -201,9 +201,10 @@ class BaseSoC(SoCCore):
|
||||||
self.add_video_framebuffer(phy=self.videophy, timings="800x600@60Hz", clock_domain="vga")
|
self.add_video_framebuffer(phy=self.videophy, timings="800x600@60Hz", clock_domain="vga")
|
||||||
|
|
||||||
# Leds -------------------------------------------------------------------------------------
|
# Leds -------------------------------------------------------------------------------------
|
||||||
self.submodules.leds = LedChaser(
|
if with_led_chaser:
|
||||||
pads = platform.request_all("user_led"),
|
self.submodules.leds = LedChaser(
|
||||||
sys_clk_freq = sys_clk_freq)
|
pads = platform.request_all("user_led"),
|
||||||
|
sys_clk_freq = sys_clk_freq)
|
||||||
|
|
||||||
# Build --------------------------------------------------------------------------------------------
|
# Build --------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -112,11 +112,11 @@ class BaseSoC(SoCCore):
|
||||||
def __init__(self,
|
def __init__(self,
|
||||||
variant="a7-35",
|
variant="a7-35",
|
||||||
toolchain="vivado",
|
toolchain="vivado",
|
||||||
sys_clk_freq=int(100e6),
|
sys_clk_freq=int(100e6),
|
||||||
|
with_led_chaser=True,
|
||||||
ident_version=True,
|
ident_version=True,
|
||||||
with_jtagbone=True,
|
with_jtagbone=True,
|
||||||
with_mapped_flash=False,
|
with_mapped_flash=False,
|
||||||
enable_leds = True,
|
|
||||||
**kwargs):
|
**kwargs):
|
||||||
|
|
||||||
platform = micronova_mercury2.Platform()
|
platform = micronova_mercury2.Platform()
|
||||||
|
|
@ -136,10 +136,10 @@ class BaseSoC(SoCCore):
|
||||||
#self.add_timer()
|
#self.add_timer()
|
||||||
|
|
||||||
# Leds -------------------------------------------------------------------------------------
|
# Leds -------------------------------------------------------------------------------------
|
||||||
if enable_leds:
|
if with_led_chaser:
|
||||||
self.submodules.leds = LedChaser(
|
self.submodules.leds = LedChaser(
|
||||||
pads = platform.request_all("user_led"),
|
pads = platform.request_all("user_led"),
|
||||||
sys_clk_freq = sys_clk_freq)
|
sys_clk_freq = sys_clk_freq)
|
||||||
|
|
||||||
# Build --------------------------------------------------------------------------------------------
|
# Build --------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue