KurtE
Senior Member+
@kjn - Looks good, Also looks like I need a different version of SDFat .... I think mine is still going to his Beta project...
One thing I see different which explains some of the speed differences. I was reading a raw BMP file, with 3 bytes per pixel and the overhead of the header.... Where yours is the previously processed one...
As for Max Speed you could actually draw the screen, see if can sort of do the math again.
Lets say in continuous mode, you are only outputting the pixels: so 320*240*16, but will say 17 instead of 16 for one SPI clock gap between pixel
And if your SPI was running lets say at a maximum 30mhz, then 30000000/(320x240*17) = 22.977 so about 23 frames per second.
Which is in line with what you observe.
Now how to achieve that, with minimal tearing and the like?
One thing I considered and have not done to ili9341_t3n is to have the DMA operation, give some more possible feedback as part of the operation.
Suppose, that in order to output the ILI9341 frame buffer of 320x240x2= 153600 bytes you have to split this up into something like 3 or 4 DMASettings as each setting can only output 32767 words...
Note: The actual mechanics are different for T3.6 versus T3.5 (especially SPI1/2) and T4...
Currently in theory I may interrupt once per frame and update frame counter (or stop) depending on mode.
What I thought about doing is to maybe interrupt more often, and maybe have some form of partial frame count or percentage of frame or ??? So suppose we have a 50% marker we detect.
Then code could be written, that says, Ok top half of screen output, so read in the first half of next file, when it says frame is done, read in bottom half of the next file... Again this would assume that reading in is faster than display update...
One thing I see different which explains some of the speed differences. I was reading a raw BMP file, with 3 bytes per pixel and the overhead of the header.... Where yours is the previously processed one...
As for Max Speed you could actually draw the screen, see if can sort of do the math again.
Lets say in continuous mode, you are only outputting the pixels: so 320*240*16, but will say 17 instead of 16 for one SPI clock gap between pixel
And if your SPI was running lets say at a maximum 30mhz, then 30000000/(320x240*17) = 22.977 so about 23 frames per second.
Which is in line with what you observe.
Now how to achieve that, with minimal tearing and the like?
One thing I considered and have not done to ili9341_t3n is to have the DMA operation, give some more possible feedback as part of the operation.
Suppose, that in order to output the ILI9341 frame buffer of 320x240x2= 153600 bytes you have to split this up into something like 3 or 4 DMASettings as each setting can only output 32767 words...
Note: The actual mechanics are different for T3.6 versus T3.5 (especially SPI1/2) and T4...
Currently in theory I may interrupt once per frame and update frame counter (or stop) depending on mode.
What I thought about doing is to maybe interrupt more often, and maybe have some form of partial frame count or percentage of frame or ??? So suppose we have a 50% marker we detect.
Then code could be written, that says, Ok top half of screen output, so read in the first half of next file, when it says frame is done, read in bottom half of the next file... Again this would assume that reading in is faster than display update...