BPI-R2 new image : ubuntu 16.04 V1.2.1 BT and WIFI AP mode are working fine 2017-11-27

back to Bluetooth…does anybody got a working connection? which tools are used which commands. please post log of init and connection.

Hi Frank i have now recived my new usb/serial adapter and now it is working perfect and i am booting from emmc i have a few questions you might be able to answer
is it possibel to remove some files to criate more space i am now on 90% i have a ssd conected to sata or is there things that can be moved
is it possibel to use vlan and can i use webmin to create them to separate the 4 ports on eth0

i have ap up and running i have installed dhcp bind9 webadmin setup bridge on etho and ap0 with firewall and dhcp server webmin and has a funcioning firewall/router/gateway but i would like to setup vpn client on 1 vlan to make all trafic go truvpn but only on that vlan port

hope it is understandable

kenn

you can remove kernel-modules except for your actual kernel (uname -r)…else look in /var/log for large logfiles, but instead of removing them make

echo -n "">logfile

to preserve permissions.

port-separation does not work with Kernel 4.4 which is packed with official images…you can use my 4.14 for this, but some things like hdmi and BT does not work currently in 4.14.

back to topic: can anybody test if with this image the AP can be started (and be visible) after killing histapd the first time?

step-by-step:

  • clean boot
  • running wmt-tools and echo “A”, so you get the ap0-device
  • run hostapd (with -dd configfile), you should see the AP on your client-device
  • now kill hostapd with strg+C (hostapd will clean up not only die)
  • start hostapd again, in my tests hostapd itself reports no error, but AP is not visible

i have currently found no way to restart hostapd without rebooting

@garywang @BitMaster can you confirm that behaviour (with 4.4.70)?

issue for 4.14: https://github.com/frank-w/BPI-R2-4.14/issues/4

I’ve tested it at the end of last year with your 4.14 kernel and I can confirm the AP mode is broken after killing hostapd, but I’m not completely sure if a reboot was absolutely necessary or “echo 0, echo A” could fix it as well for me.

1 Like

have you tried with 4.4 too? i assume that this Problem is also in 4.4…but currently not known

can you take a look into it and try to fix that?

Nice work!

I tried to build a kernel with SATA enabled. So i can store the root partition on my harddrive. The kernel boots fine but wifi isn’t working. do you have the kernelconfig from your build so i can add SATA or give me a directions in how to get it working?

Thanks in advance!

please give us more infos, which kernel do you build? what are your steps to enable wifi (wmt-tools)?

Hi Frank,

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…

Hi Jo_Kro

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

Workaround: https://softwarebakery.com/shrinking-images-on-linux

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 :wink:

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. :thinking:

have you make “pconf 0x48” in uboot and burned preloader to boot0-block?

http://www.fw-web.de/dokuwiki/doku.php?id=en:bpi-r2:storage#install_os_on_emmc

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?