PINE64
My optimal software configuration for pine A64(+) 2Gb - Printable Version

+- PINE64 (https://forum.pine64.org)
+-- Forum: General (https://forum.pine64.org/forumdisplay.php?fid=1)
+--- Forum: Getting Started (https://forum.pine64.org/forumdisplay.php?fid=21)
+--- Thread: My optimal software configuration for pine A64(+) 2Gb (/showthread.php?tid=9457)



My optimal software configuration for pine A64(+) 2Gb - Alkemyboy - 03-18-2020

Hi everybody, I wish write this thread because I have been search and experienced for days and days the best A64(+) software in this forum.
Some problems I solved by myself. So here I would like to share my configuration for who, like me, isn't an expert in linux and need a simple and quick configuration. For now WiFi not works, this is for lan users.
About the SD card speed there are various threads. 
This for now doesn’t include WiFi which is off, it’s limited to lan users.

Pine A64(+) 2Gb with MATE, configuration as Desktop PC, this is my best software suggestion:

- Download Xenial Minimal Image [0.6.2-77] by ayufan (https://wiki.pine64.org/index.php/Pine_A64_Software_Release#Xenial_Minimal_Image). Ubuntu Mate+Xenial is much faster than armbian Buster/Bionic and Android (7), and has various other better things. Thanks, many thanks to @ayufan. All works fine except wi-fi, but I don't need it because I've connected with ethernet.

- flash it on SD (https://wiki.pine64.org/index.php/NOOB#Step-by-Step_Instructions_to_Flashing_MicroSD_Cards)

installation of this image through pine64 installer (https://github.com/pine64dev/PINE64-Installer/blob/master/README.md) from a windows system gives good results.

First boot:
Monitor support
If you use a PC monitor with HDMI input or with VGA + HDMI-VGA adapter, all works well. Instead, if you use a DVI input monitor with HDMI-DVI adapter it will give you just black screen: initially the HDMI to DVI support is disabled by default. Note: the same issue for Android and some other so images.
To enable DVI monitor support there are two options: 
1- with a windows (or linux maybe) pc read the microSD, you'll see a folder "boot" which is editable (thanks to ayufan): go to /boot/uEnv.txt file, open it with a text editor, scroll down until “disp_dvi_compat=on” and delete the “# ” to activate it; 
2 - connect pine64 to a HDMI monitor (i.e. TV) this first time, follow the above steps to login pine, then run "sudo nano /boot/uEnv.txt", scroll down until “disp_dvi_compat=on” and delete the “# ” to activate it, exit with “ctrl+X”, saving, and overwriting the file. Then "sudo poweroff".
After this you can connect pine64 with DVI monitor with adapter.

To power on pine64 again, disconnect power supply and reconnect it.
On first boot remember to login with “pine64” as user and passwd.
I suggest you to shorten this password running "sudo passwd pine64" and then input a short one, i.e. single letter.

Now follow these steps:
- go to the folder with some upgrade programs (wiki): cd /usr/local/sbin/
- check the list of files running "ls"
- execute the resizing of the image to fit your card's space (wiki): sudo resize_rootfs.sh (sometimes was already fitted)
- execute the fix whatever command (check the exact filename in <ls> output)
- please DON'T execute any other update program (kernel and uboot): this for me caused only malfunctions.
- run a general update/upgrade of the system (ethernet connection needed): "sudo apt-get update" then "sudo apt-get upgrade" and follow the instructions.
- then reboot: "sudo reboot".

Successive boots:
Login again to the linux system. This is the endpoint for who prefers a command line system.
If you, as me, cannot use pine without a desktop GUI system, install MATE (wiki): "sudo /usr/local/sbin/install_desktop.sh mate", and wait until finished then "sudo reboot".

On reboot you will ask to login to MATE desktop.
Note. The reboot given by desktop don’t works properly, system freeze. Use power off and then power on instead.

Autologin: to allow exclusive remote control
See this thread https://forum.pine64.org/showthread.php?tid=1023
“sudo nano /usr/share/lightdm/lightdm.conf.d/50-xserver-command.conf”
add this line: autologin-user=[username]


Idea Other hints, observations and suggestions:

Hardware for multimedia
This is for me the ayufan’s xenial best strenght: the reproduction of local or streaming video is very smoot, powerful, and audio works properly. GPU acceleration is fully working . In many other OS there was no audio! Here it works fine. After adding a small and cheap (few euros) external usb DAC, the audio was amplified and enhanced: I love hi-fi music and with this configuration (and good quality headphones) the digital (16 or 24bit flac) music can can be listened to as never before! Really, it seems like 3D audio!
On the contrary, in the Armbian systems (recent kernels) no audio worked for me, also after a lot of literature (forums) research and attempts, and video reproduction was lagging, maybe Armbian don’t use hardware acceleration.

Softwares/packages management
NEVER try to update to ubuntu 18! I obviously tried... and then I went here to follow again this tutorial. I suggest to disable any software update. Just use "sudo apt-get update" and "sudo apt-get upgrade" when needed.
The desktop has already a lot of software (libreOffice, PDF reader, email, two browsers, etc). If you need more, unfortunately, the internal “software boutique” don’t work. So the best thing to do is to forget about it and install another software manager as well written here (https://forum.pine64.org/showthread.php?tid=5645) simply running "sudo apt install synaptic".

Google accounts
With the enclosed chromium version is it possible to access google chrome accounts and do sync of favourites and passwords: note that with Armbian Buster and Bionic for example this login to chrome account was blocked by te google systems! This for me was a throuble, with MATE it’s ok.

Desktop remote control (Teamviewer)
This remote desktop control is very important for me. I like Teamviewer because it's user-friendly, free, allow control from every operative system and also because I wasn't able to find any other software with the above skills. The Raspberry Pi's version (host) can be installed on pine after some adjustments. Considerng partially this thread (https://community.teamviewer.com/t5/Linux/How-to-get-TeamViewer-working-on-ARM64/td-p/49322), you need to add the armhf structure to use this version of the software, so sequentially run
- sudo dpkg --add-architecture armhf
- sudo apt-get update
- sudo apt-get upgrade
- sudo apt-get install libxtst6:armhf
- download the raspberry version .deb installation file from it's site ([url=https://www.teamviewer.com/it/download/raspberry-pi/][/url]https://www.teamviewer.com/it/download/raspberry-pi/)
- double click on the .deb file to install teamviewer

This works fine to control pine64 from another desktop pc, it is autostarting, not too cpu consuming (about 30% when connected, nothing when disconnected). But it ins't fine to control pine from smartphone because in android app the mouse isn’t showed, a small remaining bug, so it’s very hard to control it by android.

NTFS support for USB drives
Mate has problems with NTFS external drives (USB keys, SSD or HDD). They weren’t recognized or writing-protected. So they weren’t usable. 
This can be solved going to the software manager (synaptic, see above) and installing these packages: “ntfs-config” and (required) “ntfs-3g” with "sudo apt install ntfs-config". Then “sudo reboot”.
Suggestion: if you need to save downloaded material, don't use internal SD because it sould be used only for the system. USB memories should be preferred. Unfortunately i saw that pine USB ports cannot supply self-powered HDD. So initially I used a USB key. Needing more space, instead of using expensive fast or big USB keys, I find that the best memory and power saving method is an SSD sata with a sata-usb adapter: fast, with enaught space, self-powered on pine usb port. For example a 120Gb SSD, when I writing, costs about 23 euros, an adapter just few ones.

Power managing
If you want to save energy consider that this ubuntu doesn’t really never switch off the monitor, any setting is set (suspend, switch off, ...). It becames just black, but the measured power consumption is the same as it was in use. Also other power managers, which worked with armbian (i.e. xfce4-power-manager) here don’t change the result. Just forget it and manually switch off monitor. Don't care about pine64's energy consumption, I confirm with measurement it's max 2.5W (1.5 on idle).

Cecking CPU/GPU temperature (https://forum.pine64.org/showthread.php?tid=8282)
Chose a folder, for example in Documents
Create a new file named temp.sh, open in an editor and paste this text between lines
------------------------
#!/bin/bash
cpu=$(cat /sys/class/thermal/thermal_zone0/temp)
gpu=$(cat /sys/class/thermal/thermal_zone1/temp)
echo CPU ${cpu::2}C '|' GPU ${gpu::2}C
------------------------
And save
Edit file properties (right click), allow execution as program
Create a second file in desktop named Twatch.sh, and inside copy watch followed by the entire path of yor new file like this line
Watch /home/pine64/Documents/temp.sh
And save. Edit properties of this file and allow execution as program. Then simply double-click and go execute in the terminal.
The output CPU/GPU temperature, updating every 2 seconds

Samba sharing folder, to tranfer files to another pc
https://forum.pine64.org/showthread.php?tid=4983

sudo apt install samba
sudoedit /etc/samba/smb.conf
then go at the end and copy this
-------------------------
[share]
Comment = Pine64 Share
Path = <you sharing folder, path> for example /media/pine64/usbK
Browseable = yes
Writeable = Yes
only guest = no
create mask = 0777
directory mask = 0777
Public = yes
Guest ok = yes
---------------------------

Create a samba access for your user: sudo smbpasswd -a <your user>
and set your password

restart service: sudo /etc/init.d/samba restart

from windows, you should see the shared folder, to access it
open a file manager and write in the path \\<your pine ip>\share
it’s better to assign a fixed local ip to pine, so the folder have the same address



For now it’s all,
hoping to give some help with this thread


RE: My optimal software configuration for pine A64(+) 2Gb - tophneal - 03-18-2020

Thanks for sharing this!

Handy tip for if you have any copy mistakes on a post in the future, at the bottom or your posts, there's an edit button so you don't have to reply to yourself to correct anything. I merged your two posts, but I'll let you decide how you want your post tidied up.


RE: My optimal software configuration for pine A64(+) 2Gb - Alkemyboy - 03-18-2020

(03-18-2020, 06:13 AM)tophneal Wrote: Thanks for sharing this!

Handy tip for if you have any copy mistakes on a post in the future, at the bottom or your posts, there's an edit button  so you don't have to reply to yourself to correct anything. I merged your two posts, but I'll let you decide how you want your post tidied up.

Hi @tophneal, thank you, yes, when writing the post it leaves accidentally. I'm sorry, I am new here, I couldn't find any edit option for my post, no in the bottom or above. Can you please tell me more? I would like to shrink a bit the text.


RE: My optimal software configuration for pine A64(+) 2Gb - tophneal - 03-18-2020

No problem, I could tell it wasn't intentional. When you're logged in and viewing any of your posts, at the bottom of the visual block that contains your post, there is an Edit button (right next to Delete, Reply, Quote, etc) if you do not see the button on your posts, it's likely because you are a new member. After a few more posts, the forum will give you the ability.