Where is the calibration matrix in weston-wayland?

3.4k views Asked by At

I'm using an embedded linux os prepared with yocto which has weston (wayland) implementation. I can calibrate touch screen with weston-touch-calibrator but calibration reverts default values after reboot. I can't see calibration values and can't find calibration matrix. How can I calibrate the device permanently?

I appreciate any help you can provide..

1

There are 1 answers

0
ahmet cihan Akınca On

I fixed this problem. Let me add it here so that it may help someone else; Add these lines to /etc/xdg/weston/weston.ini

 [...]
 [libinput]
 touchscreen_calibrator=true
 calibration_helper=/usr/bin/save-calibration.sh
 [...]

Write this to save-calibration.sh ;

#!/bin/bash 
 # Store the transformation arguments for the resistive touchscreen as udev rule
 echo 'SUBSYSTEM=="input", KERNEL=="event[0-9]*", ENV{ID_INPUT_TOUCHSCREEN}=="1", ENV{LIBINPUT_CALIBRATION_MATRIX}="'$2 $3 $4 $5 $6 $7'"' >> /etc/udev/rules.d/touchscreen.rules

change permissions of the file;

chmod 777 /usr/bin/save-calibration.sh

That's ok..