Ahh yea looks like you’ve made some changes. I don’t recommend directly committing to the nrf
directory since when you update your changes won’t rebase along with the SDK. I’ll be sharing more about this in my upcoming blog article.
nRF Cloud AGPS Sample - Can't load using newtmgr
I didn’t perform the commit of the changes until this morning, but I had the same Error 3 as yesterday, so maybe that is only part of the problem. Also, I don’t know VSC very well and I definitely don’t know it well as a source control tool. this morning I was just trying to see if anything worked, probably to my demise. I performed the staging and commit so it would add the additional configuration commands, so I guess unfortunately I committed the changes thinking that would fix the issue. Is there a way to undo what i did easily? Or, should I delete the entire nrf directory and re-perform the entire windows setup? If I did that would that create an issue in VCS? As I mentioned above, I don’t know that would solve the issue because when I first ran into Error 3 I hadn’t staged nor committed anything. It was the same process as when I was running blinky, button or fade_led, which all ran okay with just updating the config, running west, establishing the com port, going into DFU mode and then running newtmgr for update bin and reset.
SteveD0 I committed the changes thinking that would fix the issue. Is there a way to undo what i did easily? Or, should I delete the entire nrf directory and re-perform the entire windows setup? If I did that would that create an issue in VCS?
You can always roll back a change with Git by using the git reset
command. I’m a fan of SourceTree which makes navigating things a little easier.
SteveD0 It was the same process as when I was running blinky, button or fade_led, which all ran okay with just updating the config, running west, establishing the com port, going into DFU mode and then running newtmgr for update bin and reset.
Got it. It may be your toolchain which is adding the extra size. What do you get when you run arm-none-eabi-gcc --version
?
PS C:\ncs\nrf> arm-none-eabi-gcc ‘–version’
arm-none-eabi-gcc.exe (GNU Arm Embedded Toolchain 9-2020-q2-update) 9.3.1 20200408 (release)
Copyright © 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
- Edited
What I recommend is you uninstall that version of the toolchain and install this one. I changed the documentation last week to reflect this after testing was causing problems. I would try the AGPS example again with the new toolchain when it’s done.
I’m sorry I’m such a beginner. How do I uninstall the toolchain?
SteveD0 No worries. Go into your Add/Remove programs and look for the Arm Embedded Toolchain. Uninstall it like any other program that you’ve installed on your Windows PC.
Got it - went to programs and applications and I’m now installing it.
Uninstalling!
Got a “404: Not Found” from the link you provided.
Here is the download page link: https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads/9-2019-q4-major for windows 10
SteveD0 Yup that’s the one.
I’m in the process now and I used the setx in the instructions. I still points to the old toolchain "setx ZEPHYR_TOOLCHAIN_VARIANT gnuarmemb
setx GNUARMEMB_TOOLCHAIN_PATH “C:\Program Files (x86)\GNU Arm Embedded Toolchain\9 2020-q2-update”
"
It bombed out in my west build:
PS C:\ncs\nrf\samples\nrf9160\nrf_cloud_agps> west build -b circuitdojo_feather_nrf9160ns
– west build: generating a build system
Including boilerplate (Zephyr base (cached)): C:/ncs/zephyr/cmake/app/boilerplate.cmake
– Application: C:/ncs/nrf/samples/nrf9160/nrf_cloud_agps
– Zephyr version: 2.3.99 (C:/ncs/zephyr)
– Found west: C:/Python39/Scripts/west.exe (found suitable version “0.8.0”, minimum required is “0.7.1”)
– Board: circuitdojo_feather_nrf9160ns
CMake Error at C:/ncs/zephyr/cmake/toolchain/gnuarmemb/generic.cmake:16 (message):
Nothing found at GNUARMEMB_TOOLCHAIN_PATH: ’C:/Program Files (x86)/GNU Arm
Embedded Toolchain/9 2020-q2-update’
Call Stack (most recent call first):
C:/ncs/zephyr/cmake/generic_toolchain.cmake:64 (include)
C:/ncs/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:24 (include)
C:/ncs/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:40 (include_boilerplate)
CMakeLists.txt:9 (find_package)
– Configuring incomplete, errors occurred!
FATAL ERROR: command exited with status 1: ‘C:\Program Files\CMake\bin\cmake.EXE’ ‘-DWEST_PYTHON=c:\python39\python.exe’ ‘-BC:\ncs\nrf\samples\nrf9160\nrf_cloud_agps\build’ ‘-SC:\ncs\nrf\samples\nrf9160\nrf_cloud_agps’ -GNinja
I’m going to go back and fix mine now…
I NOW HAVE THE RIGHT TOOLCHAIN INSTALLED:
C:\Program Files (x86)\GNU Tools Arm Embedded\9 2019-q4-major>setx ZEPHYR_TOOLCHAIN_VARIANT gnuarmemb
SUCCESS: Specified value was saved.
C:\Program Files (x86)\GNU Tools Arm Embedded\9 2019-q4-major>setx GNUARMEMB_TOOLCHAIN_PATH “C:\Program Files (x86)\GNU Arm Embedded Toolchain\9 2020-q2-update”
SUCCESS: Specified value was saved.
C:\Program Files (x86)\GNU Tools Arm Embedded\9 2019-q4-major>arm-none-eabi-gcc –version
arm-none-eabi-gcc (GNU Tools for Arm Embedded Processors 9-2019-q4-major) 9.2.1 20191025 (release) [ARM/arm-9-branch revision 277599]
Copyright © 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
C:\Program Files (x86)\GNU Tools Arm Embedded\9 2019-q4-major>
BUT WHEN I RUN WEST I GET THIS ERROR:
Windows PowerShell
Copyright © Microsoft Corporation. All rights reserved.
Try the new cross-platform PowerShell https://aka.ms/pscore6
PS C:\ncs\nrf\samples\nrf9160\nrf_cloud_agps> west build -b circuitdojo_feather_nrf9160ns -p
– west build: making build dir C:\ncs\nrf\samples\nrf9160\nrf_cloud_agps\build pristine
– west build: generating a build system
Including boilerplate (Zephyr base): C:/ncs/zephyr/cmake/app/boilerplate.cmake
– Application: C:/ncs/nrf/samples/nrf9160/nrf_cloud_agps
– Zephyr version: 2.3.99 (C:/ncs/zephyr)
– Found Python3: C:/Python39/python.exe (found suitable exact version “3.9.0”) found components: Interpreter
– Found west: C:/Python39/Scripts/west.exe (found suitable version “0.8.0”, minimum required is “0.7.1”)
– Board: circuitdojo_feather_nrf9160ns
CMake Error at C:/ncs/zephyr/cmake/toolchain/gnuarmemb/generic.cmake:16 (message):
Nothing found at GNUARMEMB_TOOLCHAIN_PATH: ’C:/Program Files (x86)/GNU Arm
Embedded Toolchain/9 2020-q2-update’
Call Stack (most recent call first):
C:/ncs/zephyr/cmake/generic_toolchain.cmake:64 (include)
C:/ncs/zephyr/cmake/app/boilerplate.cmake:527 (include)
C:/ncs/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:24 (include)
C:/ncs/zephyr/share/zephyr-package/cmake/ZephyrConfig.cmake:35 (include_boilerplate)
CMakeLists.txt:9 (find_package)
– Configuring incomplete, errors occurred!
FATAL ERROR: command exited with status 1: ‘C:\Program Files\CMake\bin\cmake.EXE’ ‘-DWEST_PYTHON=c:\python39\python.exe’ ‘-BC:\ncs\nrf\samples\nrf9160\nrf_cloud_agps\build’ ‘-SC:\ncs\nrf\samples\nrf9160\nrf_cloud_agps’ -GNinja -DBOARD=circuitdojo_feather_nrf9160ns
PS C:\ncs\nrf\samples\nrf9160\nrf_cloud_agps>
I’M NOT SURE WHERE THIS ISSUE IS….
Looks like the setx is not quite right:
Here is mine: C:\Program Files (x86)\GNU Tools Arm Embedded\9 2019-q4-major
Changed my environment variables for the GNUARMEMB_TOOLCHAIN_PATH to C:\Program Files (x86)\GNU Tools Arm Embedded\9 2019-q4-major
Ran newtmgr:
PS C:\ncs\nrf\samples\nrf9160\nrf_cloud_agps> newtmgr
newtmgr -c serial image upload build/zephyr/app_update.bin
190.93 KiB / 190.93 KiB [==========================================================================================================] 100.00% 15.80 KiB/s 12s
Done
WORKED!! Tomorrow I’ll focus on setting up nRF Connect for Cloud. Thanks for all the help!
SteveD0 woohoo! Sorry about the documentation issue. I missed that one. Glad it’s working though!
No worries. Overall your documentation is fantastic! The tiny glitches help us all to learn better. Thank you!