ESP-12 + FTDi + platformio I have 2 questions.


Why we have to put our functions before void loop and void setup into VScode+platformio?
I switched from arduino IDE to VScode+platformio today, when I upload the sketch with platformio into my esp-12, it doesn't work. (It works with arduino IDE)


I have this Warning: src\main.cpp:46:24: warning: large integer implicitly truncated to unsigned type [-Woverflow]
 const byte menuColor = 0XF206;

[EDIT]The problem comes from these lines:

attachInterrupt(digitalPinToInterrupt(enA), enAin, RISING);
attachInterrupt(digitalPinToInterrupt(enB), enBin, RISING);
attachInterrupt(digitalPinToInterrupt(enBtn), enBtnIn, FALLING);
Why we have to put our functions before void loop and void setup into VScode+platformio?


Because that is how C works. The Arduino IDE hides it from you by adding function prototypes at the start of your code.


  I switched from arduino IDE to VScode+platformio today, when I upload the sketch with platformio into my esp-12, it doesn't work. (It works with arduino IDE)


const byte menuColor = 0XF206;


That can never work. The value 0x06 will be assigned to menuColor since a byte is only 8 bits.  You need to learn to use data types that are suitable for the values you are trying to store in them.