Jump to content

Armbian for OrangePi PC2, AllWinner H5


Christos

Recommended Posts

Something broke in USB in the last couple of days. I just updated to the nightly kernel etc. and the hub no longer worked. 

 


23.600145] usb 5-1.1: device descriptor read/64, error -110
[   23.792099] usb 5-1.1: new full-speed USB device number 4 using ohci-platform
[   28.976623] usb 5-1.1: device descriptor read/64, error -110
[   41.351812] usb 5-1-port1: cannot reset (err = -62)
[   41.357968] usb 5-1-port1: cannot reset (err = -62)
[   41.363228] usb 5-1: USB disconnect, device number 2
[   41.363800] usb 5-1-port1: cannot reset (err = -62)
[   45.001488] usb 5-1: new low-speed USB device number 7 using ohci-platform
[   45.185479] usb 5-1: device descriptor read/64, error -62
[   45.481423] usb 5-1: device descriptor read/64, error -62
[   45.773439] usb 5-1: new low-speed USB device number 8 using ohci-platform
[   45.957500] usb 5-1: device descriptor read/64, error -62
[   46.253453] usb 5-1: device descriptor read/64, error -62
[   46.545463] usb 5-1: new low-speed USB device number 9 using ohci-platform
[   46.961541] usb 5-1: device not accepting address 9, error -62
[   47.145514] usb 5-1: new low-speed USB device number 10 using ohci-platform
[   47.561536] usb 5-1: device not accepting address 10, error -62
[   47.567592] usb usb5-port1: unable to enumerate USB device
 

 

The mouse and keyboard worked when directly plugged in. 

Link to comment
Share on other sites

On 4/3/2017 at 11:30 AM, Igor said:


We only provide testing images at the moment ... those are as is. If you want Debian -> DIY -> https://github.com/igorpecovnik/lib

 

Thanks,  unfortunately I am not capable of image DIY :blink:,  so I have to use the ugly Debian image from official website. 

 

For this image, it's better to install below two first before doing something.

 

1. ntp

 

2. locale 

 

Overall, PC2 is not impressive as a server,  $10 lite/$15 pc enough.

 

Neverthless, PC2 performs faster and better than PC when running desktop/android, but be careful: CPU gets very hot, heat sink is a must in my opinions.

 

 

 

Link to comment
Share on other sites

6 hours ago, OLO said:

Thanks,  unfortunately I am not capable of image DIY :blink:,  so I have to use the ugly Debian image from official website. 


OMG. Why don't you just use our Xenial? Bad software = bad / wrong experience.

 

22 hours ago, ImmortanJoe said:

Something broke in USB in the last couple of days. I just updated to the nightly kernel etc. and the hub no longer worked. 

 


Possible, but this looks like you are having not sufficient power supply. Are powering via USB perhaps?

Link to comment
Share on other sites

1 hour ago, Igor said:


OMG. Why don't you just use our Xenial? Bad software = bad / wrong experience.

 

Sorry I need to use Debian, My PC has been running Armbian Debian.  

 

I always think Armbian image much better than official one, unfortunately no Debian for PC2:(

Link to comment
Share on other sites

Hi all, first time posting here :)

First, thanks everyone that contribute to Armbian for OrangePi PC 2. This is my first time trying Armbian & so far it seems reliable! Running on nightly Desktop 4.10 .0 ( ARMBIAN 5.27.170331 nightly Ubuntu 16.04.2 LTS 4.10.0-sun50iw2 )
Most of the time, I use this board headless tho... Main goal is for speedy NAS because of the onboard GbE LAN(I have raspberry 2 for NAS right now).

The iperf3 benchmark amazingly consistent at ~900Mbit/s! Never expected that fast for this kind of SBC.

 

Anyway, I have issues for the USB OTG not working at all, Tried it as USB Host, or USB Device(client), none of them doing anything. On OrangePi PC 1 (using the loboris image) that port can act as a USB Host which I can plug additional flash drive there :) .

 

and other question - after googling a lot, I'm still confused about the "video hardware acceleration" and "video HW decoder" - is it the same, or the latter is only for video codecs playing capability? Can someone explain briefly why this HW acceleration is only possible on Android because of Allwinner not releasing the (source code?) Can't we use the Android's binary/modules and use it on other distro?

 

once again, thanks a lot to those that make this amazing board running a really good software (not the crap one that xunlong created :D)

Link to comment
Share on other sites

1 hour ago, tomter said:

did somebody find SPI flash usable?

Not exactly "usable", but possible to use.

 

1 hour ago, tomter said:

I am thinking about boot redirect to HDD on USB. Has anyone idea how to make that?

First, write the u-boot (u-boot-sunxi-with-spl.bin located somewhere in /usr/lib/linux-u-boot-dev...) to the SPI flash, either with dd to /dev/mtd0block or with flashcp to /dev/mtd0. No offsets are needed for dd.

Second, write a fresh image to the USB HDD (i.e. using Etcher). Old images (even after upgrades) or installed with nand-sata-install may not work and were not tested.

Third, shut down the board, remove the SD card, power it on and hope that your HDD spins up fast enough. U-boot has a timeout for detecting USB devices that AFAIK can be changed only with recompilation and if HDD spins up long enough it won't be detected.

 

If there are any issues, they will not be looked into without a log from the serial console.

Link to comment
Share on other sites

43 minutes ago, zador.blood.stained said:

Not exactly "usable", but possible to use.

 

First, write the u-boot (u-boot-sunxi-with-spl.bin located somewhere in /usr/lib/linux-u-boot-dev...) to the SPI flash, either with dd to /dev/mtd0block or with flashcp to /dev/mtd0. No offsets are needed for dd.

Second, write a fresh image to the USB HDD. Old images (even after upgrades) or installed with nand-sata-install may not work and were not tested.

Third, shut down the board, remove the SD card, power it on and hope that your HDD spins up fast enough. U-boot has a timeout for detecting USB devices that AFAIK can be changed only with recompilation and if HDD spins up long enough it won't be detected.

 

If there are any questions or issues, they will not be looked into without a log from the serial console.

dd if=u-boot... of=/dev/mtdblock

Is this right command?

Link to comment
Share on other sites

1 hour ago, zador.blood.stained said:

Yes, should be either


dd if=u-boot-sunxi-with-spl.bin of=/dev/mtd0block

or


flashcp u-boot-sunxi-with-spl.bin /dev/mtd0

flashcp is present in the "mtd-utils" package

Thank you very much! The flashcp made the work. I didn't know to what package is this utility included, since that dd did nothing. Thanks again.

Link to comment
Share on other sites

I just received my Opi PC2 and set it up with the latest nightly build (no desktop). I chose the PC2 because of the Gbit ethernet adapter as I want to use it as a file server for my LAN. After setting it up with a samba share to the connected USB 2.0 2.5'' HDD I only get ~11.7 MB/s download rate via ethernet. That's even slower than my old Atom N270 based netbook with only a 100Mbit LAN adapter which I used before with the same USB HDD.

I connected the Opi PC2 via a Gbit switch and directly to the router. I tested it with my main PC and a Lenovo Thinkpad to make sure it's not an issue with the ethernet adapters or the switch. It's always around 11.7 MB/s which is more than disappointing for a Gbit SoC. CPU load and temperatures are low during the transfer, so it's not a heat / throttling issue.

 

Anybody running samba on the Opi PC2 with better results?

Link to comment
Share on other sites

PC 2 currently receives zero optimizations (well, still not officially supported). There's something like IRQ affinity, there are some tweaks regarding IO scheduling, some regarding ondemand cpufreq governor and also some smb.conf tweaks.

 

You might want to read through 

And then try it again, watch /proc/interrupts later, have a look in /etc/init.d/armhwinfo and add 2 or 3 lines to /etc/rc.local to distribute eth0 and usb IRQs accordingly.

 

First steps are alway testing storage individually (no dd, no hdparm but iozone instead) and network individually (iperf3)

Link to comment
Share on other sites

I was thinking the same as 11,7MB/s sounds a lot like 100Mbit. But ethtool says otherwise if I'm not missing something.


Settings for eth0:
        Supported ports: [ TP MII ]
        Supported link modes:   10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Half 1000baseT/Full
        Supported pause frame use: No
        Supports auto-negotiation: Yes
        Advertised link modes:  10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
                                1000baseT/Half 1000baseT/Full
        Advertised pause frame use: No
        Advertised auto-negotiation: Yes
        Link partner advertised link modes:  10baseT/Half 10baseT/Fu
                                             100baseT/Half 100baseT/
                                             1000baseT/Half 1000base
        Link partner advertised pause frame use: Symmetric Receive-o
        Link partner advertised auto-negotiation: Yes
        Speed: 1000Mb/s
        Duplex: Full
        Port: MII
        PHYAD: 0
        Transceiver: external
        Auto-negotiation: on
        Current message level: 0x00000000 (0)

        Link detected: yes

 

USB HDD benchmark with iozone (1 thread, 1GB file) also looks ok. Or should I worry because of the lower random read / write values?


Children see throughput for  1 initial writers  =   28339.82 kB/sec
        Parent sees throughput for  1 initial writers   =   28339.19 kB/sec
        Min throughput per thread                       =   28339.82 kB/sec
        Max throughput per thread                       =   28339.82 kB/sec
        Avg throughput per thread                       =   28339.82 kB/sec
        Min xfer                                        = 1048576.00 kB

        Children see throughput for  1 rewriters        =   30909.76 kB/sec
        Parent sees throughput for  1 rewriters         =   30909.54 kB/sec
        Min throughput per thread                       =   30909.76 kB/sec
        Max throughput per thread                       =   30909.76 kB/sec
        Avg throughput per thread                       =   30909.76 kB/sec
        Min xfer                                        = 1048576.00 kB

        Children see throughput for  1 readers          =   33996.34 kB/sec
        Parent sees throughput for  1 readers           =   33996.12 kB/sec
        Min throughput per thread                       =   33996.34 kB/sec
        Max throughput per thread                       =   33996.34 kB/sec
        Avg throughput per thread                       =   33996.34 kB/sec
        Min xfer                                        = 1048576.00 kB

        Children see throughput for 1 re-readers        =   34027.61 kB/sec
        Parent sees throughput for 1 re-readers         =   34027.25 kB/sec
        Min throughput per thread                       =   34027.61 kB/sec
        Max throughput per thread                       =   34027.61 kB/sec
        Avg throughput per thread                       =   34027.61 kB/sec
        Min xfer                                        = 1048576.00 kB

        Children see throughput for 1 random readers    =    7616.90 kB/sec
        Parent sees throughput for 1 random readers     =    7616.88 kB/sec
        Min throughput per thread                       =    7616.90 kB/sec
        Max throughput per thread                       =    7616.90 kB/sec
        Avg throughput per thread                       =    7616.90 kB/sec
        Min xfer                                        = 1048576.00 kB

        Children see throughput for 1 random writers    =   12637.21 kB/sec
        Parent sees throughput for 1 random writers     =   12637.17 kB/sec
        Min throughput per thread                       =   12637.21 kB/sec
        Max throughput per thread                       =   12637.21 kB/sec
        Avg throughput per thread                       =   12637.21 kB/sec
        Min xfer                                        = 1048576.00 kB


 

According to iperf3 the problem seems to be the network.

Connecting to host 192.168.***.***, port 5201
[  4] local 192.168.***.*** port 54499 connected to 192.168.***.*** port 5201
[ ID] Interval           Transfer     Bandwidth       Retr  Cwnd
[  4]   0.00-15.00  sec   170 MBytes  11.3 MBytes/sec    0    313 KBytes       
[  4]  15.00-30.00  sec   168 MBytes  11.2 MBytes/sec    0    313 KBytes       
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval           Transfer     Bandwidth       Retr
[  4]   0.00-30.00  sec   338 MBytes  11.3 MBytes/sec    0             sender
        Sent  338 MByte / 1.00 GByte (33%) of /home/***/Temp/testfile
[  4]   0.00-30.00  sec   337 MBytes  11.2 MBytes/sec                  receiver

Link to comment
Share on other sites

3 hours ago, Harry_W said:

According to iperf3 the problem seems to be the network

 

Yep, H5 boards with Gigabit Ethernet are known to exceed 930 Mbits/sec (more than 945 MBits/sec is impossible). Ethtool only tells what both partners negotiated but not what's really possible. Would be interesting to use iperf3 with UDP.

Link to comment
Share on other sites

Server (Orange Pi PC2):


Starting Test: protocol: UDP, 1 streams, 8192 byte blocks, omitting 0 seconds, 10 second test
[ ID] Interval           Transfer     Bandwidth       Jitter    Lost/Total Datagrams
[  5]   0.00-1.00   sec  11.0 MBytes  92.5 Mbits/sec  0.726 ms  0/1412 (0%)  
[  5]   1.00-2.00   sec  11.4 MBytes  95.8 Mbits/sec  0.766 ms  0/1462 (0%)  
[  5]   2.00-3.00   sec  11.4 MBytes  95.9 Mbits/sec  0.747 ms  0/1463 (0%)  
[  5]   3.00-4.00   sec  11.4 MBytes  95.8 Mbits/sec  0.751 ms  0/1462 (0%)  
[  5]   4.00-5.00   sec  11.4 MBytes  95.7 Mbits/sec  0.777 ms  0/1460 (0%)  
[  5]   5.00-6.00   sec  11.4 MBytes  95.8 Mbits/sec  0.772 ms  0/1462 (0%)  
[  5]   6.00-7.00   sec  11.4 MBytes  95.9 Mbits/sec  0.760 ms  0/1463 (0%)  
[  5]   7.00-8.00   sec  11.4 MBytes  95.8 Mbits/sec  0.765 ms  0/1462 (0%)  
[  5]   8.00-9.00   sec  11.4 MBytes  95.9 Mbits/sec  0.771 ms  0/1463 (0%)  
[  5]   9.00-10.00  sec  11.4 MBytes  95.8 Mbits/sec  0.749 ms  0/1462 (0%)  
[  5]  10.00-10.04  sec   512 KBytes  94.8 Mbits/sec  0.717 ms  0/64 (0%)  
- - - - - - - - - - - - - - - - - - - - - - - - -
Test Complete. Summary Results:
[ ID] Interval           Transfer     Bandwidth       Jitter    Lost/Total Datagrams
[  5]   0.00-10.04  sec   114 MBytes  95.5 Mbits/sec  0.717 ms  0/14635 (0%)  
CPU Utilization: local/receiver 3.1% (0.2%u/2.9%s), remote/sender 8.2% (1.1%u/7.1%s)
iperf 3.0.11
Linux orangepipc2 4.10.0-sun50iw2 #31 SMP Tue Apr 4 09:26:18 CEST 2017 aarch64 aarch64 aarch64 GNU/Linux

 

Client (Debian Notebook):


iperf3 -c 192.168.***.*** -u -i 1 -t 10 -b 10G
Connecting to host 192.168.***.***, port 5201
[  4] local 192.168.***.*** port 45247 connected to 192.168.***.*** port 5201
[ ID] Interval           Transfer     Bandwidth       Total Datagrams
[  4]   0.00-1.00   sec  11.5 MBytes  96.6 Mbits/sec  1474  
[  4]   1.00-2.00   sec  11.4 MBytes  95.8 Mbits/sec  1462  
[  4]   2.00-3.00   sec  11.4 MBytes  95.9 Mbits/sec  1463  
[  4]   3.00-4.00   sec  11.4 MBytes  95.8 Mbits/sec  1462  
[  4]   4.00-5.00   sec  11.4 MBytes  95.9 Mbits/sec  1463  
[  4]   5.00-6.00   sec  11.4 MBytes  95.8 Mbits/sec  1462  
[  4]   6.00-7.00   sec  11.4 MBytes  95.9 Mbits/sec  1463  
[  4]   7.00-8.00   sec  11.4 MBytes  95.8 Mbits/sec  1462  
[  4]   8.00-9.00   sec  11.4 MBytes  95.9 Mbits/sec  1463  
[  4]   9.00-10.00  sec  11.4 MBytes  95.8 Mbits/sec  1462  
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval           Transfer     Bandwidth       Jitter    Lost/Total Datagrams
[  4]   0.00-10.00  sec   114 MBytes  95.9 Mbits/sec  0.717 ms  0/14635 (0%)  
[  4] Sent 14635 datagrams

iperf Done.

Link to comment
Share on other sites

Well, that's Fast Ethernet and unrelated to OPi PC 2 (so I hope an admin will move these posts to a splitted off thread to keep the thread focussed on OPi PC 2). No idea what's going on (since ethtool reports a GBit link) but obviously there's something in the chain that is Fast Ethernet only. I would assign fixed IP addresses (not really, I'm using macOS and there it's not necessary since Bonjour does the job) and connect both devices directly (GbE supports Auto MDI-X so no need for 'cross-over' cables any more).

Link to comment
Share on other sites

You're right, it was a networking issue with one of my Gbit switches which I didn't notice before. It's running fine @945Mbit now, Samba file transfer is around 33-35MB/s which is the USB 2.0 limit of the HDD.

Sorry for that. Would be nice if an admin could clean up this thread a little.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines