This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

pynrfjprog/nrf-commandline tools 10.15 on ubuntu 20.04 (native)

Installed pynrfjprog on Ubunto 20.04 (native) via pip. Can open Highlevel api etc, however fails to detect nRF52 dev board as s probe and the logs indicate DLL failure.

pynrfjprog is in stalled in a python3.9 venv environment. Tried both v10.14 and 10.15.

The ubuntu file manager shows the JLink device and I can access the 4 documents/links on the mounted drive.

I also downloaded and installed the Desktop tools by downloading the .zip on Nordic site. extracting and clicking on the .deb file. Install into /opt.

I only need solution for pynrfjprog. In older related posts I saw asked for the below outputs for nrfjprog.

>nrfjprog -i
ERROR: JLinkARM DLL load failed. Try again. If it keeps failing, please
ERROR: reinstall latest JLinkARM from Segger webpage.
NOTE: For additional output, try running again with logging enabled (--log).
NOTE: Any generated log error messages will be displayed.

>strace nrfjprog -i

execve("/usr/local/bin/nrfjprog", ["nrfjprog", "-i"], 0x7ffe22998748 /* 48 vars */) = 0
brk(NULL)                               = 0x55cd9f154000
arch_prctl(0x3001 /* ARCH_??? */, 0x7ffd712bf0a0) = -1 EINVAL (Invalid argument)
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/tls/haswell/avx512_1/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/tls/haswell/avx512_1/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/tls/haswell/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/tls/haswell/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/tls/avx512_1/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/tls/avx512_1/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/tls/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/tls/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/haswell/avx512_1/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/haswell/avx512_1/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/haswell/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/haswell/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/avx512_1/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/avx512_1/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/x86_64/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "'$/'/libdl.so.2", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=60882, ...}) = 0
mmap(NULL, 60882, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f54b5454000

(Truncated the middle part of below output since 100 plus lines)

wait4(110038, 0x7ffd712bd714, WNOHANG, NULL) = -1 ECHILD (No child processes)
--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=110038, si_uid=1001, si_status=0, si_utime=0, si_stime=0} ---
futex(0x7f54b3a4b9d0, FUTEX_WAIT, 110037, NULL) = 0
unlink("/dev/shm/ab59a960-b1dc-4d51-8a5a-db90a232769f-args") = 0
epoll_ctl(5, EPOLL_CTL_DEL, 9, 0x7ffd712bdb40) = 0
close(9)                                = 0
epoll_ctl(5, EPOLL_CTL_DEL, 7, 0x7ffd712bdb40) = 0
close(7)                                = 0
close(5)                                = 0
close(6)                                = 0
close(4)                                = 0
unlink("/dev/shm/ab59a960-b1dc-4d51-8a5a-db90a232769f-log") = 0
unlink("/dev/shm/ab59a960-b1dc-4d51-8a5a-db90a232769f-ack") = -1 ENOENT (No such file or directory)
unlink("/dev/shm/ab59a960-b1dc-4d51-8a5a-db90a232769f-req") = -1 ENOENT (No such file or directory)
munmap(0x7f54b3a4c000, 16777216)        = 0
write(2, "ERROR: JLinkARM DLL load failed."..., 71ERROR: JLinkARM DLL load failed. Try again. If it keeps failing, please) = 71
write(2, "\n", 1
)                       = 1
write(2, "ERROR: reinstall latest JLinkARM"..., 53ERROR: reinstall latest JLinkARM from Segger webpage.) = 53
write(2, "\n", 1
)                       = 1
write(2, "NOTE: For additional output, try"..., 76NOTE: For additional output, try running again with logging enabled (--log).) = 76
write(2, "\n", 1
)                       = 1
write(2, "NOTE: Any generated log error me"..., 57NOTE: Any generated log error messages will be displayed.) = 57
write(2, "\n", 1
)                       = 1
exit_group(32)                          = ?
+++ exited with 32 +++

Parents
  • You also need to do 

    `tar -xvf nrf-command-line-tools-10.15.0_Linux-amd64.tar.gz`

    then `sudo dpkg -i JLink_Linux_V756a_x86_64.deb`  

  • Thanks - the problem was indeed that JLink was not installed.

    When opening the nrf-command-line-tools-10.15.0_amd.zip and clicking on the nrf-command-...amd64.deb file it installed the nrf-command-line-tools portion from the tar archive (incl creating the two symbolic links mentioned in README), but did not recursively install the .deb for Jlink that was contained therein. Since the README was inside the .tar, there was no info about what to do.

Reply
  • Thanks - the problem was indeed that JLink was not installed.

    When opening the nrf-command-line-tools-10.15.0_amd.zip and clicking on the nrf-command-...amd64.deb file it installed the nrf-command-line-tools portion from the tar archive (incl creating the two symbolic links mentioned in README), but did not recursively install the .deb for Jlink that was contained therein. Since the README was inside the .tar, there was no info about what to do.

Children
No Data
Related