Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
arduino-nRF5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
arduino-nRF5
Commits
7da8ba75
Commit
7da8ba75
authored
Nov 25, 2020
by
Sandeep Mistry
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add conditional updates to new MDK files + update to new NRFxx_SERIES defines
parent
8882b99d
Changes
30
Show whitespace changes
Inline
Side-by-side
Showing
30 changed files
with
70 additions
and
22 deletions
+70
-22
cores/nRF5/SDK/components/device/nrf_erratas.h
cores/nRF5/SDK/components/device/nrf_erratas.h
+2
-0
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf51.S
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf51.S
+2
-0
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52.S
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52.S
+2
-0
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52805.S
.../nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52805.S
+2
-0
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52810.S
.../nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52810.S
+2
-0
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52811.S
.../nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52811.S
+2
-0
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52820.S
.../nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52820.S
+2
-0
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52833.S
.../nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52833.S
+2
-0
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52840.S
.../nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52840.S
+2
-0
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf5340_application.S
...omponents/toolchain/gcc/gcc_startup_nrf5340_application.S
+2
-0
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf5340_network.S
...DK/components/toolchain/gcc/gcc_startup_nrf5340_network.S
+2
-0
cores/nRF5/SDK/components/toolchain/system_nrf51.c
cores/nRF5/SDK/components/toolchain/system_nrf51.c
+2
-0
cores/nRF5/SDK/components/toolchain/system_nrf52.c
cores/nRF5/SDK/components/toolchain/system_nrf52.c
+2
-0
cores/nRF5/SDK/components/toolchain/system_nrf52805.c
cores/nRF5/SDK/components/toolchain/system_nrf52805.c
+2
-0
cores/nRF5/SDK/components/toolchain/system_nrf52810.c
cores/nRF5/SDK/components/toolchain/system_nrf52810.c
+2
-0
cores/nRF5/SDK/components/toolchain/system_nrf52811.c
cores/nRF5/SDK/components/toolchain/system_nrf52811.c
+2
-0
cores/nRF5/SDK/components/toolchain/system_nrf52820.c
cores/nRF5/SDK/components/toolchain/system_nrf52820.c
+2
-0
cores/nRF5/SDK/components/toolchain/system_nrf52833.c
cores/nRF5/SDK/components/toolchain/system_nrf52833.c
+2
-0
cores/nRF5/SDK/components/toolchain/system_nrf52840.c
cores/nRF5/SDK/components/toolchain/system_nrf52840.c
+2
-0
cores/nRF5/SDK/components/toolchain/system_nrf5340_application.c
...RF5/SDK/components/toolchain/system_nrf5340_application.c
+2
-0
cores/nRF5/SDK/components/toolchain/system_nrf5340_network.c
cores/nRF5/SDK/components/toolchain/system_nrf5340_network.c
+2
-0
cores/nRF5/Uart.cpp
cores/nRF5/Uart.cpp
+4
-4
cores/nRF5/wiring_analog.h
cores/nRF5/wiring_analog.h
+3
-1
cores/nRF5/wiring_analog_nRF51.c
cores/nRF5/wiring_analog_nRF51.c
+2
-4
cores/nRF5/wiring_analog_nRF52.c
cores/nRF5/wiring_analog_nRF52.c
+2
-4
libraries/Wire/Wire.h
libraries/Wire/Wire.h
+4
-4
libraries/Wire/Wire_nRF51.cpp
libraries/Wire/Wire_nRF51.cpp
+3
-1
libraries/Wire/Wire_nRF52.cpp
libraries/Wire/Wire_nRF52.cpp
+3
-1
variants/Generic/variant.h
variants/Generic/variant.h
+4
-2
variants/Waveshare_BLE400/variant.h
variants/Waveshare_BLE400/variant.h
+3
-1
No files found.
cores/nRF5/SDK/components/device/nrf_erratas.h
View file @
7da8ba75
...
@@ -43,7 +43,9 @@ NRF_MDK_VERSION_ASSERT_AT_LEAST(8,34,0);
...
@@ -43,7 +43,9 @@ NRF_MDK_VERSION_ASSERT_AT_LEAST(8,34,0);
#include "nrf51_erratas.h"
#include "nrf51_erratas.h"
#include "nrf52_erratas.h"
#include "nrf52_erratas.h"
#include "nrf53_erratas.h"
#include "nrf53_erratas.h"
#ifndef ARDUINO
#include "nrf91_erratas.h"
#include "nrf91_erratas.h"
#endif
/*lint --flb "Leave library region" */
/*lint --flb "Leave library region" */
...
...
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf51.S
View file @
7da8ba75
#if defined(ARDUINO) && defined(NRF51)
/*
/*
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
...
@@ -298,3 +299,4 @@ Default_Handler:
...
@@ -298,3 +299,4 @@ Default_Handler:
IRQ
SWI5_IRQHandler
IRQ
SWI5_IRQHandler
.
end
.
end
#
endif
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52.S
View file @
7da8ba75
#if defined(ARDUINO) && defined(NRF52)
/*
/*
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
...
@@ -404,3 +405,4 @@ Default_Handler:
...
@@ -404,3 +405,4 @@ Default_Handler:
IRQ
FPU_IRQHandler
IRQ
FPU_IRQHandler
.
end
.
end
#
endif
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52805.S
View file @
7da8ba75
#if defined(ARDUINO) && defined(NRF52805_XXAA)
/*
/*
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
...
@@ -391,3 +392,4 @@ Default_Handler:
...
@@ -391,3 +392,4 @@ Default_Handler:
IRQ
SWI5_IRQHandler
IRQ
SWI5_IRQHandler
.
end
.
end
#
endif
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52810.S
View file @
7da8ba75
#if defined(ARDUINO) && defined(NRF52810_XXAA)
/*
/*
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
...
@@ -417,3 +418,4 @@ Default_Handler:
...
@@ -417,3 +418,4 @@ Default_Handler:
IRQ
PDM_IRQHandler
IRQ
PDM_IRQHandler
.
end
.
end
#
endif
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52811.S
View file @
7da8ba75
#if defined(ARDUINO) && defined(NRF52811_XXAA)
/*
/*
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
...
@@ -394,3 +395,4 @@ Default_Handler:
...
@@ -394,3 +395,4 @@ Default_Handler:
IRQ
PDM_IRQHandler
IRQ
PDM_IRQHandler
.
end
.
end
#
endif
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52820.S
View file @
7da8ba75
#if defined(ARDUINO) && defined(NRF52820_XXAA)
/*
/*
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
...
@@ -393,3 +394,4 @@ Default_Handler:
...
@@ -393,3 +394,4 @@ Default_Handler:
IRQ
USBD_IRQHandler
IRQ
USBD_IRQHandler
.
end
.
end
#
endif
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52833.S
View file @
7da8ba75
#if defined(ARDUINO) && defined(NRF52833_XXAA)
/*
/*
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
...
@@ -408,3 +409,4 @@ Default_Handler:
...
@@ -408,3 +409,4 @@ Default_Handler:
IRQ
SPIM3_IRQHandler
IRQ
SPIM3_IRQHandler
.
end
.
end
#
endif
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf52840.S
View file @
7da8ba75
#if defined(ARDUINO) && defined(NRF52840_XXAA)
/*
/*
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
...
@@ -410,3 +411,4 @@ Default_Handler:
...
@@ -410,3 +411,4 @@ Default_Handler:
IRQ
SPIM3_IRQHandler
IRQ
SPIM3_IRQHandler
.
end
.
end
#
endif
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf5340_application.S
View file @
7da8ba75
#if defined(ARDUINO) && defined(NRF5340_XXAA) && defined(NRF_APPLICATION)
/*
/*
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
...
@@ -543,3 +544,4 @@ Default_Handler:
...
@@ -543,3 +544,4 @@ Default_Handler:
IRQ
CRYPTOCELL_IRQHandler
IRQ
CRYPTOCELL_IRQHandler
.
end
.
end
#
endif
cores/nRF5/SDK/components/toolchain/gcc/gcc_startup_nrf5340_network.S
View file @
7da8ba75
#if defined(ARDUINO) && defined(NRF5340_XXAA) && defined(NRF_NETWORK)
/*
/*
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
Copyright
(
c
)
2009
-
2020
ARM
Limited
.
All
rights
reserved
.
...
@@ -404,3 +405,4 @@ Default_Handler:
...
@@ -404,3 +405,4 @@ Default_Handler:
IRQ
SWI3_IRQHandler
IRQ
SWI3_IRQHandler
.
end
.
end
#
endif
cores/nRF5/SDK/components/toolchain/system_nrf51.c
View file @
7da8ba75
...
@@ -27,6 +27,7 @@ NOTICE: This file has been modified by Nordic Semiconductor ASA.
...
@@ -27,6 +27,7 @@ NOTICE: This file has been modified by Nordic Semiconductor ASA.
#include <stdbool.h>
#include <stdbool.h>
#include "nrf.h"
#include "nrf.h"
#include "nrf_erratas.h"
#include "nrf_erratas.h"
#if defined(ARDUINO) && defined(NRF51_SERIES)
#include "system_nrf51.h"
#include "system_nrf51.h"
/*lint ++flb "Enter library region" */
/*lint ++flb "Enter library region" */
...
@@ -87,3 +88,4 @@ void SystemInit(void)
...
@@ -87,3 +88,4 @@ void SystemInit(void)
}
}
/*lint --flb "Leave library region" */
/*lint --flb "Leave library region" */
#endif
cores/nRF5/SDK/components/toolchain/system_nrf52.c
View file @
7da8ba75
...
@@ -28,6 +28,7 @@ NOTICE: This file has been modified by Nordic Semiconductor ASA.
...
@@ -28,6 +28,7 @@ NOTICE: This file has been modified by Nordic Semiconductor ASA.
#include "nrf.h"
#include "nrf.h"
#include "nrf_peripherals.h"
#include "nrf_peripherals.h"
#include "nrf_erratas.h"
#include "nrf_erratas.h"
#if defined(ARDUINO) && defined(NRF52_SERIES)
#include "system_nrf52.h"
#include "system_nrf52.h"
#define __SYSTEM_CLOCK_64M (64000000UL)
#define __SYSTEM_CLOCK_64M (64000000UL)
...
@@ -314,3 +315,4 @@ void SystemInit(void)
...
@@ -314,3 +315,4 @@ void SystemInit(void)
SystemCoreClockUpdate
();
SystemCoreClockUpdate
();
}
}
#endif
cores/nRF5/SDK/components/toolchain/system_nrf52805.c
View file @
7da8ba75
...
@@ -30,4 +30,6 @@ POSSIBILITY OF SUCH DAMAGE.
...
@@ -30,4 +30,6 @@ POSSIBILITY OF SUCH DAMAGE.
*/
*/
#ifndef ARDUINO
#include "system_nrf52.c"
#include "system_nrf52.c"
#endif
cores/nRF5/SDK/components/toolchain/system_nrf52810.c
View file @
7da8ba75
...
@@ -30,4 +30,6 @@ POSSIBILITY OF SUCH DAMAGE.
...
@@ -30,4 +30,6 @@ POSSIBILITY OF SUCH DAMAGE.
*/
*/
#ifndef ARDUINO
#include "system_nrf52.c"
#include "system_nrf52.c"
#endif
cores/nRF5/SDK/components/toolchain/system_nrf52811.c
View file @
7da8ba75
...
@@ -30,4 +30,6 @@ POSSIBILITY OF SUCH DAMAGE.
...
@@ -30,4 +30,6 @@ POSSIBILITY OF SUCH DAMAGE.
*/
*/
#ifndef ARDUINO
#include "system_nrf52.c"
#include "system_nrf52.c"
#endif
cores/nRF5/SDK/components/toolchain/system_nrf52820.c
View file @
7da8ba75
...
@@ -30,4 +30,6 @@ POSSIBILITY OF SUCH DAMAGE.
...
@@ -30,4 +30,6 @@ POSSIBILITY OF SUCH DAMAGE.
*/
*/
#ifndef ARDUINO
#include "system_nrf52.c"
#include "system_nrf52.c"
#endif
cores/nRF5/SDK/components/toolchain/system_nrf52833.c
View file @
7da8ba75
...
@@ -30,4 +30,6 @@ POSSIBILITY OF SUCH DAMAGE.
...
@@ -30,4 +30,6 @@ POSSIBILITY OF SUCH DAMAGE.
*/
*/
#ifndef ARDUINO
#include "system_nrf52.c"
#include "system_nrf52.c"
#endif
cores/nRF5/SDK/components/toolchain/system_nrf52840.c
View file @
7da8ba75
...
@@ -30,4 +30,6 @@ POSSIBILITY OF SUCH DAMAGE.
...
@@ -30,4 +30,6 @@ POSSIBILITY OF SUCH DAMAGE.
*/
*/
#ifndef ARDUINO
#include "system_nrf52.c"
#include "system_nrf52.c"
#endif
cores/nRF5/SDK/components/toolchain/system_nrf5340_application.c
View file @
7da8ba75
#if defined(ARDUINO) && defined(NRF5340_XXAA) && defined(NRF_APPLICATION)
/*
/*
Copyright (c) 2009-2020 ARM Limited. All rights reserved.
Copyright (c) 2009-2020 ARM Limited. All rights reserved.
...
@@ -248,3 +249,4 @@ void SystemInit(void)
...
@@ -248,3 +249,4 @@ void SystemInit(void)
}
}
/*lint --flb "Leave library region" */
/*lint --flb "Leave library region" */
#endif
cores/nRF5/SDK/components/toolchain/system_nrf5340_network.c
View file @
7da8ba75
#if defined(ARDUINO) && defined(NRF5340_XXAA) && defined(NRF_NETWORK)
/*
/*
Copyright (c) 2009-2020 ARM Limited. All rights reserved.
Copyright (c) 2009-2020 ARM Limited. All rights reserved.
...
@@ -91,3 +92,4 @@ void SystemInit(void)
...
@@ -91,3 +92,4 @@ void SystemInit(void)
}
}
/*lint --flb "Leave library region" */
/*lint --flb "Leave library region" */
#endif
cores/nRF5/Uart.cpp
View file @
7da8ba75
...
@@ -225,9 +225,9 @@ size_t Uart::write(const uint8_t data)
...
@@ -225,9 +225,9 @@ size_t Uart::write(const uint8_t data)
return
1
;
return
1
;
}
}
#if defined(NRF52)
#if defined(NRF52
_SERIES
)
#define NRF_UART0_IRQn UARTE0_UART0_IRQn
#define NRF_UART0_IRQn UARTE0_UART0_IRQn
#elif defined(NRF51)
#elif defined(NRF51
_SERIES
)
#define NRF_UART0_IRQn UART0_IRQn
#define NRF_UART0_IRQn UART0_IRQn
#endif
#endif
...
@@ -237,7 +237,7 @@ size_t Uart::write(const uint8_t data)
...
@@ -237,7 +237,7 @@ size_t Uart::write(const uint8_t data)
Uart
Serial
(
NRF_UART0
,
NRF_UART0_IRQn
,
PIN_SERIAL_RX
,
PIN_SERIAL_TX
);
Uart
Serial
(
NRF_UART0
,
NRF_UART0_IRQn
,
PIN_SERIAL_RX
,
PIN_SERIAL_TX
);
#endif
#endif
#if defined(NRF52)
#if defined(NRF52
_SERIES
)
extern
"C"
extern
"C"
{
{
void
UARTE0_UART0_IRQHandler
()
void
UARTE0_UART0_IRQHandler
()
...
@@ -245,7 +245,7 @@ extern "C"
...
@@ -245,7 +245,7 @@ extern "C"
Serial
.
IrqHandler
();
Serial
.
IrqHandler
();
}
}
}
}
#elif defined(NRF51)
#elif defined(NRF51
_SERIES
)
extern
"C"
extern
"C"
{
{
void
UART0_IRQHandler
()
void
UART0_IRQHandler
()
...
...
cores/nRF5/wiring_analog.h
View file @
7da8ba75
...
@@ -25,10 +25,12 @@
...
@@ -25,10 +25,12 @@
extern
"C"
{
extern
"C"
{
#endif
#endif
#include "nrf.h"
/*
/*
* \brief nRF51 and nRF52 have different reference options.
* \brief nRF51 and nRF52 have different reference options.
*/
*/
#if
def NRF52
#if
defined(NRF52_SERIES)
typedef
enum
_eAnalogReference
typedef
enum
_eAnalogReference
{
{
AR_DEFAULT
,
AR_DEFAULT
,
...
...
cores/nRF5/wiring_analog_nRF51.c
View file @
7da8ba75
...
@@ -17,13 +17,11 @@
...
@@ -17,13 +17,11 @@
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
*/
#ifdef NRF51
#include "nrf.h"
#include "Arduino.h"
#include "Arduino.h"
#include "wiring_private.h"
#include "wiring_private.h"
#if defined(NRF51_SERIES)
#ifdef __cplusplus
#ifdef __cplusplus
extern
"C"
{
extern
"C"
{
#endif
#endif
...
...
cores/nRF5/wiring_analog_nRF52.c
View file @
7da8ba75
...
@@ -17,13 +17,11 @@
...
@@ -17,13 +17,11 @@
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
*/
#ifdef NRF52
#include "nrf.h"
#include "Arduino.h"
#include "Arduino.h"
#include "wiring_private.h"
#include "wiring_private.h"
#if defined(NRF52_SERIES)
#ifdef __cplusplus
#ifdef __cplusplus
extern
"C"
{
extern
"C"
{
#endif
#endif
...
...
libraries/Wire/Wire.h
View file @
7da8ba75
...
@@ -34,7 +34,7 @@
...
@@ -34,7 +34,7 @@
class
TwoWire
:
public
Stream
class
TwoWire
:
public
Stream
{
{
public:
public:
#if
def NRF52
#if
defined(NRF52_SERIES)
TwoWire
(
NRF_TWIM_Type
*
p_twim
,
NRF_TWIS_Type
*
p_twis
,
IRQn_Type
IRQn
,
uint8_t
pinSDA
,
uint8_t
pinSCL
);
TwoWire
(
NRF_TWIM_Type
*
p_twim
,
NRF_TWIS_Type
*
p_twis
,
IRQn_Type
IRQn
,
uint8_t
pinSDA
,
uint8_t
pinSCL
);
#else
#else
TwoWire
(
NRF_TWI_Type
*
p_twi
,
uint8_t
pinSDA
,
uint8_t
pinSCL
);
TwoWire
(
NRF_TWI_Type
*
p_twi
,
uint8_t
pinSDA
,
uint8_t
pinSCL
);
...
@@ -43,7 +43,7 @@ class TwoWire : public Stream
...
@@ -43,7 +43,7 @@ class TwoWire : public Stream
void
setPins
(
uint8_t
pinSDA
,
uint8_t
pinSCL
);
void
setPins
(
uint8_t
pinSDA
,
uint8_t
pinSCL
);
#endif // ARDUINO_GENERIC
#endif // ARDUINO_GENERIC
void
begin
();
void
begin
();
#if
def NRF52
#if
defined(NRF52_SERIES)
void
begin
(
uint8_t
);
void
begin
(
uint8_t
);
#endif
#endif
void
end
();
void
end
();
...
@@ -63,7 +63,7 @@ class TwoWire : public Stream
...
@@ -63,7 +63,7 @@ class TwoWire : public Stream
virtual
int
read
(
void
);
virtual
int
read
(
void
);
virtual
int
peek
(
void
);
virtual
int
peek
(
void
);
virtual
void
flush
(
void
);
virtual
void
flush
(
void
);
#if
def NRF52
#if
defined(NRF52_SERIES)
void
onReceive
(
void
(
*
)(
int
));
void
onReceive
(
void
(
*
)(
int
));
void
onRequest
(
void
(
*
)(
void
));
void
onRequest
(
void
(
*
)(
void
));
void
onService
(
void
);
void
onService
(
void
);
...
@@ -72,7 +72,7 @@ class TwoWire : public Stream
...
@@ -72,7 +72,7 @@ class TwoWire : public Stream
using
Print
::
write
;
using
Print
::
write
;
private:
private:
#if
def NRF52
#if
defined(NRF52_SERIES)
NRF_TWIM_Type
*
_p_twim
;
NRF_TWIM_Type
*
_p_twim
;
NRF_TWIS_Type
*
_p_twis
;
NRF_TWIS_Type
*
_p_twis
;
#else
#else
...
...
libraries/Wire/Wire_nRF51.cpp
View file @
7da8ba75
...
@@ -18,7 +18,9 @@
...
@@ -18,7 +18,9 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
*/
#ifdef NRF51
#include "nrf.h"
#if defined(NRF51_SERIES)
extern
"C"
{
extern
"C"
{
#include <string.h>
#include <string.h>
...
...
libraries/Wire/Wire_nRF52.cpp
View file @
7da8ba75
...
@@ -18,7 +18,9 @@
...
@@ -18,7 +18,9 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
*/
#ifdef NRF52
#include "nrf.h"
#if defined(NRF52_SERIES)
extern
"C"
{
extern
"C"
{
#include <string.h>
#include <string.h>
...
...
variants/Generic/variant.h
View file @
7da8ba75
...
@@ -17,8 +17,10 @@
...
@@ -17,8 +17,10 @@
#ifndef _VARIANT_GENERIC_
#ifndef _VARIANT_GENERIC_
#define _VARIANT_GENERIC_
#define _VARIANT_GENERIC_
#include "nrf.h"
/** Master clock frequency */
/** Master clock frequency */
#if
def NRF52
#if
defined(NRF52_SERIES)
#define VARIANT_MCK (64000000ul)
#define VARIANT_MCK (64000000ul)
#else
#else
#define VARIANT_MCK (16000000ul)
#define VARIANT_MCK (16000000ul)
...
@@ -61,7 +63,7 @@ static const uint8_t A2 = PIN_A2 ;
...
@@ -61,7 +63,7 @@ static const uint8_t A2 = PIN_A2 ;
static
const
uint8_t
A3
=
PIN_A3
;
static
const
uint8_t
A3
=
PIN_A3
;
static
const
uint8_t
A4
=
PIN_A4
;
static
const
uint8_t
A4
=
PIN_A4
;
static
const
uint8_t
A5
=
PIN_A5
;
static
const
uint8_t
A5
=
PIN_A5
;
#if
def NRF52
#if
defined(NRF52_SERIES)
#define ADC_RESOLUTION 14
#define ADC_RESOLUTION 14
#else
#else
#define ADC_RESOLUTION 10
#define ADC_RESOLUTION 10
...
...
variants/Waveshare_BLE400/variant.h
View file @
7da8ba75
...
@@ -17,8 +17,10 @@
...
@@ -17,8 +17,10 @@
#ifndef _VARIANT_GENERIC_
#ifndef _VARIANT_GENERIC_
#define _VARIANT_GENERIC_
#define _VARIANT_GENERIC_
#include "nrf.h"
/** Master clock frequency */
/** Master clock frequency */
#if
def NRF52
#if
defined(NRF52_SERIES)
#define VARIANT_MCK (64000000ul)
#define VARIANT_MCK (64000000ul)
#else
#else
#define VARIANT_MCK (16000000ul)
#define VARIANT_MCK (16000000ul)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment