Skip to content

Setup: Troubleshooting

neshami edited this page Aug 4, 2022 · 31 revisions

Whitescreen

This indicates your driver is not working, please consult your touchscreen maker for installation instructions.

Boots to Blackscreen

X11 is using the wrong framebuffer for displaying TouchUI.

  1. Run sudo nano /usr/share/X11/xorg.conf.d/99-fbdev.conf
    if file/path does not exist then create it

  2. Find the following code:

    Section "Device"  
      Identifier "touchscreen"
      Driver "fbdev"
      Option "fbdev" "/dev/fb1"
    EndSection
    

    if not found, paste the code into the file
    if found, replace /dev/fb1 into /dev/fb0 or /dev/fb0 into /dev/fb1

  3. Save & Exit (CTR-O, ENTER, CTR-X)

  4. Run sudo chmod +x /usr/share/X11/xorg.conf.d/99-fbdev.conf

  5. Reboot

Inverted touch Y/X axis

  1. Make sure you followed the Calibration part first!

  2. Edit the calibration file you made sudo nano /etc/X11/xorg.conf.d/99-calibration.conf

  3. Add the following line before the EndSection that you copied from the calibration:

    For inverting horizontal axis

    Option "InvertX" "true"
    

    For inverting vertical axis

    Option "InvertY" "true"
    

Webcam image not working

Configurate the webcam settings as followed:
if you're using OctoPi you could also use octopi.local

  1. Open a browser and type http://<pi-ip-address>:8080/webcam/?action=snapshot.
    If this works, then replace /webcam/?action=snapshot with http://<pi-ip-address>:8080/webcam/?action=snapshot and save

  2. If that didn't work, then try <pi-ip-address>:8080/?action=snapshot
    If this works, then replace /webcam/?action=snapshot with http://<pi-ip-address>:8080/?action=snapshot and save

Disabling screensaver

  1. Make sure your bootloader is updated.
  2. Edit TouchUI default file: sudo nano /etc/default/touchui
  3. Add or change the variable DISABLE_SCREENSAVER=false to DISABLE_SCREENSAVER=true
  4. Save (CTR-O, Enter, CTR-X)
  5. Restart TouchUI sudo service touchui restart

Calibration

Please consult your touchscreen maker for better details. These steps below work on a Waveshare 3.5

Calibration touch location

  1. Stop TouchUI with sudo service touchui stop
  2. Run sudo apt-get install -y xinput-calibrator
  3. Run sudo xinit ~/TouchUI-autostart/helpers/calibration.xinit *
  4. Follow the calibration steps
  5. After you completed step 4, pay attention to your command line, because it will show a wall of text with at the bottom instructions, copy Section to Endsection
  6. Exit by pressing CTR-C
  7. Run sudo nano /usr/share/X11/xorg.conf.d/99-calibration.conf and replace the file with the copied Section code from step 5.
  8. Save (CTR-O, Enter, CTR-X)
  9. Reboot **

* if the file does not exist, update your bootloader!.

** if your changes to the file 99-calibration.conf seems to be ignored, you might be victim to the problem explained here

Calibration rotate touchscreen

  1. Update your bootloader!.
  2. Read the instructions from https://wiki.ubuntu.com/X/InputCoordinateTransformation
  3. Run sudo apt-get install xinput
  4. To get your device name run FRAMEBUFFER=/dev/fb1 & DISPLAY=:0.0 xinput list
    use /dev/fb0 if you're using HDMI or the Official RPI display
  5. Create a new file touch ~/TouchUI-autostart/calibration.sh
  6. Edit the new file nano ~/TouchUI-autostart/calibration.sh
  7. Copy su $TOUCHUI_USER -c "xinput set-prop 'YOUR DEVICE NAME' 'Coordinate Transformation Matrix' 0 1 0 -1 0 1 0 0 1"
  8. Replace 'YOUR DEVICE NAME' and the coordinates with the instructions from the ubuntu wiki.
  9. Save & Exit (CTR-O, ENTER, CTR-X)
  10. Reboot

Upgrading your kernel:

Upgrading your kernel can result in unexpected behaviors, if your kernel was installed by the touchscreen manufacturer then try to install the latest version from your manufacturer

  1. Run:
    sudo apt-get upgrade
    sudo apt-get install rpi-update
    
  2. Run:
    sudo rpi-update
    
  3. Reboot:
    sudo reboot