board.h 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. /*
  2. * board.h
  3. *
  4. * Created on:
  5. * Author:
  6. */
  7. #ifndef BOARD_H_
  8. #define BOARD_H_
  9. //#define XPRESSO_812_BOARD // For the LPC812 Max board
  10. //#define XPRESSO_824_BOARD // For the LPC824 Max board
  11. //#define XPRESSO_845_BOARD // For the LPC845 Max board
  12. //#define XPRESSO_802_BOARD // For the LPC802 Max board
  13. #define XPRESSO_804_BOARD // For the LPC804 Max board
  14. // LPC812 Max board
  15. #ifdef XPRESSO_812_BOARD
  16. #define RED (1<<7)
  17. #define BLUE (1<<16)
  18. #define GREEN (1<<17)
  19. #define red_led_port P0_7
  20. #define blue_led_port P0_16
  21. #define green_led_port P0_17
  22. #define PCF8591_address 0x4F // The on-board ADC/DAC default I2C address
  23. #define PCA9672_address 0x23 // The on-board GPIO Expander default I2C address
  24. #define TARGET_TX P0_6 // For the VCOM serial port
  25. #define TARGET_RX P0_1 // For the VCOM serial port
  26. #define NUM_IOCON_P0_SLOTS 19 // For looping through the pad controls
  27. #endif
  28. // LPC824 Max board
  29. #ifdef XPRESSO_824_BOARD
  30. #define RED (1<<12)
  31. #define BLUE (1<<27)
  32. #define GREEN (1<<16)
  33. #define red_led_port P0_12
  34. #define blue_led_port P0_27
  35. #define green_led_port P0_16
  36. #define TARGET_TX P0_7 // For the VCOM serial port
  37. #define TARGET_RX P0_18 // For the VCOM serial port
  38. #define NUM_IOCON_P0_SLOTS 31 // For looping through the pad controls
  39. #endif
  40. // LPC845 Max board
  41. #ifdef XPRESSO_845_BOARD
  42. #define LED_RED P0_12
  43. #define LED_BLUE P1_15
  44. #define LED_GREEN P0_0
  45. #define TARGET_TX P1_17 // For the VCOM serial port
  46. #define TARGET_RX P1_16 // For the VCOM serial port
  47. #define DACOUT0_PIN PIO0_17
  48. #define DACOUT1_PIN PIO0_29
  49. #define AUDIO_AMP_ENABLE_PORT PORT1
  50. #define AUDIO_AMP_ENABLE_PIN Bit11
  51. #define NUM_IOCON_P0_SLOTS 56 // For looping through the pad controls
  52. #endif
  53. // LPC802 MAX board
  54. #ifdef XPRESSO_802_BOARD
  55. #define LED_BLUE P0_8
  56. #define LED_RED P0_9
  57. #define LED_GREEN P0_12
  58. #define TARGET_TX P0_4 // For the VCOM serial port
  59. #define TARGET_RX P0_0 // For the VCOM serial port
  60. #endif
  61. // LPC804 MAX board
  62. #ifdef XPRESSO_804_BOARD
  63. #define LED_BLUE P0_11
  64. #define LED_RED P0_13
  65. #define LED_GREEN P0_12
  66. #define TARGET_TX P0_4 // For the VCOM serial port
  67. #define TARGET_RX P0_0 // For the VCOM serial port
  68. #define TARTET_I2CSCL P0_14
  69. #define TARTET_I2CSDA P0_7
  70. #define DACOUT_PIN PIO0_19
  71. #endif
  72. #endif /* BOARD_H_ */