PlatformIO package of the Teensy core framework compatible with GCC 10 & C++20
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

42 行
762B

  1. /*
  2. A benchmark test - measure the speed of many drawing functions of RA8875 library at any rotation
  3. Open your serial monitor for results
  4. */
  5. #include <SPI.h>
  6. #include <RA8875.h>
  7. #define DELAY_BETWEEN 500
  8. /*
  9. Teensy3.x and Arduino's
  10. You are using 4 wire SPI here, so:
  11. MOSI: 11//Teensy3.x
  12. MISO: 12//Teensy3.x
  13. SCK: 13//Teensy3.x
  14. the rest of pin below:
  15. */
  16. #define RA8875_CS 10
  17. #define RA8875_RESET 9
  18. /*
  19. DUE can use 4,10 or 52( or 53? don't remember)
  20. */
  21. RA8875 tft = RA8875(RA8875_CS, RA8875_RESET);
  22. void setup() {
  23. Serial.begin(38400);
  24. long unsigned debug_start = millis ();
  25. while (!Serial && ((millis () - debug_start) <= 5000)) ;
  26. tft.begin(RA8875_800x480);
  27. }
  28. uint8_t rot = 0;
  29. void loop(void) {
  30. test(rot);
  31. rot++;
  32. if (rot > 3) rot = 0;
  33. }