{"id":933,"date":"2016-09-23T11:49:44","date_gmt":"2016-09-23T09:49:44","guid":{"rendered":"http:\/\/www.fabienm.eu\/wordpress\/?p=933"},"modified":"2016-09-23T14:55:59","modified_gmt":"2016-09-23T12:55:59","slug":"comment-versionner-son-projet-vivado","status":"publish","type":"post","link":"http:\/\/www.fabienm.eu\/wordpress\/2016\/09\/23\/comment-versionner-son-projet-vivado\/","title":{"rendered":"Comment versionner son projet vivado ?"},"content":{"rendered":"<p>Alors voila, vous avez bien avanc\u00e9 dans votre projet FPGA avec Vivado. Mais vous souhaiteriez le conserver et surtout le versionner de mani\u00e8re \u00e0 pouvoir le reproduire et le r\u00e9utiliser ailleurs.<\/p>\n<p>Le document <a href=\"http:\/\/www.xilinx.com\/support\/documentation\/application_notes\/xapp1165.pdf\">xapp1165<\/a> de Xilinx donne la marche \u00e0 suivre, il suffit de lire le chapitre \u00abproject mode\u00bb.<br \/>\nVoici un petit r\u00e9sum\u00e9:<\/p>\n<p><strong>write_project_tcl<\/strong><\/p>\n<p>Tout d&rsquo;abord il faut bien s\u00fbr lancer vivado et ouvrir son projet. Une fois cela fait, il faut se rendre dans la console tcl et lancer la commande write_project_tcl:<\/p>\n<pre><code>\r\nwrite_project_tcl monprojetperso_project\r\nINFO: [Vivado-projutils-8] Tcl script 'monprojetperso_project.tcl' generated in output directory '\/usr\/local\/opt\/Xilinx\/Vivado\/2016.2\/bin'\r\n\r\nINFO: [Vivado-projutils-15] Please note that by default, the file path for the project source files were set wrt the 'origin_dir' variable in the\r\n generated script. When this script is executed from the output directory, these source files will be referenced wrt this 'origin_dir' path value.\r\n In case this script was later physically moved to a different directory, the 'origin_dir' value MUST be set manually in the script with the path\r\n relative to the new output directory to make sure that the source files are referenced correctly from the original project. You can also set the\r\n 'origin_dir' automatically by setting the 'origin_dir_loc' variable in the tcl shell before sourcing this generated script. The 'origin_dir_loc'\r\n variable should be set to the path relative to the new output directory. Alternatively, if you are sourcing the script from the Vivado command line,\r\n then set the origin dir using '-tclargs --origin_dir <path>'. For example, 'vivado -mode tcl -source monprojetperso_project.tcl -tclargs --origin_dir \"..\"\r\n\r\nWARNING: [Vivado-projutils-10] Found source(s) that were local or imported into the project. If this project is being source controlled, then\r\n please ensure that the project source(s) are also part of this source controlled data. The list of these local source(s) can be found in the generated script\r\n under the header section.\r\n<\/code><\/pre>\n<p>Un message d&rsquo;information nous indique o\u00f9 se trouve le script tcl ainsi g\u00e9n\u00e9r\u00e9 (ici : \/usr\/local\/opt\/Xilinx\/Vivado\/2016.2\/bin). Il suffit donc de copier ce script dans le r\u00e9pertoire que nous souhaitons versionner.<\/p>\n<pre>\r\ncd ~\/monprojet\/\r\ncp \/usr\/local\/opt\/Xilinx\/Vivado\/2016.2\/bin\/monprojetperso_project.tcl\r\n<\/pre>\n<p>Mais \u00e7a n&rsquo;est pas le seul fichier que nous devons versionner si nous souhaitons pouvoir le reconstruire. Les autres fichiers \u00e0 sauvegarder son indiquer dans l&rsquo;ent\u00eate du script :<\/p>\n<pre>\r\n#*****************************************************************************************\r\n# NOTE: In order to use this script for source control purposes, please make sure that the\r\n#       following files are added to the source control system:-\r\n#\r\n# 1. This project restoration tcl script (monprojetperso_project.tcl) that was generated.\r\n#\r\n# 2. The following source(s) files that were local or imported into the original project.\r\n#    (Please see the '$orig_proj_dir' and '$origin_dir' variable setting below at the start of the script)\r\n#\r\n#    <none>\r\n#\r\n# 3. The following remote source files that were added to the original project:-\r\n#\r\n#    \"\/usr\/local\/projects\/monprojetperso\/hardware\/monprojetpersomonoproc\/monprojetperso\/monprojetperso.srcs\/sources_1\/bd\/pea_monprojetperso\/pea_monprojetperso.bd\"\r\n#    \"\/usr\/local\/projects\/monprojetperso\/hardware\/monprojetpersomonoproc\/monprojetperso\/monprojetperso.srcs\/sources_1\/imports\/hdl\/pea_monprojetperso_wrapper.vhd\"\r\n#    \"\/usr\/local\/projects\/monprojetperso\/hardware\/monprojetpersomonoproc\/monprojetperso\/monprojetperso.srcs\/sources_1\/bd\/pea_monprojetperso\/ip\/pea_monprojetperso_mig_7series_0_0\/mig_a.prj\"\r\n#    \"\/usr\/local\/projects\/monprojetperso\/hardware\/monprojetpersomonoproc\/monprojetperso\/monprojetperso.srcs\/sources_1\/bd\/pea_monprojetperso\/ip\/pea_monprojetperso_mig_7series_0_0\/mig_b.prj\"\r\n#    \"\/usr\/local\/projects\/monprojetperso\/hardware\/monprojetpersomonoproc\/monprojetperso\/monprojetperso.srcs\/constrs_1\/new\/monprojetperso_constraints.xdc\"\r\n#\r\n#*****************************************************************************************\r\n<\/pre>\n<p>Pour il suffira donc de copier les fichiers indiqu\u00e9s dans notre r\u00e9pertoire projet et de modifier le script pour ajuster les path.<br \/>\n<a href=\"http:\/\/xillybus.com\/tutorials\/vivado-version-control-packaging\">Une meilleurs explication sur le blog de xillibus.<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Alors voila, vous avez bien avanc\u00e9 dans votre projet FPGA avec Vivado. Mais vous souhaiteriez le conserver et surtout le versionner de mani\u00e8re \u00e0 pouvoir le reproduire et le r\u00e9utiliser ailleurs. Le document xapp1165 de Xilinx donne la marche \u00e0 &hellip; <a href=\"http:\/\/www.fabienm.eu\/wordpress\/2016\/09\/23\/comment-versionner-son-projet-vivado\/\">Continuer la lecture <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[132,1],"tags":[],"class_list":["post-933","post","type-post","status-publish","format-standard","hentry","category-fpga","category-non-classe"],"_links":{"self":[{"href":"http:\/\/www.fabienm.eu\/wordpress\/wp-json\/wp\/v2\/posts\/933","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.fabienm.eu\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.fabienm.eu\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.fabienm.eu\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.fabienm.eu\/wordpress\/wp-json\/wp\/v2\/comments?post=933"}],"version-history":[{"count":5,"href":"http:\/\/www.fabienm.eu\/wordpress\/wp-json\/wp\/v2\/posts\/933\/revisions"}],"predecessor-version":[{"id":938,"href":"http:\/\/www.fabienm.eu\/wordpress\/wp-json\/wp\/v2\/posts\/933\/revisions\/938"}],"wp:attachment":[{"href":"http:\/\/www.fabienm.eu\/wordpress\/wp-json\/wp\/v2\/media?parent=933"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.fabienm.eu\/wordpress\/wp-json\/wp\/v2\/categories?post=933"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.fabienm.eu\/wordpress\/wp-json\/wp\/v2\/tags?post=933"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}