From 579d0ac23c2df6de1cbc8be4b6deda0ccc437ba0 Mon Sep 17 00:00:00 2001 From: Neel Date: Mon, 16 Jul 2018 18:19:25 +0530 Subject: [PATCH] stop myhdl being necessary --- src/myhdlgen/mux.py | 6 +++++- src/myhdlgen/pins.py | 9 ++++++--- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/src/myhdlgen/mux.py b/src/myhdlgen/mux.py index 1495026..c2b9e8b 100644 --- a/src/myhdlgen/mux.py +++ b/src/myhdlgen/mux.py @@ -1,7 +1,11 @@ # mux.py from math import log -from myhdl import * +try: + from myhdl import * +except ImportError: + def block(*args): + pass period = 20 # clk frequency = 50 MHz diff --git a/src/myhdlgen/pins.py b/src/myhdlgen/pins.py index 28fcc2e..feb0f73 100644 --- a/src/myhdlgen/pins.py +++ b/src/myhdlgen/pins.py @@ -1,7 +1,10 @@ # mux.py - -from myhdl import * -from myhdl._block import _Block +try: + from myhdl import * + from myhdl._block import _Block +except ImportError: + def block(*args): + pass from mux import mux4 from functools import wraps, partial import inspect -- 2.30.2