Skip to content
glennrub edited this page May 24, 2017 · 8 revisions

nRF51 / nRF52 MicroPython Port

Compile and Flash

By default PCA10040 (nrf52832) is used as compile target. To build issue the following command inside the nrf5/ folder:

 make
 make flash

Alternativly the target board could be defined:

 make BOARD=pca10040
 make flash

Compile and Flash with Bluetooth Stack

First prepare the bluetooth folder by downloading Bluetooth LE stacks and headers:

 ./drivers/bluetooth/download_ble_stack.sh

If the Bluetooth stacks has been downloaded, compile the target with the following command:

make BOARD=pca10040 SD=s132
make sd

The make sd will trigger a flash of the bluetooth stack before that application is flashed. Note that make sd will perform a full erase of the chip, which could cause 3rd party bootloaders to also be wiped.

Note: further tuning of features to include in bluetooth or even setting up the device to use REPL over Bluetooth can be configured in the bluetooth_conf.h.