PINE64
How to Write an Image to the eMMC Module Tutorial - Printable Version

+- PINE64 (https://forum.pine64.org)
+-- Forum: ROCK64 (https://forum.pine64.org/forumdisplay.php?fid=85)
+--- Forum: General Discussion on ROCK64 (https://forum.pine64.org/forumdisplay.php?fid=86)
+--- Thread: How to Write an Image to the eMMC Module Tutorial (/showthread.php?tid=4924)

Pages: 1 2 3 4 5 6


RE: How to Write an Image to the eMMC Module Tutorial - Boia11 - 08-30-2017

(08-15-2017, 05:31 AM)MarkHaysHarris777 Wrote: Greetings,

The purpose of this post is to document the procedure for writing gnu+linux images to the eMMC module on the Rock64 board; the procedure is fairly straight-forward and is not difficult with some small planning and care. First I'll give just a little discussion of the overall theory, then list the materials that you will need, and finally we'll cover the step-by-step detail.

......
Ehi Mark! Wink
Can you add pics to the guide for make it more readable? Please  Angel


RE: How to Write an Image to the eMMC Module Tutorial - jl_678 - 08-30-2017

(08-30-2017, 01:20 PM)tarlo766 Wrote: Experienced IT guy here, but noob to SBC. I just wanted to make sure I got this right.
Do I need a serial terminal to install Android to the eMMC or just to install linux to the eMMC? (per fire219 on 08-15-2017, 02:05 PM).
If so does the CP2102 module USB to 3.3V TTL referenced in the tutorial require soldering to the rock64?
if so are their guides for it? Thanks for the support.
Hi,

I can answer your second question. The USB to serial adapter does not require soldering. It simply attaches to the pins on rock64. The end of the adapter is a dupont connector so it can easily slide on and off the pins.

Sent from my XT1254 using Tapatalk


RE: How to Write an Image to the eMMC Module Tutorial - zoogoober - 08-30-2017

(08-30-2017, 04:49 PM)Boia11 Wrote:
(08-15-2017, 05:31 AM)MarkHaysHarris777 Wrote: Greetings,

The purpose of this post is to document the procedure for writing gnu+linux images to the eMMC module on the Rock64 board; the procedure is fairly straight-forward and is not difficult with some small planning and care. First I'll give just a little discussion of the overall theory, then list the materials that you will need, and finally we'll cover the step-by-step detail.

......
Ehi Mark! Wink
Can you add pics to the guide for make it more readable? Please  Angel

Hey Boia11, There are pictures in the hyperlink to the serial tutorial included. Is there something specific you need pictures of that is not included there? I'm sure I can snap a couple if need be.


RE: How to Write an Image to the eMMC Module Tutorial - Lexstar - 08-31-2017

I got my TTL to USB adapter today with the CH340 chip, I did every step according to the tutorial but I just get this on the console (using baud rate 150000):

Code:
[01:08:36:617] <break>
[01:08:42:620] <0xfa><break>
[01:08:55:692] <0xfc>␊



RE: How to Write an Image to the eMMC Module Tutorial - MarkHaysHarris777 - 08-31-2017

(08-31-2017, 05:11 PM)Lexstar Wrote: I got my TTL to USB adapter today with the CH340 chip, I did every step according to the tutorial but I just get this on the console (using baud rate 150000):

Code:
[01:08:36:617] <break>
[01:08:42:620] <0xfa><break>
[01:08:55:692] <0xfc>␊


yeah, its not baud 150000.

...  its 1.5M  1500000

Please count the zeros.


RE: How to Write an Image to the eMMC Module Tutorial - belfastraven - 08-31-2017

(08-31-2017, 05:11 PM)Lexstar Wrote: I got my TTL to USB adapter today with the CH340 chip, I did every step according to the tutorial but I just get this on the console (using baud rate 150000):

Code:
[01:08:36:617] <break>
[01:08:42:620] <0xfa><break>
[01:08:55:692] <0xfc>␊

I believe the baud rate is actually 1500000  --I think you are missing a zero.....


RE: How to Write an Image to the eMMC Module Tutorial - z4v4l - 09-03-2017

Why installation is not done by just like this:
1) insert an SD card card with the "minimal" linux.
2) snap an empty eMMC in
3) turn the board on, boot from SD
4) download an image and flash it into eMMC by that smartass script.

I know it's obvious and hardly nobody could think of it before, rather there are some obstacles to do so. What they are?


RE: How to Write an Image to the eMMC Module Tutorial - rhille - 09-03-2017

Did not work for me but basically did the same with an additional step and then succeeded.
downloaded ayufan image and burned to sd
booted from sd
deleted partition on "brand new" emmc using fdisk
created a new partition using fdisk
created filesystem using mkfs
dd image to emmc

BUT since then I do have a message

blk_update_request: I/O error, dev mmcblk0rpmb, sector 0

in syslog which I'm a little bit scared of.


RE: How to Write an Image to the eMMC Module Tutorial - MarkHaysHarris777 - 09-03-2017

(09-03-2017, 07:43 AM)z4v4l Wrote: Why installation is not done by just like this:
1) insert an SD card card with the "minimal" linux.
2) snap an empty eMMC in
3) turn the board on, boot from SD
4) download an image and flash it into eMMC by that smartass script.

I know it's obvious and hardly nobody could think of it before, rather there are some obstacles to do so. What they are?


Hi, the reason your simplified approach will not work is that boot precedence and eMMC initialization create two problems which prevent it.  If there is an image on the eMMC already, then the eMMC will boot 'first'.  If there is no image on the eMMC then either the machine will not boot, or if it does boot,  both devices will not be 'seen' by the OS during initialization; both mmcblk0 and mmcblk1 must be present, AND the machine has to be booted from SD.

The jumper used has one function,  it grounds the clock line of the eMMC, deactivating it temporarily;  that way the SD card will boot-up because (for all intents and purposes) the eMMC is not there.  We interrupt the boot-up at the uboot timer and then continue the bootup with the jumper removed--  this allows the boot-up to continue on SD, but also allows the OS to 'see' the eMMC module during initialization.

Thanks for the question.


RE: How to Write an Image to the eMMC Module Tutorial - rhille - 09-03-2017

(09-03-2017, 12:10 PM)MarkHaysHarris777 Wrote:
(09-03-2017, 07:43 AM)z4v4l Wrote: Why installation is not done by just like this:
1) insert an SD card card with the "minimal" linux.
2) snap an empty eMMC in
3) turn the board on, boot from SD
4) download an image and flash it into eMMC by that smartass script.

I know it's obvious and hardly nobody could think of it before, rather there are some obstacles to do so. What they are?


Hi, the reason your simplified approach will not work is that boot precedence and eMMC initialization create two problems which prevent it.  If there is an image on the eMMC already, then the eMMC will boot 'first'.  If there is no image on the eMMC then either the machine will not boot, or if it does boot,  both devices will not be 'seen' by the OS during initialization; both mmcblk0 and mmcblk1 must be present, AND the machine has to be booted from SD.

The jumper used has one function,  it grounds the clock line of the eMMC, deactivating it temporarily;  that way the SD card will boot-up because (for all intents and purposes) the eMMC is not there.  We interrupt the boot-up at the uboot timer and then continue the bootup with the jumper removed--  this allows the boot-up to continue on SD, but also allows the OS to 'see' the eMMC module during initialization.

Thanks for the question.

Seems I'm missing something here because

booted from sd

Code:
rock64@rock64:~$ /usr/bin/hostnamectl
  Static hostname: rock64
        Icon name: computer
       Machine ID: ba551e15e1de486494c058b5367a1a09
          Boot ID: 57ff54573ab34ebc8ac34780bb3a95dd
 Operating System: Debian GNU/Linux 9 (stretch)
           Kernel: Linux 4.4.77-rockchip-ayufan-92
     Architecture: arm64
         
rock64@rock64:~$ lsblk
NAME         MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda            8:0    1 29.8G  0 disk
`-sda1         8:1    1 29.8G  0 part
mmcblk1      179:0    0 29.8G  0 disk
|-mmcblk1p1  179:1    0  3.9M  0 part
|-mmcblk1p2  179:2    0   64K  0 part
|-mmcblk1p3  179:3    0    4M  0 part
|-mmcblk1p4  179:4    0    4M  0 part
|-mmcblk1p5  179:5    0    4M  0 part
|-mmcblk1p6  179:6    0  112M  0 part
`-mmcblk1p7  179:7    0    1G  0 part /
mmcblk0      179:32   0 28.9G  0 disk
|-mmcblk0p1  179:33   0  3.9M  0 part
|-mmcblk0p2  179:34   0   64K  0 part
|-mmcblk0p3  179:35   0    4M  0 part
|-mmcblk0p4  179:36   0    4M  0 part
|-mmcblk0p5  179:37   0    4M  0 part
|-mmcblk0p6  179:38   0  112M  0 part /boot/efi
`-mmcblk0p7  179:39   0 28.8G  0 part
mmcblk0boot0 179:64   0    4M  1 disk
mmcblk0boot1 179:96   0    4M  1 disk
mmcblk0rpmb  179:128  0    4M  0 disk
   

booted from emmc
   
Code:
rock64@therock:~$ hostnamectl
 Static hostname: therock
       Icon name: computer
      Machine ID: 3b727929d77847c5834cba2762c208f7
         Boot ID: 64466c4d78084c9ba2b84b9e73afefe1
Operating System: Ubuntu 16.04.3 LTS
          Kernel: Linux 4.4.77-rockchip-ayufan-92
    Architecture: arm64
       
rock64@therock:~$ lsblk
NAME         MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda            8:0    1 29.8G  0 disk
└─sda1         8:1    1 29.8G  0 part
mmcblk0rpmb  179:96   0    4M  0 disk
mmcblk0boot0 179:32   0    4M  1 disk
mmcblk0boot1 179:64   0    4M  1 disk
mmcblk0      179:0    0 28.9G  0 disk
├─mmcblk0p1  179:1    0  3.9M  0 part
├─mmcblk0p2  179:2    0   64K  0 part
├─mmcblk0p3  179:3    0    4M  0 part
├─mmcblk0p4  179:4    0    4M  0 part
├─mmcblk0p5  179:5    0    4M  0 part
├─mmcblk0p6  179:6    0  112M  0 part /boot/efi
└─mmcblk0p7  179:7    0 28.8G  0 part /

Can you enlight me?