{"id":860,"date":"2023-04-29T17:39:09","date_gmt":"2023-04-29T15:39:09","guid":{"rendered":"https:\/\/immerhax.com\/?p=860"},"modified":"2023-04-29T17:39:09","modified_gmt":"2023-04-29T15:39:09","slug":"notes-on-programming-efinix-trion-fpgas","status":"publish","type":"post","link":"https:\/\/immerhax.com\/?p=860","title":{"rendered":"Notes on programming Efinix Trion FPGAs"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">When building my BKM-68X alternative boards, I&#8217;ve been using efinix&#8217; Trion FPGAs which are still fairly new to many. Efinix have been so kind to have the &#8220;official&#8221; supported programmer be the easily available FTDI chips FT2232H and FT4232H, for which some rather cheap development kits exists, namely the &#8220;ft232h mini&#8221; and &#8220;ft4232h mini&#8221; modules. Note that these also exist in a &#8220;-56Q&#8221; version, which is a bit easier to get going with as some common connections has been done directly on the boards, which is otherwise necessary to manually make.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The non &#8220;-56Q&#8221; versions seems dead when connected to your PC if nothing is done, but this is simply because the board has options as to how the chip should be powered. Reading the manual of the respective boards should show this:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large is-resized\"><a href=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-1024x185.png\" alt=\"\" class=\"wp-image-861\" width=\"840\" height=\"151\" srcset=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-1024x185.png 1024w, https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-300x54.png 300w, https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-768x138.png 768w, https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image.png 1309w\" sizes=\"auto, (max-width: 840px) 100vw, 840px\" \/><\/a><figcaption class=\"wp-element-caption\">Taken from the ft4232h manual, it is the same for the ft2232h version<\/figcaption><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">So put a jumper (wire) between CN3 pin 1 and 3, and your PC should now actually detect stuff, and then do the V3V3 connections for CN2, as CN3 isn&#8217;t relevant for this.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The manuals for the ft2232 and ft4232 can be found here:<br><a href=\"https:\/\/ftdichip.com\/wp-content\/uploads\/2020\/07\/DS_FT2232H_Mini_Module.pdf\">https:\/\/ftdichip.com\/wp-content\/uploads\/2020\/07\/DS_FT2232H_Mini_Module.pdf<\/a><br><a href=\"https:\/\/ftdichip.com\/wp-content\/uploads\/2020\/07\/DS_FT4232H_Mini_Module.pdf\">https:\/\/ftdichip.com\/wp-content\/uploads\/2020\/07\/DS_FT4232H_Mini_Module.pdf<\/a><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">On the Trion based 68X boards there are both JTAG (J401) and SPI programming (J601) headers. The SPI one is the relevant, as we&#8217;ll program the SPI flash through this which in turn will be read by the FPGA for its configuration.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The hookup of the programmer is straight from efinix&#8217; documentation:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><a href=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-1.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1021\" height=\"611\" src=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-1.png\" alt=\"\" class=\"wp-image-862\" srcset=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-1.png 1021w, https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-1-300x180.png 300w, https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-1-768x460.png 768w\" sizes=\"auto, (max-width: 1021px) 100vw, 1021px\" \/><\/a><figcaption class=\"wp-element-caption\">Taken from <strong>AN006 &#8211; Configuration of Trion FPGAs<\/strong><\/figcaption><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\"> It is recommended to read efinix&#8217; documentation for further information.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Programming the FPGA through Efinity<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Load the project into efinity and ensure the program is synthesized, routed, etc. by ensuring the flow is &#8220;complete&#8221; like this:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full is-resized\"><a href=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-2.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-2.png\" alt=\"\" class=\"wp-image-863\" width=\"362\" height=\"143\" srcset=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-2.png 362w, https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-2-300x119.png 300w\" sizes=\"auto, (max-width: 362px) 100vw, 362px\" \/><\/a><figcaption class=\"wp-element-caption\">Efinitys &#8220;flow&#8221; process<\/figcaption><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">If not, press the (01) button and let it run.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Press <strong>Tools<\/strong> -> <strong>Open Programmer<\/strong> to get this window:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><a href=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-3.png\"><img loading=\"lazy\" decoding=\"async\" width=\"725\" height=\"1008\" src=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-3.png\" alt=\"\" class=\"wp-image-864\" srcset=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-3.png 725w, https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-3-216x300.png 216w\" sizes=\"auto, (max-width: 725px) 100vw, 725px\" \/><\/a><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">Press the &#8220;01&#8221; button (&#8220;Select Image File&#8221;) and select the &#8220;.hex&#8221; file (inside the <strong>outflow<\/strong> directory of the project). <\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><a href=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-4.png\"><img loading=\"lazy\" decoding=\"async\" width=\"178\" height=\"93\" src=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-4.png\" alt=\"\" class=\"wp-image-865\"\/><\/a><\/figure>\n<\/div>\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><a href=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-5.png\"><img loading=\"lazy\" decoding=\"async\" width=\"424\" height=\"70\" src=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-5.png\" alt=\"\" class=\"wp-image-866\" srcset=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-5.png 424w, https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-5-300x50.png 300w\" sizes=\"auto, (max-width: 424px) 100vw, 424px\" \/><\/a><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">Ensure the settings are like this:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><a href=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-6.png\"><img loading=\"lazy\" decoding=\"async\" width=\"690\" height=\"249\" src=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-6.png\" alt=\"\" class=\"wp-image-867\" srcset=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-6.png 690w, https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-6-300x108.png 300w\" sizes=\"auto, (max-width: 690px) 100vw, 690px\" \/><\/a><\/figure>\n<\/div>\n\n\n<p class=\"wp-block-paragraph\">Press the program button, and let it rip \ud83d\ude42<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><a href=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-7.png\"><img loading=\"lazy\" decoding=\"async\" width=\"54\" height=\"47\" src=\"https:\/\/immerhax.com\/wp-content\/uploads\/2023\/04\/image-7.png\" alt=\"\" class=\"wp-image-868\"\/><\/a><\/figure>\n<\/div>","protected":false},"excerpt":{"rendered":"<p>When building my BKM-68X alternative boards, I&#8217;ve been using efinix&#8217; Trion FPGAs which are still fairly new to many. Efinix have been so kind to have the &#8220;official&#8221; supported programmer be the easily available FTDI chips FT2232H and FT4232H, for which some rather cheap development kits exists, namely the &#8220;ft232h mini&#8221; and &#8220;ft4232h mini&#8221; modules. &hellip; <a href=\"https:\/\/immerhax.com\/?p=860\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Notes on programming Efinix Trion FPGAs<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-860","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/immerhax.com\/index.php?rest_route=\/wp\/v2\/posts\/860","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/immerhax.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/immerhax.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/immerhax.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/immerhax.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=860"}],"version-history":[{"count":1,"href":"https:\/\/immerhax.com\/index.php?rest_route=\/wp\/v2\/posts\/860\/revisions"}],"predecessor-version":[{"id":869,"href":"https:\/\/immerhax.com\/index.php?rest_route=\/wp\/v2\/posts\/860\/revisions\/869"}],"wp:attachment":[{"href":"https:\/\/immerhax.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=860"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/immerhax.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=860"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/immerhax.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=860"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}