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

Picosoc fusesoc #9

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

Picosoc fusesoc #9

wants to merge 4 commits into from

Conversation

olofk
Copy link

@olofk olofk commented Aug 18, 2018

Add support for building and simulating picosoc for TinyFPGA-BX with FuseSoC

To test this the core libraries must first be available. Create a workspace directory and run

fusesoc library add picosoc https://github.com/cliffordwolf/picorv32
fusesoc library add tinyfpga-bx https://github.com/tinyfpga/TinyFPGA-BX

or, alternatively if the repos are already on disk and you want to use those instead, run

fusesoc library add picosoc /path/to/picorv32_repo
fusesoc library add tinyfpga-bx /path/to/TinyFPGA-BX_repo

Picosoc for TinyFPGA-BX can now be built with

fusesoc build tinyfpga:bx:picosoc

This uses nextpnr by default. To use arachne-pnr, change pnr : next to pnr : arachne in the .core file

To simulate, first create firmware.hex (make -C examples/picosoc/firmware.hex). It is recommended to decrease the blink period tme as simulation takes a long time otherwise (e.g. change to reg_leds = led_timer >> 6; in firmware.c. With the newly created firmware.hex run

fusesoc run --target=sim tinyfpga:bx:picosoc --spi_flash_file=/path/to/firmware.hex

To use modelsim instead of icarus add --tool=modelsim after --target=sim

To find out all available simulation options (e.g. to generate a VCD file or set a simulation timeout) run

fusesoc run --target=sim tinyfpga:bx:picosoc --help

FuseSoC 1.8.4 or later is required

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

Successfully merging this pull request may close these issues.

1 participant