This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

DM368 Uart Booting

Hello,
 
I am trying to boot the DM368 processor on the DM368 EVM using UART. I am trying to use the Serial Loader Host utility (from the DVSDK) to load the UBL and u-boot binary. While using it, i got the following output. Can anybody tell me what went wrong? Also if anybody could suggest me a good guide for UART Booting. My intention is to boot till "u-boot" using uart port.
 
===================================================
                     output
===================================================
 
C:\Users\admin\Documents\uart_boot>slh_DM36x.exe -load2IRAM -p COM3 slt_DM36x
-----------------------------------------------------
   TI Serial Loader Host Program for DM36x
   (C) 2009, Texas Instruments, Inc.
   Ver. 1.50
-----------------------------------------------------
 
 
Loading image to ARM IRAM
 
 
Attempting to connect to device COM3...
Press any key to end this program at any time.
 
 
Unhandled Exception: System.ArgumentException: Destination array is not long enough to copy all the items in the collection. Check array index and length.
   at System.BitConverter.ToInt32(Byte[] value, Int32 startIndex)
   at System.BitConverter.ToUInt32(Byte[] value, Int32 startIndex)
   at TIBootAndFlash.Program.TransmitUBL(Byte[] imageData, UARTBOOT_Header ackHeader)
   at TIBootAndFlash.Program.TransmitAppToIRAM()
   at TIBootAndFlash.Program.WorkerThreadStart()
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart()
 
===================================================
 
Please note : The output is same on both windows and Linux platforms.

Thanks and regards ,

Anand Misry

  • Anand,

    Which is the DM36x silicon revision? Is it 1.1 or 1.2?

  • Hello Renjith,

    After having a closer look at the processor on my DM368 EVM, I came to know that its a DMVA2 with the following text printed on it.

    "DMVA2ZCE", "IAACV7W", "570" and "GI" with an underline.

    I couldn't find its datasheet so i don't have the silicon revision.


    Thanks and regards,
    Anand Mistry

  • Anand,

    DMVA is another name of DM36x silicon. This is mainly targeted for Video Analytics Market. It is i the same silicon as DM36x.

  • Thanks Thomas,

    Google also gave the same answer but the question is what is the silicon version? Why is UART boot mode not working in DM368EVM? Is it because it is of silicon version 1.1? Anand has provided the complete part number so it should be easy for you to tell the silicon version. 

  • What is the part number. If its 1.1 UART boot will not work. You need at least 1.2 revision for uart boot to work.

  • Renjith,

    I tried with DM365EVM having chip revision 1.2. I am able to flash NAND but unable to boot from serial. I tried following command sequence to run u-boot through UART.

    slh_DM36x.exe -load2IRAM slt_DM36x.bin

    slh_DM36x.exe -load2DDR u-boot-dm365-evm.bin

    Plz suggest what's wrong.

  • Vipul,

    Are you getting the same error as posted in your first post? If no, can you post the logs from the PC side?

  • I tried on windows and yes i got same output but then i continued with second command to load uboot. But after loading uboot the program never returned. If any key is pressed after this the program gets aborted.

  • Vipul,

    Are you sure that whether COM3 is the right serial port in your PC? Also make sure that you reset the board after running the command. Also can you cross check whether you are using UART as your first boot device according to the bootmode pin settings?

  • Renjith,

    Have you increased your points by asking such questions or by providing solutions? Do you ever read what has been posted before replying? Let me elaborate further:

    1. Objective: Trying to run serial boot mode in DM368 to load uboot & kernel through serial port. 

    2. Achieved: Successfully flashed NAND with uboot using serial flasher. This proves we are using UART as boot device. BOOT ME message can be seen on hyperterminal. 

    3. COM port: The COM port is fine because this command runs without any error "slh_DM36x.exe -load2IRAM slt_DM36x.bin".

    4. Problem: If you know plz mention steps how to boot kernel using serial port.

    Here are the logs,

    =====================================================================================================================

    -----------------------------------------------------
    TI Serial Loader Host Program for DM36x
    (C) 2009, Texas Instruments, Inc.
    Ver. 1.50
    -----------------------------------------------------


    Platform is Windows.
    Loading image to ARM IRAM


    Attempting to connect to device COM1...
    Press any key to end this program at any time.


    Waiting for the DM36x...
    BOOTME commmand received. Returning ACK and header...
    ACK command sent. Waiting for BEGIN command...
    Target: BEGIN
    BEGIN commmand received. Sending CRC table...
    100% [ ]
    CRC table sent....

    Waiting for DONE...
    DONE received. Sending the UBL...
    100% [ ]
    UBL sent....

    Unhandled Exception: System.IO.IOException: The I/O operation has been aborted b
    ecause of either a thread exit or an application request.

    at System.IO.Ports.InternalResources.WinIOError(Int32 errorCode, String str)
    at System.IO.Ports.SerialStream.BeginReadCore(Byte[] array, Int32 offset, Int
    32 numBytes, AsyncCallback userCallback, Object stateObject)
    at System.IO.Ports.SerialStream.ReadByte(Int32 timeout)
    at System.IO.Ports.SerialStream.ReadByte()
    at System.IO.Ports.SerialPort.ReadByte()
    at UtilLib.IO.SerialIO.waitForSequence(String str, String altStr, SerialPort
    sp, Boolean verbose)
    at TIBootAndFlash.Program.TransmitUBL(Byte[] imageData, UARTBOOT_Header ackHe
    ader)
    at TIBootAndFlash.Program.TransmitAppToIRAM()
    at TIBootAndFlash.Program.WorkerThreadStart()
    at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
    at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, C
    ontextCallback callback, Object state)
    at System.Threading.ThreadHelper.ThreadStart()

    C:\Documents and Settings\admin>

    =====================================================================================================================

    -----------------------------------------------------
    TI Serial Loader Host Program for DM36x
    (C) 2009, Texas Instruments, Inc.
    Ver. 1.50
    -----------------------------------------------------


    Platform is Windows.
    Loading image to DDR


    Attempting to connect to device COM1...
    Press any key to end this program at any time.


    Waiting for the DM36x...
    BOOTME commmand received. Returning ACK and header...
    ACK command sent. Waiting for BEGIN command...
    Target: BEGIN
    BEGIN commmand received. Sending CRC table...
    100% [ ]
    CRC table sent....

    Waiting for DONE...
    DONE received. Sending the UBL...
    100% [ ]
    UBL sent....


    DONE received. UBL was accepted.
    UBL transmitted successfully.


    Waiting for SLT on the DM36x...
    Target: Starting UART Boot...
    Target: BOOTUBL
    BOOTUBL commmand received. Returning CMD and command...
    CMD value sent. Waiting for DONE...
    DONE received. Command was accepted.
    Waiting for SENDIMG sequence...
    SENDIMG received. Returning ACK and header for image data...
    ACK command sent. Waiting for BEGIN command...
    BEGIN commmand received.

    100% [ ]
    Image data sent...


    Waiting for DONE...
    DONE received. All bytes of image data received...

    =====================================================================================================================

    The program didn't return and i have to forcefully end this program by pressing any key.

  • Vipul,

    If you check the post clearly you can see that Anand has posted the original query. Later you've started asking questions. How will I know that both of you are working in the same company with the same setup? Is it mentioned somewhere in your post? 

    vipul mahajan said:

    I am able to flash NAND but unable to boot from serial.

    Does it say that you are using serial to flash NAND?

    Please post the query properly in the forum before start cribbing about the response. Also I'm not sitting with the 1.2 board to debug the issue for you.

  • Renjith,

    Renjith Thomas said:
    If you check the post clearly you can see that Anand has posted the original query. Later you've started asking questions. How will I know that both of you are working in the same company with the same setup? Is it mentioned somewhere in your post?

    We are two different people in two different company working on 2 different boards. I have DM365EVM having version 1.2 and he has DM368EVM having some other chip. So I need not to mention it.

    Renjith Thomas said:
    Does it say that you are using serial to flash NAND?

    Yes, it says so. Try to read 2 - 3 posts earlier I said I am able to flash NAND using serial but unable to boot through serial. Was my english that bad? Or I am not suppose to ask questions in other people's posts?

    If you won't answer or won't suggest a way out to solve the problem I will definitely make fuss about it. If you are not having 1.2 board and no idea about whats going wrong then plz stop suggesting irrelevant things (e.g checking the port, reset the board, etc).

  • Vipul,

    vipul mahajan said:
    If you won't answer or won't suggest a way out to solve the problem I will definitely make fuss about it.

    Thanks for your inputs. Will take care from next time. Also you can choose not reply if you find my questions are stupid.

    Let's get back to the real problem. Can you share the following info?

    1. What is the size of both ubl and u-boot images that you are loading?

    2. What is the load address of both the images? 

  • Thanks Renjith for pointing the issue of load address. We are able to load uboot through UART. 

    Run this command for UBL:

    slh_DM36x.exe -load2IRAM slt_DM36x.bin

    Run this command for uboot:

    slh_DM36x.exe -load2DDR -startAddr 0x81080000 -loadAddr 0x81080000 u-boot-dm365-evm.bin

    Without specifying the startAddr & loadAddr it takes the default address i.e 0x80000000

  • My problem's solved. I dont know what chip revision it is, but it booted successfully!!

    Thanks Renjith for pointing out the image size and address issues
    and thanks Vipul for posting your commands and keeping this discussion up.
    I'd almost thought that my board doesnt support uart boot.

    This is how i did it.

    What was wrong?

        - Image size.
                I was trying to load "slt_DM36x" file which is a ~40k image.
                whereas i had to actually load slt_DM36x.bin file which is ~5k.
        - Load and Start Addresses.
                By not providing explicit load addresses, the U-Boot shall be
                loaded to default load address.

    Whats the solution?

        1. The slt_DM36x file had to be converted to slt_DM36x.bin using the following command

            arm-none-linux-gnueabi-objcopy --gap-fill 0xFF -S -O binary slt_DM36x slt_DM36x.bin
            
        2. The following commands were used to boot u-boot at correct addresses

            mono ./slh_DM36x.exe -load2IRAM -p /dev/ttyUSB0 ./slt_DM36x.bin
            mono ./slh_DM36x.exe -load2DDR -p /dev/ttyUSB0 -startAddr 0x81080000 -loadAddr 0x81080000 u-boot.bin

    NOTE : All these commands were run on linux

  • Hi Friend:

       I am follow the script and I can not uboot the DM368 from UART.  What ' s  happend ?

    slh_DM36x.exe -load2IRAM slt_DM36x.bin

    -----------------------------------------------------
       TI Serial Loader Host Program for DM36x
       (C) 2009, Texas Instruments, Inc.
       Ver. 1.50
    -----------------------------------------------------


    Platform is Windows.
    Loading image to ARM IRAM


    Attempting to connect to device COM1...
    Press any key to end this program at any time.


    Waiting for the DM36x...

  • Hello :

    How to identify the silicon revision. My DM368 is DM368ZCE 14AELFW G1

     

  • Jemy,

    Please refer the Silicon errata for the info.

    http://www.ti.com/lit/er/sprz316b/sprz316b.pdf

  • hi, Vipul, I encounter almost the same proble with you, can you tell me what's the reason of this and how can solve it? Many thanks.