File tree Expand file tree Collapse file tree 2 files changed +5
-19
lines changed
targets/TARGET_NORDIC/TARGET_NRF5/TARGET_MCU_NRF51822_UNIFIED/TARGET_DELTA_DFCM_NNN50 Expand file tree Collapse file tree 2 files changed +5
-19
lines changed Original file line number Diff line number Diff line change 18
18
#ifndef MBED_DEVICE_H
19
19
#define MBED_DEVICE_H
20
20
21
-
22
-
23
-
24
-
25
-
26
-
27
-
28
-
29
-
30
-
31
-
32
-
33
-
34
-
35
-
36
21
#include "objects.h"
37
22
38
23
#endif
Original file line number Diff line number Diff line change 15
15
*/
16
16
17
17
#include "cmsis.h"
18
+ #include "PinNames.h"
18
19
19
20
void mbed_sdk_init ()
20
21
{
21
22
char * debug_date = __DATE__ ;
22
23
char * debug_time = __TIME__ ;
23
24
24
25
// Default RF switch setting, pull p19 to low and p28 to high for turning antenna switch to BLE radiated path
25
- NRF_GPIO -> PIN_CNF [19 ] = (GPIO_PIN_CNF_SENSE_Disabled << GPIO_PIN_CNF_SENSE_Pos )
26
+ NRF_GPIO -> PIN_CNF [p19 ] = (GPIO_PIN_CNF_SENSE_Disabled << GPIO_PIN_CNF_SENSE_Pos )
26
27
| (GPIO_PIN_CNF_DRIVE_S0S1 << GPIO_PIN_CNF_DRIVE_Pos )
27
28
| (GPIO_PIN_CNF_PULL_Disabled << GPIO_PIN_CNF_PULL_Pos )
28
29
| (GPIO_PIN_CNF_INPUT_Disconnect << GPIO_PIN_CNF_INPUT_Pos )
29
30
| (GPIO_PIN_CNF_DIR_Output << GPIO_PIN_CNF_DIR_Pos );
30
- NRF_GPIO -> PIN_CNF [28 ] = (GPIO_PIN_CNF_SENSE_Disabled << GPIO_PIN_CNF_SENSE_Pos )
31
+ NRF_GPIO -> PIN_CNF [p28 ] = (GPIO_PIN_CNF_SENSE_Disabled << GPIO_PIN_CNF_SENSE_Pos )
31
32
| (GPIO_PIN_CNF_DRIVE_S0S1 << GPIO_PIN_CNF_DRIVE_Pos )
32
33
| (GPIO_PIN_CNF_PULL_Disabled << GPIO_PIN_CNF_PULL_Pos )
33
34
| (GPIO_PIN_CNF_INPUT_Disconnect << GPIO_PIN_CNF_INPUT_Pos )
@@ -40,8 +41,8 @@ void mbed_sdk_init()
40
41
NRF_CLOCK -> XTALFREQ = 0x00 ;
41
42
NRF_CLOCK -> EVENTS_HFCLKSTARTED = 0 ;
42
43
NRF_CLOCK -> TASKS_HFCLKSTART = 1 ;
43
- while (NRF_CLOCK -> EVENTS_HFCLKSTARTED == 0 )
44
- { // Do nothing.
44
+ while (NRF_CLOCK -> EVENTS_HFCLKSTARTED == 0 ) {
45
+ // Do nothing.
45
46
}
46
47
47
48
}
You can’t perform that action at this time.
0 commit comments