projects
/
pinmux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
70a9e00
)
Added granuality assert (for now)
author
Andrey Miroshnikov
<andrey@technepisteme.xyz>
Tue, 24 May 2022 21:01:54 +0000
(22:01 +0100)
committer
Andrey Miroshnikov
<andrey@technepisteme.xyz>
Tue, 24 May 2022 21:01:54 +0000
(22:01 +0100)
src/spec/simple_gpio.py
patch
|
blob
|
history
diff --git
a/src/spec/simple_gpio.py
b/src/spec/simple_gpio.py
index f8e1f20f00d0577426b09aaf2ee17cca4caffbd3..ae699a88a9cf95abc8f13bfffb048532329835b3 100644
(file)
--- a/
src/spec/simple_gpio.py
+++ b/
src/spec/simple_gpio.py
@@
-63,6
+63,10
@@
class SimpleGPIO(Elaboratable):
temp.append(Record(name=name, layout=gpio_layout))
self.gpio_ports = Array(temp)
+ self.granuality = (len(self.bus.dat_w) // len(self.bus.sel))
+ print("Granuality: %d" % self.granuality)
+ assert self.granuality == 8, "Only byte granuality is supported atm!"
+
def elaborate(self, platform):
m = Module()
comb, sync = m.d.comb, m.d.sync