Using eMMC

I'm interested in loading up the newest images onto the eMMC card, but I'm a little at a loss. With the eMMC in the device it boots into Android and I didn't see any tools for formatting storage. I see that eMMCs for the board are on sale here (loverpi) and come with a Type-A to Type-A for programming, but haven't found any docs about how this works.

Any advice appreciated :)

Comments

  • Update: I went back to the packaging and saw that the board came with a Type-A to Type-A. I dug around and found some comments on the Kickstarter page that indicate I should try the USB_Burning_Tool from amlogic. I'll give that a try, but if I'm on the wrong path and anyone has other instructions please LMK (I'll check back here).

  • @JSchibley: I haven't found any other information. Please let us now if armlogic tool is working. I was also waiting for a kind of wiki how to flash eMMC...

  • I personally did that using the board itself.
    Wrote linux image to SD card, boot from it, connected the eMMC card, and it is in the system as /dev/mmcblk1, which is just a block device on which you can image your images according to any guide how to do that in linux.

  • @OverSun: Which OS are you using? I can't see eMMC by using df -h.

  • ubuntu. "df -h" shows you mounted partitions. if you connect eMMC after booting it's not mounted, it is still just a block device in /dev.
    And it's going to be /dev/mmcblk0, not /dev/mmcblk1, my bad, but not a big difference.

  • edited January 19

    @OverSun Do I need to clean/format device first? With dd I always get 'No space left on device'? :-(

  • what is the command you try? block device has nothing to do with space at all, it's just a stream of bytes for the system itself...

  • lsblk is just showing mmcblk1 with p1,p2 & p3 before and after plugging eMMC to board. However, dd starts for mmcblk0.

    Please find attached my terminal commands.

    My eMMC is working with pre-installed Android - I have not recognized any issue yet. I hope that it is not defect...

    dd.PNG 978.5K
  • mmcblk1 is your sd card.
    and only 1 gig is written to the mmcblk0 device and then it stops, like the device has ended. which is quite strange, I don't think you have 1 Gig eMMC
    I don't really have an idea why it stops at this point. Is there a way you plug in together sd card and eMMC before boot? I don't really remember which one is going to be chosen to boot from, it could be eMMC will take precedance, or SD. If SD will boot you linux, there is a chance you will have proper mmcblk0 device representing eMMC card.

  • edited January 19

    That's the trick. Bootloader is checking first for eMMC and second for SD card. I just powered board and connected eMMC 1-2s afterwards. By doing this I can see mmcblk0 and dd is working as expected. Unfortunately the board does not boot from eMMC only with image 4.14.11. :'(
    I will check with a better power supply and/or another image later today again...

  • edited January 19

    it's quite possible that it's hardcoded in u-boot to boot from mmc 0 (which is sd) and not from mmc 1 (which is emmc), and it stops in the very beginning.
    Do you have UART to check what's in the output of u-boot?

  • edited January 19

    No, sorry. I do not have UART to check.

    I think emmc is mmc0 and sd card is mmc1 ;)

    @loverpi: Isn't it a question for image creator? It would be good if image is booting from both SD or eMMC.

  • ironically in u-boot sd is mmc 0 and emmc is mmc 1. at least for u-boot 2015 used for 3.14 and 4.9 kernel. maybe they changed it to match OS numbering in mainline u-boot.

  • Power supply does not make a difference. I guess that root is defined as mmc1p2. Not sure how to change this.
    @OverSun : Can you provide your OS as image file?

  • I'm planning to do image when 18.04 is out.
    18.04 is going to be LTS and is advanced than current 17.10 that is very much intermediate between LTS-es. 17.04 just yesterday lost support completely, even update branch is no longer there for apt-update. and 16.04 that is current LTS is two years old. So I don't see a reason to do an image on something that is obsolete in two months...

  • @wappi, The u-boot script (boot.scr) is not set to detect eMMC. Will add it to the next image.

  • Was glad to see the thread had picked up comments because I had no luck with the USB_Burning_Tool (it did not recognize the device and gave errors about invalid images). I had been shy to mount the eMMC with power, but I tried and the method @wappi mentioned, and this allowed me to see the eMMC.

    Unfortunately after I loaded up the image file on the sd-card, I've been unable to get my USB ports working (mouse won't light, tried different power). I'm going to put this aside for now and order a second device to make debugging easier.

  • I have formated my emmc and Ubuntu always starts from SD now. I am waiting for an proper image to boot from eMMC.
Sign In or Register to comment.