<?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>LayerscapeのトピックRe: board bringup  using ls1043a custom  board</title>
    <link>https://community.nxp.com/t5/Layerscape/board-bringup-using-ls1043a-custom-board/m-p/1741967#M13501</link>
    <description>&lt;P&gt;After using QCVS DDR tool to calculate DDR controller configuration parameters, you need to use QCVS DDRv tool to connect to the target board to do verification and optimization to get the final DDR controller configuration parameters.&lt;/P&gt;
&lt;P&gt;You could modify CodeWarrior initialization file and use diagnostic feature provided in CodeWarrior to check whether DDR access on your custom board is OK. You could also run CodeWarrior bareboard project to check whether the UART console is OK.&lt;/P&gt;
&lt;P&gt;You also need to modify DDR controller configuration in u-boot source code.&lt;/P&gt;
&lt;P&gt;In addition, you need to compile u-boot binary file for&amp;nbsp;SD/eMMC or NAND.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 18 Oct 2023 08:48:38 GMT</pubDate>
    <dc:creator>yipingwang</dc:creator>
    <dc:date>2023-10-18T08:48:38Z</dc:date>
    <item>
      <title>board bringup  using ls1043a custom  board</title>
      <link>https://community.nxp.com/t5/Layerscape/board-bringup-using-ls1043a-custom-board/m-p/1738640#M13477</link>
      <description>&lt;P&gt;&amp;nbsp;Hi,&lt;/P&gt;&lt;P&gt;we are trying to&amp;nbsp; bringup our custom board with LS1043A by following procedure given in&amp;nbsp; &lt;STRONG&gt;Bringing up layerscape devices using CCS script and DRAM init&amp;nbsp; AN12270.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Due to issue with Flash device , we&amp;nbsp; want to use DRAM boot . As apart of that we have customized&amp;nbsp; ddr4 Init&amp;nbsp; using QCVS Tool and&amp;nbsp; also U-boot&amp;nbsp; complied to target&amp;nbsp; DRAM BOOT.&amp;nbsp;&lt;/P&gt;&lt;P&gt;After&amp;nbsp; &amp;nbsp;run the Lsbp.tcl&amp;nbsp; script. following data is coming&amp;nbsp; in CCS window.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Pamid_0-1697109286256.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/244816i84AA26B144817715/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Pamid_0-1697109286256.png" alt="Pamid_0-1697109286256.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;We have verified U-Boot&amp;nbsp; dump in ddr4&amp;nbsp; by memory view and it was ok. But we are not getting any&amp;nbsp; status&amp;nbsp; on console port.&amp;nbsp;As per the docs from NXP&amp;nbsp; for dram boot, PBL is not required and it will be in bypass mode. Am&amp;nbsp; I correct?.&lt;/P&gt;&lt;P&gt;1.&amp;nbsp; After dumping the&amp;nbsp; U-boot in ddr4, how control will jump to starting address of boot code?&lt;/P&gt;&lt;P&gt;2. As per RCW src console port&amp;nbsp; UART1 is enabled. But we are unable to&amp;nbsp; access it. no prompt is coming on serial port..&lt;/P&gt;&lt;P&gt;3.Please clarify where will be the b problem? or approach is not correct?.&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;For your reference copy of&amp;nbsp; &amp;nbsp;customized Lsbp.tcl&amp;nbsp; is given below.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;-----------------------------------------------------------------------&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;# Script to init ddr, copy u-boot and launch it&lt;/P&gt;&lt;P&gt;namespace eval lsbp {&lt;/P&gt;&lt;P&gt;proc lsbp {} {&lt;/P&gt;&lt;P&gt;#1: Customize the ddr init script file name&lt;BR /&gt;source ddr-init-ls1043rdb_pd.tcl&lt;BR /&gt;#2: Set device, currently supports ls1021a/ls1043a/ls1046a&lt;BR /&gt;set device ls1043a&lt;BR /&gt;switch -exact $device {&lt;BR /&gt;"ls1021a" { set dut ls1020a }&lt;BR /&gt;"ls1043a" { set dut ls1043a }&lt;BR /&gt;"ls1046a" { set dut ls1043a }&lt;BR /&gt;default {echo This device is not supported; return 0}&lt;BR /&gt;}&lt;BR /&gt;#3: Set hardcode_rcw&lt;BR /&gt;# For LS1043A and LS1046A&lt;BR /&gt;# 0x9E: DDRCLK is the reference clock for DDR&lt;BR /&gt;# 0x9F: DIFF_SYSCLK is the reference clock for DDR&lt;BR /&gt;# For LS1021A&lt;BR /&gt;# 0x9B: First try value. See RM for more options&lt;BR /&gt;set hardcode_rcw 0x9F&lt;/P&gt;&lt;P&gt;#4: Please customize the CWTAP setting, see Apps note for more info&lt;BR /&gt;delete all&lt;BR /&gt;config cc cwtap:192.168.10.229&lt;BR /&gt;ccs::config_chain "$dut dap sap2"&lt;/P&gt;&lt;P&gt;# Call rcw-override procedure&lt;BR /&gt;lsbp::rcw-override $dut $hardcode_rcw&lt;/P&gt;&lt;P&gt;# Parse the JTAG to find out the chain position of DAP, SAP2, Boot Core&lt;BR /&gt;set tap [lsbp::tap-parse]&lt;BR /&gt;set dap [lindex $tap 0]&lt;BR /&gt;set sap2 [lindex $tap 1]&lt;BR /&gt;set boot_core [lindex $tap 2]&lt;/P&gt;&lt;P&gt;# Call the pbi procedure to write minimal registers&lt;BR /&gt;lsbp::pbi $dut $dap&lt;/P&gt;&lt;P&gt;# Call init-ddrc procedure to initialize DDR controller&lt;BR /&gt;lsbp::init-ddrc $dap&lt;/P&gt;&lt;P&gt;# Call loadb procedure to load u-boot.bin to DDR address 0x82000000&lt;BR /&gt;lsbp::loadb $sap2&lt;BR /&gt;# Release the boot core, ARM core 0&lt;BR /&gt;ccs::run_core $boot_core&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;proc rcw-override {dut hardcode_rcw} {&lt;BR /&gt;ccs::config_template 0 0x1001 5000&lt;BR /&gt;ccs::config_template 0 0x1000 1&lt;BR /&gt;ccs::write_reg 0 rcw_src $hardcode_rcw&lt;BR /&gt;ccs::write_reg 0 rcw11 0x01098800&lt;BR /&gt;ccs::reset_to_debug&lt;BR /&gt;ccs::config_chain "$dut dap sap2"&lt;BR /&gt;display ccs::get_config_chain&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;proc pbi {dut chain_pos} {&lt;BR /&gt;if {$dut == "ls1020a"} {&lt;BR /&gt;ccs::write_mem $chain_pos 0 0x1ee0200 4 0 0x82000000&lt;BR /&gt;} elseif {$dut == "ls1043a"} {&lt;BR /&gt;# For both LS1043/LS1046&lt;BR /&gt;ccs::write_mem $chain_pos 0 0x1570418 4 0 0x0000009e&lt;BR /&gt;ccs::write_mem $chain_pos 0 0x157041c 4 0 0x0000009e&lt;BR /&gt;ccs::write_mem $chain_pos 0 0x1570420 4 0 0x0000009e&lt;BR /&gt;#ccs::write_mem $chain_pos 0 0x1570188 4 0 0x80000000&lt;BR /&gt;ccs::write_mem $chain_pos 0 0x1570600 4 0 0x00000000&lt;BR /&gt;ccs::write_mem $chain_pos 0 0x1570604 4 0 0x82000000&lt;BR /&gt;} else {&lt;BR /&gt;echo This device is not supported;&lt;BR /&gt;return 0&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;proc loadb { chain_pos } {&lt;BR /&gt;ccs::set_max_tck $chain_pos 18000&lt;BR /&gt;set fd [open ./u-boot.bin r]&lt;BR /&gt;fconfigure $fd -translation binary&lt;BR /&gt;set i 0&lt;BR /&gt;while 1 {&lt;BR /&gt;set data0 [read $fd 8]&lt;BR /&gt;set data0h [bin2hex $data0]&lt;BR /&gt;set data1 [read $fd 8]&lt;BR /&gt;set data1h [bin2hex $data1]&lt;BR /&gt;set data2 [read $fd 8]&lt;BR /&gt;set data2h [bin2hex $data2]&lt;BR /&gt;set data3 [read $fd 8]&lt;BR /&gt;set data3h [bin2hex $data3]&lt;BR /&gt;ccs::write_mem $chain_pos 0 [format 0x%x [expr 0x82000000+$i]] 8 0 "$data0h $data1h $data2h $data3h"&lt;BR /&gt;if { [eof $fd] } break&lt;BR /&gt;incr i 32&lt;BR /&gt;}&lt;BR /&gt;close $fd&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;proc bin2hex {binstr {delim ""}} {&lt;BR /&gt;set s ""&lt;BR /&gt;set 0x " 0x"&lt;BR /&gt;for {set i 0} {$i &amp;lt; [string length $binstr]} {incr i} {&lt;BR /&gt;binary scan [string index $binstr $i] H2 cc&lt;BR /&gt;set s ${cc}${s}&lt;BR /&gt;if { $i == 3 || $i == 7} {&lt;BR /&gt;set s ${0x}${s}&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;switch [string length $binstr] {&lt;BR /&gt;0 { return "0x00000000 0x00000000" }&lt;BR /&gt;1 { return "0x00000000 0x000000${s}" }&lt;BR /&gt;2 { return "0x00000000 0x0000${s}" }&lt;BR /&gt;3 { return "0x00000000 0x00${s}" }&lt;BR /&gt;4 { return "0x00000000${s}" }&lt;BR /&gt;5 { return "0x000000${s}" }&lt;BR /&gt;6 { return "0x0000${s}" }&lt;BR /&gt;7 { return "0x00${s}" }&lt;BR /&gt;default {&lt;BR /&gt;return $s&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;proc tap-parse {} {&lt;BR /&gt;set sap2 0&lt;BR /&gt;set dap 0&lt;BR /&gt;set sp 0&lt;BR /&gt;set dpaa 0&lt;BR /&gt;set gpp_cores {}&lt;BR /&gt;set chain_pos 0&lt;BR /&gt;set children [ccs::get_config_chain]&lt;BR /&gt;set tap_num 0&lt;BR /&gt;foreach child $children {&lt;BR /&gt;set type $child&lt;BR /&gt;#echo $type&lt;BR /&gt;if {$type == $ccs::core(sap2)} { set sap2 $tap_num&lt;BR /&gt;} elseif {$type == $ccs::core(dap)} { set dap $tap_num&lt;BR /&gt;} elseif {$type == $ccs::core(CortexA5)} { set sp $tap_num&lt;BR /&gt;} elseif {$type == $ccs::core(lsdpaa2)} { set dpaa $tap_num&lt;BR /&gt;} elseif {$type == $ccs::core(CortexA53)} { lappend gpp_cores $tap_num&lt;BR /&gt;} elseif {$type == $ccs::core(CortexA72)} { lappend gpp_cores $tap_num&lt;BR /&gt;} elseif {$type == $ccs::core(CortexA7)} { lappend gpp_cores $tap_num }&lt;BR /&gt;incr tap_num&lt;BR /&gt;}&lt;BR /&gt;set boot_core [lindex $gpp_cores 0]&lt;BR /&gt;echo $gpp_cores;&lt;BR /&gt;echo boot_core;&lt;BR /&gt;return [list $dap $sap2 $boot_core]&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&amp;amp; regards&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 12 Oct 2023 12:18:57 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Layerscape/board-bringup-using-ls1043a-custom-board/m-p/1738640#M13477</guid>
      <dc:creator>Pamid</dc:creator>
      <dc:date>2023-10-12T12:18:57Z</dc:date>
    </item>
    <item>
      <title>Re: board bringup  using ls1043a custom  board</title>
      <link>https://community.nxp.com/t5/Layerscape/board-bringup-using-ls1043a-custom-board/m-p/1741967#M13501</link>
      <description>&lt;P&gt;After using QCVS DDR tool to calculate DDR controller configuration parameters, you need to use QCVS DDRv tool to connect to the target board to do verification and optimization to get the final DDR controller configuration parameters.&lt;/P&gt;
&lt;P&gt;You could modify CodeWarrior initialization file and use diagnostic feature provided in CodeWarrior to check whether DDR access on your custom board is OK. You could also run CodeWarrior bareboard project to check whether the UART console is OK.&lt;/P&gt;
&lt;P&gt;You also need to modify DDR controller configuration in u-boot source code.&lt;/P&gt;
&lt;P&gt;In addition, you need to compile u-boot binary file for&amp;nbsp;SD/eMMC or NAND.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 18 Oct 2023 08:48:38 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Layerscape/board-bringup-using-ls1043a-custom-board/m-p/1741967#M13501</guid>
      <dc:creator>yipingwang</dc:creator>
      <dc:date>2023-10-18T08:48:38Z</dc:date>
    </item>
  </channel>
</rss>

