<whine mode on> Why is my source buried in the bowels of the project?...

R

Rick C

Guest
I\'ve always found it awkward that when I create a project the various temporary files the tool creates are at the top of the project tree and my files are down at the end of a branch of the subdirectory tree. This sees so upside down to me. I should be able to put all my source files in a simple directory in the main project folder with all the tool specific files in a separate directory not below and not above my folder. Then finding source and backing it up is a breeze.

Of course I can always put my files anywhere I want them and just point the tool to them. The tools tend to make this awkward and when the tool creates a boilerplate file where does it want to put it? In with the other tool related files.

Then there are the various tool specific files that are still technically source such as the pin connection file and the timing constraints. They need to be with the rest of the source files too.

Not really talking about one tool. I mostly use Lattice, but I recall it is very similar to the previous Xilinx tools and I don\'t recall the Altera tools being any better in this regard either.

I guess I\'m just out of step with the rest of the world. I wonder how the tools of the various Chinese startups work in this regard?

--

Rick C.

- Get 1,000 miles of free Supercharging
- Tesla referral code - https://ts.la/richard11209
 
On 20/06/2020 21:49, Rick C wrote:
I\'ve always found it awkward that when I create a project the various temporary files the tool creates are at the top of the project tree and my files are down at the end of a branch of the subdirectory tree. This sees so upside down to me. I should be able to put all my source files in a simple directory in the main project folder with all the tool specific files in a separate directory not below and not above my folder. Then finding source and backing it up is a breeze.

Of course I can always put my files anywhere I want them and just point the tool to them. The tools tend to make this awkward and when the tool creates a boilerplate file where does it want to put it? In with the other tool related files.

Then there are the various tool specific files that are still technically source such as the pin connection file and the timing constraints. They need to be with the rest of the source files too.

Not really talking about one tool. I mostly use Lattice, but I recall it is very similar to the previous Xilinx tools and I don\'t recall the Altera tools being any better in this regard either.

I guess I\'m just out of step with the rest of the world. I wonder how the tools of the various Chinese startups work in this regard?

A copy of the files are sent immediately to Xi Jinping and his henchmen :)

I too have trouble digging files out of the Lattice mire on occasion.
Vivado uses a more logical structure (IMO) but there is so much of it
that it\'s no easier to find stuff.

MK
 
On Saturday, June 20, 2020 at 2:49:28 PM UTC-6, Rick C wrote:
I\'ve always found it awkward that when I create a project the various temporary files the tool creates are at the top of the project tree and my files are down at the end of a branch of the subdirectory tree. This sees so upside down to me. I should be able to put all my source files in a simple directory in the main project folder with all the tool specific files in a separate directory not below and not above my folder. Then finding source and backing it up is a breeze.

Of course I can always put my files anywhere I want them and just point the tool to them. The tools tend to make this awkward and when the tool creates a boilerplate file where does it want to put it? In with the other tool related files.

Then there are the various tool specific files that are still technically source such as the pin connection file and the timing constraints. They need to be with the rest of the source files too.

Not really talking about one tool. I mostly use Lattice, but I recall it is very similar to the previous Xilinx tools and I don\'t recall the Altera tools being any better in this regard either.

I guess I\'m just out of step with the rest of the world. I wonder how the tools of the various Chinese startups work in this regard?

--

Rick C.

- Get 1,000 miles of free Supercharging
- Tesla referral code - https://ts.la/richard11209

When using Vivado, I would suggest using \"non-project\" mode. I use a TCL script. It gets the source files from the source directories (and does not make local copies) and writes any files to the work directories I\'ve specified. The GUI I use only to look at placement or schematics of failing paths.
 
On Saturday, June 20, 2020 at 9:49:28 PM UTC+1, Rick C wrote:
I\'ve always found it awkward that when I create a project the various temporary files the tool creates are at the top of the project tree and my files are down at the end of a branch of the subdirectory tree. This sees so upside down to me. I should be able to put all my source files in a simple directory in the main project folder with all the tool specific files in a separate directory not below and not above my folder. Then finding source and backing it up is a breeze.

Of course I can always put my files anywhere I want them and just point the tool to them. The tools tend to make this awkward and when the tool creates a boilerplate file where does it want to put it? In with the other tool related files.

Then there are the various tool specific files that are still technically source such as the pin connection file and the timing constraints. They need to be with the rest of the source files too.

Not really talking about one tool. I mostly use Lattice, but I recall it is very similar to the previous Xilinx tools and I don\'t recall the Altera tools being any better in this regard either.

I guess I\'m just out of step with the rest of the world. I wonder how the tools of the various Chinese startups work in this regard?

Lattice, Xilinx, Altera and Microsemi can all be made to build FPGA projects in a way more like software projects are built, i.e. by starting out with the source and constraint files etc stored in the directory structure as you would like them, and instructing the tools to build to a programming file in a build directory that you specify. Then when you want to commit sources to version control you can ignore the build directory. But for this you need to read the manuals and do a bit of Tcl scripting.

I have written some Tcl scripts for my own projects that do this here: https://www.p-code.org/ttask/, with the aim of providing a fairly simple abstraction over the underlying tools. From the example on the altera quartus page, you can see the level of abstraction:


set part 5CSEMA4U23C6

task new {fpga build -exe new}
task build {fpga build -exe build}
task conv {fpga build -exe conv}
task conf {fpga build -exe conf}
task prog {fpga build -exe prog}
task clean {rmdir build}

project add fpga -type altera-quartus
fpga src -lib my_lib -add lib/src/*.vhdl -lib my_fpga -add src/*.vhdl -add impl/*
fpga build -buildDir build -part $part -name my_fpga


i.e. specify source files and constraints/settings (stored in impl/), then you can clean build, create project, build to bit file, convert bit file, configure FPGA and program non-volatile configuration memory all from the command line.

What I found is that other tools can more or less be abstracted the same way. For example see the Xilinx Vivado page.
 
On Friday, June 26, 2020 at 11:11:54 AM UTC-4, pau...@googlemail.com wrote:
On Saturday, June 20, 2020 at 9:49:28 PM UTC+1, Rick C wrote:
I\'ve always found it awkward that when I create a project the various temporary files the tool creates are at the top of the project tree and my files are down at the end of a branch of the subdirectory tree. This sees so upside down to me. I should be able to put all my source files in a simple directory in the main project folder with all the tool specific files in a separate directory not below and not above my folder. Then finding source and backing it up is a breeze.

Of course I can always put my files anywhere I want them and just point the tool to them. The tools tend to make this awkward and when the tool creates a boilerplate file where does it want to put it? In with the other tool related files.

Then there are the various tool specific files that are still technically source such as the pin connection file and the timing constraints. They need to be with the rest of the source files too.

Not really talking about one tool. I mostly use Lattice, but I recall it is very similar to the previous Xilinx tools and I don\'t recall the Altera tools being any better in this regard either.

I guess I\'m just out of step with the rest of the world. I wonder how the tools of the various Chinese startups work in this regard?


Lattice, Xilinx, Altera and Microsemi can all be made to build FPGA projects in a way more like software projects are built, i.e. by starting out with the source and constraint files etc stored in the directory structure as you would like them, and instructing the tools to build to a programming file in a build directory that you specify. Then when you want to commit sources to version control you can ignore the build directory. But for this you need to read the manuals and do a bit of Tcl scripting.

It\'s not just the scripting that needs to be done manually, it is also writing the various source files. The tools have appication specific editors which don\'t require you to learn the syntax, etc. They also have coverage tools for the timing constraints. I am an intermittent user of the various tools and am often frustrated by the many specialized features that are required to be learned. Writing my own pin out descriptor files and timing files along with scripts is an awkward choice at best.


I have written some Tcl scripts for my own projects that do this here: https://www.p-code.org/ttask/, with the aim of providing a fairly simple abstraction over the underlying tools. From the example on the altera quartus page, you can see the level of abstraction:


set part 5CSEMA4U23C6

task new {fpga build -exe new}
task build {fpga build -exe build}
task conv {fpga build -exe conv}
task conf {fpga build -exe conf}
task prog {fpga build -exe prog}
task clean {rmdir build}

project add fpga -type altera-quartus
fpga src -lib my_lib -add lib/src/*.vhdl -lib my_fpga -add src/*.vhdl -add impl/*
fpga build -buildDir build -part $part -name my_fpga


i.e. specify source files and constraints/settings (stored in impl/), then you can clean build, create project, build to bit file, convert bit file, configure FPGA and program non-volatile configuration memory all from the command line.

What I found is that other tools can more or less be abstracted the same way. For example see the Xilinx Vivado page.

Thanks for your comments.

--

Rick C.

+ Get 1,000 miles of free Supercharging
+ Tesla referral code - https://ts.la/richard11209
 
Rick C <gnuarm.deletethisbit@gmail.com> writes:

I\'ve always found it awkward that when I create a project the various
temporary files the tool creates are at the top of the project tree
and my files are down at the end of a branch of the subdirectory tree.

I dunno. I\'ve mostly used Intel Quartus in the last few years, don\'t
really know other tools that well currently.

Anyways, with Quartus I have a setup where I have quartus folder, src
folder, sim folder. Sometimes also \'tools\' or something for various
scripts and whatnot. The quartus folder ends up somewhat messy since I
put also all IP in there, sometimes under an IP folder but if it\'s just
a single file from the Megawizard (or did they rename that?), then it
stays in the quartus folder. Still, all the useless gunk quartus puts in
db and incremental_db folders so those don\'t go in version
control. Also, Quartus puts actual output files (binaries and reports)
in an output_files folder by default.

I think back in the Xilinx ISE era my directory structure was pretty
much like this too.
 

Welcome to EDABoard.com

Sponsor

Back
Top