pca20006.h 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. /* Copyright (c) 2014 Nordic Semiconductor. All Rights Reserved.
  2. *
  3. * The information contained herein is property of Nordic Semiconductor ASA.
  4. * Terms and conditions of usage are described in detail in NORDIC
  5. * SEMICONDUCTOR STANDARD SOFTWARE LICENSE AGREEMENT.
  6. *
  7. * Licensees are granted free, non-transferable use of the information. NO
  8. * WARRANTY of ANY KIND is provided. This heading must NOT be removed from
  9. * the file.
  10. *
  11. */
  12. #ifndef PCA20006_H
  13. #define PCA20006_H
  14. // LEDs and buttons definition for PCA20006 board (beacon)
  15. #define LEDS_NUMBER 3
  16. #define LED_RGB_RED 16
  17. #define LED_RGB_GREEN 12
  18. #define LED_RGB_BLUE 15
  19. #define BSP_LED_0 LED_RGB_RED
  20. #define BSP_LED_1 LED_RGB_GREEN
  21. #define BSP_LED_2 LED_RGB_BLUE
  22. #define LEDS_LIST { LED_RGB_RED, LED_RGB_GREEN, LED_RGB_BLUE}
  23. #define BSP_LED_0_MASK (1<<BSP_LED_0)
  24. #define BSP_LED_1_MASK (1<<BSP_LED_1)
  25. #define BSP_LED_2_MASK (1<<BSP_LED_2)
  26. #define LEDS_MASK (BSP_LED_0_MASK | BSP_LED_1_MASK | BSP_LED_2_MASK)
  27. #define LEDS_INV_MASK LEDS_MASK
  28. #define BUTTON_0 8
  29. #define BUTTON_1 18
  30. #define BUTTON_PULL NRF_GPIO_PIN_PULLUP
  31. #define BSP_BUTTON_0 BUTTON_0
  32. #define BSP_BUTTON_1 BUTTON_1
  33. #define BUTTONS_NUMBER 2
  34. #define BSP_BUTTON_0_MASK (1<<BUTTON_0)
  35. #define BSP_BUTTON_1_MASK (1<<BUTTON_1)
  36. #define BUTTONS_MASK (BSP_BUTTON_0_MASK | BSP_BUTTON_1_MASK)
  37. #define BUTTONS_LIST { BUTTON_0, BUTTON_1 }
  38. #define RX_PIN_NUMBER 24
  39. #define TX_PIN_NUMBER 9
  40. #define CTS_PIN_NUMBER 21
  41. #define RTS_PIN_NUMBER 11
  42. #define HWFC true
  43. // Low frequency clock source to be used by the SoftDevice
  44. #ifdef S210
  45. #define NRF_CLOCK_LFCLKSRC NRF_CLOCK_LFCLKSRC_XTAL_20_PPM
  46. #else
  47. #define NRF_CLOCK_LFCLKSRC {.source = NRF_CLOCK_LF_SRC_XTAL, .rc_ctiv = 0, .rc_temp_ctiv = 0, .xtal_accuracy=NRF_CLOCK_LF_XTAL_ACCURACY_20_PPM}
  48. #endif
  49. #endif