Search

Technical Discussion Group Forum

This forum is provided for user discussion. While Logic PD support staff and engineers participate, Logic PD does not guarantee the accuracy of all information within in the Technical Discussion Group (TDG).

The "Articles" forums provide brief Articles written by Logic PD engineers that address the most frequently asked technical questions.

To receive email notifications when updates are posted for a Logic PD product download, please subscribe to the TDG Forum of interest.

PrevPrev Go to previous topic
NextNext Go to next topic
Last Post 27 Nov 2018 03:19 PM by  Qui Le
Error on resetting board to boot RAMDisk image from SD card
 24 Replies
Sort:
You are not authorized to post a reply.
Page 1 of 212 > >>
Author Messages

Qui Le



New Member


Posts:12
New Member


--
26 Nov 2018 01:22 PM

    Hi All,

     

        I am following the instructions (ie. from "DM37x Linux 4.9.y BSP User Guide" ) to build the BSP for my Logic board and trying to boot up the board from the SD card.  I was able to copy the MLO, u-boot.img, logicpd-torpedo-37xx-devkit.dtb, zImage and rootfs.cpio.uboot onto the sdcard.  I've inserted the sd card into the board, booted the board and entered U-boot.  I followed the instructions of:

    OMAP Logic # nand unlock

    OMAP Logic # nand erase.chip

    OMAP Logic # reset 
     
    Pause U-Boot  
     
    OMAP Logic # nand unlock

    OMAP Logic # setenv ramdisksize 100000

    OMAP Logic # setenv ramdiskimage rootfs.cpio.uboot 

    ...

     

       However after entering "reset", the board never came back up for me to enter U-boot.  The comms is hosed.  I've tried change baud rate. Nothing.  I took the sd card out and still no comms after reboot.  How do I recover from this?  It seems everything is hosed.  Any help is appreciated!

     

    Caveat:  I tried using the HP Formatting Tool, but I never got it to work properly.  It keeps on getting "Device media is write-protected".  I tried everything to bypass this: unlocked, tape it, diskpart.  But it is not write-protected since I could copy files to it, reinsert back it and read those files.  Anyway, I ended up formatting with the Windows utility.  I labelled it "boot", but it always ends up "BOOT" as the label.  I don't know whether it matters.

     

    Thanks,

     

     

     


    Adam Ford



    Advanced Member


    Posts:754
    Advanced Member


    --
    26 Nov 2018 01:31 PM
    The internal boot ROM of the DM37 requires the MLO file to be in a very specific place which the HP formatting tool has historically done well. I am not sure why you're seeing issues. If the file is not in the exact location it expects, it will appear to hang.

    You can try to format it in Linux.

    sudo umount /media/logic/BOOT

    #replace sdb1 with whatever device yours is
    sudo mkfs.vfat /dev/sdb1 -n boot

    #mount by clicking on 'boot' that should now appear as as drive



    #The following assumes you're using the VM, so if you're not using the VM, replace 'logic' with whatever username you have
    cp MLO /media/logic/boot
    cp u-boot.img /media/logic/boot


    Qui Le



    New Member


    Posts:12
    New Member


    --
    26 Nov 2018 02:09 PM
    Thanks Adam! I did noticed that when I formatted using the Windows utility, it had a "System Volume Information" folder in it. I guess the MLO should be the first thing copied to the sd card after a truely clean format.

    Anyway, I follow your instructions for formatting it in linux, but it is still hosed at the prompt. No comms, so I can't get into U-boot. Any suggestions?

    I did copy the MLO, u-boot.img, logicpd-torpedo-37xx-devkit.dtb, zImage and rootfs.cpio.uboot into the sd card ... in that order before inserting into the logic target board.


    Thanks,
    -Qui

    Adam Ford



    Advanced Member


    Posts:754
    Advanced Member


    --
    26 Nov 2018 02:13 PM
    I have to ask...Are you using our development kit? If not, can you try it on the development kit? Can you also tell if the Power On Light is lit? If not, try pressing S2

    adam

    Qui Le



    New Member


    Posts:12
    New Member


    --
    26 Nov 2018 02:18 PM
    I am pretty sure it is your development kit. It has Logic logo on it and "Texas Instruments ... driven by DM3730". And the power light is on ... when switched on.

    Qui Le



    New Member


    Posts:12
    New Member


    --
    26 Nov 2018 02:25 PM
    I forgot to mention that my board has 2 sd card slots. I've tried both and the same results. The slot under the power input is supposed to be for boot-up use.

    Thanks,
    -Qui

    Adam Ford



    Advanced Member


    Posts:754
    Advanced Member


    --
    26 Nov 2018 02:49 PM
    The SD card socket under the power connector is correct.

    Can you try installing MLO and u-boot.img from our pre-built binaries? (with a fresh format)

    I am still leaning toward a formatting issue and/or incompatible SD card.

    The pre-built images are
    http://support.logicpd.com/DesktopM...tryId=3054

    If the link is broke, re-log into the support site and it should become available.


    adam

    Qui Le



    New Member


    Posts:12
    New Member


    --
    26 Nov 2018 03:11 PM
    Hi Adam,

    I just did a fresh format and copied the pre-built files onto the sd card ... MLO file being the first file copied in, then u-boot.img and then the rest. After power on, I still get the same thing. My Tera Term just hangs there with blinking prompt.

    The sd card that I'm using is one of demo sd cards you guys supply with the kit.


    Thanks again for looking into this for me,
    -Qui

    Qui Le



    New Member


    Posts:12
    New Member


    --
    27 Nov 2018 08:15 AM
    Hi Adam,

    I also tried with the Linux "demo" sd card and u-boot still doesn't come up. What does "nand erase.chip" actually do? Anyway when I issued the "reset" command, it displayed "resetting ..." but it never came back up. After a while, I did a power reset and nothing happened. That's my current state.

    -Qui

    Adam Ford



    Advanced Member


    Posts:754
    Advanced Member


    --
    27 Nov 2018 08:23 AM
    The command "nand erase.chip" just erases all the contents of the NAND flash part. If the SD card is bad, it goes through a variety of boot sources until it can find it. It's quite possible that your board booted from NAND and not the SD card, so when you erased NAND and rebooted, it would hang if it cannot boot from SD since the NAND is not blank.

    Can you check to see if anything is connected to the SYS_BOOTx pins? These pins control the boot sources. Two of them share lines with buttons on the baseboard. They are read on startup to determine what the boot source is. If they held in the wrong state during boot, it may not boot properly.

    Can you also try a different SD card?

    Qui Le



    New Member


    Posts:12
    New Member


    --
    27 Nov 2018 08:31 AM
    Hi Adam,

    Yes, I think the board used to boot from NAND. Where is the SYS_BOOTx pins? I don't think I had the schematic.

    As far as trying a different sd card, I tried the Linux "demo" sd card. I also tried on a different sd card where I tried it with my built and also with the pre-built binaries you mentioned yesterday.

    Thanks,
    -Qui

    Adam Ford



    Advanced Member


    Posts:754
    Advanced Member


    --
    27 Nov 2018 08:33 AM
    The Schematic is located: http://support.logicpd.com/DesktopM...ntryId=589

    You'll have to log into the support site for the link to work.

    Check the baseboard schematic and look for SYS_BOOT. There are a multiple. You can also try checking to see if your pushbuttons are bad. Two of them are connected to SYS_BOOT pins as is the LCD, so you can try removing the LCD as well.

    adam

    Qui Le



    New Member


    Posts:12
    New Member


    --
    27 Nov 2018 08:53 AM
    Hi Adam,

    I can't seem to get to the schematic site. It is complaining about redirecting too many times and I need to clear my cookies. I have cleared all my cookies, logged back onto Logic website and still get the same error.

    Looking at the target boa
    I see jumpers on the JP1(LCD power jumper), JP5, JP2, JP3,J31 and another one ... I think its JP4.

    I see 6 User buttons. I do see the Sysboot0 (S3) and Sysboot5(S4) button. Should press these buttons during power-up?

    Adam Ford



    Advanced Member


    Posts:754
    Advanced Member


    --
    27 Nov 2018 08:59 AM
    The buttons should not be pressed. I was hoping you can confirm that they are not stuck and/or driving the BOOT pins low.

    Regarding the downloading of the schematic, are you able to go directly to the product download page and download it from there? It could also be a brower issue as well. I have had good success with Chrome, while others have had good success with Firefox. There might be some security certificate issues, so you may have to tell the brower to ignore the security certificates. I know our IT is working through updating some of them.

    adam

    Adam Ford



    Advanced Member


    Posts:754
    Advanced Member


    --
    27 Nov 2018 09:10 AM
    I am still thinking there is something wrong with the formatting of the SD card. Can you insert the SD card into your host computer and run fdisk on it?

    I want to make sure you have the partitioning set correctly and the bootflag is set. I have pasted my SD card info for partition 1 below.

    Disk /dev/sdb: 4012 MB, 4012900352 bytes
    255 heads, 63 sectors/track, 487 cylinders, total 7837696 sectors
    Units = sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disk identifier: 0x00000000

    Device Boot Start End Blocks Id System
    /dev/sdb1 * 63 401624 200781 c W95 FAT32 (LBA)

    Command (m for help):

    Adam Ford



    Advanced Member


    Posts:754
    Advanced Member


    --
    27 Nov 2018 09:11 AM
    sudo umount /media/logic/boot

    sudo fdisk /dev/sdb1

    p

    Qui Le



    New Member


    Posts:12
    New Member


    --
    27 Nov 2018 09:55 AM
    Mine is:

    Disk /dev/mmcblk0p1: 3.8 GiB, 4012868096 bytes, 7837633 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disklabel type: dos
    Disk identifier: 0x00000000

    Command (m for help):

    Why is my Disklabel type "dos"?

    Qui Le



    New Member


    Posts:12
    New Member


    --
    27 Nov 2018 10:25 AM
    I am trying to create a partition and make it active. But it errors out:

    Command (m for help): d
    Selected partition 1
    Partition 1 has been deleted.

    Command (m for help): n
    Partition type
    p primary (0 primary, 0 extended, 4 free)
    e extended (container for logical partitions)
    Select (default p): p
    Partition number (1-4, default 1): 1
    First sector (2048-7837632, default 2048):
    Last sector, +sectors or +size{K,M,G,T,P} (2048-7837632, default 7837632):

    Created a new partition 1 of type 'Linux' and of size 3.8 GiB.

    Command (m for help): p
    Disk /dev/mmcblk0p1: 3.8 GiB, 4012868096 bytes, 7837633 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disklabel type: dos
    Disk identifier: 0x00000000

    Device Boot Start End Sectors Size Id Type
    /dev/mmcblk0p1p1 2048 7837632 7835585 3.8G 83 Linux

    Command (m for help): t
    Selected partition 1
    Hex code (type L to list all codes): b
    Changed type of partition 'Linux' to 'W95 FAT32'.

    Command (m for help): a
    Selected partition 1
    The bootable flag on partition 1 is enabled now.

    Command (m for help): p
    Disk /dev/mmcblk0p1: 3.8 GiB, 4012868096 bytes, 7837633 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disklabel type: dos
    Disk identifier: 0x00000000

    Device Boot Start End Sectors Size Id Type
    /dev/mmcblk0p1p1 * 2048 7837632 7835585 3.8G b W95 FAT32

    Command (m for help): w
    The partition table has been altered.
    Failed to remove partition 1 from system: Invalid argument
    Failed to add partition 1 to system: Invalid argument

    The kernel still uses the old partitions. The new table will be used at the next reboot.
    Syncing disks.

    Adam Ford



    Advanced Member


    Posts:754
    Advanced Member


    --
    27 Nov 2018 10:48 AM
    A few ideas you could try:

    1. run fdisk to delete the partition, and write it back without creating new partitions, then create new partitions

    2. run dd if=/dev/null of=/dev/sdb (or whatever your umounted device is) to wipe out the partition info

    Adam Ford



    Advanced Member


    Posts:754
    Advanced Member


    --
    27 Nov 2018 10:52 AM

    From a blank SD card, here is how I formatted it:


    Welcome to fdisk (util-linux 2.27.1).
    Changes will remain in memory only, until you decide to write them.
    Be careful before using the write command.


    Command (m for help): p
    Disk /dev/sdf: 3.8 GiB, 4012900352 bytes, 7837696 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disklabel type: dos
    Disk identifier: 0x00000000

    Command (m for help): n
    Partition type
    p primary (0 primary, 0 extended, 4 free)
    e extended (container for logical partitions)
    Select (default p): p
    Partition number (1-4, default 1): 1
    First sector (2048-7837695, default 2048):
    Last sector, +sectors or +size{K,M,G,T,P} (2048-7837695, default 7837695): +250M

    Created a new partition 1 of type 'Linux' and of size 250 MiB.

    Command (m for help): t
    Selected partition 1
    Partition type (type L to list all types): c
    Changed type of partition 'Linux' to 'W95 FAT32 (LBA)'.

    Command (m for help): a
    Selected partition 1
    The bootable flag on partition 1 is enabled now.

    Command (m for help): n
    Partition type
    p primary (1 primary, 0 extended, 3 free)
    e extended (container for logical partitions)
    Select (default p): p
    Partition number (2-4, default 2):
    First sector (514048-7837695, default 514048):
    Last sector, +sectors or +size{K,M,G,T,P} (514048-7837695, default 7837695):

    Created a new partition 2 of type 'Linux' and of size 3.5 GiB.

    Command (m for help): w
    The partition table has been altered.
    Calling ioctl() to re-read partition table.
    Syncing disks.

    logic@logic:~$

    You are not authorized to post a reply.
    Page 1 of 212 > >>