Skip to content
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

Long run of static signals only show time = 0 #32

Open
patekd opened this issue Apr 4, 2024 · 1 comment
Open

Long run of static signals only show time = 0 #32

patekd opened this issue Apr 4, 2024 · 1 comment

Comments

@patekd
Copy link

patekd commented Apr 4, 2024

When my input signals don't change the VCD file only shows time = 0 in GTKwaves.
I attached 2 VCD files with 512 samples, one is incrementing from 100 to 611 the other is
a static 100. You should be able to replicate this but if you need more information or my
code let me know.

waves_512_samples_inc_vcd.txt
waves_512_samples_static_vcd.txt

@jpgrayson
Copy link
Collaborator

PyVCD has optimizations to both avoid writing superfluous value changes when the value doesn't change as well as only writing timestamps in conjunction with value changes (to avoid superfluous timestamps). So in this kind of pathological case where none of the values ever change, the timestamp won't be updated via value changes.

However, VCDWriter.flush() and VCDWriter.close() both have an optional timestamp parameter that may be used to force a timestamp to be written without an accompanying value change. For your application, it seems like calling close() with the final timestamp would meet your need.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants