-
Notifications
You must be signed in to change notification settings - Fork 17
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
Capacitive Variant TFT #1
Comments
Backlight in capacitive version is used diffrently. Try commenting out
Did you set your touchscreen using adafruits tutorial that is made for capacitive version or did you just followed my instruction? If you used resistive config that might be reason for mouse crash. If you run following commands do you see image?
|
Yes I used adafruits tutorial and also adafruits prepared debian image. It of course did work with those lines disabled, but then the backlight is lit up all the time and mouse pointer visible allt he time. The command you wrote above displays nicely adafruits image on the display. I'm running an mpd server and when I start (with the disabled lines) pmb-pitft I can hear disturbance in the played music sound. |
Do you hear that disturbance all the time or just start? I had problems with audio when I used adafruits image. I still have small disturbance at start of tracks when software fetches cover art. That is only with online source(eq. spotify) and with wifi. What does What kind of setup you are running? Which audio output you are using? If you are not using headphone jack you could try following changes to make backlight work. I made couple changes to code so now all backlight related codes are in one place.
Replace line 488: Replace line 492: |
I do hear that disturbance when music is played. ls -l /dev/input/touchscree returns: I've taken the Adafruit image for the capacitive tft and written in to the sd card for my raspberry. I installed MPD und my music files are on a network attached storage. Your above commands echoed into the pwm0 files do work and changes the backlight! Here is an output of process time consumption and when pmb-pitft runs python consumes over 70%
|
I also have the Adafruit capacitive touchscreen LCD. I ended up using the Adafruit guide to setting it up and am using the kernel and boot loader that are found on the initial setup pages. Calibrating the screen did not work with the Adafruit automatic script, but I was able to do it with the manual calibration found on the other PiTFT pages. Let me say that this is a great project! I am enjoying the process of getting this GUI to work. I tried the changes given above and I experienced distortion in playing back a stream. I have a USB soundcard. I changed the lines that turn the LCD on and off to just 'pass' to give a dummy line of code for the code blocks. After that, the sound issues went away at the expense of the backlight code. It seems to me that the PWM calls are interfering with the audio stream. I'm not sure what could be done about this. Could there be some other workaround? Thanks for sharing this with the community! |
Sorry that answering took very long, but I had very busy December. @numer with my setupo mopidy uses ~70% CPU and python ~25% except when song is changing. @truckershitch https://learn.adafruit.com/adafruit-2-8-pitft-capacitive-touch/backlight-control there is something about pwm, but is only with headphone jack so I dont have any idea why it does that. And for extra note I am ordering capacitive module too. |
I have a Raspberry Pi B revision 2.0. I have been trying to pinpoint the source of the noise. I can't seem to get good audio whenever the capacitive screen is on. I am not sure at this point what is going on. I will keep trying. I had the console displaying (the boot screen) and noticed a pulsing which I determined to be the blinking cursor. I also get noise when I reboot, with the text on the screen. It appears that your code may be fine with respect to audio noise and it is something on my side. I might have to try this again from the beginning. Maybe it is some kind of power supply issue. Also, i fixed a small bug. When the sleep is set, and then set back to OFF, the display still shows a value instead of OFF. I added the last 3 lines to the # Sleeptimer if statement block (around 302-304): # Sleeptimer
if self.sleepTimer:
td = self.sleepTimer - datetime.datetime.now()
if self.sleepTimer > datetime.datetime.now():
sleepTimerText = str(int(td.total_seconds() / 60))
if self.sleepTimerText != sleepTimerText:
self.sleepTimerText = sleepTimerText
self.updateSleepTimer = True
else:
self.sleepTimerText = "OFF"
self.sleepTimer = None
self.updateSleepTimer = True
self.sleepThread = Thread(target=self.sleep)
self.sleepThread.start()
else:
self.sleepTimerText = "OFF"
self.updateSleepTimer = True Did anyone run into problems with audio feedback from the screen? If so, did you resolve them? |
Okay, I made some progress with the buzzing. I found this page on the Adafruit Forums that seems to be working. I now have I hope this helps someone else. |
Hi, From pitft-ui.py you need to change font if you are using something else than Helvetica Neue Bold and check that path is correct. But all I get is [screen is terminating] and the only thing that stop is the font on line 52. Let me know |
@retrorich75 Put font that you want to use pmb-pitft folder where .py files and images are. After that edit line 26 from pitft_ui.py file I hope this helps. |
@ISO-B can you update your suggested changes for the latest version of your files? thanks a lot :-) |
Software does not start.
Mouse can not be disabled, it crashes on:
pygame.mouse.set_visible(False)
In terms of backlight the following error occurse:
tee: /sys/class/backlight/*/bl_power: No such file or directory
The text was updated successfully, but these errors were encountered: