0

pygame problem with adafruit-pitft on raspbian jessie
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Re: pygame problem with adafruit-pitft on raspbian jessie

by adafruit2 on Wed Apr 25, 2018 2:38 pm

spoth, whee linux! what exact hardware are you using?

adafruit2
Site Admin
 
Posts: 16442
Joined: Fri Mar 11, 2005 7:36 pm

Re: pygame problem with adafruit-pitft on raspbian jessie

by spotrh on Wed Apr 25, 2018 2:55 pm

PiTFT 2.8 capacitive screen, Raspberry Pi 3.

spotrh
 
Posts: 4
Joined: Mon Jun 25, 2012 3:34 pm

Re: pygame problem with adafruit-pitft on raspbian jessie

by spotrh on Wed Apr 25, 2018 2:59 pm

Another useful datapoint: I have a jessie based Raspbian image and it works properly, with libsdl1.2debian 1.2.15-5 and libts-0.0-0 1.0-12

spotrh
 
Posts: 4
Joined: Mon Jun 25, 2012 3:34 pm

Re: pygame problem with adafruit-pitft on raspbian jessie

by adafruit2 on Wed Apr 25, 2018 3:22 pm

capacitive touch broke in the console, its 'mouse only' - we dont have a fix right now. its a device driver change :(

adafruit2
Site Admin
 
Posts: 16442
Joined: Fri Mar 11, 2005 7:36 pm

Re: pygame problem with adafruit-pitft on raspbian jessie

by spotrh on Wed Apr 25, 2018 4:39 pm

Bummer. We will keep using the jessie image for now, but if you find a fix for this, please update the thread!

spotrh
 
Posts: 4
Joined: Mon Jun 25, 2012 3:34 pm

Re: pygame problem with adafruit-pitft on raspbian jessie

by adafruit2 on Wed Apr 25, 2018 4:43 pm

thanks for understanding!

adafruit2
Site Admin
 
Posts: 16442
Joined: Fri Mar 11, 2005 7:36 pm

Re: pygame problem with adafruit-pitft on raspbian jessie

by nnifinn on Fri May 18, 2018 3:40 am

I experienced similar issues with the touchscreen reading incorrect values in pygame (Pi Zero W, Raspbian Stretch 3/14/18, 3.5" PiTFT, easy install script, tslib calibration worked) and after awhile trying different solutions online, I found that adding two lines to my code makes it work correctly. Turns out I needed to read further down in the linked pygame tutorial!

Code: Select all | TOGGLE FULL SIZE
os.environ["SDL_MOUSEDRV"] = "TSLIB"
os.environ["SDL_MOUSEDEV"] = "/dev/input/touchscreen"


Hope this helps.

nnifinn
 
Posts: 1
Joined: Fri May 18, 2018 2:26 am

Re: pygame problem with adafruit-pitft on raspbian jessie

by willcooke on Fri May 25, 2018 11:55 am

Joshb08 wrote:The installsdl.sh script in the tutorial needs to be updated again. If you run it as-is you get:

Code: Select all | TOGGLE FULL SIZE
E: The value 'stable' is invalid for APT::Default-Release as such a release is not available in the sources


"stable" is no longer valid for wheezy, instead it needs to be "oldstable" The fix is to change line 8 in the script to:

Code: Select all | TOGGLE FULL SIZE
echo "APT::Default-release \"oldstable\";


It works great with that change.



This needs updating again, this time to "oldoldstable".
willcooke
 
Posts: 2
Joined: Fri Jan 03, 2014 3:33 pm

Re: pygame problem with adafruit-pitft on raspbian jessie

by adafruit2 on Fri May 25, 2018 1:03 pm

will, can you verify what version of the Raspbian OS you're using so we can replciate/check? thx!

adafruit2
Site Admin
 
Posts: 16442
Joined: Fri Mar 11, 2005 7:36 pm

Please be positive and constructive with your questions and comments.