Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DE-10 Lite Doesn't Work #55

Open
ghost opened this issue Feb 14, 2021 · 0 comments
Open

DE-10 Lite Doesn't Work #55

ghost opened this issue Feb 14, 2021 · 0 comments

Comments

@ghost
Copy link

ghost commented Feb 14, 2021

I have tried to use the following example code:

from nmigen import *

from nmigen_boards.de10_lite import *

from nmigen.build import *
from nmigen.vendor.intel import *
from nmigen_boards.upduino_v2 import *

class Blinky(Elaboratable):
    def elaborate(self, platform):
        led   = platform.request("led", 0)
        timer = Signal(20)

        m = Module()
        m.d.sync += timer.eq(timer + 1)
        m.d.comb += led.o.eq(timer[-1])
        return m


if __name__ == "__main__":
    platform = DE10LitePlatform()
    platform.build(Blinky(), do_program=True)

But I get this error:

Traceback (most recent call last):
  File "/run/media/sci4me/ldata/Projects/nmigen-test/test.py", line 22, in <module>
    platform.build(Blinky(), do_program=True)
  File "/usr/lib/python3.9/site-packages/nmigen/build/plat.py", line 78, in build
    plan = self.prepare(elaboratable, name, **kwargs)
  File "/usr/lib/python3.9/site-packages/nmigen/build/plat.py", line 120, in prepare
    fragment._propagate_domains(self.create_missing_domain, platform=self)
  File "/usr/lib/python3.9/site-packages/nmigen/hdl/ir.py", line 380, in _propagate_domains
    new_domains = self._create_missing_domains(missing_domain, platform=platform)
  File "/usr/lib/python3.9/site-packages/nmigen/hdl/ir.py", line 356, in _create_missing_domains
    value = missing_domain(domain_name)
  File "/usr/lib/python3.9/site-packages/nmigen/build/plat.py", line 102, in create_missing_domain
    clk_i = self.request(self.default_clk).i
  File "/usr/lib/python3.9/site-packages/nmigen/build/res.py", line 62, in request
    resource = self.lookup(name, number)
  File "/usr/lib/python3.9/site-packages/nmigen/build/res.py", line 57, in lookup
    raise ResourceError("Resource {}#{} does not exist"
nmigen.build.res.ResourceError: Resource clk50#0 does not exist

Switching to DE-10 Nano, for example, does not have this problem and works just fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

0 participants