rpi-5inch-hdmi-touchscreen-driver
rpi-5inch-hdmi-touchscreen-driver copied to clipboard
Cannot run calibration on raspberry pi 4
When trying to run touch-test.py
on my raspberry pi 4 (running raspberry pi OS) I get the following error:
Device found: /dev/hidraw2
Reading device
error: XDG_RUNTIME_DIR not set in the environment.
A1..A7: 15847 -11532 -2804646 -585 7964 -1169328 65536
Screen dims: X= 800 Y= 480
Traceback (most recent call last):
File "touch-test.py", line 174, in <module>
test_calib_screen(deviceFound)
File "touch-test.py", line 91, in test_calib_screen
screen = pygame.display.set_mode(ssize, pygame.FULLSCREEN)
pygame.error: Could not initialize EGL
Touchscreen is working nicely with this driver, but I need to calibrate it as something is currently off - touch is only registered on ~ 1/3 of the screen and starts to shift the further I move right. Probably just a calibration thing, but I was unsuccessful to do this without the calibration script so far.
Any input would be really appreciated :)