Orange PI Zero (H2+) as a GPS "compass" from box to works
Slackware - ARMThis forum is for the discussion of Slackware ARM.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
So how in the world do you use an computer that has no video output device?
You VNC in and out of it.
How?
file: /etc/X11/xorg.conf.d/10-libvnc.conf
Code:
# This file contains configuration of libvnc.so module
# Source: http://pkgs.fedoraproject.org/cgit/tigervnc.git/plain/10-libvnc.conf
#
# To get libvnc.so module working, do this:
# 1. run "vncpasswd" as root user
# 2. uncomment configuration lines below
#
# Please note you can specify any option which Xvnc accepts.
# Refer to `Xvnc -help` output for detailed list of options.
Section "Module"
Load "vnc"
EndSection
Section "Screen"
Identifier "Screen0"
DefaultDepth 16
Option "SecurityTypes" "VncAuth"
Option "PasswordFile" "/root/.vnc/passwd"
EndSection
And on the other side you TigerVNC into it by entering it's IP
Now you can set up many and wast things that can only be solved on X...
In the following replays i plan to publish the LCD config and the remaining tools used in rc.local
Gallery on imgur
I plan to replace the 5V 5A SBEC with an single cell boost converter (1S -> 5V 2A) and still use two 18650 cells but then switched in parallel.
Also i plan to duct the light from the two LEDs properly to the side light duct.
Then i will check why the pi won't boot each time its switched on - does it need switch de-bounce or brown out prevention?
Further I plan to replace the wireless keyboard with a WiFi dongle for remote ssh and VNC access
#!/bin/sh
#wrapper for editing /boot.src
# ISC apply - support on Linuxquestions.org for Slackware ARM
# author: cest73@ya.ru
# version V1.2
# file /usr/local/sbin/bootedit
#
Editor="$(which vi)"
Converter="$(which mkimage)"
pars='-vC none -A arm -T script'
tgt='boot.scr'
src='boot.cmd'
bootdir='/boot'
if [[ -d $bootdir ]]; then
cd $bootdir
else
echo "Wrong (?) bootdir defined, aborting!"
exit 2
fi
if [[ -x ${Editor} ]] ; then
if [[ -x ${Converter} ]] ; then
if $Editor ${src}
then echo "$Converter ${pars} -d ${src} ${tgt}"
$Converter ${pars} -d ${src} ${tgt}
fi
else
echo "converter [${Converter}] not found! aborting."
exit 2
fi
else
echo "editor [${Editor}] not found! aborting."
exit 2
fi
echo "done."
file:/usr/local/sbin/dtedit
Code:
#!/bin/bash
# cest73@ya.ru under ISC license for Slackware-current 2017 onward
#
EDITOR="/usr/bin/mcedit -S gotar" # gotar is a skin of mc ;-)
#EDITOR="/usr/bin/vi"
filter=$1
case $filter in
"-h"|*usage|*help|"-?")
echo "Usage:"
echo "dtedit [regexp]"
echo
echo "Edit one of the dts files as dtb and store back as dts"
echo "Filer the list with optional [regexp] like 'sun8' or 'zero'"
echo "without quotes:"
echo
echo "dtedit zero"
echo "help keys: '-?','-h','--help','usage'"
echo "happy hacking!"
exit 0
esac
#we rely on symlink here:
kver="dtb"
dt_path='/boot'
cd $dt_path
configs=$(ls ${kver} | grep ".dtb" | grep "${filter}" | awk -F.dtb '{print $1 " " $1 }')
if [[ "X$configs" == "X" ]]; then
echo "filter ["$filter"], you provided, yileded no results in ["$dt_path"/"$kver"/*.dtb]."
echo "Please retry."
exit 2
fi
dialog --backtitle "Board selection list, cancel to abort" --no-tags --menu "Boards to pick from:" 0 0 12 ${configs} 2>/dev/shm/result
selection=$(cat /dev/shm/result)
echo "our target is: ["$selection"]"
if [[ "X$selection" == "X" ]]; then
echo "exiting due to user cancels"
exit 1
fi
dtb_file="${dt_path}/${kver}/${selection}.dtb"
back_file="${dt_path}/${kver}/${selection}.dtb.orig"
dts_file="${dt_path}/${kver}/${selection}.dts"
edited_file="/tmp/${selection}.dts"
ls $dtb_file
rm -v $dts_file
rm -v $edited_file
dtc -W no-unit_address_vs_reg -I dtb -O dts $dtb_file -o $edited_file
$EDITOR $edited_file
dtc -W no-unit_address_vs_reg -O dtb -I dts $edited_file -o $dtb_file
Code:
# dtedit orangepi
... and pick my exact version listed from the /boot/ dir. after editing the instant i leave the editor the file gets saved and generated.
All that is left to do is to reboot - maybe it could be possible to force the change in runtime - but i had no interest in that (yet).
I had picked vi for the editor (free choice) because it is complying with most adverse terminal environments - despite i like mcedit more - as soon as i could i opted back for mcedit - maybe nano could be good there too.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.