|
| 1 | + /* |
| 2 | + Copyright (c) 2014-2015 Arduino LLC. All right reserved. |
| 3 | + Copyright (c) 2016 Sandeep Mistry All right reserved. |
| 4 | + Copyright (c) 2018, Adafruit Industries (adafruit.com) |
| 5 | +
|
| 6 | + This library is free software; you can redistribute it and/or |
| 7 | + modify it under the terms of the GNU Lesser General Public |
| 8 | + License as published by the Free Software Foundation; either |
| 9 | + version 2.1 of the License, or (at your option) any later version. |
| 10 | + This library is distributed in the hope that it will be useful, |
| 11 | + but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
| 13 | + See the GNU Lesser General Public License for more details. |
| 14 | + You should have received a copy of the GNU Lesser General Public |
| 15 | + License along with this library; if not, write to the Free Software |
| 16 | + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA |
| 17 | +*/ |
| 18 | + |
| 19 | +#ifndef _VARIANT_MDBT50Q_RX_ |
| 20 | +#define _VARIANT_MDBT50Q_RX_ |
| 21 | + |
| 22 | +/** Master clock frequency */ |
| 23 | +#define VARIANT_MCK (64000000ul) |
| 24 | + |
| 25 | +#define USE_LFXO // Board uses 32khz crystal for LF |
| 26 | +// define USE_LFRC // Board uses RC for LF |
| 27 | + |
| 28 | +/*---------------------------------------------------------------------------- |
| 29 | + * Headers |
| 30 | + *----------------------------------------------------------------------------*/ |
| 31 | + |
| 32 | +#include "WVariant.h" |
| 33 | + |
| 34 | +#ifdef __cplusplus |
| 35 | +extern "C" |
| 36 | +{ |
| 37 | +#endif // __cplusplus |
| 38 | + |
| 39 | +// Number of pins defined in PinDescription array |
| 40 | +#define PINS_COUNT (3) |
| 41 | +#define NUM_DIGITAL_PINS (3) |
| 42 | +#define NUM_ANALOG_INPUTS (0) // A6 is used for battery, A7 is analog reference |
| 43 | +#define NUM_ANALOG_OUTPUTS (0) |
| 44 | + |
| 45 | +// LEDs |
| 46 | +#define PIN_LED1 (0) |
| 47 | +#define PIN_LED2 (1) |
| 48 | + |
| 49 | +#define LED_BUILTIN PIN_LED1 |
| 50 | +#define LED_CONN PIN_LED2 |
| 51 | + |
| 52 | +#define LED_RED PIN_LED1 |
| 53 | +#define LED_BLUE PIN_LED2 |
| 54 | + |
| 55 | +#define LED_STATE_ON 0 // State when LED is litted |
| 56 | + |
| 57 | +/* |
| 58 | + * Buttons |
| 59 | + */ |
| 60 | +#define PIN_BUTTON1 2 |
| 61 | + |
| 62 | +#define PIN_DFU 2 |
| 63 | + |
| 64 | +// Buttons |
| 65 | +/* |
| 66 | +#define PIN_BUTTON1 (2) |
| 67 | +#define PIN_BUTTON2 (3) |
| 68 | +#define PIN_BUTTON3 (4) |
| 69 | +#define PIN_BUTTON4 (5) |
| 70 | +*/ |
| 71 | + |
| 72 | +#define ADC_RESOLUTION 14 |
| 73 | + |
| 74 | +// Bad things happen if the serial pins aren't defined. Instead |
| 75 | +// define them with an invalid pin number |
| 76 | +// Serial |
| 77 | +#define PIN_SERIAL1_RX (3) |
| 78 | +#define PIN_SERIAL1_TX (3) |
| 79 | + |
| 80 | + |
| 81 | +#ifdef __cplusplus |
| 82 | +} |
| 83 | +#endif |
| 84 | + |
| 85 | +/*---------------------------------------------------------------------------- |
| 86 | + * Arduino objects - C++ only |
| 87 | + *----------------------------------------------------------------------------*/ |
| 88 | + |
| 89 | +#endif |
0 commit comments