<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Reading and Writing register i.MX6UL in i.MX Processors</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/Reading-and-Writing-register-i-MX6UL/m-p/671574#M103416</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For direct memory access Linux provides special node /dev/mem. You can try to write to registers directly using memtool included in imx-test package.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Basically You may look at memtool sources. Please note that accesses to non-supported address regions (hardcoded in /dev/mem driver) may cause system issues.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Supported registers may be shown using the next command&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$ /unit_tests/memtool .&lt;/P&gt;&lt;P&gt;or&lt;/P&gt;&lt;P&gt;$ /unit_tests/memtool *&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;For help&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$ /unit_tests/memtool&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can find and exampl of usage in page 30 of next document.&lt;BR /&gt;&lt;A class="jive-link-external-small" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.freescale.com%2Ffiles%2F32bit%2Fdoc%2Fapp_note%2FAN4576.pdf" rel="nofollow" target="_blank"&gt;http://www.freescale.com/files/32bit/doc/app_note/AN4576.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To include this tool in your build you need to add IMAGE_iNSTALL_append = "imx-test" in the local.conf&lt;/P&gt;&lt;P&gt;After built succeed, unit_test can be found in build-6ul-x11/tmp/deploy/images/imx6ulevk/core-image-base-imx6ulevk.tar.bz2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want to access through you own c code you may check the sourcecode of memtool. Or here you can see an example.&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.nxp.com/thread/321352"&gt;Accessing CCSR from linux user space&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Best regards,&lt;BR /&gt;TIC&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 08 May 2017 21:47:29 GMT</pubDate>
    <dc:creator>Carlos_Musich</dc:creator>
    <dc:date>2017-05-08T21:47:29Z</dc:date>
    <item>
      <title>Reading and Writing register i.MX6UL</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Reading-and-Writing-register-i-MX6UL/m-p/671573#M103415</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I want to read and write LPTAR register for my board using i.MX6UL processor to wake up board from shutdown state. Is their any sample code how to read and write register from userspace in yocto?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 May 2017 13:57:31 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Reading-and-Writing-register-i-MX6UL/m-p/671573#M103415</guid>
      <dc:creator>pratyushtomar</dc:creator>
      <dc:date>2017-05-08T13:57:31Z</dc:date>
    </item>
    <item>
      <title>Re: Reading and Writing register i.MX6UL</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Reading-and-Writing-register-i-MX6UL/m-p/671574#M103416</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For direct memory access Linux provides special node /dev/mem. You can try to write to registers directly using memtool included in imx-test package.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Basically You may look at memtool sources. Please note that accesses to non-supported address regions (hardcoded in /dev/mem driver) may cause system issues.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Supported registers may be shown using the next command&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$ /unit_tests/memtool .&lt;/P&gt;&lt;P&gt;or&lt;/P&gt;&lt;P&gt;$ /unit_tests/memtool *&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;For help&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$ /unit_tests/memtool&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can find and exampl of usage in page 30 of next document.&lt;BR /&gt;&lt;A class="jive-link-external-small" href="https://community.nxp.com/external-link.jspa?url=http%3A%2F%2Fwww.freescale.com%2Ffiles%2F32bit%2Fdoc%2Fapp_note%2FAN4576.pdf" rel="nofollow" target="_blank"&gt;http://www.freescale.com/files/32bit/doc/app_note/AN4576.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To include this tool in your build you need to add IMAGE_iNSTALL_append = "imx-test" in the local.conf&lt;/P&gt;&lt;P&gt;After built succeed, unit_test can be found in build-6ul-x11/tmp/deploy/images/imx6ulevk/core-image-base-imx6ulevk.tar.bz2&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want to access through you own c code you may check the sourcecode of memtool. Or here you can see an example.&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.nxp.com/thread/321352"&gt;Accessing CCSR from linux user space&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Best regards,&lt;BR /&gt;TIC&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-----------------------------------------------------------------------------------------------------------------------&lt;BR /&gt;Note: If this post answers your question, please click the Correct Answer button. Thank you!&lt;BR /&gt;-----------------------------------------------------------------------------------------------------------------------&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 May 2017 21:47:29 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Reading-and-Writing-register-i-MX6UL/m-p/671574#M103416</guid>
      <dc:creator>Carlos_Musich</dc:creator>
      <dc:date>2017-05-08T21:47:29Z</dc:date>
    </item>
  </channel>
</rss>

