section type conflict

You showed us your Arduino sketch code, which is good, but it includes 8 files and 1 of those (AMY-Arduino.h) is something unfamiliar, not anything installed by Teensyduino. Your compiler errors also how the offending lines are in "libraries\amy\src\patches.h" included by libraries\amy\src\patches.c. I hope you can understand how the best anyone can do is blind guessing and generic advice when we can't reproduce the problem and we even can't see patches.h and patches.c or anything else associated with AMY-Arduino.h.

So with generic advice, which may or may not apply to your specific problem, usually the 2 things to be done about section type conflicts are to be careful about using PROGMEM only for variables and FLASHMEM only for functions. These do basically the same thing and either can work for either usage. Two of them exist because of the section type conflict errors gcc gives. The other thing you can do is divy your code up into smaller files, where no single .c or .cpp "compile unit" has conflicting usage of section keywors like PROGMEM and FLASHMEM.
 
The problem files are contained within the AMY-Arduino.h Additive Music synthesizer library and the files it pulls in.
The library is here.
Even the supposedly tested Teensy example program from examples fails to compile.
I suggest you contact the Author of the software for a solution.
 
Last edited:
With help from the amy dev I had to make the declaration like this

C-like:
static const char * const patch_commands[256] PROGMEM = {
 
Back
Top