[Guide] ili9341 SPI TFT Screen on Retropie

Various user-contributed guides for hardware-related things
Post Reply
User avatar
Mischief
Posts: 225
Joined: Sat May 21, 2016 7:50 am
Location: Wolverhampton, UK
Has thanked: 29 times
Been thanked: 69 times

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Post by Mischief » Wed Apr 26, 2017 2:12 am

Just an update on the issues I was having, turns out the ribbon cable on the screen was broken so had to request a new one :( that's why the backlight was so dim.

User avatar
moosepr
Posts: 524
Joined: Wed Jan 25, 2017 6:18 am
Has thanked: 69 times
Been thanked: 241 times
Contact:

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Post by moosepr » Wed Apr 26, 2017 2:13 am

Mischief wrote:
Wed Apr 26, 2017 2:12 am
Just an update on the issues I was having, turns out the ribbon cable on the screen was broken so had to request a new one :( that's why the backlight was so dim.
ah that sucks!! at least you didnt do anything wrong!
Get a small cheep LCD in your project https://www.sudomod.com/forum/viewtopic.php?f=22&t=2312
Wrap it all round a battery https://www.sudomod.com/forum/viewtopic.php?f=13&t=2292
Or use a custom PCB to make it really small https://www.sudomod.com/forum/viewtopic.php?f=13&t=2512
or make it really really really really tiny!! https://www.sudomod.com/forum/viewtopic.php?f=13&t=2919

bitbank
Posts: 6
Joined: Tue May 09, 2017 4:49 pm
Been thanked: 10 times

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Post by bitbank » Wed May 10, 2017 9:45 am

I'm working on a custom game emulator project which uses all of my own code and talks directly to the SPI TFT. Many games are able to run at 60fps and all games run with considerably less input lag and no display tearing compared to the retropie+fbtft+fbcp setup. The code currently uses smart buffer management to only send the parts of the display which change each frame. I'm working on adding support for the hardware scroll register of the ili9341 to make side-scrollers run at 60fps too. It currently supports many coin-op, Gameboy, GameGear/SMS, TG16, NES and Genesis. Not all of the emulators have the same level of compatibility as the ones used in retropie because I wrote every line of code myself as a hobby. Let me know if anyone would like to beta test it and I'll work with you to get it running on your hardware.

A video sample of how it looks:

https://goo.gl/photos/9DsgvQswbdPwUUuDA

Sound is working with certain hardware (Pi0 pwm output) and hdmi.


bitbank
Posts: 6
Joined: Tue May 09, 2017 4:49 pm
Been thanked: 10 times

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Post by bitbank » Fri May 12, 2017 9:36 am

abrugsch wrote:
Fri May 12, 2017 7:59 am
wow that sounds awesome!
I just added ASCII configuration file parsing to allow customization for any hardware. It can read GPIO pins directly for game inputs (no Linux drivers needed) or gamepads/keyboard. Do you have a RPi with a ili9341 LCD connected? I can share the executable if you'd like to give it a spin.

User avatar
abrugsch
Posts: 971
Joined: Tue Aug 02, 2016 10:00 am
Has thanked: 356 times
Been thanked: 430 times
Contact:

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Post by abrugsch » Sat May 13, 2017 3:09 am

Yes and no... I have a couple of ili9341 screens but nothing set up that works...

bitbank
Posts: 6
Joined: Tue May 09, 2017 4:49 pm
Been thanked: 10 times

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Post by bitbank » Sun May 14, 2017 8:22 am

abrugsch wrote:
Sat May 13, 2017 3:09 am
Yes and no... I have a couple of ili9341 screens but nothing set up that works...
That's the nice part of using my emulator. You don't need to set anything up. The only thing you need is to do is connect the display and controls and build pigpio with EMBEDDED_IN_VM defined in pigpio.c (oh - and SDL2 for joystick support). No other external dependencies.

BTW - I just got the hardware scroll support working. Makes side scrolling games have even less tearing and higher framerates. Here's a short demo video of the latest code:

https://www.youtube.com/watch?v=Pn4AXWC0IQs

Jay_Adusumilli
Posts: 3
Joined: Thu May 18, 2017 6:44 pm

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Post by Jay_Adusumilli » Thu May 18, 2017 6:58 pm

Hi,

I've been following your guide and ran into a problem.

Code: Select all

sudo modprobe fbtft_device custom name=fb_ili9341  gpios=reset:25,dc:24,led:18 speed=16000000 bgr=1
After I type this into the command line, the code below gives an error about syntax.

Code: Select all

con2fbmap 1 1
I've looked around and couldn't find an answer I could understand (I'm a beginner btw) and was wondering if you could help.

Thanks in advance!

User avatar
moosepr
Posts: 524
Joined: Wed Jan 25, 2017 6:18 am
Has thanked: 69 times
Been thanked: 241 times
Contact:

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Post by moosepr » Thu May 18, 2017 11:35 pm

Jay_Adusumilli wrote:
Thu May 18, 2017 6:58 pm
Hi,

I've been following your guide and ran into a problem.

Code: Select all

sudo modprobe fbtft_device custom name=fb_ili9341  gpios=reset:25,dc:24,led:18 speed=16000000 bgr=1
After I type this into the command line, the code below gives an error about syntax.

Code: Select all

con2fbmap 1 1
I've looked around and couldn't find an answer I could understand (I'm a beginner btw) and was wondering if you could help.

Thanks in advance!
Do you get any errors after running the modprobe line?
Get a small cheep LCD in your project https://www.sudomod.com/forum/viewtopic.php?f=22&t=2312
Wrap it all round a battery https://www.sudomod.com/forum/viewtopic.php?f=13&t=2292
Or use a custom PCB to make it really small https://www.sudomod.com/forum/viewtopic.php?f=13&t=2512
or make it really really really really tiny!! https://www.sudomod.com/forum/viewtopic.php?f=13&t=2919

Jay_Adusumilli
Posts: 3
Joined: Thu May 18, 2017 6:44 pm

Re: [Guide] ili9341 SPI TFT Screen on Retropie

Post by Jay_Adusumilli » Fri May 19, 2017 4:34 pm

No, I typed it in and it waited for a second and the ~$ thing came back.
Also thanks for replying.

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest