Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Can I use your UART with verilator? #4

Open
willlogs opened this issue May 24, 2022 · 6 comments
Open

Can I use your UART with verilator? #4

willlogs opened this issue May 24, 2022 · 6 comments

Comments

@willlogs
Copy link

Hi John.
Thank you for your amazing repo!

I don't have access to an FPGA and am trying to build something like spam-1 on verilator. I'm starting with the UART and am trying to use your implementation of it.

The thing is that verilator is run on c++ and can't possibly pass data to the UART module in a 9600 bits/sec speed. Do I NEED to choose a lower speed to be able to do this or am I doing something wrong?

@Johnlon
Copy link
Owner

Johnlon commented May 24, 2022

Spam-1 is a breadboard build btw and I have no experience of fpga.

I use verilog as it allowed me to simulate all the 7400 components during the build.

The uart model I wrote for the ftdi device was useful for my Sims as I can interact with it over a file.

I don't know how useful it would be for your use case. I don't consider baud rates when thinking about this stuff because like I say the "terminal" in my case are files not a serial cable.

Perhaps some more info.

@Johnlon
Copy link
Owner

Johnlon commented May 24, 2022

Perhaps you have some code to show and discuss?

@Johnlon
Copy link
Owner

Johnlon commented May 24, 2022

Also since I use Icarus verilog and not verilator there will be mods needed.

It would be good if these could be added to my model using #defines rather than creating an disconnected model if possible.

I can't exactly recall why I don't use verilator - I'm sure there was a reason. Icarus verilog isn't super fast tho it does allow me to run with realistic propagation delays which has helped spot errors.

@willlogs
Copy link
Author

willlogs commented May 24, 2022 via email

@Johnlon
Copy link
Owner

Johnlon commented May 25, 2022 via email

@willlogs
Copy link
Author

willlogs commented May 25, 2022 via email

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

No branches or pull requests

2 participants