2020-01-30 20:44:24 +01:00
|
|
|
# See LICENSE for licensing information.
|
|
|
|
|
#
|
|
|
|
|
# Copyright (c) 2016-2020 Regents of the University of California and The Board
|
|
|
|
|
# of Regents for the Oklahoma Agricultural and Mechanical College
|
|
|
|
|
# (acting for and on behalf of Oklahoma State University)
|
|
|
|
|
# All rights reserved.
|
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
class _dff:
|
2020-02-05 08:35:06 +01:00
|
|
|
def __init__(self, use_custom_ports, custom_port_list, custom_type_list, clk_pin):
|
2020-01-30 20:44:24 +01:00
|
|
|
self.use_custom_ports = use_custom_ports
|
|
|
|
|
self.custom_port_list = custom_port_list
|
|
|
|
|
self.custom_type_list = custom_type_list
|
2020-02-05 08:35:06 +01:00
|
|
|
self.clk_pin = clk_pin
|
2020-01-30 20:44:24 +01:00
|
|
|
|
|
|
|
|
class module_properties():
|
|
|
|
|
"""
|
|
|
|
|
TODO
|
|
|
|
|
"""
|
|
|
|
|
def __init__(self):
|
|
|
|
|
self.names = {}
|
|
|
|
|
self._dff = _dff(use_custom_ports = False,
|
2020-02-05 08:35:06 +01:00
|
|
|
custom_port_list = ["D", "Q", "clk", "vdd", "gnd"],
|
|
|
|
|
custom_type_list = ["INPUT", "OUTPUT", "INPUT", "POWER", "GROUND"],
|
|
|
|
|
clk_pin= "clk")
|
2020-01-30 20:44:24 +01:00
|
|
|
|
|
|
|
|
@property
|
|
|
|
|
def dff(self):
|
|
|
|
|
return self._dff
|