You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
From this point onward, you can now use a simple serial port for firmware
106
113
updates.
107
114
115
+
Note: You can specify other version that are available in the directory `Adafruit_nRF52_Bootloader/bin/feather_nrf52840_express/` . The `VERSION=latest` will use the latest bootloader available.
116
+
108
117
### IMPORTANT: Disable Mass Storage on PCA10056 J-Link
109
118
110
119
The J-Link firmware on the PCA10056 implement USB Mass Storage, but this
@@ -135,31 +144,14 @@ J-Link>exit
135
144
136
145
## Building and Flashing CircuitPython
137
146
138
-
### Installing `nrfutil`
147
+
### Installing `adafruit-nrfutil`
139
148
140
-
If you haven't installed the required command-line tool yet, go to the
141
-
`/libs/nrfutil` folder (where nrfutil 0.5.2b is installed as a sub-module)
142
-
and run the following commands:
143
-
144
-
> If you get a 'sudo: pip: command not found' error running 'sudo pip install',
145
-
you can install pip via 'sudo easy_install pip'
149
+
run follow command to install [adafruit-nrfutil](https://github.com/adafruit/Adafruit_nRF52_nrfutil) from PyPi
146
150
147
151
```
148
-
$ cd ../../lib/nrfutil
149
-
$ sudo pip install -r requirements.txt
150
-
$ sudo python setup.py install
152
+
$ pip3 install adafruit-nrfutil --user
151
153
```
152
154
153
-
#### Changes to `nrfutil` in 0.5.2d
154
-
155
-
**IMPORTANT**: Make sure that you have version **0.5.2d**, since a small
156
-
change was required to `dfu_transport_serial.py` to account for the
157
-
increased minimum flash erase time on the nRF52840 compared to the earlier
158
-
nRF52832!
159
-
160
-
You can also manually change the file with the following new values (lines
161
-
67-68), and reinstall the utility via `sudo python setup.py install`:
162
-
163
155
### Flashing CircuitPython with USB CDC
164
156
165
157
With the serial bootloader present on your board, you first need to force your
@@ -169,8 +161,7 @@ BUTTON1 still pressed as you come out of reset).
169
161
This will give you a **fast blinky DFU pattern** to indicate you are in DFU
170
162
mode.
171
163
172
-
At this point, you can **build and flash** a CircuitPython binary via the following
173
-
command:
164
+
you can **build and flash** a CircuitPython binary via the following command:
174
165
175
166
```
176
167
$ make V=1 SD=s140 SERIAL=/dev/tty.usbmodem1411 BOARD=feather52840 all dfu-gen dfu-flash
@@ -197,19 +188,19 @@ Device programmed.
197
188
198
189
### Flashing CircuitPython with MSC UF2
199
190
200
-
Make `uf2` target to generate the uf2
191
+
uf2 file is generated at the end of `all` target
201
192
202
193
```
203
-
$ make V=1 SD=s140 SERIAL=/dev/tty.usbmodem1411 BOARD=feather52840 all uf2
194
+
$ make V=1 SD=s140 SERIAL=/dev/tty.usbmodem1411 BOARD=feather52840 all
Converting to uf2, output size: 392192, start address: 0x26000
207
198
Wrote 392192 bytes to build-feather52840-s140/firmware.uf2.
208
199
```
209
200
210
201
Simply drag and drop firmware.uf2 to the MSC, the nrf52840 will blink fast and reset after done.
211
202
212
-
**Note**: you need to update `tools/uf2` for uf2conv.py to support hex file input, current circuitpython's master use older verion of uf2conv.py which only support biin file input. To update, change directory to top folder of circuitpython and run. The size of uf2 should be ~400KB, if using the old uf2conv.py the output file would be 1 MB which is not correct.
203
+
**Note**: you need to update `tools/uf2` for uf2conv.py to support hex file input, current circuitpython's master use older verion of uf2conv.py which only support bin file input. To update, change directory to top folder of circuitpython and run. The size of uf2 should be ~400KB, if using the old uf2conv.py the output file would be 1 MB which is not correct.
0 commit comments