[libmaple] FSMC LCD 16bit

zmemw16
Wed Jul 05, 2017 3:28 pm
Black F407VET, latest [libmaple] from Steve, graphicstest from examples, but with blank/black screen?

TFT LCD test
TFT size is 320x480
TFT begin done.
rotation: 0, runtime: 6082
rotation: 1, runtime: 6081
rotation: 2, runtime: 6083
rotation: 3, runtime: 6082

Benchmark Time (microseconds)
Screen fill 48116
Text 6083
Lines 90352
Horiz/Vert Lines 4257
Rectangles (outline) 2716
Rectangles (filled) 117333
Circles (filled) 41612
Circles (outline) 38206
Triangles (outline) 17330
Triangles (filled) 50977
Rounded rects (outline) 12972
Rounded rects (filled) 135136
Done!


stevestrong
Wed Jul 05, 2017 11:39 pm
I just made a new build of the 16 bit lib, and got the test pictures as expected.
TFT LCD test
TFT size is 320x480
TFT begin done.
rotation: 0, runtime: 5677
rotation: 1, runtime: 5679
rotation: 2, runtime: 5678
rotation: 3, runtime: 5679

Benchmark Time (microseconds)
Screen fill 48090
Text 5679
Lines 83823
Horiz/Vert Lines 4256
Rectangles (outline) 2651
Rectangles (filled) 117318
Circles (filled) 39350
Circles (outline) 35171
Triangles (outline) 23372
Triangles (filled) 50037
Rounded rects (outline) 12155
Rounded rects (filled) 134536


zmemw16
Thu Jul 06, 2017 12:24 am
you’re lucky it wasn’t called marple, i was severely tempted :D way, way too much Agatha Christie

is it me or are my timings about 4-5% lower ?

slightly confused by the reference to wiring, the display plugs on to the board.
board source advertised a compatible display, albeit a tad more than standard.
all the wiring is the engagement length of a pin and socket.
i’ve checked the schematic and the display pinnings are compatible.

if you are using real wires, what have you done with the LCD_BL connection(s?) ?
schematic says it’s on PB2. the sketch doesn’t seem to use or mention it.

only just spotted you’ve changed the 16 bit library or am i misreading it?
away to check the repo, i spotted the arduino_stm32 at 32min.
i suppose i want a check and fetch if changed script.

[e2] already had it, written the bin, still blank/black :(

as an aside: there’s more than one version of the Black F407ZGT about, silk screen has the white angular shapes around the f407 chip, i’ve at least one without it.

stephen


stevestrong
Thu Jul 06, 2017 7:16 am
I don’t use that back-light pin in my software at all, so it is possible that this is missing in your case.
I use a Rpi3 320×480 TFT adapted for 16 bit access. Last change in the library 2 month ago.

Do you have a schematic for your display board, just to figure out what to do with that LCD_BL pin?

[zmemw16 – Thu Jul 06, 2017 12:24 am] –
is it me or are my timings about 4-5% lower ?

As I mentioned before, it seems so, except triangle (outline) test, where you are 20% faster :shock:


zmemw16
Thu Jul 06, 2017 11:39 am
steve,
i’m getting worse, there was a bit of code using PB2 with a while(1) :?: it was commented out.
i added setup for it and waggled it at 50/50 mS, also for the leds.
nothing on the display.
looks like i’m doing some wiring.

it does look like it’s seen as the 9341 id’s are being returned.

i looked through the fsmc code, noted that it won’t work for the Black F407ZE.
there’re some annotations on the schematic applicable for the ZE variant.
A18–>A6 is one.

stephen


stevestrong
Thu Jul 06, 2017 11:53 am
PB2 in the sketch was intended for debugging only, no importance for the functionality, should be removed.

I just checked the black F4Vet board schematic, it seems that PB1 is used to control TFT_BL.
This means, you should set PB1 low in order to give brightness to the display.

Insert in the sketch setup:
pinMode(PB1, OUTPUT);
digitalWrite(PB1, LOW);


Pito
Thu Jul 06, 2017 12:52 pm
It seems on Black 407ZET the LCD_BL is PB15, connected to a highside pnp switch, where its collector is connected to the TFT’s connector pin 28 (and to a pulldown 1k5 as well).
It seems the pin 28 of the ACELEX TFT (when we talk this one) is a logical input as there is a transistor on the TFT board driving most probably the LEDs.
So you have to toggle the PB15 to see at which log level it lits TFT’s LEDs..

zmemw16
Thu Jul 06, 2017 2:23 pm
add cross eyed to the list
noticed the readID had been ‘fixed’, removed the fix and …
class Adafruit_TFTLCD_16bit_STM32' has no member named 'readID'

stevestrong
Thu Jul 06, 2017 2:29 pm
Don’t try to read out the ID, it wont work. my board does not have this feature.
But of course, you are invited to implement it if your board supports it.

Just set the identifier to 0x9341 in the graphicstest sketch and it should work.
Don’t forget PB1 for LCD_BL.


zmemw16
Thu Jul 06, 2017 3:19 pm
PB1 set low, identifier to 0x9341, blank, nada

@Pito It’s a Black F407VE in use at the moment and the same circuitry but uses PB1, adding PB15 on the off chance – no effect
off to waggle control lines …
srp


Pito
Thu Jul 06, 2017 4:59 pm
I refer below these two generic Black F407VET6/ZET6 boards:

http://wiki.stm32duino.com/index.php?title=STM32F407

you may get them here:
https://www.aliexpress.com/item/Free-sh … 22721.html
https://www.aliexpress.com/item/Free-sh … .64.4hrwhV
.

BLack407VE_TFT_FSMC.JPG
BLack407VE_TFT_FSMC.JPG (50.5 KiB) Viewed 1472 times

stevestrong
Thu Jul 06, 2017 7:23 pm
There is one more thing which you can do: play arround with these values: https://github.com/stevstrong/Arduino_S … fsmc.c#L79
Increasing them means slower but more reliable access.
These values work for me, but since i dont know your board, it may have other requirements.

Pito
Thu Jul 06, 2017 7:32 pm
FSMC_BTR_DATAST_(6) | FSMC_BTR_ADDHLD_(0) | FSMC_BTR_ADDSET_(2));
I would start with e.g.
DATAST 50 (1..255)
ADDSET 15 (0..15)
as the TFT displays could be slow..

zmemw16
Thu Jul 06, 2017 8:07 pm
i think i mentioned a18/a6 and said something else changed as well.
that’s why i said Steves TFT 16bit library would need attention.
i suppose a #define setting a V|Z flag in the sketch for the library, not the best way i think
i know something like __STMF4__ is set, but is there one distinguishing between V and Z ?
stephen

stevestrong
Thu Jul 06, 2017 8:25 pm
Stephen, what you say refers to the v/z difference between the boards.
I think as long as you use the black vet6 board (and it seems that you do, see first post), my software should run on it without any change.
Exept maybe some fine tuning for fsmc, but not more essential.

But now i realize that not all my wires come from the onboard tft socket, i have to check it again.


zmemw16
Fri Jul 07, 2017 12:31 am
[e3]@Pito your connector for the ZE is wrong[/e3] NOTE TO SELF it’s the ZG that has a 34w socket

i wonder if the Black F4 boards need a wiki page all of their own :?:
i have schematics for all 3, VE, ZE & ZG.
i now have pictures of all 3 front & rear
i will have pictures of each display connections silk screen.

any chance of a picture of your setup :?:
i would be very interested in those ‘extra’ connections :) i don’t understand how you have extras though. :?
the displays that i have connect only via the tft header, there are no other connectors available on the display.

i tried the links from my order, it needed a login, so the store is Numon Electronic Cyberport Storehttps://www.aliexpress.com/store/2274002

these links are to the relevant image location.
these i think are for the ZE & ZG, should be 34w and a header on the display
https://ae01.alicdn.com/kf/UT8z8FjX2hXX … 2b40d25fe8
up to date product
http://ae01.alicdn.com/kf/HTB1JH9SRFXXX … a5d49c2a2c

for the VE, should be 32w and a socket on the display
https://ae01.alicdn.com/kf/UT8z8FjX2hXX … 2b40d25fe8

up to date product
http://ae01.alicdn.com/kf/HTB1JH9SRFXXX … a5d49c2a2c

just confirmed that the pin labelling on some ‘3.2 LCD MODULES’ i got yonks ago is an exact match for the ZE/ZG boards.
[e1] https://ae01.alicdn.com/kf/HTB1U3PcKXXX … XFXXXe.jpg
[/e1] £8.48 & £8.88
KELI Electronics Technology Co., Ltd i’m a repeat customer of theirs, nothing excessive in price though
https://www.aliexpress.com/store/623118 … .27.Vqw0Ec

China Electrical Industry Store maybe, not sure
https://www.aliexpress.com/store/216604 … 0.0.I1aIWb

stephen


Pito
Fri Jul 07, 2017 8:55 am
I’ve updated my above “headers – TFT connectors” post with links as it seems we starting to introduce a bit of chaos in what we understand as generic Black F407VET/ZET :)

stevestrong
Fri Jul 07, 2017 9:09 am
I was always referring to this (generic) black F407VET6 board (wiki link).
The ZET6 variant on the bottom of the page should be actually detailed, please, one of you who owns that, feel free to add more information.

zmemw16
Fri Jul 07, 2017 10:54 am
the Numon Electronic Cyberport Store has only the ZGT in stock, but it’s dropped a bit in price.

i put up the original pictures of the VE & ZE on the wiki, someone else inserted a board in between them.
first, okular & gimp
now remembering how to upload ?

stephen


stevestrong
Fri Jul 07, 2017 1:25 pm
I think I remember now I had problems to set the FSMC_A18 line high (used as LCD_CD(RS) control line), it didn’t work.
https://github.com/stevstrong/Arduino_S … fsmc.c#L69
Instead, another address line, I think A16 worked only in the current configuration, and I don’t know why…
Could you check with a scope whether this pin will be set when writing something to “fsmcData”?

stevestrong
Fri Jul 07, 2017 3:27 pm
OK, it looks like everything should work as expected.

I had 3 wires which were not coming from the TFT header:
– reset – I defined a separate reset pin in the 16 bit LCD library, but I tried and it also works when connected directly to the board reset pin (default for the board’s TFT header)
– FSMC_A18 – I had it connected to PD13 on the J3 header pin 42, it was the time when I did debug. Now I connected it directly to FSMC_A18 on the TFT header and it still works.
– 5v – my TFT board requires 5 V so I have to connect it to J2 header pin 1.
The rest of pins from the TFT board are wired to the appropriate TFT header pins of the black F407V board.

So, Stephen, I can just recommend to play a bit with those DATAST and ADDSET values as suggested by Pito.
Just to be sure I ask again, have you tried the BIN file I posted?


Pito
Fri Jul 07, 2017 3:40 pm
@steve: I may try with my tft as well, it is SSD1289 16bit one however.. I’ve got it working with MultiLCD library https://github.com/stanleyhuangyc/MultiLCD on F1 (libmaple, 16bit portB) which is based on utft (data not via FSMC). Here is the 1289 driver with tft init and a few i/o primitives I modded. Maybe easy to port when someone knows how to..

SSD1289.rar
(3.9 KiB) Downloaded 57 times

zmemw16
Fri Jul 07, 2017 4:16 pm
i’m reminded of work, telephone ‘can i speak to chris or steve’
‘which one, we’ve 7 chris’s and 6 steve’s’

on leaving work at 4:00pm, we’d take a quick’ish 60mls car ride to purchase computer bits in Manchester and they shut at 5:15pm. 90% motorway = 70mph, maybe the speedo read on the low side.
we needed a ‘company name’ for the sellers billing, S Cubed comprising the 3 steves involved.

got the io & disp connections done now in 6 files xcf via Gimp 5.9M

re: bin
istr trying it as i recall looking for st-flash in the history file.
now be honest, how many zeros after the 0x8 ?
pretty sure it didn’t do anything, any colour or any sort of flash i’d remember that :)
i’d be ecstatic if i just got a white screen

stephen


stevestrong
Fri Jul 07, 2017 8:08 pm
I attached a video to my first post in this thread.
https://www.youtube.com/watch?v=cQXc7nye6Vo
(how to attach it online?)


acronis
Thu Jul 20, 2017 7:46 am
Hello.
Tell me how to clear the screen to not flicker ?
I need to display the stitching time and if I do a clean fill of the screen (the tft.fillScreen(BLACK)) – can be seen flickering.
Flickering a little , but its noticeable

stevestrong
Thu Jul 20, 2017 9:39 am
[acronis – Thu Jul 20, 2017 7:46 am] –
I need to display the stitching time

sorry, I don’t really understand what you mean, could you please detail it.
If you want to erase only a text portion from the screen then I would actually write the same text using the background color as foreground color. This way you don’t need to clear the whole display, but you have to keep track of the text information.
Or overwrite the same line with number of spaces identical with the number of letters in the text.


acronis
Thu Jul 20, 2017 9:41 am
Great !
I don’t came to this idea ! I’ll try it.
Thanks for Your continued help and tips !

vegfokic
Thu Sep 28, 2017 4:42 pm
I have stm32f407vet6 board
http://www.ebay.com/itm/STM32F407VET6-S … No-Battery

And 3.2″ lcd module.
http://www.ebay.com/itm/3-2-IPS-TFT-LCD … o-Mega2560

My Arduino IDE 1.8.3

LCD libray:
https://github.com/ZinggJM/GxTFT

Hardware library:
https://github.com/greiman/Arduino_STM32

Using of these libraries choised ILI9481 or HX8357 driver and “stm32f4 boards/generic stm32f407v series” board working fine. I manage to run the graphicstest.

If I use other tft library from steve I manage to upload the code but there is no works. What I noticed that the screen is fully white, and after uploading the code there is a screen for a short time ~ 100ms show some register data or someting, and the screen is again just fully white. In the serial monitor I can see the result times of lines, rectangles..

https://github.com/stevstrong/Adafruit_ … 6bit_STM32

I noticed the previous statement If I use GXTFT lib with other hardvare lib from danieleff also with working serial monitor, coised stm32generic for stm32 boards/ black f407ve/ze/zg boards

https://github.com/danieleff/STM32GENERIC

Any idea to solve this problem?


stevestrong
Thu Sep 28, 2017 7:43 pm
I am wondering how the LCD lib with FSMC for F1 (pointed by your link) is supposed to work on the F4 board…

Anyway, if you use my 16 bit parallel library for the F4 board, you have to take my Arduino_STM32 repository, because the Roger’s repository does not contain (nor Greiman’s) my latest commits for F4 (PRs ongoing).

I just rebuilt the 16 bit lib for my generic black F4 board using FSMC, and it works.

For your specific display module you could adapt these values here: https://github.com/stevstrong/Arduino_S … fsmc.c#L79 to those from here:
+#define ADDSET 7 // 100ns (ADDSET+1)*12.5ns = CS to RW
+#define DATAST 3 // 50ns (DATAST+1)*12.5ns = RW length


vegfokic
Sat Sep 30, 2017 10:12 am
I fully delete my old repo and TFT lib. Copy your freshly downloaded repo and TFT lib. Upload the sketch but no working.
I changed in the FSMC.C to FSMC_BTR_DATAST_(3), FSMC_BTR_ADDSET_(7) but still no work after upload.
I changed in the sketch the lcd ID to a fix value 8357 because my lcd dont has RD pin, no work after upload.
I fully clean your TFT lib just use one lcd driver 8357 and write the hx8357.h and c files, no work after upload.
I tied with roger repo with values of FSMC_BTR_DATAST_(3), FSMC_BTR_ADDSET_(7) and FSMC_BTR_DATAST_(6), FSMC_BTR_ADDSET_(2) , no work.
I upload directly your test.ino.bin file to the board but also no work.

I copy again roger repo and use GxTFT lib, working again with both values of FSMC_BTR_DATAST_(3), FSMC_BTR_ADDSET_(7) and FSMC_BTR_DATAST_(6), FSMC_BTR_ADDSET_(2)

Benchmark Time (microseconds)
Screen fill 54965
Text 23824
Lines 245359
Horiz/Vert Lines 12452
Rectangles (outline) 4334
Rectangles (filled) 134326
Circles (filled) 143890
Circles (outline) 229991
Triangles (outline) 48260
Triangles (filled) 153115
Rounded rects (outline) 67433
Rounded rects (filled) 241204


stevestrong
Sat Sep 30, 2017 10:19 am
Because the BIN is not working for you, I assume the pin connections/definitions may be different.
How does it look like in your case?
Btw, 8357 was not tested, only 8341.
Check my graphicstest here: https://github.com/stevstrong/Adafruit_ … cstest.ino

Gx TFT lib not work with your repo error: ‘struct gpio_reg_map’ has no member named ‘BSRRL’……….in several lines
This is one of the differences between the repositories, in my repo BSRR is defined as 32 bit register.
Are you sure you are using FSMC, or rather bit banging? Because for FSMC this should not be relevant at all…
For using FSMC, you have to respect the FSMC pinning given here: https://github.com/stevstrong/Arduino_S … fsmc.c#L47
according to schematic: http://wiki.stm32duino.com/images/a/a8/ … AG-TFT.pdf


vegfokic
Sat Sep 30, 2017 6:24 pm
The pin connection is the same like yours. FSMC data pins are locked. Only some of the control pins are selectable but they are also the same.
I checked the stm32f407vet6 datasheet before made the connections and also checked same fsmc tft lib which pins are connected from the selectable pins. Yes same as in the linnk and also have these pdf datasheet about the pin connections of the board

stevestrong
Sat Sep 30, 2017 7:52 pm
I think that by using the GxTFT lib you are using bit-banging, not FSMC.

The clear indication for this is that you get the error warning related to BSRRL (used here: https://github.com/ZinggJM/GxTFT/blob/m … 16.cpp#L66).
If you would use FSMC, this error should not be there, writing the BSSR register in that case is not needed.

Other indication for this is that your benchmark is much slower than my benchmark with FSMC.

As I could only test my lib with a ILI9341 compatible display, it may happen that the part for ILI8357 does not work correctly.
But I think that the software configured for ILI9341 should also at least show something on ILI8357 LCD other than white screen.

Btw, which GxTFT sketch do you use? Please post it here or give a link to it.
I may try to build it myself for a test.


vegfokic
Sat Sep 30, 2017 8:24 pm
I see but its difficult for me :) So If my working sketch use bitbang instead of real FSMC how can I cahange to use FSMC?
Yes not too fast therefore I want to try other libs like yours which may faster.
ILI9341, ILI9481, HX8357 are similar thereefore the screen not white than shows something. The little differences cause inverted or rotated, mirrorred pics..or maybe color problem.

I have arduino mega and my TFT directly inserted in it. Using of bommer lib the speed almost the same what I wrote benchmark result
https://github.com/Bodmer/TFT_HX8357

Your screen will be faster because of yours is 320×240 and my is 480×320.

Zingg test I think the same like yours just the TFT configuration and board select are different.
https://github.com/ZinggJM/GxTFT/blob/m … cstest.ino


stevestrong
Sat Sep 30, 2017 8:57 pm
My LCD is also 320×480 (or 480×320, as you wish), check the benchmark text.

To use FSMC, I think you should include in line 40 of the GxTFT sketch this header:
#include <GxIO/STM32GENERIC/GxIO_STM32F4_FSMC/GxIO_STM32F4_FSMC.h>


vegfokic
Sun Oct 01, 2017 6:23 am
Ahh I see. When I have bagan test tried to use those lines but there was no pics just white screen and the only one working line was the
#include "../GxIO/GxIO_STM32F407V_P16/GxIO_STM32F407V_P16.h"

stevestrong
Sun Oct 01, 2017 7:06 am
[vegfokic – Sun Oct 01, 2017 6:23 am] – So if I see well now I have fully working TFT driver using in 16 bit mode connected to fsmc pins.

Yes. Although these benchmarks seem to show 16 bit parallel control wherein each bit is written separately. Pretty inefficient.

However, this is not inline with your previously posted benchmark here: viewtopic.php?f=39&t=2298&p=35090#p35090, which is quite different from these, not sure if it was really showing picture, please check again.

So yes, it seems that you have generally an issue with FSMC, independent on the used repo.
I would still try larger ADDSET and DATAST values, let’s say (7, 7) or even (10, 10) or larger, up to (15, 255), see RM0090, pages 1554/1555.
ADDSET gives the clocks between CS falling edge and WR falling edge, DATAST gives the clocks for WR active low period.
These have to be set according to your TFT controller spec.
Usually, ADDSET is much smaller than DATAST.
For my TFT (2, 6) gave the best performance.

BTW, during editing, you can use the tag “</>” to mark parts of the text as code.


vegfokic
Sun Oct 01, 2017 8:07 am
Yes the first result is different from these two. The first is 16bit mode with screen. The latest two in FSMC mode with white screen
I try to check the tft datasheet and playing very big datast and addset values.

StrangerM
Mon Oct 02, 2017 12:47 pm
Hello all. Thank you, Steve. Thank you, Roger. Cheap and fairly fast tft screen with cheap and rather powerful MC in Arduino IDE is the best idea for amature devices. It can be used for example in a fishfinder etc.
I used: tft https://www.aliexpress.com/item/3-2-inc … 0.0.bSxwyj & Black F407VET with Arduino IDE 1.8.4. https://yadi.sk/i/jLNOYVcy3NNRSg
TFT LCD test
TFT size is 320x480
TFT begin done.
rotation: 0, runtime: 5750
rotation: 1, runtime: 5750
rotation: 2, runtime: 5750
rotation: 3, runtime: 5750

Benchmark Time (microseconds)
Screen fill 48058
Text 5750
Lines 88029
Horiz/Vert Lines 4234
Rectangles (outline) 2673
Rectangles (filled) 117146
Circles (filled) 40319
Circles (outline) 37180
Triangles (outline) 16897
Triangles (filled) 50329
Rounded rects (outline) 12594
Rounded rects (filled) 134523
Done!


exider
Sat Oct 14, 2017 4:17 am
Hi all,

I’am using the exact setup as StrangerM does( STM32F407VE + matching 3.2 ACELEX TFT using 16 bit fsmc) but getting multiple errors when compiling with arduino 1.8.3 and 1.8.5.

I have changed #define USE_FSMC 1 .

First I was getting “fatal error: wiring_private.h: No such file or directory”
/home/ivan/Arduino/libraries/Adafruit-GFX-Library/Adafruit_SPITFT.cpp:21:31: fatal error: wiring_private.h: No such file or directory
#include "wiring_private.h"
^
compilation terminated.
Multiple libraries were found for "Adafruit_TFTLCD_16bit_STM32.h"
Used: /home/ivan/Downloads/Programming/Arduino/arduino-1.8.5/libraries/Adafruit_TFTLCD_16bit_STM32
Not used: /home/ivan/Arduino/libraries/111Adafruit_TFTLCD_16bit_STM32
Multiple libraries were found for "Adafruit_GFX.h"
Used: /home/ivan/Arduino/libraries/Adafruit-GFX-Library
Not used: /home/ivan/Downloads/Programming/Arduino/arduino-1.8.5/libraries/Adafruit-GFX-Library
Not used: /home/ivan/Downloads/Programming/Arduino/arduino-1.8.5/libraries/Adafruit-GFX-Library
Not used: /home/ivan/Downloads/Programming/Arduino/arduino-1.8.5/libraries/Adafruit-GFX-Library
Not used: /home/ivan/Downloads/Programming/Arduino/arduino-1.8.5/libraries/Adafruit-GFX-Library
Using library Adafruit_TFTLCD_16bit_STM32 at version 1.0.0 in folder: /home/ivan/Downloads/Programming/Arduino/arduino-1.8.5/libraries/Adafruit_TFTLCD_16bit_STM32
Using library Adafruit-GFX-Library at version 1.2.2 in folder: /home/ivan/Arduino/libraries/Adafruit-GFX-Library
Using library SPI at version 1.0 in folder: /home/ivan/Arduino/hardware/Arduino_STM32/STM32F4/libraries/SPI
exit status 1
Error compiling for board Generic STM32F407V series.


zmemw16
Sat Oct 14, 2017 5:49 am
oh thank you, i’m not alone any more, same target and screen, using st-link blue/cream egg; even better it’s not down to my lack of Linux knowledge.
Debian Stretch 9.x on i7 laptop and the ‘stock’ binary distro of Arduino 64bit 1.8.5, not had any need to write device drivers isa & pci since 1996.

i did try the posted bin file, nothing at all.

uncommented line 15 to allow FSMC and exactly the same message with wiring_private.h

steves repo Arduino_STM32 as of 12-10-2017 2315 and his doesn’t list the Black F407VE board, consequently selected generic F407. SPI interfaces might become confusing though later on.

with his Adafruit_TFTLCD_16bit_STM32 as of 12-10-2017 2314

a minor issue is i’m not sure where to source the Adafruit_GFX library files from, so i got it from github/adafruit ?
i keep thinking i’d need to use the Adafruit_GFX_STM32 version?

@stevstrong would you please comment on the above if i’ve got it wrong :)
does the gcc pre-processor handle the platform.txt and boards.txt files ?

i’ve set all messages for compiler and upload in preferences.txt, so no apologies for the length :!:
Arduino: 1.8.5 (Linux), Board: "Generic STM32F407V series, USB inactive, STLink, Smallest (default)"

/home/stephen/arduino-1.8.5/arduino-builder -dump-prefs -logger=machine -hardware /home/stephen/arduino-1.8.5/hardware -hardware /home/stephen/.arduino15/packages -hardware /home/stephen/sketchbook/hardware -tools /home/stephen/arduino-1.8.5/tools-builder -tools /home/stephen/arduino-1.8.5/hardware/tools/avr -tools /home/stephen/.arduino15/packages -built-in-libraries /home/stephen/arduino-1.8.5/libraries -libraries /home/stephen/sketchbook/libraries -fqbn=Arduino_STM32:STM32F4:generic_f407v:usb_cfg=usb_nc,upload_method=STLinkMethod,opt=osstd -ide-version=10805 -build-path /tmp/arduino_build_524430 -warnings=all -build-cache /tmp/arduino_cache_279927 -prefs=build.warn_data_percentage=75 -verbose /home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/examples/graphicstest/graphicstest.ino
/home/stephen/arduino-1.8.5/arduino-builder -compile -logger=machine -hardware /home/stephen/arduino-1.8.5/hardware -hardware /home/stephen/.arduino15/packages -hardware /home/stephen/sketchbook/hardware -tools /home/stephen/arduino-1.8.5/tools-builder -tools /home/stephen/arduino-1.8.5/hardware/tools/avr -tools /home/stephen/.arduino15/packages -built-in-libraries /home/stephen/arduino-1.8.5/libraries -libraries /home/stephen/sketchbook/libraries -fqbn=Arduino_STM32:STM32F4:generic_f407v:usb_cfg=usb_nc,upload_method=STLinkMethod,opt=osstd -ide-version=10805 -build-path /tmp/arduino_build_524430 -warnings=all -build-cache /tmp/arduino_cache_279927 -prefs=build.warn_data_percentage=75 -verbose /home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/examples/graphicstest/graphicstest.ino
Using board 'generic_f407v' from platform in folder: /home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4
Using core 'maple' from platform in folder: /home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4
Detecting libraries used...
"/home/stephen/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -c -g -Os -Wall -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_generic_f407v -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -DERROR_LED_PORT=GPIOA -DERROR_LED_PIN=7 -w -x c++ -E -CC -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10805 -DARDUINO_STM32GenericF407VET6 -DARDUINO_ARCH_STM32F4 -mthumb -DSTM32_HIGH_DENSITY -DSTM32F4 -DBOARD_generic_f407v -DUSB_NC -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -mthumb -D__STM32F4__ "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/system/libmaple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple/libmaple/usbF4" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/variants/generic_f407v" "/tmp/arduino_build_524430/sketch/graphicstest.ino.cpp" -o "/dev/null"
"/home/stephen/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -c -g -Os -Wall -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_generic_f407v -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -DERROR_LED_PORT=GPIOA -DERROR_LED_PIN=7 -w -x c++ -E -CC -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10805 -DARDUINO_STM32GenericF407VET6 -DARDUINO_ARCH_STM32F4 -mthumb -DSTM32_HIGH_DENSITY -DSTM32F4 -DBOARD_generic_f407v -DUSB_NC -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -mthumb -D__STM32F4__ "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/system/libmaple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple/libmaple/usbF4" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/variants/generic_f407v" "-I/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src" "/tmp/arduino_build_524430/sketch/graphicstest.ino.cpp" -o "/dev/null"
"/home/stephen/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -c -g -Os -Wall -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_generic_f407v -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -DERROR_LED_PORT=GPIOA -DERROR_LED_PIN=7 -w -x c++ -E -CC -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10805 -DARDUINO_STM32GenericF407VET6 -DARDUINO_ARCH_STM32F4 -mthumb -DSTM32_HIGH_DENSITY -DSTM32F4 -DBOARD_generic_f407v -DUSB_NC -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -mthumb -D__STM32F4__ "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/system/libmaple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple/libmaple/usbF4" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/variants/generic_f407v" "-I/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src" "-I/home/stephen/sketchbook/libraries/Adafruit_GFX" "/tmp/arduino_build_524430/sketch/graphicstest.ino.cpp" -o "/dev/null"
"/home/stephen/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -c -g -Os -Wall -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_generic_f407v -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -DERROR_LED_PORT=GPIOA -DERROR_LED_PIN=7 -w -x c++ -E -CC -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10805 -DARDUINO_STM32GenericF407VET6 -DARDUINO_ARCH_STM32F4 -mthumb -DSTM32_HIGH_DENSITY -DSTM32F4 -DBOARD_generic_f407v -DUSB_NC -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -mthumb -D__STM32F4__ "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/system/libmaple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple/libmaple/usbF4" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/variants/generic_f407v" "-I/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src" "-I/home/stephen/sketchbook/libraries/Adafruit_GFX" "/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src/Adafruit_TFTLCD_16bit_STM32.cpp" -o "/dev/null"
"/home/stephen/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -c -g -Os -Wall -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_generic_f407v -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -DERROR_LED_PORT=GPIOA -DERROR_LED_PIN=7 -w -x c++ -E -CC -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10805 -DARDUINO_STM32GenericF407VET6 -DARDUINO_ARCH_STM32F4 -mthumb -DSTM32_HIGH_DENSITY -DSTM32F4 -DBOARD_generic_f407v -DUSB_NC -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -mthumb -D__STM32F4__ "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/system/libmaple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple/libmaple/usbF4" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/variants/generic_f407v" "-I/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src" "-I/home/stephen/sketchbook/libraries/Adafruit_GFX" "/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src/hx8347g.cpp" -o "/dev/null"
"/home/stephen/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -c -g -Os -Wall -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_generic_f407v -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -DERROR_LED_PORT=GPIOA -DERROR_LED_PIN=7 -w -x c++ -E -CC -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10805 -DARDUINO_STM32GenericF407VET6 -DARDUINO_ARCH_STM32F4 -mthumb -DSTM32_HIGH_DENSITY -DSTM32F4 -DBOARD_generic_f407v -DUSB_NC -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -mthumb -D__STM32F4__ "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/system/libmaple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple/libmaple/usbF4" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/variants/generic_f407v" "-I/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src" "-I/home/stephen/sketchbook/libraries/Adafruit_GFX" "/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src/hx8357x.cpp" -o "/dev/null"
"/home/stephen/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -c -g -Os -Wall -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_generic_f407v -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -DERROR_LED_PORT=GPIOA -DERROR_LED_PIN=7 -w -x c++ -E -CC -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10805 -DARDUINO_STM32GenericF407VET6 -DARDUINO_ARCH_STM32F4 -mthumb -DSTM32_HIGH_DENSITY -DSTM32F4 -DBOARD_generic_f407v -DUSB_NC -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -mthumb -D__STM32F4__ "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/system/libmaple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple/libmaple/usbF4" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/variants/generic_f407v" "-I/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src" "-I/home/stephen/sketchbook/libraries/Adafruit_GFX" "/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src/ili932x.cpp" -o "/dev/null"
"/home/stephen/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -c -g -Os -Wall -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_generic_f407v -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -DERROR_LED_PORT=GPIOA -DERROR_LED_PIN=7 -w -x c++ -E -CC -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10805 -DARDUINO_STM32GenericF407VET6 -DARDUINO_ARCH_STM32F4 -mthumb -DSTM32_HIGH_DENSITY -DSTM32F4 -DBOARD_generic_f407v -DUSB_NC -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -mthumb -D__STM32F4__ "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/system/libmaple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple/libmaple/usbF4" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/variants/generic_f407v" "-I/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src" "-I/home/stephen/sketchbook/libraries/Adafruit_GFX" "/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src/ili9341.cpp" -o "/dev/null"
"/home/stephen/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -c -g -Os -Wall -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_generic_f407v -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -DERROR_LED_PORT=GPIOA -DERROR_LED_PIN=7 -w -x c++ -E -CC -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10805 -DARDUINO_STM32GenericF407VET6 -DARDUINO_ARCH_STM32F4 -mthumb -DSTM32_HIGH_DENSITY -DSTM32F4 -DBOARD_generic_f407v -DUSB_NC -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -mthumb -D__STM32F4__ "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/system/libmaple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple/libmaple/usbF4" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/variants/generic_f407v" "-I/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src" "-I/home/stephen/sketchbook/libraries/Adafruit_GFX" "/home/stephen/sketchbook/libraries/Adafruit_GFX/Adafruit_GFX.cpp" -o "/dev/null"
"/home/stephen/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -c -g -Os -Wall -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_generic_f407v -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -DERROR_LED_PORT=GPIOA -DERROR_LED_PIN=7 -w -x c++ -E -CC -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10805 -DARDUINO_STM32GenericF407VET6 -DARDUINO_ARCH_STM32F4 -mthumb -DSTM32_HIGH_DENSITY -DSTM32F4 -DBOARD_generic_f407v -DUSB_NC -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -mthumb -D__STM32F4__ "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/system/libmaple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple/libmaple/usbF4" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/variants/generic_f407v" "-I/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src" "-I/home/stephen/sketchbook/libraries/Adafruit_GFX" "/home/stephen/sketchbook/libraries/Adafruit_GFX/Adafruit_SPITFT.cpp" -o "/dev/null"
"/home/stephen/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -c -g -Os -Wall -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_generic_f407v -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -DERROR_LED_PORT=GPIOA -DERROR_LED_PIN=7 -w -x c++ -E -CC -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10805 -DARDUINO_STM32GenericF407VET6 -DARDUINO_ARCH_STM32F4 -mthumb -DSTM32_HIGH_DENSITY -DSTM32F4 -DBOARD_generic_f407v -DUSB_NC -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -mthumb -D__STM32F4__ "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/system/libmaple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple/libmaple/usbF4" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/variants/generic_f407v" "-I/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src" "-I/home/stephen/sketchbook/libraries/Adafruit_GFX" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/libraries/SPI/src" "/home/stephen/sketchbook/libraries/Adafruit_GFX/Adafruit_SPITFT.cpp" -o "/dev/null"
"/home/stephen/.arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -c -g -Os -Wall -std=gnu++11 -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -DBOARD_generic_f407v -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -DERROR_LED_PORT=GPIOA -DERROR_LED_PIN=7 -w -x c++ -E -CC -mcpu=cortex-m4 -DF_CPU=168000000L -DARDUINO=10805 -DARDUINO_STM32GenericF407VET6 -DARDUINO_ARCH_STM32F4 -mthumb -DSTM32_HIGH_DENSITY -DSTM32F4 -DBOARD_generic_f407v -DUSB_NC -DVECT_TAB_FLASH -DUSER_ADDR_ROM=(uint32)0x08000000 -mthumb -D__STM32F4__ "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/system/libmaple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple/libmaple/usbF4" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/cores/maple" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/variants/generic_f407v" "-I/home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32/src" "-I/home/stephen/sketchbook/libraries/Adafruit_GFX" "-I/home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/libraries/SPI/src" "/home/stephen/sketchbook/libraries/Adafruit_GFX/Adafruit_SPITFT.cpp" -o "/tmp/arduino_build_524430/preproc/ctags_target_for_gcc_minus_e.cpp"
/home/stephen/sketchbook/libraries/Adafruit_GFX/Adafruit_SPITFT.cpp:21:32: fatal error: wiring_private.h: No such file or directory
#include "wiring_private.h"
^
compilation terminated.
Using library Adafruit_TFTLCD_16bit_STM32 at version 1.0.0 in folder: /home/stephen/sketchbook/libraries/Adafruit_TFTLCD_16bit_STM32
Using library Adafruit_GFX at version 1.2.2 in folder: /home/stephen/sketchbook/libraries/Adafruit_GFX
Using library SPI at version 1.0 in folder: /home/stephen/sketchbook/hardware/Arduino_STM32/STM32F4/libraries/SPI
exit status 1
Error compiling for board Generic STM32F407V series.


exider
Sat Oct 14, 2017 6:10 am
My wild guess would be : it would be best if someone can provide a working docker image
and share it here will be best!
hanks

stevestrong
Sat Oct 14, 2017 8:26 am
@all,
I don’t know which sketch are you using. I have tested the graphicstest example from my Adafruit_TFTLCD_16_STM32 bit lib.
Please use this example!
This way the error messages related to “wiring_private.h” will disappear, the SPI lib will (and should) not be part of the project.

Btw, I had indeed 2 places with typo error (used FSCM instead of FSMC), which I have corrected now.
So please check out the latest version form here: https://github.com/stevstrong/Adafruit_ … 6bit_STM32
and the sketch: https://github.com/stevstrong/Adafruit_ … cstest.ino

@exider,
First of all, there is a BIN file attached to this post: http://stm32duino.com/viewtopic.php?f=39&t=2298#p31037
Second, what means “I have changed
#define USE_FSMC 1


exider
Sat Oct 14, 2017 3:49 pm
I have used graphigtest example.

@ stevestrong
“Second, what means “I have changed”
I have uncommented it , i.e. use it !

I guess, that typo has a lot to do with the error as dew to it , it wasn’t using fsmc ..

Will try out in a minute and let you know.

Thank you for looking into it.


exider
Sat Oct 14, 2017 4:27 pm
found another typo…

just above line 157 in Adafruit_TFTLCD_16bit_STM32.cpp change FSCM to FSMC .

"Adafruit_TFTLCD_16bit_STM32.cpp:157:19: error: 'writeData_' was not declared in this scope writeData_(color);


stevestrong
Sat Oct 14, 2017 4:50 pm
[exider – Sat Oct 14, 2017 4:27 pm] –
another typo…
just above line 157 in Adafruit_TFTLCD_16bit_STM32.cpp change FSCM to FSMC .

That was one of the two typos what I have corrected before, and committed.
Are you really sure u are using the latest lib from github?


exider
Sat Oct 14, 2017 4:56 pm
Yes, that was it!
It works now!

@zmemw16
Copy wiring_private.h to Adafruit-GFX-Library folder and correct the two typo errors in Adafruit_TFTLCD_16bit_STM32.h ,and should work.

Thanks Steve!


stevestrong
Sat Oct 14, 2017 5:10 pm
[exider – Sat Oct 14, 2017 4:56 pm] –
Copy wiring_private.h to Adafruit-GFX-Library folder

Wait, this is not needed. For me, it works without this step.


zmemw16
Sat Oct 14, 2017 5:30 pm
@stevstrong just curious – do you have your own local copy of Adafruit_GFX ?
so i went off to google with >adafruit wiring_private.h< and followed the 3rd answer to github

#include "Adafruit_SPITFT.h"
#ifndef ARDUINO_STM32_FEATHER
#include "pins_arduino.h"
#ifndef RASPI
#include "wiring_private.h" <========================== line 21
#endif
#endif
#include <limits.h>

#include "Adafruit_SPITFT_Macros.h"


stevestrong
Sat Oct 14, 2017 5:53 pm
My local Adafruit_GFX version is dated April 2017, so it may happen that they changed something since then.

Could any of you try to copy the Adafruit_GFX_AS lib from F1 to F4 lib directory?
Then replace in the 16 bit lib header file
#include <Adafruit_GFX.h>


exider
Sat Oct 14, 2017 6:58 pm
@stevestrong

Could any of you try to copy the Adafruit_GFX_AS lib from F1 to F4 lib directory?
Then replace in the 16 bit lib header file

Code: Select all

#include <Adafruit_GFX.h>

by

Code: Select all

#include <Adafruit_GFX_AS.h>

and tell me wheter it builds and works?

Yes, it builds and it works!


stevestrong
Sat Oct 14, 2017 7:05 pm
Nice, thanks for letting me know.
Then I suggest to use this.

EDIT
I modified the lib to get rid of compiler warnings, find attached here.
Place it under Arduino_STM32/STM32F4/libraries.


zmemw16
Sat Oct 14, 2017 9:52 pm
yes, i’ve checked udev scripts and the resultant /dev/tty* permissions, all the same as on my other systems.

@stevstrong
as seems usual for me, i just get the text output via a usb serial block on pa9/pa10, serial usb (ttyACM0) nothing, nothing on tft lcd.

am i correct in thinking the only changes required for using the ze/zg variants would be setting the ne[1-4] block and the address line a6, a10, a18 etc? i’ve multiple available of those, one(?2?) of the vet

@both can you post a picture of your setups ?
optional :-) maybe screen captures of the tools drop down or just a list of what’s set … …

maybe try it on windows, like that’s going to happen, ok maybe just sleep

stephen


stevestrong
Sun Oct 15, 2017 3:52 pm
Here is a short video of my setup: viewtopic.php?f=39&t=2298#p31037
My settings? Just the basic stuff: Win 10, Arduino IDE 1.6.12, Tools->Board: Generic F407VE series, USB serial active.
+ my repo, and my Adafruit 16 bit lib with activated FSMC, and the Adafruit_GFX_AS lib for F4, as attached in my other post above. That’s all.

And a correct wiring… ;)

I don’t know the ze/zg boards.

EDIT
@stephen, are you sure your LCD board is set to 16 bit parallel access?


StrangerM
Sun Oct 15, 2017 4:10 pm
Hi. I am sorry. I used Arduino 1.8.5 in WinXP. I modified Adafruit_TFTLCD_16bit_STM32 for compilation. https://yadi.sk/d/5gzxn-wu3NmaDk

zmemw16
Sun Oct 15, 2017 6:04 pm
[stevestrong – Sun Oct 15, 2017 3:52 pm] –
EDIT
@stephen, are you sure your LCD board is set to 16 bit parallel access?

stev have you echoed the 16bit changes into the 8bit ?
that would seem the easiest route.

2017-10-15 18.51.05.png
2017-10-15 18.51.05.png (87.52 KiB) Viewed 595 times

StrangerM
Mon Oct 16, 2017 12:09 am
It`s the back of my display https://yadi.sk/i/cQu3UM1X3Nn3wZ

zmemw16
Mon Oct 16, 2017 3:15 am
i’d say identical, bad, bad news :( :(

i went looking via my order list on aliexpress for the display, current product is about 30% of the backside components.

could you attach your binary with a rename extension of dot txt
and maybe the source sketch as well ?

this has to be something stupid or so, so basically fundamental i’m completely missing it.
have i mentioned i can kill a system unit, stm32 board or display with a look :D

stephen


StrangerM
Mon Oct 16, 2017 12:33 pm
Look throught attentivly my previous attach. There is everything in it – my Adafruit_TFTLCD_16bit_STM32 and arduino_build_857036.

StrangerM
Mon Oct 16, 2017 12:53 pm
In my project Ichanged Adafruit_SPITFT.cpp .

#include "Adafruit_SPITFT.h"
#ifndef ARDUINO_STM32_FEATHER
#include "pins_arduino.h"
#ifndef RASPI
// #include "wiring_private.h" !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
#endif
#endif
#include <limits.h>

#include "Adafruit_SPITFT_Macros.h"


exider
Mon Oct 16, 2017 1:09 pm
@ zmemw16

I’d say, my LCD is identical to yours.

https://photos.app.goo.gl/1FFPgePQX46PHCHk2

Ignore the connected GPIO cables. They are for MPU9250 10 DOF sensor board and are irrelevant to the LCD.
The LCD plugs into the tft connector.


acronis
Sun Feb 18, 2018 4:10 am
Hi Steve.
I downloaded the latest library for Your display (FSMC LCD 16bit)

and now there are compile-time errors.
In file included from C:\Users\V\Documents\Arduino\libraries\Adafruit_TFTLCD_16bit_STM32-master\src\Adafruit_common.h:5:0,

from C:\Users\V\Documents\Arduino\libraries\Adafruit_TFTLCD_16bit_STM32-master\src\Adafruit_TFTLCD_16bit_STM32.cpp:7:

C:\Users\V\Documents\Arduino\libraries\Adafruit_TFTLCD_16bit_STM32-master\src\Adafruit_TFTLCD_16bit_STM32.cpp: In member function 'void Adafruit_TFTLCD_16bit_STM32::reset()':

C:\Users\V\Documents\Arduino\libraries\Adafruit_TFTLCD_16bit_STM32-master\src/Adafruit_TFTLCD_16bit_STM32.h:137:48: error: 'gpio_reg_map' has no member named 'CRL'

#define setWriteDir() { TFT_DATA_PORT->regs->CRL = 0x33333333; TFT_DATA_PORT->regs->CRH = 0x33333333; } // set the bits as output

^

C:\Users\V\Documents\Arduino\libraries\Adafruit_TFTLCD_16bit_STM32-master\src\Adafruit_TFTLCD_16bit_STM32.cpp:105:2: note: in expansion of macro 'setWriteDir'

setWriteDir();

^

C:\Users\V\Documents\Arduino\libraries\Adafruit_TFTLCD_16bit_STM32-master\src/Adafruit_TFTLCD_16bit_STM32.h:137:87: error: 'gpio_reg_map' has no member named 'CRH'

#define setWriteDir() { TFT_DATA_PORT->regs->CRL = 0x33333333; TFT_DATA_PORT->regs->CRH = 0x33333333; } // set the bits as output

^

C:\Users\V\Documents\Arduino\libraries\Adafruit_TFTLCD_16bit_STM32-master\src\Adafruit_TFTLCD_16bit_STM32.cpp:105:2: note: in expansion of macro 'setWriteDir'

setWriteDir();


stevestrong
Sun Feb 18, 2018 9:06 am
Which target/board do you use? Did you correctly selected it from the Arduino IDE menu option?
With FSMC enabled or without?

EDIT
OK, I’ve figure it out, F4 without FSMC shows the symptom. I am investigating the issue.

But if you use F4, why don’t you enable FSMC by enabling this line: https://github.com/stevstrong/Adafruit_ … TM32.h#L12?

EDIT2
I just checked in a fix for that. It now compiles error free, but the functionality is not tested. Let me know if it works.


acronis
Sun Feb 18, 2018 9:37 am
Steven, Thank you so much.

#define USE_FSMC 1


jdenis
Fri Feb 23, 2018 9:03 pm
Hi for all…

I’m trying to use FSMC with a SSD1963 7″ LCD, it works, but kinda slow…

In this video I show it working with a STD STM32F407VET6 board from aliexpress!

It’s very slow, but the image source is a 25q128 spi eeprom, and hopefully i’ll be able to use DMA for something…

So here is the question… Is it possible to reduce de clock divider for the FSMC control?

I REALLY don’t know what i’m doing, i’m trying to learn the full structure of this things so maybe that’s not possible! But still… Thanks for the lib and all!!

Forgot to say it’s a 800×480 pix…


zmemw16
Fri Feb 23, 2018 9:34 pm
video is unavailable above and using the you-tube url
of course browsing the thread it now works.

which cpu board are you using ? one of the Black series ?
that mcu looks more like a ze or zg than a ve

darn, i didn’t wait long enough
:D
srp


jdenis
Fri Feb 23, 2018 9:35 pm
OOPS… Fixed!!!

Manny
Sat Feb 24, 2018 12:15 pm
[jdenis – Fri Feb 23, 2018 9:03 pm] –

It’s very slow, but the image source is a 25q128 spi eeprom, and hopefully i’ll be able to use DMA for something…

Dont look that slow to me.


jdenis
Sat Feb 24, 2018 1:26 pm
Yeah thats because i cheated… thats the fastest frame rate possible in this config… this video IC has memory so i instruct to get the information to the video memory and then show it at once… thats why you cant se the construction of the image! i’m getting something arround 12 mbps… and with a simple fill screen i get the same using:

for(uint32_t i = 0; i < 800*480; i++) {writeData(0xFFFF);}


stevestrong
Sat Feb 24, 2018 3:21 pm
[jdenis – Sat Feb 24, 2018 1:26 pm] –
Isn there a clock div on the FSMC?

Not that I know.


jdenis
Sat Feb 24, 2018 3:52 pm
I did see this:

https://vjordan.info/log/fpga/stm32f4-g … -fsmc.html

I really don’t know how to handle this level of commands yet, so I’ll study a little but i think it’s possible…


stevestrong
Sat Feb 24, 2018 4:45 pm
The FSMC uses Mode 1 accesses, so you can get the idea from RM0090 chap. 36.5.4, fig. 435.
Configurable parameters: ADDSET and DATAST.

jdenis
Sat Feb 24, 2018 11:20 pm
Hey thanks for answering… just a question, if i change on fsmc.c the:

val = (FSMC_BTR_ACCMOD_A | FSMC_BTR_DATLAT_(0) | FSMC_BTR_CLKDIV_(0) | FSMC_BTR_BUSTURN_(0) | FSMC_BTR_DATAST_(6) | FSMC_BTR_ADDHLD_(0) | FSMC_BTR_ADDSET_(2));


jdenis
Sun Feb 25, 2018 12:18 am
HEYYY just got it!! i’m stupid :D

I was using DOUBLE for the or loop and getting 800khz
for(double i = 0; i < pixels; i++) {*fsmcData = color;}


jdenis
Sun Feb 25, 2018 5:36 pm
Here is the video with showing directly all… its 5 800×480 images and full screen R G B W BLK…

FSMC @ 28MHZ * 16bit

SPI with DMA for the 25Q128

again thanks Steve!!!

Here is the link for the screen:
https://www.ebay.com/itm/7-7inch-TFT-LC … SwnsRaXGg3


stevestrong
Tue Feb 27, 2018 12:20 pm
[jdenis – Sun Feb 25, 2018 5:36 pm] –
SPI with DMA for the 25Q128

@jdenis,
Since I have it on my todo list for F4, do you have some code to share for 25Q flash device?


jdenis
Wed Feb 28, 2018 8:41 pm
Yes i used this one…

winbondFlashSPI mem;
SPIClass spiToUse(1);

if(mem.begin(spiToUse,PA4)) SPIEEPROMCONNECTED = 1; else{SPIEEPROMCONNECTED = 0;

mem.read(address, SPI_EEPROM_BUFFER, width);


C_D
Sun Feb 03, 2019 8:25 pm
Steve, i’m looking to run your 16bit FSMC LCD library on an F1 rather than an F4 as I have a board with an F103VET6 which is wired to the FSMC pins. I see some of the functions in fsmc.c in the F4 core are non implemented in the F1 core. Is that all I need to change or are there other places in the code i need to look also?

stevestrong
Tue Feb 05, 2019 8:46 am
Sorry, but I have no idea about what to adapt for the F1. You are alone here, I’m afraid.

C_D
Thu Feb 07, 2019 2:45 am
[stevestrong – Tue Feb 05, 2019 8:46 am] –
You are alone here, I’m afraid.

Woohoo!

Time to try and run it and see where falls over then :lol:


Leave a Reply

Your email address will not be published. Required fields are marked *