[Libre-soc-dev] LibreSOC Implementation on arty7 fpga dev boards.

lkcl luke.leighton at gmail.com
Wed Oct 6 14:42:44 BST 2021

On Wed, Oct 6, 2021 at 2:23 PM varun mohan <varunmadhavam at gmail.com> wrote:
> > https://github.com/litex-hub/litex-boards/commits/master/litex_boards/platforms/digilent_arty.py
> > then view history.
> > find date and commit.  then git log and find diff.  pipe to file then run through patch command.
> If you have time, can you elaborate a bit or point to the right resources. The mentioned steps are pretty new to me.


ok, so it's a chain, and you just have to be ultra-patient and track
things through, one step at a time, making "logical deductions" and
reasonable rational assumptions along the way.  and not getting
totally irritated at the litex coding style which is a _major_
impediment.  sigh.

first, click on the hashes.  a3f4798 and 8a3caca

that way, you can see evidence they simply did a name-change in the
first, and in the second just added PMOD IO (which you can probably do


so, with no *actual* changes, there, you can logically deduce that
using "arty" is perfectly fine.  dont worry about PMOD IO, you don't
need it straight away.

next, we have to work out how - and when - the heck
"toolchain=symbiflow" was added.

so, first track it down.

this is, unfortunately, where litex's coding style really pisses me
off.  you *cannot* rely on the "import" list because it's using


fortunately: at the top, they did "from litex_boards.platforms import
arty" then arty.Platform receives the "toolchain" argument:

so, next we jump to litex_boards.platforms to find "arty", only to
find that it doesn't exist.


however, digilent_arty.py *does* exist and has a class Platform at line 337:

that's inheriting from XilinxPlatform.  again *very* luckily, right at
the top: "from litex.build.xilinx import XilinxPlatform"

so now we jump to _litex_ - not litex-boards - _litex_, and go look
there.  the __init__.py is where the litex/build/xilinx imports from:

so that in turn (line 1) imports XilinxPlatform... which... ah HA!

ta-daaaa, symbiflow.

*now* we can go back through the history... *of xlilinx platform.py*
.... and find out the last commit.


hooraaay, Jun 1 2020


now, because those commit checksums i gave Las (and you should now
have) are *AFTER* that
date, you should in fact have that commit, which adds symbiflow
support, already.

now, in *combination* with the fact that the arty.py files are "just a
rename" (except for the PMOD IO which you don't need), we may
reasonably and logically deduce that you should in fact just be able
to use "import ..... arty" in place of "import .... digilent_arty".

does that sound reasonable?


More information about the Libre-soc-dev mailing list