board.h 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. /*
  2. ChibiOS - Copyright (C) 2017 Theodore Ateba
  3. Licensed under the Apache License, Version 2.0 (the "License");
  4. you may not use this file except in compliance with the License.
  5. You may obtain a copy of the License at
  6. http://www.apache.org/licenses/LICENSE-2.0
  7. Unless required by applicable law or agreed to in writing, software
  8. distributed under the License is distributed on an "AS IS" BASIS,
  9. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  10. See the License for the specific language governing permissions and
  11. limitations under the License.
  12. */
  13. #ifndef BOARD_H
  14. #define BOARD_H
  15. /*
  16. * Setup for the Mattair board.
  17. */
  18. /*
  19. * Board identifier.
  20. */
  21. #define BOARD_MT_DB_X4
  22. #define BOARD_NAME "MT-DB-X4 board"
  23. /* All inputs with pull-ups */
  24. #define VAL_DDRA 0x00
  25. #define VAL_PORTA 0xFF
  26. /* All inputs. */
  27. #define VAL_DDRB 0x00
  28. #define VAL_PORTB 0xFF
  29. /* All inputs with pull-ups */
  30. #define VAL_DDRC 0x00
  31. #define VAL_PORTC 0xFF
  32. /* All inputs with pull-ups */
  33. #define VAL_DDRD 0x00
  34. #define VAL_PORTD 0xFF
  35. /* All inputs except PE1 wich has a LED connected. */
  36. #define VAL_DDRE 0x02
  37. #define VAL_PORTE 0xFF
  38. /* All inputs with pull-ups */
  39. #define VAL_DDRF 0x00
  40. #define VAL_PORTF 0xFF
  41. /* All inputs with pull-ups */
  42. #define VAL_DDRG 0x00
  43. #define VAL_PORTG 0xFF
  44. /* All inputs with pull-ups */
  45. #define VAL_DDRH 0x00
  46. #define VAL_PORTH 0xFF
  47. /* All inputs with pull-ups */
  48. #define VAL_DDRJ 0x00
  49. #define VAL_PORTJ 0xFF
  50. /* All inputs with pull-ups */
  51. #define VAL_DDRK 0x00
  52. #define VAL_PORTK 0xFF
  53. /* All inputs with pull-ups */
  54. #define VAL_DDRL 0x00
  55. #define VAL_PORTL 0xFF
  56. #define PORTE_LED 1
  57. #if !defined(_FROM_ASM_)
  58. #ifdef __cplusplus
  59. extern "C" {
  60. #endif
  61. void boardInit(void);
  62. #ifdef __cplusplus
  63. }
  64. #endif
  65. #endif /* _FROM_ASM_ */
  66. #endif /* BOARD_H */