Skip to content

Commit ab13cfd

Browse files
committed
add back raytac dongle with correct PID
1 parent 6c8c8d1 commit ab13cfd

File tree

3 files changed

+185
-0
lines changed

3 files changed

+185
-0
lines changed

boards.txt

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -496,3 +496,55 @@ particle_xenon.menu.debug.l2.build.debug_flags=-DCFG_DEBUG=2
496496
particle_xenon.menu.debug.l3=Level 3 (Segger SystemView)
497497
particle_xenon.menu.debug.l3.build.debug_flags=-DCFG_DEBUG=3
498498
particle_xenon.menu.debug.l3.build.sysview_flags=-DCFG_SYSVIEW=1
499+
500+
# ----------------------------------
501+
# Raytac MDBT50Q - RX
502+
# ----------------------------------
503+
mdbt50qrx.name=Raytac MDBT50Q-RX Dongle
504+
505+
# VID/PID for bootloader, Arduino + Circuitpython App
506+
mdbt50qrx.vid.0=0x239A
507+
mdbt50qrx.pid.0=0x810B
508+
mdbt50qrx.vid.1=0x239A
509+
mdbt50qrx.pid.1=0x010B
510+
mdbt50qrx.vid.2=0x239A
511+
mdbt50qrx.pid.2=0x810C
512+
513+
# Upload
514+
mdbt50qrx.bootloader.tool=bootburn
515+
mdbt50qrx.upload.tool=nrfutil
516+
mdbt50qrx.upload.protocol=nrfutil
517+
mdbt50qrx.upload.use_1200bps_touch=true
518+
mdbt50qrx.upload.wait_for_upload_port=true
519+
mdbt50qrx.upload.maximum_size=815104
520+
mdbt50qrx.upload.maximum_data_size=237568
521+
522+
# Build
523+
mdbt50qrx.build.mcu=cortex-m4
524+
mdbt50qrx.build.f_cpu=64000000
525+
mdbt50qrx.build.board=MDBT50Q_RX
526+
mdbt50qrx.build.core=nRF5
527+
mdbt50qrx.build.variant=raytac_mdbt50q_rx
528+
mdbt50qrx.build.usb_manufacturer="Raytac Corporation"
529+
mdbt50qrx.build.usb_product="Raytac MDBT50Q - RX"
530+
mdbt50qrx.build.extra_flags=-DNRF52840_XXAA {build.flags.usb}
531+
mdbt50qrx.build.ldscript=nrf52840_s140_v6.ld
532+
mdbt50qrx.build.vid=0x239A
533+
mdbt50qrx.build.pid=0x810B
534+
535+
# SofDevice Menu
536+
mdbt50qrx.menu.softdevice.s140v6=0.5.0 SoftDevice s140 6.1.1
537+
mdbt50qrx.menu.softdevice.s140v6.build.sd_name=s140
538+
mdbt50qrx.menu.softdevice.s140v6.build.sd_version=6.1.1
539+
mdbt50qrx.menu.softdevice.s140v6.build.sd_fwid=0x00B6
540+
541+
# Debug Menu
542+
mdbt50qrx.menu.debug.l0=Level 0 (Release)
543+
mdbt50qrx.menu.debug.l0.build.debug_flags=-DCFG_DEBUG=0
544+
mdbt50qrx.menu.debug.l1=Level 1 (Error Message)
545+
mdbt50qrx.menu.debug.l1.build.debug_flags=-DCFG_DEBUG=1
546+
mdbt50qrx.menu.debug.l2=Level 2 (Full Debug)
547+
mdbt50qrx.menu.debug.l2.build.debug_flags=-DCFG_DEBUG=2
548+
mdbt50qrx.menu.debug.l3=Level 3 (Segger SystemView)
549+
mdbt50qrx.menu.debug.l3.build.debug_flags=-DCFG_DEBUG=3
550+
mdbt50qrx.menu.debug.l3.build.sysview_flags=-DCFG_SYSVIEW=1
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
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+
11+
This library is distributed in the hope that it will be useful,
12+
but WITHOUT ANY WARRANTY; without even the implied warranty of
13+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
14+
See the GNU Lesser General Public License for more details.
15+
16+
You should have received a copy of the GNU Lesser General Public
17+
License along with this library; if not, write to the Free Software
18+
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19+
*/
20+
21+
#include "variant.h"
22+
23+
#include "wiring_constants.h"
24+
#include "wiring_digital.h"
25+
#include "nrf.h"
26+
27+
const uint32_t g_ADigitalPinMap[] =
28+
{
29+
// D0 .. D13
30+
45, // D0 is P1.13 (LED1)
31+
43, // D1 is P1.11 (LED2)
32+
15, // D2 is P0.15 (Button)
33+
};
34+
35+
void initVariant()
36+
{
37+
// LED1 & LED2
38+
pinMode(PIN_LED1, OUTPUT);
39+
ledOff(PIN_LED1);
40+
41+
pinMode(PIN_LED2, OUTPUT);
42+
ledOff(PIN_LED2);
43+
}
44+

variants/raytac_mdbt50q_rx/variant.h

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
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

Comments
 (0)