Page 2 of 27

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Posted: Tue Jan 31, 2017 8:49 pm
by wermy
Thanks for sharing! :) I got the same screen working pretty well recently. I just used fbtft_device name=adafruit22a and used the same pin configuration they did. I was able to set the speed on mine to 80000000 (only after soldering it up directly to the pi with 3-4" wires - it was unstable otherwise), and it's running great! Well enough for playing games in my opinion, anyway. I'll be using it in my next project. :)

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Posted: Tue Jan 31, 2017 11:53 pm
by Helder
kamon wrote:Thank you!!! Ordered one to play with :).

Also, guys.
I followed a project awhile back where someone built a custom PCB for the GBA and used a 3.2" SPI LCD, here's a link to the GH project:

https://github.com/Ryzee119/GBA_Emulator-by-Ryzee119-/

Not only did they release their Eagle files so you can get the boards made, but they also had a SPI breakout board over on oshpark: https://oshpark.com/shared_projects/9tH3I87q

Looks like everything would work.

And, even more interesting to me:
@Helder, would you ever be interested in turning his Eagle files into a more robust one that at least has X/Y buttons, and preferably with some of the features your AIO has?

Maybe even for commission :)?
That is my whole reason to be looking into these screens to be honest and I'm well aware of those files but thanks for the links. I plan to make some changes to his choices of components for power and charging but I wanted to look into screen possibilities that are not 3.5 inch but more like 3.2inch so there doesn't need to be any case modding for the screen.

NTSC TVs (older tube sets) run at around 30fps and these SPI screens run about that speed so these emulators should run decent on them.

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Posted: Wed Feb 01, 2017 12:53 am
by kamon
I figured as much, but always good to make sure everyone has as much info as possible :D.

If possible support for both 3.2 and 2.8 screens would be nice. The 2.8 especially so because it's nearly identical in size to the GBA's and you can use the original screen(or a new replacement).
The less items that need to be bought/custom made the better!

Though, 3.2 and a screen with a border like dominator's would be awesome, too.

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Posted: Wed Feb 01, 2017 2:11 am
by moosepr
Helder wrote: That is my whole reason to be looking into these screens to be honest and I'm well aware of those files but thanks for the links. I plan to make some changes to his choices of components for power and charging but I wanted to look into screen possibilities that are not 3.5 inch but more like 3.2inch so there doesn't need to be any case modding for the screen.

NTSC TVs (older tube sets) run at around 30fps and these SPI screens run about that speed so these emulators should run decent on them.

if we are sharing, then i best add to the list!! here is a link to the super minimal board in the puctures

https://oshpark.com/shared_projects/BP9tGKag

I did have a bit of a play making a board that would have the screen on one side, a pi zero stuck on the other, and power/gpio pins round the edges

https://oshpark.com/shared_projects/tSdupLd4

I have only been using eagle for a short while (only been designing pcb's the same length of time) so be gentle

I also made an eagle library for the ili9341 screens. Until my screens land i cant be sure its 100% right, but i think its ok

https://github.com/moosepr/eaglez/blob/ ... I-Zero.lbr

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Posted: Wed Feb 01, 2017 2:23 am
by Mischief
Can PWM audio still be used with these screens? I do like the screen/Pi Zero combo PCB so much space saved :D

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Posted: Wed Feb 01, 2017 2:34 am
by moosepr
Mischief wrote:Can PWM audio still be used with these screens? I do like the screen/Pi Zero combo PCB so much space saved :D
by default my guide uses GPIO18 for the backlight. this is mainly because it can do pwm and let you adjust the backlight brightness. This would interfere with the PWM audio, but in the command you are using to initialise the screen, there is an 'LED' parameter, so you could shift that to make it easier.

on my board i have the backlight powered from the same input as the screen, so it removes it all together (although i need to research to see if the fbtft driver can be used without the LED parameter) giving you another pin to play with!!

if you are not using UART or I2C, you get 20 GPIO's to play with (22 if we use the 'hat eeprom' pins 30 and 31)!!! the board still needs some refinement, all those pins are a bit squished, and i would like to have more power/gnd pins available

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Posted: Wed Feb 01, 2017 3:55 am
by Helder
Mischief wrote:Can PWM audio still be used with these screens? I do like the screen/Pi Zero combo PCB so much space saved :D
PWM Audio can be used out of the other pwm pin as combined Stereo on 1 pin. Also aren't there 2 PWM1 or PWM0 pins? So theoretically 3 PWM pins?

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Posted: Wed Feb 01, 2017 4:12 am
by moosepr
Helder wrote:
Mischief wrote:Can PWM audio still be used with these screens? I do like the screen/Pi Zero combo PCB so much space saved :D
PWM Audio can be used out of the other pwm pin as combined Stereo on 1 pin. Also aren't there 2 PWM1 or PWM0 pins? So theoretically 3 PWM pins?

You can use the ALT5 pin confiuration to get the PWM audio, you only get the 2 i think, there looks to be 3 on the standard config, but thats on pins the zero doesnt have access to

http://elinux.org/RPi_BCM2835_GPIOs

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Posted: Wed Feb 01, 2017 5:56 am
by Mischief
I just wasn't sure as I only follow the guides, from the pinout images I have seen (many of them) there are 2 PWM1 pins (GPIO 13 and 19 physical pins 33 and 35) and only 1 PWM0 (GPIO 18 physical pin 12) as this screen method will save space it's a shame to take up the gained space by using a USB DAC.

As these screens seem to be cheap I may just get one to play around with, I have a couple of spare zero's to test with.

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Posted: Wed Feb 01, 2017 6:15 am
by moosepr
Mischief wrote:I just wasn't sure as I only follow the guides, from the pinout images I have seen (many of them) there are 2 PWM1 pins (GPIO 13 and 19 physical pins 33 and 35) and only 1 PWM0 (GPIO 18 physical pin 12) as this screen method will save space it's a shame to take up the gained space by using a USB DAC.

As these screens seem to be cheap I may just get one to play around with, I have a couple of spare zero's to test with.
Go for it!! for £10 you can make a pocket pi!!

the 4 main pins for the screen cant be changed (they are the hardware spi pins)
SCK------------pin 23 (GPIO 11)
MISO----------pin 21 (GPIO 9)
MOSI----------pin 19 (GPIO 10)
CS--------------pin 24 (GPIO 8)

but the other 3 can, just change the parameters in the fbtft.conf
BL--------------pin 12 (GPIO 18)
RST------------pin 22 (GPIO 25)
D/C-------------pin 18 (GPIO 24)

i think its only the backlight pin that clashes with PWM audio ability