Teensy 4.1 core updated for C++20
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

main.cpp 412B

12345678910111213141516171819202122232425262728
  1. #include "WProgram.h"
  2. extern "C" int main(void)
  3. {
  4. #if !defined(ARDUINO)
  5. // To use Teensy 3.0 without Arduino, simply put your code here.
  6. // For example:
  7. pinMode(13, OUTPUT);
  8. while (1) {
  9. digitalWriteFast(13, HIGH);
  10. delay(500);
  11. digitalWriteFast(13, LOW);
  12. delay(500);
  13. }
  14. #else
  15. // Arduino's main() function just calls setup() and loop()....
  16. setup();
  17. while (1) {
  18. loop();
  19. yield();
  20. }
  21. #endif
  22. }