please give us more infos, which kernel do you build? what are your steps to enable wifi (wmt-tools)?
Basically what i did was:
Installed the image from this topic on the internal EMMC storage.
Copyied the contents from /dev/mmcblk0p2 to /dev/sda1 (harddisk connected through a onboard SATA port)
Downloaded and extracted https://github.com/BPI-SINOVOIP/BPI-R2-bsp/archive/master.zip on an Ubuntu 16.04 VM
./build.sh option 4
Changed the following to include (*) Device drivers > Serial ATA and Parallel ATA divers (libata) Device drivers > Serial ATA and Parallel ATA divers (libata) > AHCI SATA support save config to .config
./build.sh option 1
Placed the uImage in bananapi/bpi-r2/linux on my BPI-BOOT partition on SD card (not internal EMMC). And after that i rebooted my BPI so it can boot with the image from my SD card and mount /dev/sda1 as rootfs.
This is my kern.log after boot kern.log (67,9 KB)
then you should have the same options like the official kernel including sata…
for wifi you must run the wmt-tools…
Please check device /dev/wmtWifi is available, if yes, please execute command " echo 1 > /dev/wmtWifi" to enable wifi STA.
Is it ok, that I encounter “no space left on device” while trying to get this image ( 2017-09-04 MD5:8c554bfe1f2e84c74fc60aef298282fa) to emmc via “bpi-copy .img.zip” or dd ? Why the image is so big?
This image is larger than emmc…it’s been posted in another thread
just for reference: BPI-R2 new Image：Ubuntu-16.04-mate-desktop-bpi-r2-sd-emmc-v1.2.0.img.zip 2017-09-04 (not the same image, but steps to shrink the image are the same)
another way would be:
- dd only the first 1MB to mmcblk1
- run fdisk to check partition table (make sure its not leaving boundaries) and resync part-table
- create filesystem on both partitions (p1=vfat,p2=ext4)
- copy content (files) from boot and root to emmc-partitions
Thank you so much, Frank. At the moment bpiR2 is a useless brick without your helpful advices. I wonder why one would upload image with substrings BPIR2 and EMMC that does not fit into R2’s emmc without hacks to the official downloads page. Gary or whoever, please don’t do that in the future.
they simply not check the size…i assume that they use a 8GB SD which is a bit smaller than emmc and make a dd from it
you’ll find instructions in my wiki how to install a Operating System from scratch
- burn preloader+uboot
- create partitions
- install debootstrap of debian (same way should work for ubuntu)
- install kernel you want (4.4 with hdmi, 4.14 with port-separation), uploaded 4.4.118 and 4.14.22 today
Shrinked image was written to emmc, but nothing is being loaded from emmc. Only RGB leds are glowing after restart. Though this shrinked image is working from SD.
have you make “pconf 0x48” in uboot and burned preloader to boot0-block?
have you make “pconf 0x48” in uboot
no. Is uboot included in ubuntu image? How do I start its console? Can it be made from terminal with mmc-tools you mentioned in http://www.fw-web.de/dokuwiki/doku.php?id=en:bpi-r2:storage#install_os_on_emmc ?
Uboot is included and started before kernel is loaded. You can access it with debug-uart.
mmc-tools i’ve mentioned are imho only for reading, did not find out how to write pconf yet
mmc-utils shows that Boot config bytes is 0x0. Have no uart adapter to attach via uart, bad luck. No other way to set Boot configuration bytes?
I did it with mmc-utils:
mmc bootpart enable 1 1 /dev/mmcblk1
Now ubuntu image is being loaded from emmc. Thank you
Nice,can you look if partition config is now 0x48 and if this stays active after reboot/preloader-flash?
Yes. It is persistent. System loads well after poweroff, and Boot configuration bytes aka PARTITION_CONFIG == 0x48
Ok,thank you,thats an alternate way for users having problems entering uboot-console (missing uart cable or similar) and want to use emmc. Will add this to my wiki
Concerning booting from EMMC I see the setting of the flash be changed to writeable. My question is, after the image is programmed, can I set the flash back to be read only or are there log files that need to be written to the flash?
So my question is, shouldn’t there be a
echo 1 > /sys/block/mmcblk1boot0/force_ro
at the end?
Don’t need to make it to be read-only, because the setting is not persistent.
@garywang, where can I download your script that builds ubuntu and creates the img file from scratch?