pins_arduino.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  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-12-01 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 A0 (13)
  27. #define A1 (14)
  28. #define A2 (15)
  29. #define DAC0 (16)
  30. #define F_CPU 80000000L /* CPU:80MHz */
  31. /* i2c1 : PB7-SDA PB6-SCL */
  32. #define RTDUINO_DEFAULT_IIC_BUS_NAME "i2c1"
  33. /* spi1 : PA1-SCK PA6-MISO PA12-MOSI */
  34. #define SS D1 /* Chip select pin of default spi */
  35. #define RTDUINO_DEFAULT_SPI_BUS_NAME "spi1"
  36. /* Serial : PC4-TX PC5-RX */
  37. #define RTDUINO_SERIAL2_DEVICE_NAME "uart3"
  38. #endif /* Pins_Arduino_h */