New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unsupported vpiRawTwoStateVal (etc) #1151
Comments
Original Redmine Comment Accidentally created other errors just before uploading.. |
Original Redmine Comment Sorry this was confusing for you.
If you have additional problems can you please use the verilator test format as described in the manual? This makes it much quicker to setup and debug, and also makes it easy to run under other simulators presuming you have something else. Thanks. |
Original Redmine Comment Hi Wilson, Thanks for the reply. I initially thought that maybe the type that I was supposed to use was 'vpiRawTwoStateVal', I have no specific desire to use it.. :) I have made the changes as suggested. I have some conceptual questions if you don't mind. I seem to be capturing a value from the 32 bit register when using:
but the result is always 0 no matter what the value I set it to (using parameters). Is this behaviour expected? If it is a bug I wil create a test as you describe. Regards |
Original Redmine Comment You won't see the values until at least the initial blocks have executed (you called eval once), so I suspect that's the problem. |
Original Redmine Comment Thanks, that solves it. I apologize for the waste-of-time type questions. Once you know the answer it seems quite obvious. Not to be rude, but the intricacies of VPI-use in the documentation would go a long way for new-comers that need If you think its a good idea, we should create some slides or something to capture just that, for verilog test-benchers to more easily understand how to setup the testbench to interact with the Verilog variables. we could include what the limitations of the VPI implementation are etc etc. Your input has been greatly appreciated. Regards |
Original Redmine Comment Fair point, I updated the examples. |
Author Name: Calvin Maree
Original Redmine Issue: 1151 from https://www.veripool.org
Hello,
I have been trying to get access to the registers defined in my verilog module delay.v from the cpp testbench,
but I am doing something wrong.
What I would like to update 32bit registers from the test bench.
Due to the errors, I have tried for now just to read a 1 bit register.
The error(s) I get as output when I run the sim (Vdelay) are as follows :
This is the case no matter the format I specify.. I have tried a few other formats from the verilated_vpi files.
I based the code on the VPI example. I suspect I am not capturing module..
Relevant part of my tb code :
compilation :
The delay.v and delay_tb.cpp is attached.
Regards
Calvin
The text was updated successfully, but these errors were encountered: