ghdl / ghdl-cosim

Documentation with code examples about interfacing VHDL with foreign languages and tools through GHDL
https://ghdl.github.io/ghdl-cosim
Apache License 2.0
46 stars 9 forks source link

vpi: fix quickstart example for mcode build; add ref to CoCoTb-pygame demo #29

Closed chuckb closed 2 years ago

chuckb commented 2 years ago

Running on Mac...installed ghdl via homebrew. That binary was build for mcode generation. Thus, this example did not work.

chuckb commented 2 years ago

I also added an example interactive GUI I whipped up by using cocotb and python.

umarcor commented 2 years ago

@chuckb would you mind partially rewriting the GHDL-CoCoTb example description to address the following details?

Moreover, if you want, your article might be contributed as a section to the docs of this repo, along with adding the sources as an example. I believe we might test it in CI with xvfb. That'd be in an upcoming PR, of course; no need to handle it now.

chuckb commented 2 years ago

Yes, I will make the changes you suggest. I would very much like to have the example included within the docs somehow, as there are not many GUI-related examples...none really with Cocotb as you mentioned. Fusing Cocotb and pygame was an interesting exercise and kind of fun.

I should have split up the PR, I recognize...

umarcor commented 2 years ago

I did a minor style fix, I rebased and I merged. Thanks!

would very much like to have the example included within the docs somehow, as there are not many GUI-related examples...none really with Cocotb as you mentioned.

You can start creating subdir vpi/cocotb/pygame in a branch, and adding the sources of the example there. Then, we can iterate on that to add it to CI and to the docs.

BTW, https://twitter.com/unaimarcor/status/1476772035728715782

chuckb commented 2 years ago

Thanks for the kind mention. I also integrated this example into a FuseSoC core...lots of open source goodies to explore. https://github.com/chuckb/alchitry-au-fusesoc