FriendlyArm NanoPi R1 flash image to eMMC

So I’ve tried unsuccessfully to get the image transferred from the SD card onto the onboard eMMC but I’m hitting a brick wall. As the title says, I’m using a FriendlyArm NanoPi R1 device and it’s working well from the SD card.

Things I’ve tried so far

  • Resize the SD card partition to match the onboard eMMC partition size then use DD to flash that image to the eMMC - SD still boots when inserted but system does not boot after removing SD card
  • Copy SD image to root of SD card then use DD to flash image to eMMC - Again, SD card boots fine but does not boot after removal of SD card.

I can see that the onboard eMMC drive is listed as /dev/mmcblk2 and is partitioned with 3 partitions - first is marked as boot and size 124M, formatted ast Fat32. Second is an empty 512B partition and third is a 1.2G Linux filesystem so I know that the DD command is working.

Any pointers on making this work?

I’m going to try the to follow the github info on this page to see if I can create an eflasher image -

So I’m not sure I have the resources or the knowledge needed to build the entire image from source and slip in the eflasher portion.

I had very limited sucess with this on Banana Pi. I could get it to boot & run from SD, provided that only /var was on a SATA device.

YMMV with the H3 CPU, although it seems to use a similar boot procedure. With the A20, I needed to start with a running system, then edit boot.cmd, to set new locations, then run mkimage to compile a revised boot.scr.

Core of the problem was lack of adequate documentation. boot.scr and kernel need to know what the root device is called, but nothing worked - sda1, hda1, sata1, mmcblk2p1 - all produced “device not found” have some guides for putting ARM distributions on eMMC or SATA, but don’t cover H3 or NanoPi.

to boot from eMMC you need a special u-boot that switch mmc0 and mmc2.

I have just added this to the wiki.

1 Like


Wouldn’t the NanoPi R1S be better with the Allwinner H5 processor version?

It would be 64Bits.
I would have AES.
No eMMC problems.
Two interfaces at 1Gb (although one goes through USB2.0)

The only downside is that it has 512Mb of ram, but with 512 the same is done as with 1Gb.


I have not got a H5 to boot yet. Looks like they need a signed binary blob for building u-boot. Also im not sure if the AES module is supported by linux 4.14.

But i can say the R1 with 1MB is buch better than the OrangePi Zero (512MB) with a similar Realtek USB LAN dongle as second interface. It may be the ram or the much better cooling in the case of the R1.

Im also not sure if the H3 version of the R1S is working. I have not checked the schematic for imported changes that may need a new devicetree file.

I will try this shortly and report back, thank you!

I can confirm the updated wiki instructions works to install to eMMC. Thanks so much @Arne.F

Hi @arne_f

I’ve got to start the IPFire on the R1S hardware by modifying the UBOOT.

But now the problem is different. The following network cards are detected:


The problem is this card:

GREEN : "of: Unknown Network Interface (eth0)"
GREEN : (02:81:7b:e3:e3:07)

Put this:

[root@ipfire ~]# ethtool eth0
Settings for eth0:
Cannot get device settings: No such device
Cannot get wake-on-lan settings: No such device
Cannot get message level: No such device
Cannot get link status: No such device
No data available

[root@ipfire log]# vi bootlog
[   34.406689] vcc3v0: disabling
[   34.406703] vcc5v0: disabling
[   34.406709] usb0-vbus: disabling
[   34.406716] gmac-3v3: disabling
[  168.101183] platform 1c30000.ethernet green0: renamed from eth0
[  168.233124] r8152 3-1:1.0 red0: renamed from eth1
[  168.372777] rtl8189es mmc1:0001:1 blue0: renamed from wlan0

In messages:
Dec 14 11:14:25 ipfire kernel: platform 1c30000.ethernet green0: Could not attach to PHY

Any ideas.



How recent is your Nano Pi R1 ? My Nano Pi R1 was dispatched 16 December. lsusb shows:

Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 002: ID 18a5:0302 Verbatim, Ltd Flash Drive
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 0bda:8152 Realtek Semiconductor Corp. RTL8152 Fast Ethernet Adapter
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

The RTL8152 was detected for GREEN without problem.

Hi @rodneyp

No, I´m trying with NanoPi R1S versión, no R1.

It is cheaper than R1 and in some scenarios it may be a cheaper solution.

Thanks for all.


My oversight.

It would still be worth running lsusb to see what chip is reported on USB2-Ethernet and then lsmod to see whether a module for it is found.

Thanks @rodneyp

I leave it as impossible, apart from not detecting anything with the lsmod, every time I restart the R1S, the MAC of the other interface changes. For the price that R1 has, it is not worth wasting time.

To all this, how does it work where you have (Nano Pi R1)?. Does the two interfaces and the wifi work?.


Greetings Roberto

The Nano Pi R1 is working well for me. Both wired interfaces work consistently and reliably. As Arne.F has pointed out, the 10/100 LAN interface will be limited in speed, if that is important to you.

I did not succeed in getting WiFi working, but I have neglegible experience with it. Instead, I use the WiFi on my ISP router occasionally. Another thread explains how to make it happen.

Hello Roberto,
I also had problems with the Wlan. The problem was a ‘missing’ file: /lib/firmware/brcm/brcmfmac43430a0-sdio.txt. I add this file to this comment. Perhaps it helps you too … :slight_smile:brcmfmac43430a0-sdio.tar (10 KB)

1 Like

Thanks @komiker I will try it when I get R1 and I tell you.


The needed file for the A0 version of the Ampac AP6212 Wlan is shipped with IPFire but not copied. run

cp -f /lib/firmware/brcm/brcmfmac43430a0-sdio.ONDA-V80_PLUS.txt /lib/firmware/brcm/brcmfmac43430a0-sdio.txt

I have added this for core140…;a=blobdiff;f=src/initscripts/system/partresize;h=e7e3bf40b0f748a624f9ebb2464c65d5bdfce1af;hp=040c6c3690e379c43c4fccfeda144a64e4872cbe;hb=97f4b51474551b9076af00bb9fc69acd0eba9bfc;hpb=7fd560d81fb0041d292445fff194f40dd5dbbd23

The R1S is not supported by the R1 dtb file. (the 2nd serial port doesn’t exist which is used for console in the R1, the entry for the 8153 MAC Address is missing and the Wlan needs a different sdio entry. Maybee also the rtl 8153 driver needs a patch to support getting the MAC from u-boot. It’s makeable but not without hardware to test.

Hello @arne_f .

How can I send you an R1S to do your magic?

Send me a private with the shipping address and I’ll send you one.

Greetings and thanks.

@arne_f, Is the AP6212 WiFi Module on the NanoPi R1 suitable / working for Wireless Client mode?