This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Error JLINKARM_DLL_ERROR when using Power Profiler

I am getting an error in the Power Profiler ppk.py when it is starting. The error occurs on the first call to nrfjprog.rtt_read. The error is JLINKARM_DLL_ERROR, which is -102.

(Updated) I wrote a similar small Python program to test pynrfprog and I find that the rtt_is_control_block_found() is always returning False.

I am using the software versions specified in the PPK User Guide:

  • Python 2.7.12 (32 bit)
  • nRF5x Command Line Tools (which installs Segger JLink 5.12g)
  • Python packages as installed by 'python_packages.bat', specifically pynrfjprog 9.0.0

I have programmed the DK with PPK_v1_0_0.hex using flash_pkk.py

Here is the cutdown program that fails to find the rtt control block:

import libs.rtt as rtt
import time
from pynrfjprog import API
JLINK_PRO_V8    = 4000

# Always try to have highest speed
JLINK_SPEED_KHZ = JLINK_PRO_V8

nrfjprog = API.API('NRF52')
nrfjprog.open()

nrfjprog.connect_to_emu_without_snr(jlink_speed_khz=JLINK_SPEED_KHZ)
nrfjprog.sys_reset()
nrfjprog.go()
nrfjprog.rtt_start()
time.sleep(1)
print nrfjprog.dll_version()

# It never exits this while() - just prints 'waiting' continuously
while (not nrfjprog.rtt_is_control_block_found()):
  print 'waiting for control block'
  time.sleep(1)

# This fails with JLINKARM_DLL_ERROR if we let it get here
nrfjprog.rtt_read(0,10000, encoding=None)
Parents
  • This block has always worked for me

        self.nrfjprog.sys_reset()
        self.nrfjprog.go()
        self.nrfjprog.rtt_start()
        time.sleep(1)
    
        data = self.nrfjprog.rtt_read(0, 100, encoding=None)
    

    But quite a few people have the ppk software and haven't stumbled into this issue, so it makes me wonder if you have an outdated or failing Segger Jlink installation(?).

Reply
  • This block has always worked for me

        self.nrfjprog.sys_reset()
        self.nrfjprog.go()
        self.nrfjprog.rtt_start()
        time.sleep(1)
    
        data = self.nrfjprog.rtt_read(0, 100, encoding=None)
    

    But quite a few people have the ppk software and haven't stumbled into this issue, so it makes me wonder if you have an outdated or failing Segger Jlink installation(?).

Children
Related