Difference between revisions of "R-Car/Boards/Koelsch"

From eLinux.org
Jump to: navigation, search
(Add link to SCIF FIFO test page)
Line 26: Line 26:
 
</pre>
 
</pre>
  
 +
== Bootloader ==
  
 +
=== Updating U-Boot ===
 +
You may want to update U-Boot in case of upgrade or if the board you received does not have the U-Boot flashed. Follow these steps carefully to flash U-Boot:
 +
 +
<ol>
 +
<li>
 +
Set SW17 to pin 3 side. This selects 4MB SPI Flash with MiniMonitor as a boot device.<br/>
 +
[[File:SILKSwitchRight.png|100px|Switch pin layout]]<br/>
 +
MiniMonitor is loaded via SPI boot interface of R-Car M2.
 +
</li>
 +
<li>
 +
Connect to serial console over microUSB.<br/>
 +
<pre>
 +
minicom -b 38400 -D DEVICE
 +
</pre>
 +
</li>
 +
<li>
 +
Switch the board ON or reset it. <br/>
 +
You should see the following output on the console (version numbers can be different):
 +
<pre class="bash">
 +
--------------------------------------------------------                                                                                                                                             
 +
| KOELSCH SPI_BOOT_LOADER            V0.04 2013.07.03 |                                                                                                                                             
 +
|      -----  QUAD READ (DMA Version)  -----        |                                                                                                                                             
 +
--------------------------------------------------------                                                                                                                                             
 +
SPI BOOT DEVICE : S25FL032                                                                                                                                                                         
 +
Now Loading ... ok                                                                                                                                                                                 
 +
                                                                                                                                                                                                     
 +
KOELSCH MiniMonitor SPI_BOOT                                                                                                                                                                         
 +
Work memory DRAM (H'40200000-)                                                                                                                                                                     
 +
2013.07.16 Ver0.04 ** Program on DRAM (H'40000000-)  **
 +
 +
>
 +
</pre>
 +
</li>
 +
<li>
 +
Execute the '''ls''' command:
 +
<pre>
 +
> ls
 +
Load Program to Spiflash memory (U16:S25FL512S)
 +
</pre>
 +
</li>
 +
<li>
 +
You should be able to see the following output:
 +
<pre class="bash">
 +
SW18[5:1]=OFF! Setting OK? (Push Y key)
 +
</pre>
 +
Enter '''y''' to confirm.
 +
</li>
 +
<li>
 +
You should be able to see the following output:
 +
<pre class="bash">
 +
SW16 1pin-Side! Setting OK? (Push Y key)
 +
</pre>
 +
Enter '''y''' to confirm.
 +
</li>
 +
<li>
 +
You should be able to see the following output:
 +
<pre class="bash">
 +
SW17 1pin-Side! Setting OK? (Push Y key)
 +
</pre>
 +
Set SW17 to pin 1 side then enter '''y''' to confirm.<br/>
 +
[[File:SILKSwitch.png|100px|Switch pin layout]]<br/>
 +
</li>
 +
<li>
 +
You should be able to see the following output:
 +
<pre class="bash">
 +
Load Program to Spiflash memory (U16:S25FL512S)                                                                                                                                                     
 +
---------------------------------------------------------                                                                                                                                           
 +
Please select,SPI-FLASH Save Area.                                                                                                                                                                   
 +
1:Loader Program : Program to execute on SecureRAM                                                                                                                                                 
 +
        SPI_Address = H' 000_0000-H' 003_FFFF                                                                                                                                                       
 +
                                                                                                                                                                                                     
 +
2:User Program : Program to execute on DRAM or SecureRAM                                                                                                                                           
 +
        SPI_Address = H' 008_0000-H' 3FF_FFFF                                                                                                                                                       
 +
---------------------------------------------------------                                                                                                                                           
 +
  Select area(1-2)>
 +
</pre>
 +
Select area by entering '''2''' and pressing <enter>.
 +
</li>
 +
<li>
 +
You should be able to see the following output:
 +
<pre class="bash">
 +
-- User Program ----------------------------                                                                                                                                                         
 +
Please Input User Program Start Address :
 +
</pre>
 +
Enter program address '''e6304000''' and press <enter>.
 +
</li>
 +
<li>
 +
You should be able to see the following output:
 +
<pre class="bash">
 +
Work RAM(H'50000000-H'53FFFFFF) Clear....       
 +
please send ! ('.' & CR stop load)
 +
</pre>
 +
Now you need to send the new U-Boot image in srec format over the serial console. There are different ways of doing this in in different terminal applications, here minicom is used.
 +
 +
Use '''Ctrl+A, S''', choose ascii, then locate u-boot.srec file and hit <enter>. Transmission should start immediately and the progress counter should be displayed, once the transmission is finished you should be able to see the following:
 +
 +
<pre class="bash">
 +
+------------[ascii upload - Press CTRL-C to quit]------------+                                       
 +
|ASCII upload of "u-boot.srec"                                |                                       
 +
|                                                            |                                       
 +
|678.6 Kbytes transferred at 3839 CPS... Done.                |                                       
 +
|                                                            |                                       
 +
| READY: press any key to continue...                        |                                       
 +
|                                                            |                                       
 +
|                                                            |                                       
 +
+-------------------------------------------------------------+
 +
</pre>
 +
Press <enter> to confirm.
 +
</li>
 +
<li>
 +
You should be able to see the following output:
 +
<pre class="bash">
 +
SPI Data Clear(H'FF) Check :H'00080000-000BFFFF,Clear OK?(y/n)
 +
</pre>
 +
Enter '''y''' to confirm.
 +
</li>
 +
<li>
 +
You should be able to see the following output:
 +
<pre class="bash">
 +
SAVE SPI-FLASH....... complete!                                                                                 
 +
                                                                                                               
 +
==========  SPI Flash Sector1 Save Information  =========                                                       
 +
Program Start Address :  H'E6304000                                                                           
 +
Program Size          :  H'000388BC                                                                           
 +
=========================================================                                                       
 +
                                                                                                               
 +
>
 +
</pre>
 +
U-Boot is now updated, reset the board and try it out!
 +
 +
Remember to change baud rate if you are using something different then 38400.
 +
</li>
 +
 +
<li>
 +
If you are updating from a old U-Boot version which already had a environment present make sure that the following variables are present in your new U-Boot environment (values for variables are the default ones but might be different on other systems?).
 +
<pre class="bash">
 +
bootm_low=0x40e00000
 +
bootm_size=0x100000
 +
</pre>
 +
</li>
 +
</ol>
 
== Test procedures ==
 
== Test procedures ==
  
 
* [[Tests:SCIF-FIFO]]: Test SCIF FIFO behavior, using SCIF3, SCIFA5, SCIFB0, and HSCIF1 on expansion I/O connectors
 
* [[Tests:SCIF-FIFO]]: Test SCIF FIFO behavior, using SCIF3, SCIFA5, SCIFB0, and HSCIF1 on expansion I/O connectors

Revision as of 02:45, 12 August 2016

Renesas Koelsch

Introduction

This is the Wiki for the Renesas R-Car M2-W Koelsch board (RTP0RC7791SEB00010S). Refer to the R-Car page for information about Renesas' R-Car SoC family.

Serial Console

Use a micro-USB cable to connect to "Debug Serial 0". Serial settings are 115200 8N1.

Booting Linux

 * Kernel config: shmobile_defconfig
 * Kernel image: arch/arm/boot/zImage
 * DTB: arch/arm/boot/dts/r8a7791-koelsch.dtb

U-Boot boot command:

tftp 41000000 zImage
tftp 40f00000 r8a7791-koelsch.dtb
bootz 41000000 - 40f00000

Bootloader

Updating U-Boot

You may want to update U-Boot in case of upgrade or if the board you received does not have the U-Boot flashed. Follow these steps carefully to flash U-Boot:

  1. Set SW17 to pin 3 side. This selects 4MB SPI Flash with MiniMonitor as a boot device.
    Switch pin layout
    MiniMonitor is loaded via SPI boot interface of R-Car M2.
  2. Connect to serial console over microUSB.
    minicom -b 38400 -D DEVICE
    
  3. Switch the board ON or reset it.
    You should see the following output on the console (version numbers can be different):
    --------------------------------------------------------                                                                                                                                              
    | KOELSCH SPI_BOOT_LOADER             V0.04 2013.07.03 |                                                                                                                                              
    |       -----   QUAD READ (DMA Version)   -----        |                                                                                                                                              
    --------------------------------------------------------                                                                                                                                              
     SPI BOOT DEVICE : S25FL032                                                                                                                                                                           
     Now Loading ... ok                                                                                                                                                                                   
                                                                                                                                                                                                          
    KOELSCH MiniMonitor SPI_BOOT                                                                                                                                                                          
     Work memory DRAM (H'40200000-)                                                                                                                                                                       
     2013.07.16 Ver0.04 ** Program on DRAM (H'40000000-)  **
    
    >
    
  4. Execute the ls command:
    > ls
    Load Program to Spiflash memory (U16:S25FL512S)
    
  5. You should be able to see the following output:
    SW18[5:1]=OFF! Setting OK? (Push Y key)
    

    Enter y to confirm.

  6. You should be able to see the following output:
    SW16 1pin-Side! Setting OK? (Push Y key)
    

    Enter y to confirm.

  7. You should be able to see the following output:
    SW17 1pin-Side! Setting OK? (Push Y key)
    

    Set SW17 to pin 1 side then enter y to confirm.
    Switch pin layout

  8. You should be able to see the following output:
    Load Program to Spiflash memory (U16:S25FL512S)                                                                                                                                                       
    ---------------------------------------------------------                                                                                                                                             
    Please select,SPI-FLASH Save Area.                                                                                                                                                                    
     1:Loader Program : Program to execute on SecureRAM                                                                                                                                                   
            SPI_Address = H' 000_0000-H' 003_FFFF                                                                                                                                                         
                                                                                                                                                                                                          
     2:User Program : Program to execute on DRAM or SecureRAM                                                                                                                                             
            SPI_Address = H' 008_0000-H' 3FF_FFFF                                                                                                                                                         
    ---------------------------------------------------------                                                                                                                                             
      Select area(1-2)>
    

    Select area by entering 2 and pressing <enter>.

  9. You should be able to see the following output:
    -- User Program ----------------------------                                                                                                                                                          
    Please Input User Program Start Address :
    

    Enter program address e6304000 and press <enter>.

  10. You should be able to see the following output:
    Work RAM(H'50000000-H'53FFFFFF) Clear....         
    please send ! ('.' & CR stop load)
    

    Now you need to send the new U-Boot image in srec format over the serial console. There are different ways of doing this in in different terminal applications, here minicom is used.

    Use Ctrl+A, S, choose ascii, then locate u-boot.srec file and hit <enter>. Transmission should start immediately and the progress counter should be displayed, once the transmission is finished you should be able to see the following:

    +------------[ascii upload - Press CTRL-C to quit]------------+                                         
    |ASCII upload of "u-boot.srec"                                |                                         
    |                                                             |                                         
    |678.6 Kbytes transferred at 3839 CPS... Done.                |                                         
    |                                                             |                                         
    | READY: press any key to continue...                         |                                         
    |                                                             |                                         
    |                                                             |                                         
    +-------------------------------------------------------------+ 
    

    Press <enter> to confirm.

  11. You should be able to see the following output:
    SPI Data Clear(H'FF) Check :H'00080000-000BFFFF,Clear OK?(y/n)
    

    Enter y to confirm.

  12. You should be able to see the following output:
    SAVE SPI-FLASH....... complete!                                                                                  
                                                                                                                     
    ==========  SPI Flash Sector1 Save Information  =========                                                        
     Program Start Address :  H'E6304000                                                                             
     Program Size          :  H'000388BC                                                                             
    =========================================================                                                        
                                                                                                                     
    > 
    

    U-Boot is now updated, reset the board and try it out!

    Remember to change baud rate if you are using something different then 38400.

  13. If you are updating from a old U-Boot version which already had a environment present make sure that the following variables are present in your new U-Boot environment (values for variables are the default ones but might be different on other systems?).
    bootm_low=0x40e00000
    bootm_size=0x100000
    

Test procedures

  • Tests:SCIF-FIFO: Test SCIF FIFO behavior, using SCIF3, SCIFA5, SCIFB0, and HSCIF1 on expansion I/O connectors