PPK2 and Power Profiler desktop: time scale way off

Did a quick search and it seems I am not the only one experiencing this issue Disappointed But can't find a solution.

I just got a PPK2 and started testing some devices (ESP8266). I quickly noticed that the time in the graphs was completely off.
Have a look at this screenshot:

Without even activating the power supply, just starting measuring and stopping 5 seconds later. You can see down in the log:

19:17:20.698	Sampling started
19:17:25.735	Sampling stopped

But if I click on SELECT ALL it says 1.606 seconds
So basically it reports around 1 second for every 3 actual seconds.

It doesn't matter how many samples per second I take, it does it all the time.
Zooming doesn't change anything, it is still wrong.
Tried with 3 different USB ports already both USB2 and USB3, different cables too.
And the DUT I don't think it matters, tried a few already but same problem regardless.

Should I return the unit? Or is it a software error? Any workaround?

System:
Manjaro/KDE
Linux Kernel 6.0.15
AMD Ryzen 5 5600X
16GB RAM
MSI B450 Tomahawk Max II on latest BIOS: 7C02vH9 2022-08-15 (it was happening with a previous BIOS too)

Power Profiler v3.5.3

Edit: tried on windows, same problem.

Edit2: tried on an ancient Intel laptop, with windows, and it works fine. So it is not the hardware, it is the software that is broken. And has been broken for 2 years according to the reports: github.com/.../141

# nRFConnect System Report - 2023-01-20T21-32-39.794Z

- System:     Micro-Star International Co., Ltd MS-7C02
- BIOS:       American Megatrends International, LLC. H.90
- CPU:        1 x AMD Ryzen 5 5600X 6-Core Processor 3.7 GHz 12 cores (6 physical)
- Memory:     10.2 GB free of 15.5 GB total
- Filesystem: S.ficheros (Tipo) 0 Bytes NaN% used

- OS:         ManjaroLinux (22.0.0) linux x64

- Versions
    - kernel: 6.0.15-1-MANJARO
    - git: 2.39.0
    - node: 14.16.0
    - python: 3.10.8
    - python3: 3.10.8
    - nrf-device-lib-js: 0.4.13
    - nrf-device-lib: 0.12.8
    - nrfjprog DLL: Unknown
    - JLink: Unknown

- Connected devices:
    - C455D71461C9 : /dev/ttyACM0

- Current device:
    - name:          
    - serialNumber:  C455D71461C9
    - cores:         Unknown
    - website:       Unknown

Parents
  • I connected it to a USB3 hub and it works fine on my AMD machine.

    I have been experimenting with the python PPK2 API and discovered that just reading a fixed amount of bytes from the serial port takes longer when connected directly compared to the USB hub.

    When connected to the hub:

    Bus 003 Device 023: ID 1915:c00a Nordic Semiconductor ASA PPK2
    reading 8192 bytes took 21.00ms
    reading 8192 bytes took 20.00ms
    reading 8192 bytes took 21.00ms
    reading 8192 bytes took 20.00ms
    reading 8192 bytes took 22.00ms

    When connected directly to one USB port:

    Bus 001 Device 031: ID 1915:c00a Nordic Semiconductor ASA PPK2
    reading 8192 bytes took 64.00ms
    reading 8192 bytes took 64.00ms
    reading 8192 bytes took 64.00ms
    reading 8192 bytes took 64.00ms

    If a sample is 4 bytes this means that:

    • the hub is able to read 2048 samples every 20ish milliseconds. That is a rate of  ~100k samples per second. As expected.
    • when directly connected it reads 2048 samples per 64ms. That is a rate of 32k samples per second. That is only 32% of the theoretical sample rate.

    And if the timing on the graph relies on the 100k theoretical rate, when that rate is in reality only 32% then yeah, 5 seconds would look like only 32% of it, so 1.6 seconds.

    But why does reading take so much longer when connected to a USB port directly compared to having a USB hub in between?

  • Thank you for the detailed description.

    Seems you already found both the cause and workaround for the issuee. I will report this internally to our developers.

    TheBronx said:
    But why does reading take so much longer when connected to a USB port directly compared to having a USB hub in between?

    Not sure. I'll do some research as to why this happens.

    Br,
    Joakim

  • Have you tried on windows? Do you see the same issue there?

    Edit: Just saw that you mentioned windows in the original post.

Reply Children
No Data
Related