F.A.Q. - bobbybudnick/SFS-Mobile-Internet-Device GitHub Wiki

This is just some crap you have taped together. You can't license this can you?
Commercial computers are just some crap somebody has soldered together. This project is represenative of significant design time put it into making a series of working and practical pocketable devices. This has tangible value so I am asking to be credited through an open source hardware and software attribution license. The specific licenses are referenced on the software release page and the hardware designs page.

What modifications were made to KDE?
remove unnecessary services leaving only timezone/input actions/power management
set low display resolution and low cpu
add xvkbd to panel
add script autostart
increase window button size
increase scrollbar size
remove unnecessary tray icons
activate auto login
remove unnecessary services in /usr/share/autostart
force phone window to fixed size
setup kmenu

What modifications were made to Devuan (image mastering steps)?
delete /boot directory and replace with ads7846 compatible /boot directory
delete old modules in /lib/modules and replace with matching modules
/////
edit config.txt
copy install script
/////
fdisk
resize2fs
install software
/////
deconfigure ethernet
copy scripts
copy support files-LOCK_STATUS(gtk)/MOVE_NOTIFICATION(gtk)/FIRST_BOOT
copy folders
copy applications (desktop files) to .local/share/
copy devilspie to .devilspie - gtk
copy easystroke to .easystroke
copy pupi to /usr/share/themes - gtk
copy themerc /usr/share/themes/Pupi/xfwm4 - gtk
/////
add user with custom script
edit sudoers file with pi ALL=(ALL) NOPASSWD: ALL and uncomment allow any
change shell to bash
change password to raspberry
compile hub-ctrl
compile and install easystroke
login to generate config and manually configure if not fully replacing config
copy kde (plasma-desktop-appletsrc/kwinrulesrc/kickoffrc) to .kde - kde
copy config to .config - gtk
install display manager - gtk
setup auto login with display manager
set main thread to automatically start on login
disable root account with sudo passwd -l root

Screen resolution and size is poor for desktop use. How can you do any work?
At the existing resolution you can force window sizes in KDE and adjust browser zoom in qupzilla. You can even boost the "virtual" framebuffer resolution to practically any you would like at the result of increased blurriness. Something like 960x540 is a good trade-off.

What compression do you use for the images?
This will be needed if you want to upload your own modified images to github. This specific command is able to compress the 8GB images down to less than 2GB to fit within the github binary file limit. Within KDE itself, 7zip was the closest and fast also.
xz -9ezkvv nameofimage.img
Filter: --lzma2=dict=64MiB,lc=3,lp=0,pb=2,mode=normal,nice=273,mf=bt4,depth=512
This will twin turbocharge your compression by zeroing out free space:
dd if=/dev/zero of=/crap bs=20971520
rm /crap
now dd the image
now compress the image

How to control the screen backlight by software?
You could use a mosfet to do this by tapping into the screen power switch. But this is ultimately pointless for several reasons:
loss of reliablity due to increased complexity
complicates the build due to less space
switch is already there so it is recreating the wheel
screen only uses ~150ma

What are some good anonymous file hosting providers?
ufile.io - 30 days
jeodrive.com - 40 days
gofile.io - unlimited

How to upload stuff to github without the web interface?
copy files to folder
switch to folder
git init SFS-Interstellar
git remote add origin https://github.com/bobbybudnick/SFS-Interstellar.git
git add --all
git commit -m "initial commit"
git pull origin master --allow-unrelated-histories
git push origin master

What further optimizations were done to enable KDE 4 on the Pi Zero?
disable akonadi
use claws-mail instead of thunderbird
edit main thread to not start kopete
remove all applications from /usr/share/autostart except for plasma
turn every option off in kwin settings

What changes were made to snes9x included with the Pi Zero images?
https://github.com/otty/snes9x-raspi
aoss ./snes9x -sh -f 3 -nt -nw -ne -r 1 -sy ~/NAMEOFROM
does segfault though but works anyway
needs alsa-oss
-lm to LDLIBS in makefile
-mfloat-abi=hard to soft or softfp to OPTIMIZATION in makefile
does not seem to require raspberry pi development libraries

How to do advanced configuration of Claws Mail?
Claws mail has an easy setup but a few things can be done to improve it for touchscreen use.
*Load notification plugin/Set tray icon on/set include inbox only/set minimize on close
*Set the toolbar to icons only to reveal the delete mail icon

I am using Debian without systemd and modemmanager needs polkit to work and polkit needs modemmanager and/or I get an error like "policykit authorization failed..." when running mmcli. How can I fix this?
Install the build dependencies for modemmanager with sudo apt-get build-dep modemmanager. Install the modemmanager source with sudo apt-get source modemmanager. Change the line for polkit in the rules file to with --with-polkit=no. Did you think you were finished? Now edit modemmanager.install and remove the polkit line to prevent errors during the compile. Now compile with dpkg-buildpackage -us -uc. Now only the modemmanager package needs to be reinstalled.

I am using Debian with systemd. How can I remove it quickly?
apt-get install sysvinit-core sysvinit-utils
cp /usr/share/sysvinit/inittab /etc/inittab
reboot
apt-get remove --purge --auto-remove systemd

How to setup repeater mode with a dd-wrt router?
set wan ip as appropriate for router as client
set lan ip network different than wan ip network
add bridged virtual interface with desired repeater ssid
set wireless mode to repeater
specify ssid and security for router as client
may need to set basic rate in advanced wireless settings
may need to disable telnet and wan counter
may need to setup scheduled reboot if all else fails???

How is kickoff (application launcher) setup by default?
Kickoff configuration includes ~/.kde/share/config/kickoffrc and .local/share/applications.
The following are the list of default applications.
qupzilla
terminal
silence/clamor
extremetuxracer
wolf4sdl
numpty physics
ltris
pinball

Why does Linphone not respect silence mode and/or volume controls?
Linphone appears to drive the audio device directly without respect to the mixer when the device is specifically chosen. Choosing the default device causes Linphone to defer to the mixer. This also means Linphone can have different call behavior depending on the chosen audio device. Ideally, only the ringer should be set to the default device to allow the user to still make and take phone calls while in silence mode.

What is the CUPS address?
Try port 631.

How to configure CUPS to print working color from an HP laser printer?
Set the printer up as a "Generic PostScript Printer".

CUPS does not print?
Try installing the cups-filters package and restarting CUPS.

How to print with no drivers at all?
sed 's/$'"/echo -e \\\r/" LAPTOP_NETWORKING | nc 192.168.1.233 9100

How to setup Ekiga for voip.ms from scratch?
Basic SIP
Install Ekiga
Forward port 5060
match codecs on ekiga with voip.ms sub account
device type must be ata, ip or softphone with voip.ms
server is the name of a voip.ms sip server
user and user authentication are the same
user is the sub account without @voip.ms
password is the sub account
DID
match codecs on ekiga with voip.ms sub account
device type must be ata, ip or softphone with voip.ms
did must be correctly routed to sub account
did point of presence must match registered sip server
caller id number must be correctly set with voip.ms

How to setup a simple IDS (Intrusion Detection System)?
Try Etherape and try a filter like this to reduce noise
the mentioned ip addresses are devices that make a lot of normal traffic
ip and ((not src net 192.168.1.10) and (not dst net 192.168.1.10)) and ((not src net 192.168.1.16) and (not dst net 192.168.1.16)) and ((not src net 192.168.1.12) and (not dst net 192.168.1.12))

Some Debian VLC Streaming Tips?
debian multimedia ffmpeg because of crippled debian ffmpeg
non-jpg webcam errors abound
a file name must be specified or streaming will not work
GUI to CLI conversion

  1. :sout to --sout
  2. '(NIX) "(Windows) around output MRL
  3. If NIX, then " to '
    Mplayer Friendly
    v4l2:///dev/video0
    file - stream
    http - 8080 and /
    transcode - mpeg ts / mpeg-4 / 320x240 / no scale / no audio
    Windows Mobile must use -fps 15 and wait for some time
    WMP Friendly
    v4l2:///dev/video0
    file - stream
    http - 8080 and /
    transcode - asf / wmv1 / 320x240 / no scale / no audio
    Stream to all Windows Media Player
    cvlc v4l2:///dev/video0 :input-slave=alsa:// :v4l2-standard=0 :file-caching=300 --sout='#transcode{vcodec=WMV1,vb=800,width=320,height=240,acodec=none}:duplicate{dst=file{mux=asf,dst=stream},dst=http{mux=asf,dst=:8080/}}' :no-sout-rtp-sap :no-sout-standard-sap :sout-keep
    Stream to VLC
    cvlc v4l2:///dev/video0 :input-slave=alsa:// :v4l2-standard=0 :file-caching=300 --sout='#transcode{vcodec=mp4v,vb=800,width=320,height=240,acodec=none}:duplicate{dst=file{mux=ts,dst=stream},dst=http{mux=ts,dst=:8080/}}' :no-sout-rtp-sap :no-sout-standard-sap :sout-keep
    Authentication
    cvlc v4l2:///dev/video0 :input-slave=alsa:// :v4l2-standard=0 :file-caching=300 --sout-http-user=jason --sout-http-pwd=test --sout='#transcode{vcodec=mp4v,vb=800,width=320,height=240,acodec=none}:duplicate{dst=file{mux=ts,dst=stream},dst=http{mux=ts,dst=:8080/}}' :no-sout-rtp-sap :no-sout-standard-sap :sout-keep

How to setup WPA on the command line without writing a script or using wpa_supplicant.conf?
auto eth1
iface eth1 inet dhcp
wpa-passphrase mysecretpassphrase
wpa-ssid Name_of_my_Wireless_AP
wireless-channel 11

What is the deal with alsa configuration?
Like a virus, /var/lib/alsa/asound.state can be almost impossible to reset. The only way is to stop alsa, remove the file as root and then immediately emergency sync and reboot. Any settings read from any user's .asoundrc are put into this file. .asoundrc is usually read immediately. Though, sometimes speaker-test or a sound needs to be played to reset the configuration.

Fix for a very annoying old KDE 4 black screen problem?
PROBLEM
Screensaver turns on when set to off
Usually happens after watching a movie TESTING
qdbus org.kde.screensaver /ScreenSaver org.freedesktop.ScreenSaver.SetActive true
will activate the screensaver
/usr/local/kde4/lib/kde4/libexec/kscreenlocker
will also activate the screensaver
SOLUTION
move /usr/local/kde4/lib/kde4/libexec/kscreenlocker to somewhere else

ATI TV Wonder (analog TV tuner) troubleshooting tips?
I just went through getting these set up again. I used a dual tuner system with these from 2009-2010 with mythtv on Debian with no problems once it was set up. Challenges we have with this card right now:

  1. Reception. Being in a place that still receives analog cable or over the air broadcasts.
  2. Wear and tear. The cards are physically getting old and things like capacitors may be wearing out. One of my two cards does not work at all anymore and can only tune to a green screen.
  3. Audio issues
    A. Analog sound capture (line in, working in 2009-10 host hardware: nvidia nforce 2)
    Pulseaudio - Line-in and microphone capture rarely works. This results in (usually) no analog sound from the card. I can make it work temporarily as follows:
  4. Mute line-in/set all volume levels to max/switch capture device to line-in
  5. Set mythbackend capture card audio device to "ALSA:plughw:0,0"
  6. Start mythfrontend and watch live tv
  7. Start audacity and record a few seconds from from device: "NVidia nForce 2: - (hw:0,0): Line:0"
  8. Leave live tv
  9. Enter live tv
  10. Leave tive tv
  11. Enter live tv - proper audio should be working
    B. Digital sound capture (cx88-alsa module, also working in 2009-10) - This module is not loaded at startup and modprobing it causes it to fail to create an ALSA device. This results in no digital sound from the card.
    Alsa - Working fine once you remove the garbage that is pulseaudio
  12. Memory usage. The documentation claims that with 512MB of RAM you can watch 2 streams at once. This may have used to be possible, but now this system almost is struggling with one stream.
  13. Confusing interface. There are at least 2 channel frequency settings.
  14. Poor Documentation. It seems like documentation was actually better a few years ago. There is almost no ATI TV wonder information out there. Doing a search for "mythtv audio" "mythtv sound" "mythbuntu audio" "mythbuntu sound" - these possibly relevant pages come up: http://www.mythtv.org/wiki/PCI_TV_audio - PCI audio wiki page - says this does not work on "cheaper" cards but this card was not cheap when new, and it used to work anyway. So now you get to feel bad about having something "cheap" when it's really just bad programming causing the problem.
    http://www.mythtv.org/wiki/Sound_Troubleshooting - Sound fixes wiki pages - Is stunningly short and unhelpful.
    Time wasters on this project:
    Bad memory stick (fix: replace) - 1 hour
    Bad tuner card hardware (fix: replace) - 2 hours
    Pulseaudio bugs (fix: removal) - 10 hours
    General Settings channel frequency problem (fix: set to us-cable instead of us-bcast) - 2 hours
    Conclusion
    It is working like it used to now.

How to work one of those Honeywell IOT thermostats?
query the thermostat
curl http://192.168.1.22/tstat
turn fan on
curl http://192.168.1.22/tstat -d '{"fmode":2}'
set target temp to 72
curl http://192.168.1.22/tstat -d '{"t_cool":72}'
see daily runtime values
curl http://192.168.1.22/tstat/datalog