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.

Panda5 trouble with usbboot

Hi, I have a UEVM5432G-02-01-00 ES 2.0 GP PandaBoard -- sometimes called Panda5 (I think).  

The latest release for this appears to be Panda5AJ.1.5.1 (Sep 2013) from the list of releases here.

I downloaded the distribution from TI, and unzipped it on Ubuntu 12.04 virtual machine (under VMWare Fusion on Mac OS 10.7).

Here's what happens when I run usbboot fast mode:

$ sudo ./usbboot -f
waiting for device...
reading ASIC ID
CHIP: 5430
rom minor version: 02
IDEN: 0000000000000000000000000000000000000000
MPKH: 0000000000000000000000000000000000000000000000000000000000000000
CRC0: 071a9a31
CRC1: 00000000
device is GP
using built-in GP iboot of size 23-KB
sending 2ndstage to target...
waiting for 2ndstage response...

Then if I run fastboot.sh...

$ sudo ./fastboot.sh 
[sudo] password for davis: 

Fastboot - device detected: userdata.img

It just sits there and nothing proceeds.  adb devices output:

$ sudo ./adb devices
[sudo] password for davis: 
* daemon not running. starting it now on port 5037 *
* daemon started successfully *
List of devices attached 

lsusb output of the TI device:

Bus 001 Device 002: ID 0451:d011 Texas Instruments, Inc. 
Couldn't open device, some information will be missing
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass          255 Vendor Specific Class
  bDeviceSubClass       255 Vendor Specific Subclass
  bDeviceProtocol       255 Vendor Specific Protocol
  bMaxPacketSize0        64
  idVendor           0x0451 Texas Instruments, Inc.
  idProduct          0xd011 
  bcdDevice            0.00
  iManufacturer          33 
  iProduct               37 
  iSerial                 0 
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength           32
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          1 
    bmAttributes         0xc0
      Self Powered
    MaxPower              100mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass       255 Vendor Specific Class
      bInterfaceSubClass    255 Vendor Specific Subclass
      bInterfaceProtocol    255 Vendor Specific Protocol
      iInterface              2 
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x01  EP 1 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               0

I read through the similar threads here: 

 but was not able to resolve the issue through any of the recommended solutions.

I tried using the version of usbboot attached to that thread, and it did fix the discrepancy of iboot size from 23-K to 48-K (note in my output above it shows 23-K, which that thread claims is not correct), but fastbooth.sh still would not work and just sits there.

There was talk about having to cherry pick a specific commit from the git source and build usbboot / fastboot from that, but it isn't clear to me why or if that is applicable to my device.

Can someone please advise?

Thanks in advance

  • Hi Davis,

    Is you sysboot jumper configuration set  to 0000 ( 1st is eMMC) and then try  with the attached usbboot, adb andfastboot

    For example:

    sudo ./usbboot -f

    sudo ./fastboot flash boot boot.img

    8737.files.zip

  • Hi Boyko, thanks for the response.  Yes, the jumpers are all in the off position.  

    I am going down the path of building everything myself to see if that resolves the issue.  I have been trying to check out the source for 1.5 days now (it is still doing repo sync command for 12+ hours!)  Hoping to finish that today and do the build myself, but I appreciate the extra binaries and I will also try those.

  • Before trying to build try with  the per-builded images that way  you may verify for sure if there is a problem with the  instruments or perhaps a faulty board.

    Regards,

    Boyko

  • Hi Boyko,

    Here's a snap of the jumper settings:

    Using the files you attached to this thread, here's what happens:

    First I copied the usbboot, adb, and fastboot binaries you sent over the distribution I downloaded from http://software-dl.ti.com/omap/omap5/omap5_public_sw/OMAP5432-EVM/5AJ_1_5_1_Release/index_FDS.html

    1. Board is powered off

    2. Connect USB3 cable to board and laptop

    3. I don't have a mini-usb cable right now, so I can't connect to board and see screen tty output -- I am going to go buy one

    4. Run sudo ./usbboot -f

    android@ubuntu:~/Desktop/emmc_files$ sudo ./usbboot -f
    [sudo] password for android: 
    waiting for device...
    reading ASIC ID
    CHIP: 5430
    rom minor version: 02
    IDEN: 0000000000000000000000000000000000000000
    MPKH: 0000000000000000000000000000000000000000000000000000000000000000
    CRC0: 071a9a31
    CRC1: 00000000
    device is GP
    using built-in GP iboot of size 23-KB
    sending 2ndstage to target...
    waiting for 2ndstage response...
    

    5. I leave the terminal running there, and open a new terminal to run fastboot.  usbboot just waits there...

    android@ubuntu:~/Desktop/emmc_files$ sudo ./fastboot flash boot boot.img
    [sudo] password for android: 
    < waiting for device >
    

    That's as far as I get.  I am going to go get a micro USB cable so I can plug into the debug USB port and try to see if there are any other diag messages that can help determine what is wrong, but I appreciate any other ideas you may have.

    Thanks,

    Davis

  • I had to scrap that Ubuntu VM, b/c I ran out of disk space trying to suck down all the code with "repo sync" command, and corrupted it trying to resize with gparted, so I'm rebuilding a new one, but going through the VM settings, I noticed this screen:

    So, before I am certain that this advanced settings was configured for USB 2.0, and not USB 3.0.  I suspect that may be related to the issue I am having.  I seem to recall someone else indicating that they had trouble using a VM with USB 3.0.

    I am now rebuilding a new VM, and it will be configured for USB 3.0, and I will retry the pre-built binaries once again.

  • Hi Boyko, I have made some progress.  Changing the VM USB settings from 2.0 to 3.0 got me a bit farther, but it is not quite there yet.  Seems like maybe a timing issue.

    I did get a micro USB cable and connected to it with screen to see the debug UART terminal, here is the output:

    Texas Instruments Inc Bootloader 1.1.0-jenkins-OMAP5_usbboot-1102^0
    Build Info: May  2 2013 - 19:33:42
    OMAP reset reason PRM_RSTST = 0x0001
    PMIC reset reason SWOFF_STATUS = 0x02
    sram: boot device: EMMC
    Device Serial Number: 2E6604F0401A0001
    Entering fastboot mode...
    

    And here are the results of running usbboot + fastboot.  First I tried it with the fastboot command you posted:

    android@ubuntu:/mnt/hgfs/omap5/emmc_files$ sudo ./usbboot -f; sudo ./fastboot flash boot boot.img;
    waiting for device...
    reading ASIC ID
    CHIP: 5430
    rom minor version: 02
    IDEN: 0000000000000000000000000000000000000000
    MPKH: 0000000000000000000000000000000000000000000000000000000000000000
    CRC0: 071a9a31
    CRC1: 00000000
    device is GP
    using built-in GP iboot of size 23-KB
    sending 2ndstage to target...
    waiting for 2ndstage response...
    received 2ndstage response...
    sending 'boot' (4966 KB)...
    FAILED (command write failed (Bad file descriptor))
    finished. total time: 0.000s
    

    Then I tried it using the fastboot.sh shell script -- after powering down the board and starting over:

    android@ubuntu:/mnt/hgfs/omap5/emmc_files$ sudo ./usbboot -f; sudo ./fastboot.sh
    waiting for device...
    reading ASIC ID
    CHIP: 5430
    rom minor version: 02
    IDEN: 0000000000000000000000000000000000000000
    MPKH: 0000000000000000000000000000000000000000000000000000000000000000
    CRC0: 071a9a31
    CRC1: 00000000
    device is GP
    using built-in GP iboot of size 23-KB
    sending 2ndstage to target...
    waiting for 2ndstage response...
    received 2ndstage response...
    No device detected. Please ensure that fastboot is running on the target device
    

    Would love any recommendations on how to proceed further :)

  • So, I found this little tidbit from http://omappedia.org/wiki/Omapboot:

    | On PANDA5, connect the power cable and only after that connect the USB cable.

    So, i tried that.  Power down board, unplug usb3 from board.  Power on board, run usbboot, plugin usb3:

    android@ubuntu:/mnt/hgfs/omap5/emmc_files$ sudo ./usbboot -f
    waiting for device...
    reading ASIC ID
    CHIP: 5430
    rom minor version: 02
    IDEN: 0000000000000000000000000000000000000000
    MPKH: 0000000000000000000000000000000000000000000000000000000000000000
    CRC0: 071a9a31
    CRC1: 00000000
    device is GP
    using built-in GP iboot of size 23-KB
    sending 2ndstage to target...
    waiting for 2ndstage response...
    received 2ndstage response...
    

    Now run fastboot.sh:

    android@ubuntu:/mnt/hgfs/omap5/emmc_files$ sudo ./fastboot.sh
    
    Fastboot - device detected: 2E6604F0401A0001
    

    ...and that's as far as it gets.  Debug UART output:

    Texas Instruments Inc Bootloader 1.1.0-jenkins-OMAP5_usbboot-1102^0
    Build Info: May  2 2013 - 19:33:42
    OMAP reset reason PRM_RSTST = 0x0001
    PMIC reset reason SWOFF_STATUS = 0x00
    sram: boot device: EMMC
    Device Serial Number: 2E6604F0401A0001
    Entering fastboot mode...

  • This thread seems related: http://e2e.ti.com/support/omap/f/885/p/284030/1016095.aspx 

    Unfortunately, it will require me to download and build the sources and make a small modification to the usbboot source to add a delay in the protocol.  That is my next step, but will not be able to try until next week.

    Happy to hear if you guys at TI have any other suggestions :)

  • Hi Davis,

    Have you tried with micro usb 2 cable to connect to the  usb3 port of the target?

    when execute: sudo ./usbboot -f

    you get: waiting for device...

    *press reset*

    you get :

    reading ASIC ID
    CHIP: 5430
    rom minor version: 02
    IDEN: 0000000000000000000000000000000000000000
    MPKH: 0000000000000000000000000000000000000000000000000000000000000000
    CRC0: 071a9a31
    CRC1: 00000000
    device is GP
    using built-in GP iboot of size 23-KB
    sending 2ndstage to target...
    waiting for 2ndstage response...
    received 2ndstage response...
    bkazakov@mms:~/omap5/5AJ.1.5/emmc_files$

    console prints:

    Texas Instruments Inc Bootloader 1.1.0-jenkins-OMAP5_usbboot-1102^0
    Build Info: May  2 2013 - 19:33:42
    OMAP reset reason PRM_RSTST = 0x0001
    PMIC reset reason SWOFF_STATUS = 0x00
    sram: boot device: EMMC
    Device Serial Number: 2E6604F04C600001
    Entering fastboot mode...

    that means your fastboot is successful, now all that remains is why flashing specific images ( sudo ./fastboot flash boot boot.img for example )  is misbehaving. In my opinion is something with the communication not due the usbboot scripts.

    One other thing - When you execute  sudo ./usbboot -f and get the "received 2ndstage response..." wait a couple of seconds before you try to flash with sudo ./fastboot flash boot boot.img .

    Regards,

    Boyko

  • Hello Boyko, the reset appeared to help.  I was able to program successfully.  

    Debug UART output:

    Texas Instruments Inc Bootloader 1.1.0-ge3a6f493
    Build Info: Sep 11 2013 - 19:31:49
    OMAP reset reason PRM_RSTST = 0x0001
    PMIC reset reason SWOFF_STATUS = 0x00
    sram: boot device: EMMC
    Device Serial Number: 2E6604F0401A0001
    Entering fastboot mode...
    Reading 24141 amount of data ...
    writing to partition bootloader, begins at sector: 256 and is 262144 long
    Done flashing the non-sparse formatted image to bootloader
    Reading 5085184 amount of data ...
    writing to partition boot, begins at sector: 51488 and is 8388608 long
    Done flashing the non-sparse formatted image to boot
    Reading 231825400 amount of data ...
    writing to partition system, begins at sector: 67872 and is 536870912 long
    Done flashing the sparse formatted image to system
    Reading 51831688 amount of data ...
    writing to partition userdata, begins at sector: 1640736 and is 3119366144 long
    Done flashing the sparse formatted image to userdata
    Reading 4513940 amount of data ...
    writing to partition efs, begins at sector: 2304 and is 16777216 long
    Done flashing the sparse formatted image to efs
    Reading 6398160 amount of data ...
    writing to partition cache, begins at sector: 1116448 and is 268435456 long
    Done flashing the sparse formatted image to cache
    

    Fastboot output:

    android@ubuntu:/mnt/hgfs/omap5bin/emmc_files$ sudo ./fastboot.sh 
    
    Fastboot - device detected: 2E6604F0401A0001
    
    Missing ./cache.img
    Missing ./recovery.img
    Create GPT partition table
    ...
    OKAY [  0.009s]
    finished. total time: 0.009s
    Flashing bootloader.....
       bootloader: ./omap5uevm_GP_ES2.0_MLO
    sending 'bootloader' (23 KB)...
    OKAY [  0.005s]
    writing 'bootloader'...
    OKAY [  0.009s]
    finished. total time: 0.014s
    Flash android partitions
    sending 'boot' (4966 KB)...
    OKAY [  0.317s]
    writing 'boot'...
    OKAY [  0.412s]
    finished. total time: 0.729s
    sending 'system' (226391 KB)...
    OKAY [ 14.125s]
    writing 'system'...
    OKAY [ 20.800s]
    finished. total time: 34.925s
    Resizing userdata.img
    Current userdata partition size=3046255 KB
    Creating filesystem with parameters:
        Size: 3119362048
        Block size: 4096
        Blocks per group: 32768
        Inodes per group: 7936
        Inode size: 256
        Journal blocks: 11899
        Label: 
        Blocks: 761563
        Block groups: 24
        Reserved block group size: 191
    Created filesystem with 13/190464 inodes and 25017/761563 blocks
    sending 'userdata' (50616 KB)...
    OKAY [  3.171s]
    writing 'userdata'...
    OKAY [  4.224s]
    finished. total time: 7.395s
    Creating efs.img as 16M ext4 img...
    Creating filesystem with parameters:
        Size: 16777216
        Block size: 4096
        Blocks per group: 32768
        Inodes per group: 1024
        Inode size: 256
        Journal blocks: 1024
        Label: 
        Blocks: 4096
        Block groups: 1
        Reserved block group size: 7
    Created filesystem with 11/1024 inodes and 1102/4096 blocks
    sending 'efs' (4408 KB)...
    OKAY [  0.269s]
    writing 'efs'...
    OKAY [  0.401s]
    finished. total time: 0.670s
    Creating cache.img as empty ext4 img....
    Creating filesystem with parameters:
        Size: 268435456
        Block size: 4096
        Blocks per group: 32768
        Inodes per group: 8192
        Inode size: 256
        Journal blocks: 1024
        Label: 
        Blocks: 65536
        Block groups: 2
        Reserved block group size: 15
    Created filesystem with 11/16384 inodes and 2089/65536 blocks
    sending 'cache' (6248 KB)...
    OKAY [  0.386s]
    writing 'cache'...
    OKAY [  0.559s]
    finished. total time: 0.945s
    

    This was flashed using the distribution from TI on the downloads page, no modifications necessary.  I did get all the code finally pulled down, and can build my own images now, too.

    Thanks for the assistance.

  • FYI: to anyone searching, had this same issue. Had to use USB 2.0 instead of USB 3.0 port for connection to host (e.g. for fastboot connection, the serial is always USB 2.0).

  • I'm definitely plugging into USB 2.0 Host (see pic).  The USB host controller on the top (below that is USB 3.0 port, and USB micro serial debug port) has two standard USB ports.  I've tried multiple mice / keyboards in both of them -- rebooting, applying patch mentioned above and rebuilding images, etc.  No luck.  I have yet to try rolling back the kernel version, so it could be that, or there is a hardware issue that needs to be fixed.

  • Any progress here? I am having the same issue with this method.