LoginSignup
0
0

More than 3 years have passed since last update.

vistaでquartus その3

Last updated at Posted at 2020-06-10

概要

vistaでquartusやってみた。
polyphonyでserial叩いてみた。

環境

windows vista 32bit
quartus ii v13.0
ep2c5t144ボード

写真

CIMG2956.JPG

image

サンプルコード

from polyphony import testbench, module, is_worker_running
from polyphony.timing import clksleep
from polyphony.io import Port
from polyphony.typing import bit

@module
class tx0:
    def __init__(self):
        self.led2 = Port(bit, 'out', init=1)
        self.led4 = Port(bit, 'out', init=1)
        self.led5 = Port(bit, 'out', init=1)
        self.tx = Port(bit, 'out', init=1)
        self.append_worker(self.worker)
    def _wait(self):
        for i in range(5000):
            pass
    def worker(self):
        v = 1
        while is_worker_running():
            self.tx(v)
            v = ~v
            self._wait()

m = tx0()


以上。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0