Difference between revisions of "Spacebar"
(→Touch Screen: Added calibration information) |
|||
Line 4: | Line 4: | ||
To configure the touch screen on linux please refer to [https://hackerspace.be/Point_of_sale_kiosks this] page. | To configure the touch screen on linux please refer to [https://hackerspace.be/Point_of_sale_kiosks this] page. | ||
− | Calibration | + | === Calibration === |
To test the parameters, use | To test the parameters, use | ||
Line 16: | Line 16: | ||
Option "CalibrationMatrix" "0.985 0 0.02 0 -0.995 1.01 0 0 1" | Option "CalibrationMatrix" "0.985 0 0.02 0 -0.995 1.01 0 0 1" | ||
EndSection | EndSection | ||
+ | |||
+ | === Configuration at boot === | ||
+ | Put the following in <code>/etc/systemd/system/elographics.service | ||
+ | |||
+ | [Unit] | ||
+ | Description=Connect elographics input device | ||
+ | BindsTo=sys-devices-platform-serial8250-tty-ttyS3.device | ||
+ | After=sys-devices-platform-serial8250-tty-ttyS3.device | ||
+ | |||
+ | [Service] | ||
+ | ExecStart=/usr/bin/inputattach -elo /dev/ttyS1 | ||
+ | |||
+ | [Install] | ||
+ | WantedBy=multi-user.target | ||
+ | |||
+ | Then, enable it using | ||
+ | |||
+ | sudo systemctl enable elographics.service | ||
== Barcode Scanner == | == Barcode Scanner == |
Revision as of 14:43, 25 November 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.
Contents
Touch Screen
To configure the touch screen on linux please refer to this page.
Calibration
To test the parameters, use
xinput set-prop "Elo Serial TouchScreen" "libinput Calibration Matrix" 0.985 0 0.02 0 -0.995 1.01 0 0 1
To apply it to the system at boot, fill /etc/X11/xorg.conf.d/99-calibration.conf
with:
Section "InputClass" Identifier "calibration" MatchProduct "Elo Serial TouchScreen" Driver "libinput" Option "CalibrationMatrix" "0.985 0 0.02 0 -0.995 1.01 0 0 1" EndSection
Configuration at boot
Put the following in /etc/systemd/system/elographics.service
[Unit] Description=Connect elographics input device BindsTo=sys-devices-platform-serial8250-tty-ttyS3.device After=sys-devices-platform-serial8250-tty-ttyS3.device [Service] ExecStart=/usr/bin/inputattach -elo /dev/ttyS1 [Install] WantedBy=multi-user.target
Then, enable it using
sudo systemctl enable elographics.service
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.