You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
home/andre/Arduino/projects/libraries/FastLED/platforms/arm/stm32/led_sysdefs_arm_stm32.h:4:25: fatal error: application.h: No such file or directory
#include <application.h>
^
compilation terminated.
I took a look yesterday and I can't figure out where the hell application.h is coming from. Note that I'm not the one who added this #include statement. All in all, this is still a mystery to me :-\
I took another look, and it seems that application.h is some file which is auto-generated by Arduino.
For the reference, this #include "applcation.h" statement was added by commit f149084 (by @focalintent) and later changed to #include <application.h>" (which I believe is wrong since it's supposed to be a local include) by commit 6fd2366.
@AndKe which arduino version are you using? Please try the workarounds I provided above, let us know if it helps.
Well, I have removed #include <application.h> and everything seems working just fine. Not sure why it worked for me before, and if this is a correct solution.
Now I have to dig a blue pill out of my closet and give it a try )
The stm32 code was originally done for the particle photon boards and that platform needed the application.h - support for other stm32 variants has mostly come in from folks tweaking things to support other stm32 based boards, and they never took it out - if someone can figure out when it should be there vs when not - I’d prefer being able to gate when the include is used - otherwise I’m removing it I just open myself up to a bunch of issues complaining about things missing :)
What is the actual value for RGB_FL - if there isn’t a definition for that pin in platforms/arm/stm32/fastpin_stm32.h, then that will cause this error (for performance reasons, FastLED does its own definitions/mappings for pins to ports)
Looking at the commit for blue pill support - it looks like it doesn’t have pin definitions for all the pins on the blue pill board (eg pins 25-28, possibly others?)
What’s the whole compiler output - there should be more context to that message to show what it thinks RGB_FL is - Also where is RGB_FL getting defined? It wasn’t referenced in the Arduino STM32 core that I found.
Oh - also, what happens if you use integers instead of PA*? I generally tell folks to use integer pins - because on some platforms D* or other ways of defining pins end up not being constant expressions.
Oh - I see what you mean, you’re defining RGB_FL to be something like PA0 - it depends on how the core/platform you’re using defines PA0 and friends. But again, I generally discourage the use of named pins vs PIN numbers (there’s a reason you never see D10 in an example, but rather just 10)
yes, using integers build it successfully... except:
"Sketch uses 96600 bytes (147%) of program storage space. Maximum is 65536 bytes"
this is kind of crazy, I had this program, with the same libraries, fit on a Atmega 328 just fine, but not on this 64k STM32
Something must be eating lots of space ?
@kolyshkin
"I generally tell folks to use integer pins" I tried to use integers like 10 for PA0 , 11 for PA1 , then it compiles but the application does not seem to run on microcontroller (crashes ( hangs at FastLED.addLeds) (I see it on UART activity)
then I tried 14,15,16,17 for PA4,5,6,7 then it runs, but the led strips does not do anything
as for the compiler flags, I hope that becomes a permanent fix at some point, or easily selectable.
Activity
kolyshkin commentedon Feb 20, 2019
I took a look yesterday and I can't figure out where the hell
application.his coming from. Note that I'm not the one who added this#includestatement. All in all, this is still a mystery to me :-\I took another look, and it seems that
application.his some file which is auto-generated by Arduino.Perhaps you can either try
<application.h>to"application.h", orkolyshkin commentedon Feb 20, 2019
For the reference, this
#include "applcation.h"statement was added by commit f149084 (by @focalintent) and later changed to#include <application.h>"(which I believe is wrong since it's supposed to be a local include) by commit 6fd2366.@AndKe which arduino version are you using? Please try the workarounds I provided above, let us know if it helps.
kolyshkin commentedon Feb 20, 2019
Well, I have removed
#include <application.h>and everything seems working just fine. Not sure why it worked for me before, and if this is a correct solution.Now I have to dig a blue pill out of my closet and give it a try )
kolyshkin commentedon Feb 20, 2019
@focalintent maybe you can shed some light? It seems this
#include <application.h>is some kind of leftover that needs to be removedfocalintent commentedon Feb 21, 2019
The stm32 code was originally done for the particle photon boards and that platform needed the application.h - support for other stm32 variants has mostly come in from folks tweaking things to support other stm32 based boards, and they never took it out - if someone can figure out when it should be there vs when not - I’d prefer being able to gate when the include is used - otherwise I’m removing it I just open myself up to a bunch of issues complaining about things missing :)
stm32duino (Maple, Blue Pill, etc): compile fix
kolyshkin commentedon Feb 21, 2019
Oh, in such case it should be very easy to fix -- since the original code used
STM32F10X_MDdefine, this is what we should use :)@focalintent PTAL at #742
stm32duino (Maple, Blue Pill, etc): compile fix
AndKe commentedon Feb 21, 2019
I tried FastLED master, on Arduino 1.8.8
FastLED.addLeds<NEOPIXEL, RGB_FL>(leds, 0, NUM_LEDS_PER_STRIP);
RGB_FL is PAx or PBx throws this error:
certainly an improvement, but it does not seem to "understand" PA0 pr PB6 or any other ports/pins I tried.
I see the library defines blue pill pins, and fail to understand why it would not do so, with these defines:
focalintent commentedon Feb 21, 2019
What is the actual value for RGB_FL - if there isn’t a definition for that pin in platforms/arm/stm32/fastpin_stm32.h, then that will cause this error (for performance reasons, FastLED does its own definitions/mappings for pins to ports)
focalintent commentedon Feb 21, 2019
Looking at the commit for blue pill support - it looks like it doesn’t have pin definitions for all the pins on the blue pill board (eg pins 25-28, possibly others?)
AndKe commentedon Feb 21, 2019
I tried PA0...6 and PB5..9 (mentioned it before) so RGB_FL is/was PA0 , then PA1 and so on
to me, it seems like all the pins I tried to use are just fine here: https://github.com/FastLED/FastLED/blob/master/platforms/arm/stm32/fastpin_arm_stm32.h#L107
focalintent commentedon Feb 21, 2019
What’s the whole compiler output - there should be more context to that message to show what it thinks RGB_FL is - Also where is RGB_FL getting defined? It wasn’t referenced in the Arduino STM32 core that I found.
focalintent commentedon Feb 21, 2019
Oh - also, what happens if you use integers instead of PA*? I generally tell folks to use integer pins - because on some platforms D* or other ways of defining pins end up not being constant expressions.
focalintent commentedon Feb 21, 2019
Oh - I see what you mean, you’re defining RGB_FL to be something like PA0 - it depends on how the core/platform you’re using defines PA0 and friends. But again, I generally discourage the use of named pins vs PIN numbers (there’s a reason you never see D10 in an example, but rather just 10)
AndKe commentedon Feb 21, 2019
yes, using integers build it successfully... except:
"Sketch uses 96600 bytes (147%) of program storage space. Maximum is 65536 bytes"
this is kind of crazy, I had this program, with the same libraries, fit on a Atmega 328 just fine, but not on this 64k STM32
Something must be eating lots of space ?
AndKe commentedon Feb 21, 2019
..if I omit FastLED library and a few kb of code related to it, I am down to 52% of space.
focalintent commentedon Feb 22, 2019
That sounds odd - I wonder if the stm32 compiler is doing a poor job of pruning unreferenced code?
kolyshkin commentedon Feb 22, 2019
Haha, @AndKe, you're following my steps! The reason is, you need to add a flag. Please see rogerclarkmelbourne/Arduino_STM32#444
and
rogerclarkmelbourne/Arduino_STM32#296
AndKe commentedon Feb 22, 2019
@kolyshkin
"I generally tell folks to use integer pins" I tried to use integers like 10 for PA0 , 11 for PA1 , then it compiles but the application does not seem to run on microcontroller (crashes ( hangs at FastLED.addLeds) (I see it on UART activity)
then I tried 14,15,16,17 for PA4,5,6,7 then it runs, but the led strips does not do anything
as for the compiler flags, I hope that becomes a permanent fix at some point, or easily selectable.