{"id":485,"date":"2022-06-28T10:46:25","date_gmt":"2022-06-28T03:46:25","guid":{"rendered":"https:\/\/dgway.com\/blog_E\/?p=485"},"modified":"2022-06-28T10:47:12","modified_gmt":"2022-06-28T03:47:12","slug":"aat-demo-datamover-with-hardware-emulation","status":"publish","type":"post","link":"https:\/\/dgway.com\/blog_E\/2022\/06\/28\/aat-demo-datamover-with-hardware-emulation\/","title":{"rendered":"AAT Demo Datamover with Hardware Emulation"},"content":{"rendered":"\n<p>Datamover on AAT Demo<\/p>\n\n\n\n<p>After Both tutorial on AAT demo focusing on the running the AAT. Now, it is time to look in its features which is called Datamover. The Datamover provides a bi-directional datapath to the host. The uplink is used for transferring the updated Orderbook and the downlink transfer the requests to trade. There are 2 types of Datamover depends on environment configuration through \u201cDM_MODE\u201d. The first one is using DDR on Alveo card (U250) or HBM (U50) as data buffer to store data between waiting for process. Users can use this mode by set environment \u201cDM_MODE=DMA\u201d. The others mode is using PCIe slave bridge connecting to Host memory as a data buffer to store data waiting for process. Users can use this mode by set environment \u201cDM_MODE=SB\u201d. Datamover helps data management easier due to the flexibility.<\/p>\n\n\n\n<p><strong>Test environment<\/strong><\/p>\n\n\n\n<p>AAT demo version 2022Q1 or later.<br>XRT version 2.13.466.<br>Vitis version 2022.1<br>Xilinx platform version xilinx_u250_gen3x16_xdma_4_1_202210_1<\/p>\n\n\n\n<p><strong>Step-by-Step<\/strong><\/p>\n\n\n\n<p>The test is performed on Hardware Emulation to save the time operating. Open terminal and set environment by below commands.<\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">source \/opt\/xilinx\/xrt\/setup.sh<\/mark><\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">source \/tools\/Xilinx\/Vitis\/2022.1\/settings64.sh<\/mark><\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">export PLATFORM_REPO_PATHS=&#8217;\/opt\/xilinx\/platforms&#8217;<\/mark><\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">export XILINX_PLATFORM=&#8217;xilinx_u250_gen3x16_xdma_4_1_202210_1&#8242;<\/mark><\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">export DEVICE=&#8217;\/opt\/xilinx\/platforms\/xilinx_u250_gen3x16_xdma_4_1_202210_1\/xilinx_u250_gen3x16_xdma_4_1_202210_1.xpfm&#8217;<\/mark><\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">export DM_MODE=SB<\/mark><\/p>\n\n\n\n<p>in this article, we will shows Datamover by using Slave bridge mode.<\/p>\n\n\n\n<p><strong>Create xo and xclbin file<\/strong><\/p>\n\n\n\n<p>In this step is almost like the AAT demo with Hardware Emulation. Just changing the parameter make binary due to changing card as command below.<\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">make binary-container TARGET=hw_emu DEVICE=xilinx_u250_gen3x16_xdma_4_1_202210_1<\/mark><\/p>\n\n\n\n<p><strong>Build the software to manage AAT Demo<\/strong><\/p>\n\n\n\n<p>Using the same terminal and navigate to .\/sw\/applications\/aat. Then, create folder \u201cbuild\u201d to store software by using below command.<\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">mkdir -p build<\/mark><\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">cd build<\/mark><\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">cmake ..<\/mark><\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">make all<\/mark><\/p>\n\n\n\n<p>note that if cmake fail due to the version is not 3.13 or later. Fixing by changing path of library with below command.<\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">export PATH=\/usr\/local\/bin:$PATH<\/mark><\/p>\n\n\n\n<p>copy software \u201caat_shell_hwemu_exe\u201d to .\/build and&nbsp; navigate to .\/build. Then, generate mandatory by this command.<\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">emconfigutil &#8211;platform xilinx_u250_gen3x16_xdma_4_1_202210_1<\/mark><\/p>\n\n\n\n<p><strong>Program Alveo card<\/strong><\/p>\n\n\n\n<p>Using the same terminal and run this command<\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">.\/aat_shell_hwemu_exe -i run support\/demo_setup_with_datamover_hw_emu.cfg<\/mark><\/p>\n\n\n\n<p>When programming the Alveo card completes. It shows the status as the picture below.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"914\" height=\"522\" src=\"https:\/\/dgway.com\/blog_E\/wp-content\/uploads\/2022\/06\/DownloadSuccess.jpg\" alt=\"\" class=\"wp-image-488\" srcset=\"https:\/\/dgway.com\/blog_E\/wp-content\/uploads\/2022\/06\/DownloadSuccess.jpg 914w, https:\/\/dgway.com\/blog_E\/wp-content\/uploads\/2022\/06\/DownloadSuccess-300x171.jpg 300w, https:\/\/dgway.com\/blog_E\/wp-content\/uploads\/2022\/06\/DownloadSuccess-768x439.jpg 768w\" sizes=\"auto, (max-width: 914px) 100vw, 914px\" \/><\/figure>\n\n\n\n<p>But please wait until the callback is finished by showing the message \u201cEnd of script support\/demo_setup_with_datamover_hw_emu.cfg\u201d as the picture below. It takes 15 mins give or take depending on the computer.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"911\" height=\"503\" src=\"https:\/\/dgway.com\/blog_E\/wp-content\/uploads\/2022\/06\/programsuccess.jpg\" alt=\"\" class=\"wp-image-489\" srcset=\"https:\/\/dgway.com\/blog_E\/wp-content\/uploads\/2022\/06\/programsuccess.jpg 911w, https:\/\/dgway.com\/blog_E\/wp-content\/uploads\/2022\/06\/programsuccess-300x166.jpg 300w, https:\/\/dgway.com\/blog_E\/wp-content\/uploads\/2022\/06\/programsuccess-768x424.jpg 768w\" sizes=\"auto, (max-width: 911px) 100vw, 911px\" \/><\/figure>\n\n\n\n<p><strong>Running python script<\/strong><\/p>\n\n\n\n<p>User can do as the previous articles in the same topic.<\/p>\n\n\n\n<p><strong>Result of Running Datamover<\/strong><\/p>\n\n\n\n<p>When finish running python script. User are able to run the command to access each block in AAT Demo, such as Feed Handler, Datamover and etc. In this case, the result of reading data buffer of Datamover is shown below by using command below.<\/p>\n\n\n\n<p><mark style=\"background-color:#abb8c3\" class=\"has-inline-color\">datamover readbuffer<\/mark><\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"370\" height=\"695\" src=\"https:\/\/dgway.com\/blog_E\/wp-content\/uploads\/2022\/06\/1656243630765.jpg\" alt=\"\" class=\"wp-image-490\" srcset=\"https:\/\/dgway.com\/blog_E\/wp-content\/uploads\/2022\/06\/1656243630765.jpg 370w, https:\/\/dgway.com\/blog_E\/wp-content\/uploads\/2022\/06\/1656243630765-160x300.jpg 160w\" sizes=\"auto, (max-width: 370px) 100vw, 370px\" \/><\/figure>\n\n\n\n<p>For more information, please refer to document UG1067 from xilinx.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Datamover on AAT Demo After Both tutorial on AAT demo focusing on the running the AAT. Now, it is time to look in its features which is called Datamover. The Datamover provides a bi-directional datapath to the host. The uplink is used for transferring the updated Orderbook and the downlink transfer the requests to trade. There are 2 types of&#46;&#46;&#46;<\/p>\n","protected":false},"author":1,"featured_media":493,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[],"class_list":["post-485","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-accelerated-computing-tutorial"],"_links":{"self":[{"href":"https:\/\/dgway.com\/blog_E\/wp-json\/wp\/v2\/posts\/485","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dgway.com\/blog_E\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dgway.com\/blog_E\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dgway.com\/blog_E\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dgway.com\/blog_E\/wp-json\/wp\/v2\/comments?post=485"}],"version-history":[{"count":4,"href":"https:\/\/dgway.com\/blog_E\/wp-json\/wp\/v2\/posts\/485\/revisions"}],"predecessor-version":[{"id":492,"href":"https:\/\/dgway.com\/blog_E\/wp-json\/wp\/v2\/posts\/485\/revisions\/492"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/dgway.com\/blog_E\/wp-json\/wp\/v2\/media\/493"}],"wp:attachment":[{"href":"https:\/\/dgway.com\/blog_E\/wp-json\/wp\/v2\/media?parent=485"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dgway.com\/blog_E\/wp-json\/wp\/v2\/categories?post=485"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dgway.com\/blog_E\/wp-json\/wp\/v2\/tags?post=485"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}