Article Directory
related articles
1. "[Nordic] nRF52810 OTA upgrade (1)-DFU environment setup"
2. "[Nordic] nRF52810 OTA upgrade (2)-How to use DFU"
3. "[Nordic] nRF52810 OTA upgrade (3)-DFU theoretical analysis 》
1. Tool list
- gcc-arm-none-eabi compilation environment: GCC compilation environment
https://developer.arm.com/open-source/gnu-toolchain/gnu-rm/downloads - Cygwin platform (Linux command line for win version)
http://cygwin.com/install.html - micro-ecc-master source code
https://github.com/kmackay/micro-ecc - Python installation file
https://www.python.org/downloads/
2. GCC compiler installation
Secure DFUThe micro-ecc library is required for signature verification. Yes , it needs micro_ecc_lib_nrf52.lib
to be generated by the GCC compiler.
- Download the latest GCC compiler tool according to the link above:
- gcc-arm-none-eabi-4_9-2015q3-20150921-win32.exe, double click to install directly. Note: Remember the installation path, you will need to use it later.
- installing…
- The installation is complete
3. Cygwin tool installation
The installation of the Cygwin tool is to simulate the Linux environment on windows. Because the micro-ecc library is compiled makefile
, make
this tool needs to be installed in order to be able to execute it on windows .
Note: There are many MinGW platforms on the Internet , but if you don't use the circumvention software, the installation speed is slow and the installation is easy to fail. So, I chose Cygwin here .
If you want to use the MinGW platform , you can refer to this blog: "Secure DFU Environment Setup"
-
Download the latest Cygwin tool according to the link above:
-
Double-click the downloaded Cygwin installation file
setup-x86_64.exe
and click下一步
to install it.
-
Choose
Install from Internet
, then下一步
.
-
Select the installation path, and then
下一步
.
-
Choose the connection method
①Use System Proxy Settings
②Direct Connection Generally, most users are directly connected to the network, so they can directly use the default settings
③Use HTTP/FTP Proxy Use HTTP or FTP type proxy. If necessary, select this option and set the corresponding proxy address and port. -
Choose a download site.
Different images store different packages. In order to get the fastest download speed, we can add NetEase open source imageshttp://mirrors.163.com/cygwin/
or Alibaba Cloud imageshttp://mirrors.aliyun.com/cygwin/
-
Mainly install the GNU version make tool. After installing the make tool, you can compile with Makefile on Windows;
-
Installing
-
The installation is complete
-
Verify the development environment: open the Cygwin software, and input
make --version
, the following results are displayed, indicating that the environment is OK.
4. Python tool installation
Because nrfutil
commands are needed to make OTA packages , the nRF Util application is a Python package and command line utility provided by Nordic, which supports device firmware updates (DFU) and encryption functions. Therefore, you need to install the Python tool, and it is recommended to install it Python 2.7
.
-
Download the latest
python 2.7
tool according to the link above :
-
Double click
python-2.7.18.amd64.msi
to install
-
Select the installation path, and then click
NEXT
-
Click on
NEXT
-
installing…
-
Successful installation
-
Add to system environment variables
-
Installation verification, enter in the cmd command line:
python -V
5. Nordic nrfutil tool installation
nrfutil
Commands are needed to make an OTA package . Here, it is installed directly through Python pip, and the installation needs to be connected to the Internet.
- Enter the command on the windows command line to install:
pip install nrfutil
- After the installation is complete, enter
nrfutil version
, as follows, the installation is successful
6.Micro-ecc-master source code download
Nordic will use ECC to verify and authenticate firmware when using DFU for OTA upgrade, so it needs to be produced in the DFU project micro_ecc_lib_nrf52.lib
. How to transplant and compile will be introduced in the next article.
This article only introduces DFU environment setup, and the next article introduces how to use DFU to upgrade firmware via OTA. [Nordic] nRF52810 OTA upgrade (two)-how to use DFU