Comments (6)
Hi, this would be something like this:
from veriloggen import *
def make_module():
m = Module('xval')
i_xval = m.Input('i_xval',12,signed=True)
e_xval = m.Wire('e_xval',15,signed=True)
e_xval.assign(Cat(i_xval[11],i_xval,Repeat(Int(0,1,2),2)))
return m
print(make_module().to_verilog())
from veriloggen.
I've figured out the issues I currently had. One thing I've failed to figure out how to do is an expression like so:
input wire signed [(12-1):0] i_xval;
...
wire signed [(15-1):0] e_xval;
assign e_xval = { {i_xval[(12-1)]}, i_xval, {(3-1){1'b0}} };
from veriloggen.
That fixed my issue thanks! Is there any appetite for improving the veriloggen docs, and maybe having HTML docs hosted somewhere? Whenever I run into an issue I normally spend time going through tests and examples looking for anything that solves it and then going through the actual code which is less than ideal.
from veriloggen.
HTML docs hosted somewhere
I should prepare such documents ...
from veriloggen.
I've not published any python projects myself that have required docs but pydoc should be able to generate docs from doc comments on classes and methods. It's just a case of doc comments for existing code
from veriloggen.
@shtaxxx I am using Sphinx code generator together with readthedocs.io
https://github.com/Nic30/hwtLib/blob/master/docs/conf.py
https://hwtlib.readthedocs.io/en/latest/?badge=latest
I was relatively good and it usually works however you may have to fix some code style of doc in your code. Sphinx can also generate PDF/epub/... and readthedocs.io also supports any files.
from veriloggen.
Related Issues (20)
- Online tutorial on binder/jupyter
- memcpy between on-chip RAMs HOT 1
- Supporting multiple outstanding DMA requests HOT 1
- Supporting indirect addressing by sink RAM of Thread.Stream HOT 1
- Explicit latency constraint between two stream objects which accesses to external resources outside of the stream. HOT 1
- Infinite read size for stream.source
- Inserting user-defined simulation code for Verilator mode
- Bug of stream.ReduceDiv for signed values
- stream.source with only size without data read
- deleted
- always @ ( * ) combinational block HOT 2
- Support for SystemVerilog Interfaces HOT 2
- Creating input with literal BW in the form of [n:0] instead of [n-1:0]
- to_verilog("file.v") creates two empty lines at beginning of file
- Case statement within combinational block HOT 2
- Creating a combinational sequence
- Slice in Wire with two dimension HOT 1
- Imcompatibility of `Module.Wire` and `Module.TmpWire` regarding the keyword arguments. HOT 1
- Convention violation of AXI Lite protocol on AxiLiteSlave HOT 1
- `types.AxiMaster` should be have a cap of number of outstanding readout transactions. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from veriloggen.