Difference between revisions of "Spacebar"

From HSG Wiki
Jump to: navigation, search
(coppied over 16.04 fiasco and ht access stuff from old wiki)
Line 10: Line 10:
 
cat /dev/ttyUSB0
 
cat /dev/ttyUSB0
 
</pre>
 
</pre>
 +
 +
==Upgrade to 16.04==
 +
Don't break what doesn't need fixing!
 +
 +
Barmaid was upgraded from lubuntu 14.04 to 16.04 on April 2018.
 +
This broke usability, notably no GUI started. (the machine was still reachable by SSH and it still served the bar page (console shows nothing))
 +
 +
In an attempt to restore usability, the following was done:
 +
*modified /etc/default/grub like this [https://ubuntuforums.org/showthread.php?t=1613132]
 +
<pre>GRUB_CMDLINE_LINUX_DEFAULT="nomodeset"</pre>
 +
This fixed bootup, the next issue was that the touchscreen didn't respond. (maybe because 16.04 introduced systemd.[https://who-t.blogspot.be/2012/07/elographics-touchscreen-setup.html])
 +
*added the following to /etc/rc.local [https://who-t.blogspot.be/2012/07/elographics-touchscreen-setup.html?showComment=1500323252478#c5844794706018640686]
 +
<pre>inputattach -elo /dev/ttyS1 --daemon</pre>
 +
That fixed the touchscreen. Next, the screen would not turn back on after locking.
 +
Restarting LightDM would bring things back, so the issue was probably there.
 +
/var/log/lightdm/lightdm.log showed "Seat seat0: Failed to find session configuration light-gtk-greeter"
 +
A search returned nothing about "light-gtk-greeter" but did show "lightdm-gtk-greeter"
 +
*<s>changed /etc/lightdm/lightdm.conf from "light-gtk-greeter" to
 +
<pre>greeter-session=lightdm-gtk-greeter</pre>
 +
That made the screen wakes "correctly" but it requires the user password.
 +
*disabled password on login (the machine should be logged in anytime anyone approaches it anyway)
 +
Now upon waking the machine, the user has to press "ontgrendelen", but gets back to the bar page instantly after that.</s>
 +
 +
Update,
 +
 +
*spacebar console (tally) was fixed
 +
*"greeter" config in /etc/lightdm/lightdm.conf was commented out
 +
**still locks out after screensaving
 +
*automatic locking was disabled at light locker settings
 +
 +
===TODO===
 +
*find a systematic fix (instead of the symptomatic one outlined here)
 +
*<s>get rid of the "unlock" stage after waking</s>
 +
*calibrate the touchscreen
 +
*find a convenient OS installation method
 +
**make a system backup
 +
*get a better documentation on how to set up a new instance of Spacebar (in case of OS re-installation)
 +
*replace the entire thing with a raspberry pi + touchscreen?
 +
 +
==Security==
 +
Added .htaccess files to webroot and /spacebar-data, both require localhost to access now
 +
<pre>webroot:
 +
order deny,allow
 +
deny from all
 +
allow from localhost</pre>
 +
Please do not circumvent any security measures without providing us with a writeup.
 +
  
 
[[Category:Projects]]
 
[[Category:Projects]]

Revision as of 02:08, 18 April 2018

POS Kiosk to allow for easy money management. Current software made by User:Bloemist can be found on Github. Check out the raw datalog for a json-formatted sales history.

Touch Screen

To configure the touch screen on linux please refer to this page.

Barcode Scanner

The build in barcode scanner can be activated and read out by following commands:

/bin/stty -F /dev/ttyUSB0 19200 raw -echo
cat /dev/ttyUSB0

Upgrade to 16.04

Don't break what doesn't need fixing!

Barmaid was upgraded from lubuntu 14.04 to 16.04 on April 2018. This broke usability, notably no GUI started. (the machine was still reachable by SSH and it still served the bar page (console shows nothing))

In an attempt to restore usability, the following was done:

  • modified /etc/default/grub like this [1]
GRUB_CMDLINE_LINUX_DEFAULT="nomodeset"

This fixed bootup, the next issue was that the touchscreen didn't respond. (maybe because 16.04 introduced systemd.[2])

  • added the following to /etc/rc.local [3]
inputattach -elo /dev/ttyS1 --daemon

That fixed the touchscreen. Next, the screen would not turn back on after locking. Restarting LightDM would bring things back, so the issue was probably there. /var/log/lightdm/lightdm.log showed "Seat seat0: Failed to find session configuration light-gtk-greeter" A search returned nothing about "light-gtk-greeter" but did show "lightdm-gtk-greeter"

  • changed /etc/lightdm/lightdm.conf from "light-gtk-greeter" to
greeter-session=lightdm-gtk-greeter

That made the screen wakes "correctly" but it requires the user password.

  • disabled password on login (the machine should be logged in anytime anyone approaches it anyway)

Now upon waking the machine, the user has to press "ontgrendelen", but gets back to the bar page instantly after that.

Update,

  • spacebar console (tally) was fixed
  • "greeter" config in /etc/lightdm/lightdm.conf was commented out
    • still locks out after screensaving
  • automatic locking was disabled at light locker settings

TODO

  • find a systematic fix (instead of the symptomatic one outlined here)
  • get rid of the "unlock" stage after waking
  • calibrate the touchscreen
  • find a convenient OS installation method
    • make a system backup
  • get a better documentation on how to set up a new instance of Spacebar (in case of OS re-installation)
  • replace the entire thing with a raspberry pi + touchscreen?

Security

Added .htaccess files to webroot and /spacebar-data, both require localhost to access now

webroot:
order deny,allow
deny from all
allow from localhost

Please do not circumvent any security measures without providing us with a writeup.