pins_arduino.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. /*
  2. * Copyright (c) 2006-2022, RT-Thread Development Team
  3. *
  4. * SPDX-License-Identifier: Apache-2.0
  5. *
  6. * Change Logs:
  7. * Date Author Notes
  8. * 2022-08-05 liYony first version
  9. */
  10. #ifndef Pins_Arduino_h
  11. #define Pins_Arduino_h
  12. /* pins alias. Must keep in sequence */
  13. #define D0 (0)
  14. #define D1 (1)
  15. #define D2 (2)
  16. #define D3 (3)
  17. #define D4 (4)
  18. #define D5 (5)
  19. #define D6 (6)
  20. #define D7 (7)
  21. #define D8 (8)
  22. #define D9 (9)
  23. #define D10 (10)
  24. #define D11 (11)
  25. #define D12 (12)
  26. #define D13 (13)
  27. #define A0 (14)
  28. #define A1 (15)
  29. #define A2 (16)
  30. #define A3 (17)
  31. #define A4 (18)
  32. #define A5 (19)
  33. #define A6 (20)
  34. #define F_CPU 72000000L /* CPU: 72MHz */
  35. #define LED_BUILTIN D8 /* Default Built-in LED */
  36. /*
  37. * i2c1 - PB9-SDA PB8-SCL
  38. */
  39. #define RTDUINO_DEFAULT_IIC_BUS_NAME "i2c1"
  40. /*
  41. * uart2 - PA2-TX PA3-RX
  42. * uart3 - PB10-TX PB11-RX
  43. */
  44. #define RTDUINO_SERIAL2_DEVICE_NAME "uart2"
  45. #define RTDUINO_SERIAL3_DEVICE_NAME "uart3"
  46. /*
  47. * uart2 - PB13-SCK PB14-MISO PB15-MOSI
  48. */
  49. #define RTDUINO_DEFAULT_SPI_BUS_NAME "spi2"
  50. #endif /* Pins_Arduino_h */