ILI9341 (with and without DMA support)

Please do not post requests
zmemw16
Posts: 1072
Joined: Wed Jul 08, 2015 2:09 pm
Location: St Annes, Lancs,UK

Re: ILI9341 (with and without DMA support)

Postby zmemw16 » Sat Oct 10, 2015 11:38 pm

stanleyseow wrote:Silly question..

Got the 2.2" TFT ILI9341 working on SPI1 pins...
How do I access the SPI2 and SPI3 pins coming from UNO with ONLY 1 SPI sets of pins..

I had to look at the Mini STM32 to lookup the SPI1 pin names..

Thanks


the Uno only has a single SPI, it's the STM32F that has up to three, unless you choose to
add additional software SPI to either.

stephen

stanleyseow
Posts: 39
Joined: Sun Sep 27, 2015 3:26 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: ILI9341 (with and without DMA support)

Postby stanleyseow » Sun Oct 11, 2015 8:24 am

While running a benchmark graphicstest examples vs DigiX (DUE) , I notice the STM32 becomes slower from 3000+ msec to 8200+ msec after 20-30 interations..

The DigiX/DUE was 24609 msec , 21secs slower than the STM32 ...

Any idea why this happens ??



Image

Image
Stanley
9W2SVT / N5SVT

User avatar
RogerClark
Posts: 5470
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: ILI9341 (with and without DMA support)

Postby RogerClark » Sun Oct 11, 2015 8:14 pm

Sounds like the issue we have with the debug messages going slow if you don't have the terminal window open.

Try opening the serial terminal window and running the test again

stanleyseow
Posts: 39
Joined: Sun Sep 27, 2015 3:26 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: ILI9341 (with and without DMA support)

Postby stanleyseow » Mon Oct 12, 2015 4:04 am

RogerClark wrote:Sounds like the issue we have with the debug messages going slow if you don't have the terminal window open.

Try opening the serial terminal window and running the test again


Roger .. spot on ... something for me to take note of and disable Serial Print when not in use..
Stanley
9W2SVT / N5SVT

User avatar
RogerClark
Posts: 5470
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: ILI9341 (with and without DMA support)

Postby RogerClark » Mon Oct 12, 2015 5:57 am

Hi Stanley,

Its something we need to fix, but it didnt seem urgent, so I we forgot about it.

I did some investigation into what was causing it, but it wasn't obvious why it was happening. However I think we have a work around, as it is possible to determine the connection state of the Serial USB.

So the work around is to make the internals of the Serial USB class, ignore any chars that are printed (or written etc) to it, unless the PC terminal is open.

But we have yet to test in practice if this works, and whether it only works on the PC and with the IDE's terminal or works for other terminal programs and on OSX and Linux...

Things like this are not easy to fix as we need to test on multiple configurations.

User avatar
ahull
Posts: 1422
Joined: Mon Apr 27, 2015 11:04 pm
Location: Sunny Scotland
Contact:

Re: ILI9341 (with and without DMA support)

Postby ahull » Sat Nov 05, 2016 12:29 pm

victor_pv wrote:Available here, until thoroughly tested, then will send a pull or merge or something to Roger:
https://github.com/victorpv/TFT_ILI9163C

To use it with the standard repo SPI library comment out these 3 lines in the header file:
#define SPI_16BIT
#define SPI_MODE_DMA 1
#define SPEED_UP 1 // Enables extra calculations in the circles routine to use fastVLine and fastHLine, only in DMA mode.

To use DMA, uncomment those lines, and download the SPI library from my repo:
https://github.com/victorpv/Arduino_STM ... es/SPI/src

Once all is tested the changes to the SPI library will be integrated in Roger's repo.

Please post here if you have any issues with DMA or non-DMA.


A couple of quick questions, was all of this code merged in to Roger's master branch, and thus in to the board manager package, and is it possible to use this library with SPI2 and or SPI3 (if so, how).
- Andy Hull -

victor_pv
Posts: 1077
Joined: Mon Apr 27, 2015 12:12 pm

Re: ILI9341 (with and without DMA support)

Postby victor_pv » Fri Dec 23, 2016 11:15 pm

ahull wrote:
victor_pv wrote:Available here, until thoroughly tested, then will send a pull or merge or something to Roger:
https://github.com/victorpv/TFT_ILI9163C

To use it with the standard repo SPI library comment out these 3 lines in the header file:
#define SPI_16BIT
#define SPI_MODE_DMA 1
#define SPEED_UP 1 // Enables extra calculations in the circles routine to use fastVLine and fastHLine, only in DMA mode.

To use DMA, uncomment those lines, and download the SPI library from my repo:
https://github.com/victorpv/Arduino_STM ... es/SPI/src

Once all is tested the changes to the SPI library will be integrated in Roger's repo.

Please post here if you have any issues with DMA or non-DMA.


A couple of quick questions, was all of this code merged in to Roger's master branch, and thus in to the board manager package, and is it possible to use this library with SPI2 and or SPI3 (if so, how).



Andy, I did not have time to tinker with anything for months, well, I had a little bit, but used it for other things, cause was not enough to do any serious progress on anything with the STM32.

I do not remember if I merged all the ILI libraries to Roger's repo, I believe he instead linked it as a submodule, and may have had to unlink due to issues with the library with the latest Arduino IDE
"It looks like the new IDE version 1.6.6 fails compiles if it finds anything it doesnt like about any libraries

In your library it says the maintainer is missing from

https://github.com/victorpv/TFT_ILI9163 ... properties"

Whatever latest changes I tested with that library, must be in my repo. I haven't done anything in many months now.
If you had been using the library and developed it further, you can merge your version in the repo.

Regarding using other SPI ports, I do not remember the details, but I do remember I wrote a test script that would use one SPI port for the sdcard, reading a wav file and playing it with a timer, and another SPI port using the ILI display to draw a spinning cube and show some CPU usage stats to see how much cpu cicles I was using in all that. It was fairly low usage, so I am almost sure I used DMA in both libraries on both SPI ports.
I would need to find that code to see if I hard coded the SPI2 port in one of the libraries, or modified either library to support any port. I'll try to find it if I get some time.

dev
Posts: 24
Joined: Sun Feb 19, 2017 8:41 am

Re: ILI9341 (with and without DMA support)

Postby dev » Mon Feb 20, 2017 4:28 pm

Hi,
Will this library work with TFT_320QVT display(This is only mentioned on back)?
But i think this lcd has SSD1289 IC driver.

victor_pv
Posts: 1077
Joined: Mon Apr 27, 2015 12:12 pm

Re: ILI9341 (with and without DMA support)

Postby victor_pv » Tue Feb 21, 2017 3:49 am

dev wrote:Hi,
Will this library work with TFT_320QVT display(This is only mentioned on back)?
But i think this lcd has SSD1289 IC driver.

This library is for SPI displays, so will not work with any display with parallel interface regardless of driver IC.

zmemw16
Posts: 1072
Joined: Wed Jul 08, 2015 2:09 pm
Location: St Annes, Lancs,UK

Re: ILI9341 (with and without DMA support)

Postby zmemw16 » Tue Feb 21, 2017 7:17 am

there is a plethora of displays, any with between 32 to 50 pins in all likelihood use parallel data and 6800/8080 control lines.

data 16 pins + 4? 6800/8080 + 4 sdcard + 4 or 5 touch + 1 backlight + power 2 ==> 32 as a minimum?

there seems to be choice in the data format though.
sdcard and touch are likely to be spi interfaces
shield types - uno maybe 8 bit data, i suspect mega shields may well be 16 bit data, again sdcard and touch on spi

connector pin layout - Oh let me count the ways :lol: matching a display to a board to the fsmc pinnings to software - i'm still working on that, try a google image search for "tft connector"

reading sources of utft, u8glib or adafruit libraries may give you some insight about initialisation and use of the display, minimally what needs supplying is the init command sequence and plot(x,y).
the rest is fonts and graphics :lol:

stephen


Return to “Working / ported libraries”

Who is online

Users browsing this forum: No registered users and 1 guest