Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

7inc touch screen #17

Open
skir0cket opened this issue Feb 4, 2021 · 3 comments
Open

7inc touch screen #17

skir0cket opened this issue Feb 4, 2021 · 3 comments

Comments

@skir0cket
Copy link

hi is there a way the data can be resized to fit the raspberry pi 7inch touch screen?

@bpennypacker
Copy link
Owner

There sure is. I wrote phad in such a way that it should be relatively easy for somebody to modify it for virtually any display they want. I don't have a 7" display of my own to do the grunt work myself, but I wrote PHAD to make use of templates, so it's mostly just a matter of creating new templates for that particular display. Per the README file:

The templates used to display each phad screen are located in the templates directory. These templates are standard 
Jinja2 templates. Jinja2 is a full featured template engine for Python, and its documentation can be found at 
http://jinja.pocoo.org/docs/templates/

So by editing those files in the templates directory you can customize the display however you want. If you (or anybody else) wants to do this for 7" displays or any other size display, and create a pull request for them then I'd be more than happy to include them here so other folks can make use of them as well.

@skir0cket
Copy link
Author

ok great ill look into it thanks, also just a quick one the touchscreen has stopped working but only when in CLI mode desktop works fine, how can I unstall phad so I can reinstall again?

@bpennypacker
Copy link
Owner

The simple installer script just looks for the term phad to exist in your ~/.bashrc file. So if you want to reinstall it that way then edit that file and remove the block of code at the bottom that looks something like this:

if [ "$TERM" == "linux" ] ; then
  cd /home/pi/phad
  while :
  do
    ./phad -s 30 2>/dev/null
    sleep 10
  done
fi

If you really wan to play it safe then delete the entire phad directory as well (rm -rf /home/pi/phad should do it). After that the installer script should reinstall everything without any problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants