出自flip the world 檢視Nordic, nRF52 Preview DK的原始碼 頁面討論 閱讀檢視原始碼檢視歷史 ←Nordic, nRF52 Preview DK 您沒有權限執行編輯此頁面,由於以下原因: 您請求的操作只有這個群組的使用者能使用:使用者 您可以檢視並複製此頁面的原始碼。 The '''nRF52 Preview DK''' is Nordic's development kit for the nRF52832. These notes cover the SDK, JLink, the GCC toolchain, and programming the board. == Prepare == === Install SDK === # Get latest SDK from https://developer.nordicsemi.com/nRF52_SDK/nRF52_SDK_v0.x.x/ (ex. nRF52_SDK_0.9.2_dbc28c9.zip) # Get SDK with FreeRTOS example from http://developer.nordicsemi.com/nRF5_SDK/nRF5_SDK_v11.x.x/ (nRF5_SDK_11.0.0-2.alpha_bc3f6a0.zip) # Edit ./components/toolchain/gcc/Makefile.posix to fit your toolchain setting if necessary === Install JLink === # Download "Software and Document pack" from https://www.segger.com/jlink-software.html according your platform (ex. x86_64) # decompress and make a symbolic to /opt/SEGGER/JLink ## ln -s ~/Downloads/JLink_Linux_V510c_x86_64 /opt/SEGGER/JLink === Toolchain === sudo add-apt-repository ppa:terry.guo/gcc-arm-embedded sudo apt-get update sudo apt-get install gcc-arm-none-eabi === Programming === <syntaxhighlight lang="bash"> 1. Softdevice ex. sudo /home/tommy/projects/mbed/nRF52/NrfJProg_7_7_0_Linux/nrfjprog --family NRF52 --program ~/projects/mbed/nRF52/s132_nrf52_1.0.0-3.alpha/s132_nrf52_1.0.0-3.alpha_softdevice.hex 2. change dir to example ex. sudo ~/projects/mbed/nRF52/NrfJProg_7_7_0_Linux/nrfjprog --sectorerase --family nRF52 --program _build/nrf52832_xxaa_s132.hex 3. sudo ~/projects/mbed/nRF52/NrfJProg_7_7_0_Linux/nrfjprog --sectorerase --family nRF52 --program _build/nrf52832_xxaa.hex 4. power recycle to take effect </syntaxhighlight> <pre> tommy@tommy-HP-EliteBook-Folio-1040-G2:~/projects/mbed/nordic/nRF52/nRF5_SDK_11.0.0_89a8197/examples/ble_peripheral/ble_app_beacon/pca10040/s132/armgcc$ sudo ~/projects/mbed/nordic/tools/nrfjprog --sectorerase --family nRF52 --program ~/projects/mbed/nordic/nRF52/s132/s132_nrf52_1.0.0-3.alpha_softdevice.hex Parsing hex file. Erasing page at address 0x0. Erasing page at address 0x3000. Erasing page at address 0x4000. Erasing page at address 0x5000. Erasing page at address 0x6000. Erasing page at address 0x7000. Erasing page at address 0x8000. Erasing page at address 0x9000. Erasing page at address 0xA000. Erasing page at address 0xB000. Erasing page at address 0xC000. Erasing page at address 0xD000. Erasing page at address 0xE000. Erasing page at address 0xF000. Erasing page at address 0x10000. Erasing page at address 0x11000. Erasing page at address 0x12000. Erasing page at address 0x13000. Erasing page at address 0x14000. Erasing page at address 0x15000. Erasing page at address 0x16000. Erasing page at address 0x17000. Erasing page at address 0x18000. Erasing page at address 0x19000. Erasing page at address 0x1A000. Erasing page at address 0x1B000. Erasing page at address 0x1C000. Erasing page at address 0x1D000. Applying system reset. Checking that the area to write is not protected. Programing device. tommy@tommy-HP-EliteBook-Folio-1040-G2:~/projects/mbed/nordic/nRF52/nRF5_SDK_11.0.0_89a8197/examples/ble_peripheral/ble_app_beacon/pca10040/s132/armgcc$ sudo ~/projects/mbed/nordic/tools/nrfjprog --sectorerase --family nRF52 --program _build/nrf52832_xxaa_s132.hex Parsing hex file. Erasing page at address 0x1C000. Erasing page at address 0x1D000. Erasing page at address 0x1E000. Erasing page at address 0x1F000. Applying system reset. Checking that the area to write is not protected. Programing device. </pre> === Console, UART === [[File:nrf52_cp2105.jpg|border|350px|nRF52 preview DK + CP2105]] * cp2105 in host <pre> nRF52 Host ----------------- RX TX CTS RTS TX RX RTS CTS </pre> === Tool, nRF Connect === [[File:Nrf-connect.png|border|350px|nRF Connect v1.0]] === App source === * git clone https://github.com/NordicSemiconductor/Android-nRF-Toolbox === SDK === * git clone https://bitbucket.org/tommy0804/nrf52 (based on nRF52_SDK_0.9.2_dbc28c9.zip) [[Category:Boards and SoCs]] 返回到「Nordic, nRF52 Preview DK」。